summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorRichard Yao <[email protected]>2012-06-06 17:08:00 +0000
committerBrian Behlendorf <[email protected]>2012-06-11 10:04:49 -0700
commit6a0936babc14a44986265a12f206c41999bd48c3 (patch)
treea2787bcc41bca759e12636977f541bcb54bd0e1f /configure
parentab85f8455b995741c479f1cdcf21304de87fdaa8 (diff)
Linux 3.4 compat, d_make_root() replaces d_alloc_root()
torvalds/linux@adc0e91ab142abe93f5b0d7980ada8a7676231fe introduced introduced d_make_root() as a replacement for d_alloc_root(). Further commits appear to have removed d_alloc_root() from the Linux source tree. This causes the following failure: error: implicit declaration of function 'd_alloc_root' [-Werror=implicit-function-declaration] To correct this we update the code to use the current d_make_root() interface for readability. Then we introduce an autotools check to determine if d_make_root() is available. If it isn't then we define some compatibility logic which used the older d_alloc_root() interface. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #776
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure106
1 files changed, 106 insertions, 0 deletions
diff --git a/configure b/configure
index a8e7cb711..f46d147c7 100755
--- a/configure
+++ b/configure
@@ -15945,6 +15945,59 @@ fi
+ { $as_echo "$as_me:$LINENO: checking whether symbol d_make_root is exported" >&5
+$as_echo_n "checking whether symbol d_make_root is exported... " >&6; }
+ grep -q -E '[[:space:]]d_make_root[[:space:]]' \
+ $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
+ rc=$?
+ if test $rc -ne 0; then
+
+ export=0
+ for file in fs/dcache.c; do
+ grep -q -E "EXPORT_SYMBOL.*(d_make_root)" "$LINUX/$file" 2>/dev/null
+ rc=$?
+ if test $rc -eq 0; then
+
+ export=1
+ break;
+
+fi
+
+ done
+ if test $export -eq 0; then
+
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+
+
+else
+
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_D_MAKE_ROOT 1
+_ACEOF
+
+
+fi
+
+
+else
+
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_D_MAKE_ROOT 1
+_ACEOF
+
+
+fi
+
+
+
+
{ $as_echo "$as_me:$LINENO: checking whether symbol d_obtain_alias is exported" >&5
$as_echo_n "checking whether symbol d_obtain_alias is exported... " >&6; }
grep -q -E '[[:space:]]d_obtain_alias[[:space:]]' \
@@ -22040,6 +22093,59 @@ fi
+ { $as_echo "$as_me:$LINENO: checking whether symbol d_make_root is exported" >&5
+$as_echo_n "checking whether symbol d_make_root is exported... " >&6; }
+ grep -q -E '[[:space:]]d_make_root[[:space:]]' \
+ $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
+ rc=$?
+ if test $rc -ne 0; then
+
+ export=0
+ for file in fs/dcache.c; do
+ grep -q -E "EXPORT_SYMBOL.*(d_make_root)" "$LINUX/$file" 2>/dev/null
+ rc=$?
+ if test $rc -eq 0; then
+
+ export=1
+ break;
+
+fi
+
+ done
+ if test $export -eq 0; then
+
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+
+
+else
+
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_D_MAKE_ROOT 1
+_ACEOF
+
+
+fi
+
+
+else
+
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_D_MAKE_ROOT 1
+_ACEOF
+
+
+fi
+
+
+
+
{ $as_echo "$as_me:$LINENO: checking whether symbol d_obtain_alias is exported" >&5
$as_echo_n "checking whether symbol d_obtain_alias is exported... " >&6; }
grep -q -E '[[:space:]]d_obtain_alias[[:space:]]' \