X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=config%2Flyxinclude.m4;h=1d16ed827204294450958c93672edcc1b72506e0;hb=fdb9b989f728626622926f0b770b0f0c96c91cf0;hp=d1a657782cf898c50d88e9cfbdfe24778cceb748;hpb=27b4472dfd4a2cb0e6b15c205eb7ecadabb857ae;p=lyx.git diff --git a/config/lyxinclude.m4 b/config/lyxinclude.m4 index d1a657782c..1d16ed8272 100644 --- a/config/lyxinclude.m4 +++ b/config/lyxinclude.m4 @@ -7,7 +7,7 @@ dnl Allan Rae (rae@lyx.org) dnl Usage LYX_CHECK_VERSION Displays version of LyX being built and dnl sets variables "lyx_devel_version" and "lyx_prerelease" AC_DEFUN([LYX_CHECK_VERSION],[ -echo "configuring LyX version $VERSION" +echo "configuring LyX version" AC_PACKAGE_VERSION if echo AC_PACKAGE_VERSION | grep 'svn' >/dev/null ; then lyx_devel_version=yes AC_DEFINE(DEVEL_VERSION, 1, [Define if you are building a development version of LyX]) @@ -28,20 +28,20 @@ dnl Define the option to set a LyX version on installed executables and director dnl dnl AC_DEFUN([LYX_VERSION_SUFFIX],[ -AC_MSG_CHECKING([for install target]) +AC_MSG_CHECKING([for version suffix]) +dnl We need the literal double quotes in the rpm spec file RPM_VERSION_SUFFIX='""' AC_ARG_WITH(version-suffix, [ --with-version-suffix[=] install lyx files as lyx], [if test "x$withval" = "xyes"; then - withval="-$VERSION" + withval="-"AC_PACKAGE_VERSION ac_configure_args=`echo $ac_configure_args | sed "s,--with-version-suffix,--with-version-suffix=$withval,"` fi - PACKAGE="$PACKAGE$withval" - program_suffix=$withval + version_suffix=$withval RPM_VERSION_SUFFIX="--with-version-suffix=$withval"]) AC_SUBST(RPM_VERSION_SUFFIX) -AC_MSG_RESULT([$PACKAGE]) +AC_MSG_RESULT([$withval]) ]) @@ -245,7 +245,7 @@ if test x$GXX = xyes; then fi if test x$enable_warnings = xyes ; then case $gxx_version in - 2.*|3.1*|3.2*|3.3*) + 3.1*|3.2*|3.3*) CPPFLAGS="-W -Wall $CPPFLAGS" ;; *) @@ -255,13 +255,10 @@ if test x$GXX = xyes; then fi fi case $gxx_version in - 2.95.1) AM_CXXFLAGS="-fpermissive -ftemplate-depth-30";; - 2.95.*) AM_CXXFLAGS="-Wno-non-template-friend -ftemplate-depth-30";; - 2.96*) AM_CXXFLAGS="-fno-exceptions -ftemplate-depth-30 -Wno-non-template-friend";; - 3.1*) AM_CXXFLAGS="-finline-limit=500 -fno-exceptions";; - 3.2*|3.3*) AM_CXXFLAGS="-fno-exceptions";; + 3.1*) AM_CXXFLAGS="-finline-limit=500 ";; + 3.2*|3.3*) AM_CXXFLAGS="";; 3.4*|4.0*) - AM_CXXFLAGS="-fno-exceptions" + AM_CXXFLAGS="" test $enable_pch = yes && lyx_pch_comp=yes ;; *) AM_CXXFLAGS="";; @@ -551,13 +548,13 @@ rm -f conftest*]) ]) ### end of LYX_PATH_HEADER -### Check which frontends we want to use. The default is XForms only +### Check which frontends we want to use. ### AC_DEFUN([LYX_USE_FRONTENDS], [AC_MSG_CHECKING([what frontend should be used for the GUI]) AC_ARG_WITH(frontend, [ --with-frontend=THIS Use THIS frontend as main GUI: - Possible values: xforms, qt, gtk(EXPERIMENTAL)], + Possible values: qt3, qt4, gtk], [FRONTENDS="$withval"]) if test "x$FRONTENDS" = x ; then AC_MSG_RESULT(none) @@ -586,24 +583,30 @@ AC_ARG_WITH(packaging, AC_MSG_RESULT($lyx_use_packaging) case $lyx_use_packaging in macosx) AC_DEFINE(USE_MACOSX_PACKAGING, 1, [Define to 1 if LyX should use a MacOS X application bundle file layout]) - PACKAGE=LyX - default_prefix="/Applications/LyX.app" + PACKAGE=LyX${version_suffix} + default_prefix="/Applications/${PACKAGE}.app" bindir='${prefix}/Contents/MacOS' libdir='${prefix}/Contents/Resources' datadir='${prefix}/Contents/Resources' - mandir='${prefix}/Contents/Resources/man' ;; + pkgdatadir='${datadir}' + mandir='${datadir}/man' ;; windows) AC_DEFINE(USE_WINDOWS_PACKAGING, 1, [Define to 1 if LyX should use a Windows-style file layout]) - PACKAGE=LyX - default_prefix="C:/Program Files/LyX" + PACKAGE=LyX${version_suffix} + default_prefix="C:/Program Files/${PACKAGE}" bindir='${prefix}/bin' libdir='${prefix}/Resources' datadir='${prefix}/Resources' + pkgdatadir='${datadir}' mandir='${prefix}/Resources/man' ;; posix) AC_DEFINE(USE_POSIX_PACKAGING, 1, [Define to 1 if LyX should use a POSIX-style file layout]) - PACKAGE=lyx + PACKAGE=lyx${version_suffix} + program_suffix=$version_suffix + pkgdatadir='${datadir}/${PACKAGE}' default_prefix=$ac_default_prefix ;; *) LYX_ERROR([Unknown packaging type $lyx_use_packaging]) ;; esac +AC_SUBST(pkgdatadir) +AC_SUBST(program_suffix) ])