mirror of
https://github.com/UnnoTed/wireguird
synced 2025-02-05 17:25:30 +00:00
void: xbps package
This commit is contained in:
parent
4b2afa6154
commit
7eef84e127
@ -7,5 +7,8 @@ if [[ -f "/etc/os-release" ]]; then
|
||||
elif [[ "${ID}" == "ubuntu" ]]; then
|
||||
echo "deb package"
|
||||
./package_deb.sh
|
||||
elif [[ "${ID}" == "void" ]]; then
|
||||
echo "xbps package"
|
||||
./package_xbps.sh
|
||||
fi
|
||||
fi
|
||||
|
33
package_xbps.sh
Executable file
33
package_xbps.sh
Executable file
@ -0,0 +1,33 @@
|
||||
echo "wireguird: cleaning..."
|
||||
|
||||
opt_w_dir="./deb/opt/wireguird/"
|
||||
if [ -e "$opt_w_dir" ]; then
|
||||
rm -r "$opt_w_dir"
|
||||
fi
|
||||
|
||||
mkdir -p "$opt_w_dir"
|
||||
|
||||
echo "wireguird: building go binary..."
|
||||
time {
|
||||
go generate
|
||||
go build -ldflags "-s -w" -trimpath -o "$opt_w_dir""wireguird" -p $(nproc) -v -x
|
||||
}
|
||||
|
||||
echo "wireguird: copying icons..."
|
||||
cp -r ./Icon/ "$opt_w_dir"
|
||||
|
||||
echo "wireguird: building xbps package..."
|
||||
|
||||
touch "$opt_w_dir""wireguird.settings"
|
||||
|
||||
if [ ! -d "./build/" ]; then
|
||||
mkdir ./build/
|
||||
fi
|
||||
|
||||
xbps-create \
|
||||
-A noarch \
|
||||
-n wireguird-1.0_1 \
|
||||
-s "wireguard gtk gui for linux" \
|
||||
./deb
|
||||
|
||||
echo "wireguird: done"
|
Loading…
Reference in New Issue
Block a user