mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-25 07:51:28 +00:00
debian: fix wrong kernel version used in preinst
This script is used in the non-dkms scst package. The purpose of package is to determine kernel location at compile-time, as opposed to the package installation time. However, calling `uname -r` in package installation time violates that idea because it would get some random kernel that was running on the machine. This problem is particularly seen in containers, because in those `uname` shows the kernel running on the host, rather than the one running inside container. Fix this by determining the kernel location in `preinst` script at compile time as well. git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@9424 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
2
Makefile
2
Makefile
@@ -367,6 +367,8 @@ dpkg: ../scst_$(VERSION).orig.tar.gz
|
||||
[ -z "$$DEBFULLNAME" ] || export DEBFULLNAME="Bart Van Assche" &&\
|
||||
sed 's/%{scst_version}/$(VERSION)/' \
|
||||
<debian/scst.dkms.in >debian/scst.dkms && \
|
||||
sed 's/%{KVER}/$(KVER)/' \
|
||||
<debian/scst.preinst.in >debian/scst.preinst && \
|
||||
output_files=( \
|
||||
../*_$(VERSION)-$(DEBIAN_REVISION)_*.deb \
|
||||
../*_$(VERSION)-$(DEBIAN_REVISION)_*.ddeb \
|
||||
|
||||
2
debian/rules
vendored
2
debian/rules
vendored
@@ -29,7 +29,7 @@ export KDIR=$(DEB_KDIR_SET)
|
||||
clean:
|
||||
dh_testdir && \
|
||||
dh_prep -Xqla_isp/TAGS -Xdebian/changelog && \
|
||||
scripts/clean-source-tree -x debian/changelog -x debian/compat
|
||||
scripts/clean-source-tree -x debian/changelog -x debian/compat -x debian/scst.preinst
|
||||
|
||||
build:
|
||||
make 2release && \
|
||||
|
||||
Reference in New Issue
Block a user