📄 configure.ac
字号:
# Process this file with autoconf to produce a configure script.AC_PREREQ(2.59)m4_define([scim_tomoe_major_version], [0])m4_define([scim_tomoe_minor_version], [6])m4_define([scim_tomoe_micro_version], [0])m4_define([scim_tomoe_version], [scim_tomoe_major_version.scim_tomoe_minor_version.scim_tomoe_micro_version])AC_INIT(scim-tomoe, [scim_tomoe_version], poincare@ikezoe.net)AC_CONFIG_SRCDIR([configure.ac])# Save this value here, since automake will set cflags and cxxflags latercflags_set=${CFLAGS+set}cppflags_set=${CPPFLAGS+set}SCIM_TOMOE_MAJOR_VERSION=scim_tomoe_major_versionSCIM_TOMOE_MINOR_VERSION=scim_tomoe_minor_versionSCIM_TOMOE_MICRO_VERSION=scim_tomoe_micro_versionSCIM_TOMOE_VERSION=scim_tomoe_versionAC_SUBST(SCIM_TOMOE_MAJOR_VERSION)AC_SUBST(SCIM_TOMOE_MINOR_VERSION)AC_SUBST(SCIM_TOMOE_MICRO_VERSION)AC_SUBST(SCIM_TOMOE_VERSION)# Init automake stuffAM_INIT_AUTOMAKE(1.9)AM_CONFIG_HEADER(config.h)# Init UUID of scim-tomoeSCIM_TOMOE_UUID=b1bfe2b4-6930-41b0-8c07-d05bce8c92e2AC_SUBST(SCIM_TOMOE_UUID)AC_DEFINE_UNQUOTED(SCIM_TOMOE_UUID, "$SCIM_TOMOE_UUID", [The UUID of scim-tomoe])# Init gettextIT_PROG_INTLTOOL([0.35.0])AM_GLIB_GNU_GETTEXTdnl should run after AM_GLIB_GNU_GETTEXTAC_CONFIG_COMMANDS([modify-itlocaledir], [sed \ -i'' \ -e "s/^itlocaledir = /itlocaledir = \$(datadir)\/locale\n#itlocaledir = /" \ po/Makefile])GETTEXT_PACKAGE=scim-tomoeAC_SUBST(GETTEXT_PACKAGE)AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [The gettext domain])# Init libtoolAC_LIBTOOL_DLOPENAC_PROG_LIBTOOLAC_SUBST(LIBTOOL_DEPS)# Checks for programs.AC_PROG_CXXAC_PROG_CCAC_LANG(C++)AC_C_CONSTAC_TYPE_SIZE_T# Checks for libraries.SCIM_VERSION=1.2.0PKG_CHECK_MODULES(SCIM, [scim >= $SCIM_VERSION])# Check gtk2PKG_CHECK_MODULES(GTK2, [gtk+-2.0 >= 2.4.0])# Check tomoe-gtkPKG_CHECK_MODULES(TOMOE_GTK, [tomoe-gtk >= 0.4.0])# Check tomoePKG_CHECK_MODULES(TOMOE, [tomoe >= 0.4.0])AC_SUBST(SCIM_VERSION)# Checks for header files.AC_HEADER_STDCAC_FUNC_ALLOCAAC_CHECK_HEADERS([argz.h fcntl.h float.h inttypes.h langinfo.h libintl.h limits.h locale.h malloc.h stddef.h stdint.h stdio_ext.h stdlib.h string.h strings.h sys/param.h unistd.h wchar.h])# Checks for library functions.AC_SUBST(ac_aux_dir)# Checks for tomoePKG_CHECK_MODULES(TOMOE, tomoe)AC_SUBST(TOMOE_CFLAGS)AC_SUBST(TOMOE_LIBS)# libtool option to control which symbols are exported# right now, symbols starting with _ are not exportedLIBTOOL_EXPORT_OPTIONS='-export-symbols-regex "^[[^_]].*"'AC_SUBST(LIBTOOL_EXPORT_OPTIONS)# Extra args.AC_ARG_ENABLE(debug, [ --enable-debug Turn on debugging], [case "${enableval}" in yes) debug=yes ;; no) debug=no ;; *) AC_MSG_ERROR(bad value ${enableval} for --enable-debug) ;; esac],[debug=no])if test "x$debug" = "xyes"; then test "$cflags_set" = set || CFLAGS="$CFLAGS -g" test "$cppflags_set" = set || CPPFLAGS="$CXXFLAGS -g" SCIM_DEBUG_FLAGS="-DENABLE_DEBUG=1"else SCIM_DEBUG_FLAGS=""fiAC_SUBST(SCIM_DEBUG_FLAGS)SCIM_DATADIR=`$PKG_CONFIG --variable=scimdatadir scim`SCIM_ICONDIR=`$PKG_CONFIG --variable=icondir scim`SCIM_MODULEDIR=`$PKG_CONFIG --variable=moduledir scim`SCIM_LIBEXECDIR=`$PKG_CONFIG --variable=libdir scim`/scim-1.0if test "x$SCIM_DATADIR" = "x"; then SCIM_DATADIR=${datadir}/scimfiif test "x$SCIM_ICONDIR" = "x"; then SCIM_ICONDIR=${datadir}/scim/iconsfiif test "x$SCIM_MODULEDIR" = "x"; then SCIM_MODULEDIR=${libdir}/scim-1.0fiif test "x$SCIM_LIBEXECDIR" = "x/scim-1.0"; then SCIM_LIBEXECDIR=${libdir}/scim-1.0fiSCIM_TOMOE_DATADIR=${SCIM_DATADIR}/tomoeAC_SUBST(SCIM_DATADIR)AC_SUBST(SCIM_ICONDIR)AC_SUBST(SCIM_MODULEDIR)AC_SUBST(SCIM_LIBEXECDIR)AC_SUBST(SCIM_TOMOE_DATADIR)AC_CONFIG_FILES([Makefilepo/Makefile.insrc/Makefiledata/Makefilesrc/scim-tomoe])AC_OUTPUT
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -