1
0

patch-configure 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. - use the compiler passed in $CC
  2. - predefine iptables modules dir, since the check would
  3. always fail (cause of absolute search paths) and OpenADK
  4. (for now) doesn't compile iptables with shared objects
  5. - do not discard compiler output from tests, they're useful
  6. for debugging
  7. - additionally output the full compiler command before running
  8. it
  9. --- iproute2-2.6.37.orig/configure 2011-01-07 18:54:30.000000000 +0100
  10. +++ iproute2-2.6.37/configure 2011-01-18 02:37:39.800716449 +0100
  11. @@ -15,7 +15,8 @@ int main(int argc, char **argv) {
  12. return 0;
  13. }
  14. EOF
  15. -gcc -I$INCLUDE -o /tmp/atmtest /tmp/atmtest.c -latm >/dev/null 2>&1
  16. +echo "$CC -I$INCLUDE -o /tmp/atmtest /tmp/atmtest.c -latm"
  17. +$CC -I$INCLUDE -o /tmp/atmtest /tmp/atmtest.c -latm
  18. if [ $? -eq 0 ]
  19. then
  20. echo "TC_CONFIG_ATM:=y" >>Config
  21. @@ -49,7 +50,8 @@ int main(int argc, char **argv)
  22. EOF
  23. -if gcc -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl -lxtables >/dev/null 2>&1
  24. +echo "$CC -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl -lxtables"
  25. +if $CC -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl -lxtables
  26. then
  27. echo "TC_CONFIG_XT:=y" >>Config
  28. echo "using xtables"
  29. @@ -86,7 +88,8 @@ int main(int argc, char **argv) {
  30. }
  31. EOF
  32. -gcc -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl >/dev/null 2>&1
  33. +echo "$CC -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl"
  34. +$CC -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl
  35. if [ $? -eq 0 ]
  36. then
  37. @@ -126,7 +129,8 @@ int main(int argc, char **argv) {
  38. }
  39. EOF
  40. -gcc -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl >/dev/null 2>&1
  41. +echo "$CC -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl"
  42. +$CC -I$INCLUDE $IPTC -o /tmp/ipttest /tmp/ipttest.c $IPTL -ldl
  43. if [ $? -eq 0 ]
  44. then
  45. @@ -149,18 +153,8 @@ check_ipt()
  46. check_ipt_lib_dir()
  47. {
  48. - IPT_LIB_DIR=""
  49. - for dir in /lib /usr/lib /usr/local/lib
  50. - do
  51. - for file in $dir/$TABLES/lib*t_*so ; do
  52. - if [ -f $file ]; then
  53. - echo $dir/$TABLES
  54. - echo "IPT_LIB_DIR:=$dir/$TABLES" >> Config
  55. - return
  56. - fi
  57. - done
  58. - done
  59. - echo "not found!"
  60. + echo "/usr/lib/$TABLES"
  61. + echo "IPT_LIB_DIR:=/usr/lib/$TABLES" >> Config
  62. }
  63. echo "# Generated config based on" $INCLUDE >Config