1
0
mirror of https://github.com/QSCTech/zjunet.git synced 2026-01-22 11:44:48 +08:00

new build.sh for openwrt

This commit is contained in:
Zeno Zeng 2014-09-30 19:13:43 +08:00
parent f5a1b9aaaa
commit eb77a6953a
7 changed files with 22 additions and 21 deletions

3
.gitignore vendored
View File

@ -1 +1,2 @@
*.deb
*.deb
*.ipk

View File

@ -16,7 +16,7 @@ cp control debian/DEBIAN
# dpkg-deb
dpkg-deb --build debian
mv debian.deb zjunet_0.1-1_all.deb
mv debian.deb zjunet_0.1-2_all.deb
# remove debian/
rm -rf ./debian

View File

@ -1,5 +1,5 @@
Package: zjunet
Version: 0.1-1
Version: 0.1-2
Section: base
Priority: optional
Architecture: all
@ -7,3 +7,4 @@ Depends: xl2tpd (>= 1.3.2), curl, libc-bin
Maintainer: Zeno Zeng <zenoofzeng@gmail.com>
Description: Command Line Scripts for ZJU
This script provides a VPN / WLAN / NEXTHOP for ZJUer.

View File

@ -1,9 +1,23 @@
#!/bin/sh
VERSION=0.1-2
# lib
mkdir -p ./debian/usr/lib/zjunet
cp ../../lib/* ./debian/usr/lib/zjunet
cat > control <<EOF
Package: zjunet
Version: $VERSION
Section: base
Priority: optional
Architecture: all
Depends: xl2tpd (>= 1.3.1), curl
Maintainer: Zeno Zeng <zenoofzeng@gmail.com>
Description: Command Line Scripts for ZJU
This script provides a VPN / WLAN / NEXTHOP for ZJUer.
EOF
# bin
mkdir -p ./debian/usr/bin
echo '/usr/lib/zjunet/zjunet.sh "$@"' >> ./debian/usr/bin/zjunet
@ -12,11 +26,12 @@ chmod +x ./debian/usr/bin/zjunet
# contorl file
mkdir -p debian/DEBIAN
find ./debian -type d | xargs chmod 755
cp control/* debian/DEBIAN
cp control debian/DEBIAN
# dpkg-deb
dpkg-deb --build debian
mv debian.deb zjunet_0.1-1_all.deb
mv debian.deb zjunet_${VERSION}_all.ipk
# remove debian/
rm -rf ./debian
rm -rf control

View File

@ -1,9 +0,0 @@
Package: zjunet
Version: 0.1-1
Section: base
Priority: optional
Architecture: all
Depends: xl2tpd (>= 1.3.1), curl
Maintainer: Zeno Zeng <zenoofzeng@gmail.com>
Description: Command Line Scripts for ZJU
This script provides a VPN / WLAN / NEXTHOP for ZJUer.

View File

@ -1,4 +0,0 @@
#!/bin/sh
[ "${IPKG_NO_SCRIPT}" = "1" ] && exit 0
. ${IPKG_INSTROOT}/lib/functions.sh
default_postinst $0 $@

View File

@ -1,3 +0,0 @@
#!/bin/sh
. ${IPKG_INSTROOT}/lib/functions.sh
default_prerm $0 $@