From: Jay Freeman (saurik) Date: Sun, 8 Sep 2013 09:48:39 +0000 (-0700) Subject: Add --disable-console option to configure script. X-Git-Tag: v0.9.500%b1~19 X-Git-Url: https://git.saurik.com/cycript.git/commitdiff_plain/002ca3d9a8ba4f323999811405efcc2e3e390fd7?ds=inline Add --disable-console option to configure script. --- diff --git a/Makefile.am b/Makefile.am index 20e06f6..58303f8 100644 --- a/Makefile.am +++ b/Makefile.am @@ -51,6 +51,7 @@ libcycript_sys_la_LIBADD = $(LTLIBFFI) -ldl libcycript_sys_la_SOURCES += Cycript.tab.cc libcycript_sys_la_SOURCES += lex.cy.cpp +if CY_CONSOLE bin_PROGRAMS = cycript cycript_SOURCES = Console.cpp Display.cpp cycript_LDADD = libcycript.la libcycript-sys.la $(LTLIBAPR) $(LTLIBREADLINE) $(LTLIBTERMCAP) -ldl @@ -59,6 +60,7 @@ ldid = true entitle = $(ldid) -Scycript.xml filters = $(CY_FILTERS) +endif if CY_EXECUTE libcycript_sys_la_SOURCES += sig/ffi_type.cpp sig/parse.cpp sig/copy.cpp @@ -87,6 +89,8 @@ endif if CY_MACH libcycript_sys_la_SOURCES += Handler.mm + +if CY_CONSOLE cycript_SOURCES += Mach/Inject.cpp AM_CPPFLAGS += -DCY_ATTACH @@ -106,6 +110,7 @@ Trampoline.t.hpp: libTrampoline.t.la trampoline.sh $(srcdir)/trampoline.sh $@ .libs/libTrampoline.t.dylib Trampoline $(SED) $(LIPO) $(NM) $(OTOOL) ! grep '## symbol stub for:' $@ endif +endif libcycript_sim_la_SHORTNAME = sim if CY_IOS_SIMULATOR diff --git a/configure.ac b/configure.ac index a446810..1115adf 100644 --- a/configure.ac +++ b/configure.ac @@ -210,6 +210,10 @@ AC_ARG_ENABLE([javascript], [AS_HELP_STRING( ], [CY_CHECK_JAVASCRIPT]) dnl }}} +AC_ARG_ENABLE([console], AS_HELP_STRING([--disable-console], [disable console])) +AM_CONDITIONAL([CY_CONSOLE], [test "x$enable_console" != "xno"]) + +AM_COND_IF([CY_CONSOLE], [ dnl APR_FIND_APR {{{ AS_IF([test "x$LTLIBAPR" != x], [ AC_SUBST([LTLIBAPR]) @@ -223,6 +227,7 @@ AS_CASE([$apr_found], [yes], [ AC_MSG_ERROR([missing "libapr"]) ])]) dnl }}} +]) AC_DEFUN([CY_CHECK_PKG_CONFIG_LIBFFI], [ PKG_CHECK_MODULES([LIBFFI], [libffi], [