1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/lxd_ynh.git synced 2024-09-03 19:45:53 +02:00

fix install

This commit is contained in:
Kay0u 2021-09-06 15:17:18 +02:00
parent 77eb7a1488
commit 66671d0a0d
No known key found for this signature in database
GPG key ID: AAFEEB16CFA2AE2D
3 changed files with 11 additions and 15 deletions

View file

@ -5,7 +5,7 @@
#=================================================
# dependencies used by the app
pkg_dependencies="acl autoconf dnsmasq-base git libacl1-dev libcap-dev liblxc1 lxc-dev libsqlite3-dev libtool libudev-dev libuv1-dev make pkg-config rsync squashfs-tools tar tcl xz-utils ebtables libapparmor-dev libseccomp-dev libcap-dev liblz4-dev lvm2 thin-provisioning-tools btrfs-progs"
pkg_dependencies="acl attr autoconf dnsmasq-base git libacl1-dev libcap-dev liblxc1 lxc-dev libsqlite3-dev libtool libudev-dev liblz4-dev libuv1-dev make pkg-config rsync squashfs-tools tar tcl xz-utils ebtables libapparmor-dev libseccomp-dev libcap-dev lvm2 thin-provisioning-tools btrfs-progs"
#=================================================
# PERSONAL HELPERS

View file

@ -56,7 +56,7 @@ export PATH=$go_tmp/bin:$PATH
lxd_tmp=$(mktemp -d)
ynh_setup_source --dest_dir="$lxd_tmp" --source_id="lxd"
export GOPATH=${lxd_tmp}/_dist
export GOPATH=${lxd_tmp}/vendor/
#=================================================
# BUILD FROM SOURCES
@ -66,19 +66,16 @@ ynh_script_progression --message="Building lxd from sources..." --weight=60
pushd ${lxd_tmp}
ynh_exec_warn_less make deps
export CGO_CFLAGS="-I${GOPATH}/deps/raft/include/ -I${GOPATH}/deps/dqlite/include/"
export CGO_LDFLAGS="-L${GOPATH}/deps/raft/.libs -L${GOPATH}/deps/dqlite/.libs/"
export LD_LIBRARY_PATH="${GOPATH}/deps/raft/.libs/:${GOPATH}/deps/dqlite/.libs/"
export CGO_CFLAGS="-I${GOPATH}/raft/include/ -I${GOPATH}/dqlite/include/"
export CGO_LDFLAGS="-L${GOPATH}/raft/.libs -L${GOPATH}/dqlite/.libs/"
export LD_LIBRARY_PATH="${GOPATH}/raft/.libs/:${GOPATH}/dqlite/.libs/"
export CGO_LDFLAGS_ALLOW="(-Wl,-wrap,pthread_create)|(-Wl,-z,now)"
cd $GOPATH/src/github.com/lxc/lxd
export GOCACHE=$go_tmp
ynh_exec_warn_less make
mkdir -p /usr/local/lib/$app
mkdir -p /var/log/$app
cp -a ${GOPATH}/deps/{raft,dqlite}/.libs/lib*.so* /usr/local/lib/$app/
cp -a ${GOPATH}/{raft,dqlite}/.libs/lib*.so* /usr/local/lib/$app/
cp ${GOPATH}/bin/{lxc,lxd,lxc-to-lxd,lxd-p2c} /usr/local/bin
cp ${lxd_tmp}/scripts/bash/lxd-client /etc/bash_completion.d/
popd

View file

@ -71,7 +71,7 @@ export PATH=$go_tmp/bin:$PATH
lxd_tmp=$(mktemp -d)
ynh_setup_source --dest_dir="$lxd_tmp" --source_id="lxd"
export GOPATH=${lxd_tmp}/_dist
export GOPATH=${lxd_tmp}/vendor/
#=================================================
# BUILD FROM SOURCES
@ -81,11 +81,10 @@ ynh_script_progression --message="Building lxd from sources..." --weight=60
pushd ${lxd_tmp}
ynh_exec_warn_less make deps
export CGO_CFLAGS="-I${GOPATH}/deps/raft/include/ -I${GOPATH}/deps/dqlite/include/"
export CGO_LDFLAGS="-L${GOPATH}/deps/raft/.libs -L${GOPATH}/deps/dqlite/.libs/"
export LD_LIBRARY_PATH="${GOPATH}/deps/raft/.libs/:${GOPATH}/deps/dqlite/.libs/"
export CGO_CFLAGS="-I${GOPATH}/raft/include/ -I${GOPATH}/dqlite/include/"
export CGO_LDFLAGS="-L${GOPATH}/raft/.libs -L${GOPATH}/dqlite/.libs/"
export LD_LIBRARY_PATH="${GOPATH}/raft/.libs/:${GOPATH}/dqlite/.libs/"
export CGO_LDFLAGS_ALLOW="(-Wl,-wrap,pthread_create)|(-Wl,-z,now)"
cd $GOPATH/src/github.com/lxc/lxd
export GOCACHE=$go_tmp
@ -93,7 +92,7 @@ ynh_exec_warn_less make
mkdir -p /usr/local/lib/$app
mkdir -p /var/log/$app
cp -a ${GOPATH}/deps/{raft,dqlite}/.libs/lib*.so* /usr/local/lib/$app/
cp -a ${GOPATH}/{raft,dqlite}/.libs/lib*.so* /usr/local/lib/$app/
cp ${GOPATH}/bin/{lxc,lxd,lxc-to-lxd,lxd-p2c} /usr/local/bin
cp ${lxd_tmp}/scripts/bash/lxd-client /etc/bash_completion.d/
popd