2021-06-03 04:59:01 +08:00
|
|
|
<package-info :package="package" instsize showsbu2></package-info>
|
2021-05-11 15:29:05 +08:00
|
|
|
|
|
|
|
<script>
|
|
|
|
new Vue({
|
|
|
|
el: '#main',
|
|
|
|
data: { package: {} },
|
|
|
|
mounted: function () {
|
|
|
|
this.getPackage('libcap');
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
getPackage: function(name) {
|
|
|
|
getPackage(name)
|
|
|
|
.then(response => this.package = response);
|
|
|
|
},
|
|
|
|
}
|
|
|
|
})
|
|
|
|
</script>
|
|
|
|
|
|
|
|
## Подготовка
|
|
|
|
|
|
|
|
Отключите установку статических библиотек:
|
|
|
|
|
|
|
|
```bash
|
|
|
|
sed -i '/install -m.*STA/d' libcap/Makefile
|
|
|
|
```
|
|
|
|
|
|
|
|
## Сборка
|
|
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
make prefix=/usr lib=lib
|
|
|
|
```
|
|
|
|
## Тестирование
|
|
|
|
|
|
|
|
```bash
|
|
|
|
make test
|
|
|
|
```
|
|
|
|
|
|
|
|
## Установка
|
|
|
|
|
|
|
|
```bash
|
|
|
|
make prefix=/usr lib=lib install
|
|
|
|
```
|
|
|
|
|
|
|
|
Установите корректные права для библиотек:
|
|
|
|
|
|
|
|
```bash
|
2021-05-30 13:34:26 +08:00
|
|
|
chmod -v 755 /usr/lib/lib{cap,psx}.so.2
|
2021-05-11 15:29:05 +08:00
|
|
|
```
|
|
|
|
|
|
|
|
## Для multilib
|
|
|
|
|
|
|
|
### Очистка
|
|
|
|
|
|
|
|
```bash
|
|
|
|
make distclean
|
|
|
|
```
|
|
|
|
|
|
|
|
### Сборка
|
|
|
|
|
|
|
|
```bash
|
|
|
|
make CC="gcc -m32 -march=i686"
|
|
|
|
```
|
|
|
|
|
|
|
|
### Установка
|
|
|
|
|
|
|
|
```bash
|
|
|
|
make lib=lib32 prefix=$PWD/DESTDIR/usr -C libcap install
|
|
|
|
cp -Rv DESTDIR/usr/lib32/* /usr/lib32
|
|
|
|
sed -e "s|^libdir=.*|libdir=/usr/lib32|" -i /usr/lib32/pkgconfig/lib{cap,psx}.pc
|
2021-05-30 13:34:26 +08:00
|
|
|
chmod -v 755 /usr/lib32/lib{cap,psx}.so.2
|
2021-05-11 15:29:05 +08:00
|
|
|
rm -rf DESTDIR
|
|
|
|
```
|
|
|
|
|
|
|
|
## Установленные файлы
|
|
|
|
|
|
|
|
Программы: capsh, getcap, getpcaps и setcap
|
|
|
|
|
|
|
|
Библиотеки: libcap.so и libpsx.so
|
|
|
|
|