This repository has been archived by the owner on Sep 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpackage.yml
59 lines (56 loc) · 1.89 KB
/
package.yml
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
51
52
53
54
55
56
57
58
59
name : vhba-module
version : '20211218'
release : 224
source :
- https://sourceforge.net/projects/cdemu/files/vhba-module/vhba-module-20211218.tar.xz/download : 72c5a8c1c452805e4cef8cafefcecc2d25ce197ae4c67383082802e5adcd77b6
license : GPL-2.0-or-later
component :
- kernel.drivers
- current : kernel.drivers
summary : Provides the vhba_ctl device for CDemu
description: |
Provides the vhba_ctl device for CDemu
builddeps :
- pkgconfig(libelf)
- linux-lts
- linux-lts-headers
- linux-current
- linux-current-headers
rundeps :
- main :
- vhba-module-common
- current :
- vhba-module-common
permanent :
- /lib/modules
patterns :
- common : /usr/lib64/udev
- common : /usr/lib64/modules-load.d
- current : /lib/modules/*.current
setup : |
pushd ..
cp -a vhba-module-${version} lts-build
cp -a vhba-module-${version} current-build
build : |
pushd lts-build
KERNELRELEASE="%kernel_version_lts%" %make
pushd ../current-build
KERNELRELEASE="%kernel_version_current%" %make
install : |
# common files
pushd lts-build
install -D -m 00644 $pkgfiles/60-udev.rules $installdir/%libdir%/udev/rules.d/60-vhba-module.rules
install -D -m 00644 $pkgfiles/modprobe $installdir/%libdir%/modules-load.d/vhba-module.conf
# lts kernel
export KERNELRELEASE="%kernel_version_lts%"
export KDIR="$installdir/lib/modules/${KERNELRELEASE}/kernel/drivers/misc"
install -D -m 00644 vhba.ko $KDIR/vhba.ko
popd
# current kernel
pushd current-build
export KERNELRELEASE="%kernel_version_current%"
export KDIR="$installdir/lib/modules/${KERNELRELEASE}/kernel/drivers/misc"
install -D -m 00644 vhba.ko $KDIR/vhba.ko
popd
# Compress modules with zstd
find "$installdir" -name '*.ko' -exec strip --strip-debug {} \; -exec zstd {} \; -exec rm -v {} \;