diff options
author | Alexandru Avadanii <Alexandru.Avadanii@enea.com> | 2018-01-04 22:47:35 +0100 |
---|---|---|
committer | Alexandru Avadanii <Alexandru.Avadanii@enea.com> | 2018-01-04 22:47:35 +0100 |
commit | 84f58189f269be6633e0c8897d5624d3dfaaa650 (patch) | |
tree | 3aece687a8eb72475e2ce08886115a4ae5f5caf9 /mcp/scripts/lib.sh | |
parent | 924d481ac84e8fad9bf1132e1cff18967887017e (diff) |
[centos jump] nbd build: Fix REQ_TYPE_SPECIAL
Change-Id: Ia514418d2aae1b4f7e752d4610fa6c9829c67e51
Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
Diffstat (limited to 'mcp/scripts/lib.sh')
-rw-r--r-- | mcp/scripts/lib.sh | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/mcp/scripts/lib.sh b/mcp/scripts/lib.sh index fe80d4937..05780bb62 100644 --- a/mcp/scripts/lib.sh +++ b/mcp/scripts/lib.sh @@ -91,8 +91,12 @@ function __kernel_modules { ( cd ~/rpmbuild/SPECS rpmbuild -bp --nodeps --target="${__uname_m}" kernel*.spec - cd ~/rpmbuild/BUILD/"${__srpm%.src.rpm}/linux-${__uname_r/el7*./el7.centos.}" + cd ~/rpmbuild/BUILD/"${__srpm%.src.rpm}"/linux-* sed -i 's/^.*\(CONFIG_BLK_DEV_NBD\).*$/\1=m/g' .config + # http://centosfaq.org/centos/nbd-does-not-compile-for-3100-514262el7x86_64 + if grep -Rq 'REQ_TYPE_DRV_PRIV' drivers/block; then + sed -i 's/REQ_TYPE_SPECIAL/REQ_TYPE_DRV_PRIV/g' drivers/block/nbd.c + fi gunzip -c "/boot/symvers-${__uname_r}.gz" > Module.symvers make prepare modules_prepare make M=drivers/block -j |