pwyckoff | 99b000b | 2008-04-03 19:30:55 +0000 | [diff] [blame] | 1 | # Autoconf input file |
| 2 | # $Id$ |
| 3 | |
| 4 | # AC - autoconf |
| 5 | # FB - facebook |
| 6 | |
| 7 | ######################################################################### |
| 8 | # DO NOT TOUCH EXCEPT TO CHANGE REV# IN AC_INIT |
| 9 | |
| 10 | AC_PREREQ(2.52) |
| 11 | AC_INIT([libfb303],[20080209]) |
| 12 | #AC_CONFIG_AUX_DIR([/usr/share/automake-1.9]) |
| 13 | # To install locally |
| 14 | FB_INITIALIZE([localinstall]) |
| 15 | AC_PREFIX_DEFAULT([/usr/local]) |
| 16 | |
| 17 | ############################################################################ |
| 18 | # User Configurable. Change With CAUTION! |
| 19 | # User can include custom makefile rules. Uncomment and update only <name> in PRODUCT_MK. |
| 20 | # Include where appropriate in any Makefile.am as @PRODUCT_MK@ |
| 21 | |
| 22 | #PRODUCT_MK="include ${EXTERNAL_PATH}/shared/build/<name>.mk" |
| 23 | |
| 24 | # Default path to external Facebook components and shared build toools I.e fb303 etc. |
| 25 | # To point to other locations set environment variable EXTERNAL_PATH. |
| 26 | # To change the current default you must change bootstrap.sh. |
| 27 | FB_WITH_EXTERNAL_PATH([`pwd`]) |
| 28 | |
David Reiss | 7c28b33 | 2008-09-20 00:14:01 +0000 | [diff] [blame] | 29 | AC_ARG_VAR([PY_PREFIX], [Prefix for installing Python modules. |
| 30 | (Normal --prefix is ignored for Python because |
| 31 | Python has different conventions.) |
| 32 | Default = "/usr"]) |
| 33 | AS_IF([test "x$PY_PREFIX" = x], [PY_PREFIX="/usr"]) |
pwyckoff | 99b000b | 2008-04-03 19:30:55 +0000 | [diff] [blame] | 34 | |
| 35 | ########################################################################## |
| 36 | # User Configurable |
| 37 | |
| 38 | # Pre-defined macro to set opt build mode. Run with --disable-shared option to turn off optimization. |
| 39 | FB_ENABLE_DEFAULT_OPT_BUILD |
| 40 | |
| 41 | # Predefined macro to set static library mode. Run with --disable-static option to turn off static lib mode. |
| 42 | FB_ENABLE_DEFAULT_STATIC |
| 43 | |
| 44 | # Personalized feature generator. Creates defines/conditionals and --enable --disable command line options. |
| 45 | # FB_ENABLE_FEATURE([FEATURE], [feature]) OR FB_ENABLE_FEATURE([FEATURE], [feature], [\"<value>\"]) |
| 46 | |
| 47 | # Example: Macro supplies -DFACEBOOK at compile time and "if FACEBOOK endif" capabilities. |
| 48 | |
| 49 | # Personalized path generator Sets default paths. Provides --with-xx=DIR options. |
| 50 | # FB_WITH_PATH([<var>_home], [<var>path], [<default location>] |
| 51 | |
| 52 | # Example: sets $(thrift_home) variable with default path set to /usr/local. |
| 53 | FB_WITH_PATH([thrift_home], [thriftpath], [/usr/local]) |
David Reiss | 7c28b33 | 2008-09-20 00:14:01 +0000 | [diff] [blame] | 54 | |
| 55 | # Require boost 1.33.1 or later |
| 56 | AX_BOOST_BASE([1.33.1]) |
pwyckoff | 99b000b | 2008-04-03 19:30:55 +0000 | [diff] [blame] | 57 | |
| 58 | # Generates Makefile from Makefile.am. Modify when new subdirs are added. |
| 59 | # Change Makefile.am also to add subdirectly. |
| 60 | AC_CONFIG_FILES(Makefile cpp/Makefile py/Makefile) |
| 61 | |
| 62 | ############################################################################ |
| 63 | # DO NOT TOUCH. |
| 64 | |
| 65 | AC_SUBST(PRODUCT_MK) |
| 66 | AC_OUTPUT |
| 67 | |
| 68 | ############################################################################# |
| 69 | ######### FINISH ############################################################ |
| 70 | |
| 71 | echo "EXTERNAL_PATH $EXTERNAL_PATH" |
| 72 | |
| 73 | |
| 74 | # |
| 75 | # NOTES FOR USER |
| 76 | # Short cut to create conditional flags. |
| 77 | #enable_facebook="yes" |
| 78 | #AM_CONDITIONAL([FACEBOOK], [test "$enable_facebook" = yes]) |
| 79 | #enable_hdfs="yes" |
| 80 | #AM_CONDITIONAL([HDFS], [test "$enable_hdfs" = yes]) |
| 81 | |
| 82 | # Enable options with --enable and --disable configurable. |
| 83 | #AC_MSG_CHECKING([whether to enable FACEBOOK]) |
| 84 | #FACEBOOK="" |
| 85 | #AC_ARG_ENABLE([facebook], |
| 86 | # [ --enable-facebook Enable facebook.], |
| 87 | # [ |
| 88 | # ENABLE_FACEBOOK=$enableval |
| 89 | # ], |
| 90 | # [ |
| 91 | # ENABLE_FACEBOOK="no" |
| 92 | # ] |
| 93 | #) |
| 94 | #AM_CONDITIONAL([FACEBOOK], [test "$ENABLE_FACEBOOK" = yes]) |
| 95 | #AC_MSG_RESULT($ENABLE_FACEBOOK) |
| 96 | |