aboutsummaryrefslogtreecommitdiff
path: root/share/hoarder/xbps/unix/install
blob: 854dbff1d9b1017a7465c4dd5939d73da8c3cad6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#!/usr/bin/env sh
#
# Install XBPS package manager.
#
# Parameters
SHARE="$1"
LIB="$2"
DESTDIR="$HOME/.xbps"

# Include basic functions
. $LIB/trashman/functions || exit 1

# Check for curl
if ! which make > /dev/null 2>&1; then
  trashman_echo "Needs make to install XBPS"
  exit 1
fi

# Source folder
mkdir -p $HOME/.local/src

# Build and install
git clone https://github.com/void-linux/xbps $HOME/.local/src || exit 1
cd $HOME/.local/src/xbps                                      || exit 1
./configure --enable-rpath --prefix=/usr --sysconfdir=/etc    || exit 1
make -j$(nproc)                                               || exit 1
make DESTDIR=$DESTDIR install clean                           || exit 1

# Remove source
#rm -rf $HOME/.local/src/xbps