File: focal

package info (click to toggle)
rtpengine 13.5.1.7-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 13,692 kB
  • sloc: ansic: 86,814; perl: 59,954; python: 3,193; sh: 1,037; makefile: 687; asm: 211
file content (79 lines) | stat: -rwxr-xr-x 3,009 bytes parent folder | download | duplicates (2)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#!/bin/bash
#
# Target dist: Ubuntu Focal
DIST=focal

if [ ! -d ../../pkg/deb ] ; then
  echo "script needs to be executed at pkg/deb dir" >&2
  exit 1
fi

rm -rf ${DIST}
cp -r debian ${DIST}

# No libbcg729-dev package
sed -i -e '/libbcg729-dev/d' ${DIST}/control
# No liburing-dev package
sed -i -e '/liburing-dev/d' ${DIST}/control

# Update for focal debhelper
sed -i -e 's/debhelper-compat.*/debhelper-compat (= 12),/' ${DIST}/control
# Replace execute_* hooks with old-style overrides
sed -i -e 's/^execute_after_dh_installsystemd:/override_dh_installsystemd:\n\tdh_installsystemd/' ${DIST}/rules
sed -i -e 's/^execute_before_dh_auto_install-indep:/override_dh_auto_install-indep:/' ${DIST}/rules
sed -i -e '/^\tgzip -9 < README.md/a\\n\tdh_auto_install' ${DIST}/rules

# fix links
sed -i -e 's#${env:deb_systemdsystemunitdir}#/lib/systemd/system/#g' \
  ${DIST}/rtpengine-recording-daemon.links
sed -i -e 's#${env:deb_systemdsystemunitdir}#/lib/systemd/system/#g' \
  ${DIST}/rtpengine-daemon.links

# Add dwz override
cat >> ${DIST}/rules <<'EOF'

override_dh_dwz:
	# Disable, as dwz cannot cope with some of the plugins generated.
EOF

# dkms stuff (see MT#56627)
cp old-dkms/rtpengine-kernel-dkms.postinst "${DIST}"/
cp old-dkms/rtpengine-kernel-dkms.prerm "${DIST}"/
cp old-dkms/dkms.conf.in "${DIST}"/
rm -f "${DIST}"/rtpengine-kernel-dkms.install "${DIST}"/rtpengine-kernel-dkms.dkms
sed -i '/ngcp-rtpengine source:/d' "${DIST}"/source/lintian-overrides
sed -i '1n;/^Package: rtpengine-kernel-dkms/,/^Depends:/{ s/Depends:/Depends:\n dkms (>= 1.95),/;}' "${DIST}"/control
sed -i '/^ dh-sequence-dkms,/d' "${DIST}"/control
sed -i '/^Testsuite: autopkgtest-pkg-dkms/d' "${DIST}"/control
sed -i '/^override_dh_dkms/d' "${DIST}"/rules
sed -i '/dh_dkms /d' "${DIST}"/rules
sed -i '/^export DEB_VERSION_UPSTREAM/d' "${DIST}"/rules
sed -i '/^export DEB_SOURCE/d' "${DIST}"/rules
sed -i 's;^include /usr/share/dpkg/pkg-info.mk;include /usr/share/dpkg/pkg-info.mk\
## kernel package specific stuff\
# Name of the dkms package\
pdkms:=rtpengine-kernel-dkms\
# short upstream name, used for module source directory\
sname:=rtpengine\
# Source version\
sversion:=$(DEB_VERSION_UPSTREAM)\
## end of kernel package specific stuff\
;' "${DIST}"/rules
sed -i 's;^override_dh_auto_install-indep:;override_dh_auto_install-indep:\
\t# Create the directories to install the source into\
\tdh_installdirs -p$(pdkms)    usr/src/$(sname)-$(sversion)\
\t# Copy only the driver source to the proper locations\
\tcd kernel-module \&\& cp Makefile *.c *.h *.inc gen-* ../debian/$(pdkms)/usr/src/$(sname)-$(sversion)\
\t# Prepare dkms.conf from the dkms.conf.in template\
\tsed "s/__VERSION__/$(sversion)/g" debian/dkms.conf.in > debian/$(pdkms)/usr/src/$(sname)-$(sversion)/dkms.conf\
;' "${DIST}"/rules

if command -v wrap-and-sort &>/dev/null ; then
  wrap-and-sort -sat -d ${DIST}
else
  echo "WARN: wrap-and-sort (Debian package devscripts) not available."
fi

# clean backports scripts
rm -rf ${DIST}/backports
exit 0