Don't need NIX_CFLAGS_COMPILE in spl build anymore, consolodate zfs patches.

This commit is contained in:
Jack Cummings 2013-04-06 00:06:27 -07:00
parent d1cb67a629
commit 4c37edd6f3
5 changed files with 1 additions and 98 deletions

View File

@ -11,8 +11,6 @@ stdenv.mkDerivation {
buildInputs = [ perl kernelDev autoconf automake libtool ];
NIX_CFLAGS_COMPILE = "-I${kernelDev}/lib/modules/${kernelDev.modDirVersion}/build/include/generated";
preConfigure = ''
./autogen.sh

View File

@ -8,7 +8,7 @@ stdenv.mkDerivation {
sha256 = "1ykph9d4p70mam6lvcx0zld6d34gch15dsilds5ncbxh0m52knl0";
};
patches = [ ./mount_zfs_prefix.patch ./kerneldir_path.patch ];
patches = [ ./mount_zfs_prefix.patch ./nix-build.patch ];
buildInputs = [ kernelDev spl perl autoconf automake libtool zlib libuuid coreutils ];

View File

@ -1,70 +0,0 @@
*** git-export/module/Makefile.in.orig Wed Dec 31 16:00:01 1969
--- git-export/module/Makefile.in Tue Mar 6 00:23:07 2012
***************
*** 11,19 ****
@# installed devel headers, or they may be in the module
@# subdirectory when building against the spl source tree.
@if [ -f @SPL_OBJ@/@SPL_SYMBOLS@ ]; then \
! /bin/cp @SPL_OBJ@/@SPL_SYMBOLS@ .; \
elif [ -f @SPL_OBJ@/module/@SPL_SYMBOLS@ ]; then \
! /bin/cp @SPL_OBJ@/module/@SPL_SYMBOLS@ .; \
else \
echo -e "\n" \
"*** Missing spl symbols ensure you have built the spl:\n" \
--- 11,21 ----
@# installed devel headers, or they may be in the module
@# subdirectory when building against the spl source tree.
@if [ -f @SPL_OBJ@/@SPL_SYMBOLS@ ]; then \
! /bin/cp -f @SPL_OBJ@/@SPL_SYMBOLS@ .; \
! chmod +w @SPL_SYMBOLS@ .; \
elif [ -f @SPL_OBJ@/module/@SPL_SYMBOLS@ ]; then \
! /bin/cp -f @SPL_OBJ@/module/@SPL_SYMBOLS@ .; \
! chmod +w @SPL_SYMBOLS@ .; \
else \
echo -e "\n" \
"*** Missing spl symbols ensure you have built the spl:\n" \
***************
*** 35,55 ****
modules_install:
@# Install the kernel modules
$(MAKE) -C @LINUX_OBJ@ SUBDIRS=`pwd` \
! INSTALL_MOD_PATH=$(DESTDIR) \
INSTALL_MOD_DIR=addon/zfs $@
@# Remove extraneous build products when packaging
! if [ -n "$(DESTDIR)" ]; then \
! find $(DESTDIR)/lib/modules/@LINUX_VERSION@ \
-name 'modules.*' | xargs $(RM); \
fi
! sysmap=$(DESTDIR)/boot/System.map-@LINUX_VERSION@; \
if [ -f $$sysmap ]; then \
depmod -ae -F $$sysmap @LINUX_VERSION@; \
fi
modules_uninstall:
@# Uninstall the kernel modules
! $(RM) -R $(DESTDIR)/lib/modules/@LINUX_VERSION@/addon/zfs
distdir:
--- 37,57 ----
modules_install:
@# Install the kernel modules
$(MAKE) -C @LINUX_OBJ@ SUBDIRS=`pwd` \
! INSTALL_MOD_PATH=@prefix@ \
INSTALL_MOD_DIR=addon/zfs $@
@# Remove extraneous build products when packaging
! if [ -n "@prefix@" ]; then \
! find @prefix@/lib/modules/@LINUX_VERSION@ \
-name 'modules.*' | xargs $(RM); \
fi
! sysmap=@prefix@/boot/System.map-@LINUX_VERSION@; \
if [ -f $$sysmap ]; then \
depmod -ae -F $$sysmap @LINUX_VERSION@; \
fi
modules_uninstall:
@# Uninstall the kernel modules
! $(RM) -R @prefix@/lib/modules/@LINUX_VERSION@/addon/zfs
distdir:

View File

@ -1,25 +0,0 @@
*** git-export/module/Makefile.in.old Tue Mar 6 01:04:48 2012
--- git-export/module/Makefile.in Tue Mar 6 01:04:59 2012
***************
*** 11,20 ****
@# installed devel headers, or they may be in the module
@# subdirectory when building against the spl source tree.
@if [ -f @SPL_OBJ@/@SPL_SYMBOLS@ ]; then \
! /bin/cp -f @SPL_OBJ@/@SPL_SYMBOLS@ .; \
chmod +w @SPL_SYMBOLS@ .; \
elif [ -f @SPL_OBJ@/module/@SPL_SYMBOLS@ ]; then \
! /bin/cp -f @SPL_OBJ@/module/@SPL_SYMBOLS@ .; \
chmod +w @SPL_SYMBOLS@ .; \
else \
echo -e "\n" \
--- 11,20 ----
@# installed devel headers, or they may be in the module
@# subdirectory when building against the spl source tree.
@if [ -f @SPL_OBJ@/@SPL_SYMBOLS@ ]; then \
! cp -f @SPL_OBJ@/@SPL_SYMBOLS@ .; \
chmod +w @SPL_SYMBOLS@ .; \
elif [ -f @SPL_OBJ@/module/@SPL_SYMBOLS@ ]; then \
! cp -f @SPL_OBJ@/module/@SPL_SYMBOLS@ .; \
chmod +w @SPL_SYMBOLS@ .; \
else \
echo -e "\n" \