-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbluez
More file actions
52 lines (35 loc) · 1.09 KB
/
bluez
File metadata and controls
52 lines (35 loc) · 1.09 KB
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#!/bin/bash
export CFLAGS=-"O2"
export CXXFLAGS="-O2"
PKG_VER=5.86
URL=https://www.kernel.org/pub/linux/bluetooth/bluez-$PKG_VER.tar.xz
TAR=$(echo $URL | sed -r 's|(.*)/||')
DIR=$(echo $TAR | sed 's|.tar.*||g')
PACKAGE=$(echo $DIR | sed 's|-[^-]*$||g')
# Get Package
cd /blfs/builds
wget $URL
tar -xvf $TAR
cd $DIR
# Build
./configure --prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--disable-manpages \
--enable-library
make
# Install
sudo make DESTDIR=/pkgs/$PACKAGE install
mkdir -p /pkgs/$PACKAGE/usr/sbin
ln -svf ../libexec/bluetooth/bluetoothd /pkgs/$PACKAGE/usr/sbin
install -v -dm755 /pkgs/$PACKAGE/etc/bluetooth &&
install -v -m644 src/main.conf /pkgs/$PACKAGE/etc/bluetooth/main.conf
cd /pkgs
sudo echo "dbus glib libical" > /pkgs/$PACKAGE/depends
sudo echo "systemctl enable bluetooth" > /pkgs/$PACKAGE/postinst
sudo echo "" > /pkgs/$PACKAGE/make-depends
sudo echo "$PKG_VER" > /pkgs/$PACKAGE/version
sudo tar -cvapf $PACKAGE.tar.xz $PACKAGE
sudo cp $PACKAGE.tar.xz /finished
cd /blfs/builds
sudo rm -r $DIR