]> git.ipfire.org Git - people/amarx/ipfire-3.x.git/commitdiff
e2fsprogs: Cleanup package.
authorMichael Tremer <michael.tremer@ipfire.org>
Sat, 3 Dec 2011 10:46:49 +0000 (11:46 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Sat, 3 Dec 2011 10:46:49 +0000 (11:46 +0100)
The --host=... and --build=... flags were ignored and the
testsuite crashed when there was no /etc/mtab.

e2fsprogs/e2fsprogs.nm

index 1fce087e9feab631e7f46465b714ba645d6ea341..7b80dcdc982ce74124d6d03c950755037813ed40 100644 (file)
@@ -31,10 +31,6 @@ build
        prepare_cmds
                mkdir -pv %{DIR_APP}/build
 
-               # Fix DT_TEXTREL in e2fsprogs libraries. --disable-shared and
-               # --with-pic are not options in E2fsprogs:
-               find lib/ -name Makefile.in -exec sed -i "s/\%{ALL_CFLAGS}/& -fPIC/" {} \;
-
                # At run time libblkid looks for the BLKID_DEBUG environment variable to
                # enable debbugging, with getenv(3). Some suid-root programs use libblkid,
                # such as mount(1). e2fsprogs includes a safe_getenv() function, which calls
@@ -42,25 +38,30 @@ build
                # variables if the user is suid or sgid. So, this command replaces getenv()
                # with safe_getenv():
                sed \
-                       -e "s/getenv(\"BLKID_DEBUG\")/safe_getenv(\"BLKID_DEBUG\")/" \
+                       -e 's/getenv("BLKID_DEBUG")/safe_getenv("BLKID_DEBUG")/' \
                        -i lib/blkid/cache.c
        end
 
+       configure_options += \
+               --with-root-prefix="" \
+               --enable-elf-shlibs \
+               --disable-libblkid \
+               --disable-fsck \
+               --disable-uuidd \
+               --disable-libuuid
+
        build
                cd build
                ../configure \
-                       --prefix=/usr \
-                       --with-root-prefix="" \
-                       --enable-elf-shlibs \
-                       --disable-libblkid \
-                       --disable-fsck \
-                       --disable-uuidd \
-                       --disable-libuuid
+                       %{configure_options}
 
                make %{PARALLELISMFLAGS}
        end
 
        test
+               # Create empty mtab file if it does not exist.
+               [ -e /etc/mtab ] || touch /etc/mtab
+
                cd build && make check
        end