[898] | 1 | # Run `./bootstrap` to generate the "configure" script. |
---|
| 2 | |
---|
| 3 | # Define the package version numbers and the bug reporting link. |
---|
| 4 | m4_define([YAML_MAJOR], 0) |
---|
| 5 | m4_define([YAML_MINOR], 1) |
---|
| 6 | m4_define([YAML_PATCH], 1) |
---|
| 7 | m4_define([YAML_BUGS], [http://pyyaml.org/newticket?component=libyaml]) |
---|
| 8 | |
---|
| 9 | # Define the libtool version numbers; check the Autobook, Section 11.4. |
---|
| 10 | # Bump the libtool version numbers using the following algorithm: |
---|
| 11 | # if (the current interface has not been changed): |
---|
| 12 | # YAML_REVISION += 1 |
---|
| 13 | # else: |
---|
| 14 | # YAML_REVISION = 0 |
---|
| 15 | # YAML_CURRENT += 1 |
---|
| 16 | # if (this release is backward compatible with the previous release): |
---|
| 17 | # YAML_AGE += 1 |
---|
| 18 | # else: |
---|
| 19 | # YAML_AGE = 0 |
---|
| 20 | m4_define([YAML_RELEASE], 0) |
---|
| 21 | m4_define([YAML_CURRENT], 1) |
---|
| 22 | m4_define([YAML_REVISION], 0) |
---|
| 23 | m4_define([YAML_AGE], 0) |
---|
| 24 | |
---|
| 25 | # Initialize autoconf & automake. |
---|
| 26 | AC_PREREQ(2.59) |
---|
| 27 | AC_INIT([yaml], [YAML_MAJOR.YAML_MINOR.YAML_PATCH], [YAML_BUGS]) |
---|
| 28 | AC_CONFIG_AUX_DIR([config]) |
---|
| 29 | AC_CONFIG_HEADERS([config.h]) |
---|
| 30 | AM_INIT_AUTOMAKE([1.9 foreign]) |
---|
| 31 | |
---|
| 32 | # Define macro variables for the package version numbers. |
---|
| 33 | AC_DEFINE(YAML_VERSION_MAJOR, YAML_MAJOR, [Define the major version number.]) |
---|
| 34 | AC_DEFINE(YAML_VERSION_MINOR, YAML_MINOR, [Define the minor version number.]) |
---|
| 35 | AC_DEFINE(YAML_VERSION_PATCH, YAML_PATCH, [Define the patch version number.]) |
---|
| 36 | AC_DEFINE(YAML_VERSION_STRING, "YAML_MAJOR.YAML_MINOR.YAML_PATCH", [Define the version string.]) |
---|
| 37 | |
---|
| 38 | # Define substitutions for the libtool version numbers. |
---|
| 39 | YAML_LT_RELEASE=YAML_RELEASE |
---|
| 40 | YAML_LT_CURRENT=YAML_CURRENT |
---|
| 41 | YAML_LT_REVISION=YAML_REVISION |
---|
| 42 | YAML_LT_AGE=YAML_AGE |
---|
| 43 | AC_SUBST(YAML_LT_RELEASE) |
---|
| 44 | AC_SUBST(YAML_LT_CURRENT) |
---|
| 45 | AC_SUBST(YAML_LT_REVISION) |
---|
| 46 | AC_SUBST(YAML_LT_AGE) |
---|
| 47 | |
---|
| 48 | # Note: in order to update checks, run `autoscan` and look through "configure.scan". |
---|
| 49 | |
---|
| 50 | # Checks for programs. |
---|
| 51 | AC_PROG_CC |
---|
| 52 | AC_PROG_CPP |
---|
| 53 | AC_PROG_INSTALL |
---|
| 54 | AC_PROG_LN_S |
---|
| 55 | AC_PROG_MAKE_SET |
---|
| 56 | AC_PROG_LIBTOOL |
---|
| 57 | |
---|
| 58 | AC_CHECK_PROG(DOXYGEN, [doxygen], [true], [false]) |
---|
| 59 | AM_CONDITIONAL(DOXYGEN, [test "$DOXYGEN" = true]) |
---|
| 60 | |
---|
| 61 | # Checks for header files. |
---|
| 62 | AC_HEADER_STDC |
---|
| 63 | AC_CHECK_HEADERS([stdlib.h]) |
---|
| 64 | |
---|
| 65 | # Checks for typedefs, structures, and compiler characteristics. |
---|
| 66 | AC_C_CONST |
---|
| 67 | AC_TYPE_SIZE_T |
---|
| 68 | |
---|
| 69 | # Define Makefiles. |
---|
| 70 | AC_CONFIG_FILES([include/Makefile src/Makefile Makefile tests/Makefile]) |
---|
| 71 | |
---|
| 72 | # Generate the "configure" script. |
---|
| 73 | AC_OUTPUT |
---|