Simplify debian rules file and generator script
authorHenning Rogge <henning.rogge@fkie.fraunhofer.de>
Thu, 11 Feb 2016 09:59:35 +0000 (10:59 +0100)
committerHenning Rogge <henning.rogge@fkie.fraunhofer.de>
Thu, 11 Feb 2016 09:59:35 +0000 (10:59 +0100)
files/create_debian_package.sh
src/olsrd2/debian/rules

index e4c1526..bba0223 100755 (executable)
@@ -84,17 +84,13 @@ cp -r ${SOURCE}/src/${TARGET}/debian ./
 cp ${SOURCE}/files/default_licence.txt ./debian/copyright
 
 # adapt changelog template
-sed -i  -e "s@SHORTVERSION@${VERSION}@" \
-        -e "s@FULLVERSION@${FULLVERSION}@" \
-        -e "s@DATETIME@`date -R`@" \
-        ./debian/changelog
+sed -i -e "s@SHORTVERSION@${VERSION}@" \
+       -e "s@FULLVERSION@${FULLVERSION}@" \
+       -e "s@DATETIME@`date -R`@" \
+       ./debian/changelog
 
 # adapt rules template
-sed -i  -e "s@SOURCEDIR@${BUILDDIR}/${TARPREFIX}@" \
-        -e "s@SOURCETOOLCHAIN@${TOOLCHAIN}@" \
-        -e "s@TARGETNAME@${TARGET}@" \
-        -e "s@INSTALLDESTDIR@${BUILDDIR}/${TARPREFIX}/debian/${TARGET}@" \
-        ./debian/rules
+sed -i -e "s@SOURCETOOLCHAIN@${TOOLCHAIN}@" ./debian/rules
 
 # create debian package
 debuild -us -uc ${ARCH}
index a9d5a13..0e43c6b 100644 (file)
@@ -9,8 +9,8 @@ override_dh_auto_configure:
                -D OONF_LOGGING_LEVEL=debug \
                -D OONF_NO_WERROR:Bool=true \
                SOURCETOOLCHAIN \
-               SOURCEDIR
+               $(CURDIR)
 
 override_dh_auto_install:
-       make -j1 install_TARGETNAME_static DESTDIR=INSTALLDESTDIR AM_UPDATE_INFO_DIR=no
+       make -j1 install_olsrd2_static DESTDIR=$(CURDIR)/debian/olsrd2 AM_UPDATE_INFO_DIR=no
        install -p -m0644 $(CURDIR)/debian/olsrd2.conf $(CURDIR)/debian/olsrd2/etc/olsrd2/olsrd2.conf