Commit a64c20f2 by devttys0

Added configure option

parent 581aa6b9
......@@ -662,6 +662,7 @@ ac_user_opts='
enable_option_checking
with_python
enable_clibs
enable_bundles
enable_libmagic
enable_libfuzzy
enable_pyqtgraph
......@@ -1285,6 +1286,7 @@ Optional Features:
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--disable-clibs do not build/install any c libraries
--disable-bundles do not install bundled software
--disable-libmagic do not build/install the bundled libmagic library
--disable-libfuzzy do not build/install the bundled libfuzzy library
--disable-pyqtgraph do not install the bundled pyqtgraph library
......@@ -3317,6 +3319,14 @@ else
fi
# Check whether --enable-bundles was given.
if test "${enable_bundles+set}" = set; then :
enableval=$enable_bundles; BUILD_BUNDLES=0
else
BUILD_BUNDLES=1
fi
# Check whether --enable-libmagic was given.
if test "${enable_libmagic+set}" = set; then :
enableval=$enable_libmagic; BUILD_MAGIC=0
......@@ -3358,6 +3368,13 @@ else
SOEXT="so"
fi
if test "$BUILD_BUNDLES" == "0"
then
BUILD_MAGIC=0
BUILD_FUZZY=0
BUILD_PYQTGRAPH=0
fi
if test "$BUILD_C_LIBS" != "0"
then
if test "$BUILD_MAGIC" != "0"
......
......@@ -17,6 +17,11 @@ AC_ARG_ENABLE([clibs],
[BUILD_C_LIBS=0],
[BUILD_C_LIBS=1])
AC_ARG_ENABLE([bundles],
[AS_HELP_STRING([--disable-bundles], [do not install bundled software])],
[BUILD_BUNDLES=0],
[BUILD_BUNDLES=1])
AC_ARG_ENABLE([libmagic],
[AS_HELP_STRING([--disable-libmagic], [do not build/install the bundled libmagic library])],
[BUILD_MAGIC=0],
......@@ -49,6 +54,13 @@ else
SOEXT="so"
fi
if test "$BUILD_BUNDLES" == "0"
then
BUILD_MAGIC=0
BUILD_FUZZY=0
BUILD_PYQTGRAPH=0
fi
if test "$BUILD_C_LIBS" != "0"
then
if test "$BUILD_MAGIC" != "0"
......
......@@ -5,9 +5,6 @@ import binwalk.core.common
# This allows importing of the built-in pyqtgraph if it
# is not available on the system at run time.
try:
import pyqtgraph
except ImportError:
sys.path.append(binwalk.core.common.get_libs_path())
sys.path.append(binwalk.core.common.get_libs_path())
from binwalk.core.module import Modules, ModuleException
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment