Commit c074cad4 authored by Anders Blomdell's avatar Anders Blomdell
Browse files

Fix java build path

parent bdfcda54
......@@ -8,8 +8,9 @@ JAVAH_PATH=$(shell javah -Xbootclasspath/p:build -version >/dev/null 2>&1 && \
JNI_INCLUDE=/usr/lib/jvm/java/include/
CC=gcc
CC_JNI_FLAGS=-Wall -Werror -shared -fPIC \
-I$(JNI_INCLUDE) -I$(JNI_INCLUDE)/linux -Ibuild \
-lmoberg
-I$(JNI_INCLUDE) -I$(JNI_INCLUDE)/linux \
-I../../ -Ibuild \
-L../../build -lmoberg
JAVADIR=/tmp
INSTALL_DIR=$(JAVADIR)/$(JARNAME)
JAR_DIR=$(INSTALL_DIR)/jre/lib/ext/
......
......@@ -30,6 +30,13 @@ Requires: %{name} = %{version}-%{release}
%description devel
Development files for %{name}
%package java
Summary: Java support files for %{name}
Requires: %{name} = %{version}-%{release}
%description java
Java support files for %{name}
%package matlab
Summary: Matlab support files for %{name}
Requires: %{name} = %{version}-%{release}
......@@ -38,13 +45,6 @@ Requires: %{name}-devel = %{version}-%{release}
%description matlab
Matlab support files for %{name}
%package java
Summary: Java support files for %{name}
Requires: %{name} = %{version}-%{release}
%description java
Java support files for %{name}
%prep
%setup -q -n %{name}-__MOBERG_VERSION__
......@@ -65,6 +65,11 @@ cp build/libmoberg*.so ${RPM_BUILD_ROOT}%{_libdir}
mkdir -p ${RPM_BUILD_ROOT}%{_includedir}
cp moberg.h ${RPM_BUILD_ROOT}%{_includedir}
mkdir -p ${RPM_BUILD_ROOT}/opt/java/se.lth.control.realtime.Moberg
cp adaptors/java/README ${RPM_BUILD_ROOT}/opt/java/se.lth.control.realtime.Moberg
cp -r adaptors/java/src ${RPM_BUILD_ROOT}/opt/java/se.lth.control.realtime.Moberg/src
cp -r adaptors/java/build ${RPM_BUILD_ROOT}/opt/java/se.lth.control.realtime.Moberg/jre
mkdir -p ${RPM_BUILD_ROOT}/opt/matlab/src/moberg
mkdir -p ${RPM_BUILD_ROOT}%{_includedir}
cp adaptors/matlab/moberg4simulink.h ${RPM_BUILD_ROOT}%{_includedir}
......@@ -86,6 +91,10 @@ cp adaptors/matlab/Makefile.mex ${RPM_BUILD_ROOT}/opt/matlab/src/moberg/Makefile
%defattr(-,root,root,-)
%{_includedir}/moberg.h
%files java
%defattr(-,root,root,-)
/opt/java/se.lth.control.realtime.Moberg
%files matlab
%defattr(-,root,root,-)
%{_libdir}/libmoberg4simulink.so
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment