source: debian/rules @ af54166

Last change on this file since af54166 was af54166, checked in by HungryHobo <HungryHobo@…>, 10 years ago

Add get-orig-source rule as required by Ubuntu, see https://wiki.ubuntu.com/UbuntuDevelopment/CodeReviews#NewPackage

  • Property mode set to 100755
File size: 1.6 KB
Line 
1#!/usr/bin/make -f
2
3VERSION=`grep String\ VERSION core/java/src/net/i2p/CoreVersion.java | cut -d\" -f2`
4SOURCEURL=http://mirror.i2p2.de/i2psource_${VERSION}.tar.bz2
5
6build:
7        ant preppkg-linux-only
8        mkdir -p debian/tmp/usr/lib
9        mkdir -p debian/tmp/etc/init.d
10        cp -a debian/scripts/init debian/tmp/etc/init.d/i2p
11        cp -a pkg-temp debian/tmp/usr/lib/i2p
12        chmod +x debian/tmp/usr/lib/i2p/postinstall.sh
13        sed 's|$$INSTALL_PATH|/usr/lib/i2p|g' debian/tmp/usr/lib/i2p/wrapper.config > debian/tmp/usr/lib/i2p/a
14        sed 's|$$SYSTEM_java_io_tmpdir|/tmp|g' debian/tmp/usr/lib/i2p/a > debian/tmp/usr/lib/i2p/wrapper.config
15        mkdir -p debian/tmp/usr/bin
16        sed 's|%INSTALL_PATH|/usr/lib/i2p|g' debian/tmp/usr/lib/i2p/eepget > debian/tmp/usr/lib/i2p/a
17        mv debian/tmp/usr/lib/i2p/a debian/tmp/usr/lib/i2p/eepget
18        ln -s /usr/lib/i2p/eepget debian/tmp/usr/bin/eepget
19        sed 's|%INSTALL_PATH|/usr/lib/i2p|g' debian/tmp/usr/lib/i2p/runplain.sh > debian/tmp/usr/lib/i2p/a
20        sed 's|%SYSTEM_java_io_tmpdir|/tmp|g' debian/tmp/usr/lib/i2p/a > debian/tmp/usr/lib/i2p/runplain.sh
21        sed 's|%INSTALL_PATH|/usr/lib/i2p|g' debian/tmp/usr/lib/i2p/i2prouter > debian/tmp/usr/lib/i2p/a
22        sed 's|%SYSTEM_java_io_tmpdir|/tmp|g' debian/tmp/usr/lib/i2p/a > debian/tmp/usr/lib/i2p/i2prouter
23        ln -s /usr/lib/i2p/i2prouter debian/tmp/usr/bin/i2prouter
24        rm debian/tmp/usr/lib/i2p/a
25        touch debian/build
26
27binary: build
28        mkdir -p debian/tmp/DEBIAN
29        dpkg-gencontrol
30        cp -a debian/scripts/postinst debian/scripts/postrm debian/scripts/prerm debian/tmp/DEBIAN
31        dpkg-deb -b debian/tmp ..
32
33clean:
34        rm -f debian/build
35        rm -rf debian/tmp/
36        ant distclean
37        @exit 0
38
39get-orig-source:
40        wget ${SOURCEURL}
Note: See TracBrowser for help on using the repository browser.