1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2024-11-23 01:49:53 +03:00

Merge PR #579: debian: resolve "nonexistent" path in packaging

This commit is contained in:
Davide Beatrici 2018-07-25 23:32:16 +02:00 committed by GitHub
commit 19f08ae96e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 28 additions and 45 deletions

19
debian/makefile.patch vendored
View File

@ -1,19 +0,0 @@
--- Makefile 2014-02-04 21:20:33.422762017 +0000
+++ Makefile.old 2014-02-04 21:20:10.298761727 +0000
@@ -32,11 +32,11 @@
OPTIONS_LINK_RELEASE=-O2 -fsigned-char -m64 -lm -ldl -lrt -lpthread -lssl -lcrypto -lreadline -lncurses -lz
-INSTALL_BINDIR=/usr/bin/
-INSTALL_VPNSERVER_DIR=/usr/vpnserver/
-INSTALL_VPNBRIDGE_DIR=/usr/vpnbridge/
-INSTALL_VPNCLIENT_DIR=/usr/vpnclient/
-INSTALL_VPNCMD_DIR=/usr/vpncmd/
+INSTALL_BINDIR=usr/bin/
+INSTALL_VPNSERVER_DIR=usr/vpnserver/
+INSTALL_VPNBRIDGE_DIR=usr/vpnbridge/
+INSTALL_VPNCLIENT_DIR=usr/vpnclient/
+INSTALL_VPNCMD_DIR=usr/vpncmd/
ifeq ($(DEBUG),YES)
OPTIONS_COMPILE=$(OPTIONS_COMPILE_DEBUG)

30
debian/rules vendored
View File

@ -1,29 +1,23 @@
#!/usr/bin/make -f #!/usr/bin/make -f
define generate_stub
echo '#!/bin/sh' > debian/usr/bin/$(1)
echo '/usr/libexec/softether/$(1)/$(1) "$@"' >> debian/usr/bin/$(1)
echo 'exit $?' >> debian/usr/bin/$(1)
chmod +x debian/usr/bin/$(1)
endef
export DH_VERBOSE=1 export DH_VERBOSE=1
export CMAKE_INSTALL_PREFIX=`pwd`/../../usr export export CMAKE_INSTALL_PREFIX=../debian/usr
CFLAGS := $(shell dpkg-buildflags --get CFLAGS)
LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS)
%: %:
dh $@ dh $@
override_dh_auto_configure: configure_config
override_dh_auto_make: override_dh_auto_make:
make -C tmp make -C tmp
override_dh_auto_clean:
rm -fr Makefile* usr bin tmp src/bin/BuiltHamcoreFiles
override_dh_auto_install: override_dh_auto_install:
make -C tmp install $(call generate_stub,vpnserver)
$(call generate_stub,vpnbridge)
configure_config: $(call generate_stub,vpncmd)
if [ $(shell uname -m) = 'x86_64' ]; then echo -e "1\n2\n" | ./configure; fi $(call generate_stub,vpnclient)
if [ $(shell uname -m) = 'i686' ]; then echo -e "1\n1\n" | ./configure; fi
if [ $(shell uname -m) = 'armv6l' ]; then echo -e "1\n1\n" | ./configure; fi
if [ $(shell uname -m) = 'armv5tel' ]; then echo -e "1\n1\n" | ./configure; fi
if [ $(shell uname -m) = 'aarch64' ]; then echo -e "1\n2\n" | ./configure; fi
if [ $(shell uname -m) = 'armv7l' ]; then echo -e "1\n1\n" | ./configure; fi

6
debian/softether-vpnbridge.install vendored Executable file → Normal file
View File

@ -1,3 +1,5 @@
#! /usr/bin/dh-exec #! /usr/bin/dh-exec
debian/bin/vpnbridge usr/bin/ debian/usr/libexec/softether/vpnbridge/vpnbridge usr/libexec/softether/vpnbridge/
usr/bin/vpnbridge opt/ debian/usr/libexec/softether/vpnbridge/hamcore.se2 usr/libexec/softether/vpnbridge/
debian/usr/bin/vpnbridge usr/bin/

6
debian/softether-vpnclient.install vendored Executable file → Normal file
View File

@ -1,3 +1,5 @@
#! /usr/bin/dh-exec #! /usr/bin/dh-exec
debian/bin/vpnclient usr/bin/ debian/usr/libexec/softether/vpnclient/vpnclient usr/libexec/softether/vpnclient/
usr/bin/vpnclient opt/ debian/usr/libexec/softether/vpnclient/hamcore.se2 usr/libexec/softether/vpnclient/
debian/usr/bin/vpnclient usr/bin/

6
debian/softether-vpncmd.install vendored Executable file → Normal file
View File

@ -1,3 +1,5 @@
#! /usr/bin/dh-exec #! /usr/bin/dh-exec
debian/bin/vpncmd usr/bin/ debian/usr/libexec/softether/vpncmd/vpncmd usr/libexec/softether/vpncmd/
usr/bin/vpncmd opt/ debian/usr/libexec/softether/vpncmd/hamcore.se2 usr/libexec/softether/vpncmd/
debian/usr/bin/vpncmd usr/bin/

6
debian/softether-vpnserver.install vendored Executable file → Normal file
View File

@ -1,3 +1,5 @@
#! /usr/bin/dh-exec #! /usr/bin/dh-exec
debian/bin/vpnserver usr/bin/ debian/usr/libexec/softether/vpnserver/vpnserver usr/libexec/softether/vpnserver/
usr/bin/vpnserver opt/ debian/usr/libexec/softether/vpnserver/hamcore.se2 usr/libexec/softether/vpnserver/
debian/usr/bin/vpnserver usr/bin/