mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-06 00:10:59 +00:00
--enable-optimization configure option
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2340 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
cd8d582c67
commit
11c11ed88b
@ -1,3 +1,12 @@
|
||||
2001-07-25 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
|
||||
|
||||
* configure.in: move --enable-assertions a bit higher.
|
||||
move the setup of libtool a bit later.
|
||||
|
||||
2001-07-23 John Levon <moz@compsoc.man.ac.uk>
|
||||
|
||||
* INSTALL: document --disable-optimization
|
||||
|
||||
2001-07-25 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* Makefile.am (EXTRA_DIST): add sourcedoc
|
||||
|
11
INSTALL
11
INSTALL
@ -133,6 +133,13 @@ flags:
|
||||
You can use this feature to install more than one version of LyX on
|
||||
the same system. You can optionally specify a "version" of your own,
|
||||
by doing something like : ./configure --with-version-suffix=-latestcvs
|
||||
|
||||
o --enable-optimization=VALUE enables you to set optimization to a
|
||||
higher level as the default (-O), for example --enable-optimization=-O3.
|
||||
|
||||
o --disable-optimization - you can use this to disable compiler
|
||||
optimization of LyX. The compile may be much quicker with some
|
||||
compilers, but LyX will run more slowly.
|
||||
|
||||
There are also flags to control the internationalization support in
|
||||
LyX:
|
||||
@ -190,8 +197,8 @@ this file.
|
||||
In particular, the following options could be useful in some
|
||||
desperate cases:
|
||||
|
||||
o --with-warnings that make the compiler output more warnings during
|
||||
the compilation of LyX. Opposite is --without-warnings. By default,
|
||||
o --enable-warnings that make the compiler output more warnings during
|
||||
the compilation of LyX. Opposite is --disable-warnings. By default,
|
||||
this flag is on for development versions only.
|
||||
|
||||
o --enable-assertions that make the compilier generater run-time
|
||||
|
@ -1,3 +1,12 @@
|
||||
2001-07-25 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
|
||||
|
||||
* lyxinclude.m4 (LYX_PROG_CXX): do not handle gcc 2.97. Rename
|
||||
--with-warnings to --enable-warnings.
|
||||
|
||||
2001-07-23 John Levon <moz@compsoc.man.ac.uk>
|
||||
|
||||
* lyxinclude.m4: honour --disable-optimization
|
||||
|
||||
2001-07-18 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
|
||||
|
||||
* lyxinclude.m4 (LYX_PATH_XFORMS): do not warn against xforms
|
||||
|
@ -176,27 +176,30 @@ AC_MSG_RESULT($cross_compiling)
|
||||
|
||||
AC_PROG_CXX_GNU
|
||||
|
||||
dnl We might want to get or shut warnings.
|
||||
AC_ARG_WITH(warnings,
|
||||
[ --with-warnings tell the compiler to display more warnings],,
|
||||
### We might want to get or shut warnings.
|
||||
AC_ARG_ENABLE(warnings,
|
||||
[ --enable-warnings tell the compiler to display more warnings],,
|
||||
[ if test $lyx_devel_version = yes -o $lyx_prerelease = yes && test $ac_cv_prog_gxx = yes ; then
|
||||
with_warnings=yes;
|
||||
enable_warnings=yes;
|
||||
else
|
||||
with_warnings=no;
|
||||
enable_warnings=no;
|
||||
fi;])
|
||||
if test x$with_warnings = xyes ; then
|
||||
if test x$enable_warnings = xyes ; then
|
||||
lyx_flags="$lyx_flags warnings"
|
||||
AC_DEFINE(WITH_WARNINGS, 1,
|
||||
[Define this if you want to see the warning directives put here and
|
||||
there by the developpers to get attention])
|
||||
fi
|
||||
|
||||
# optimize less for development versions
|
||||
if test $lyx_devel_version = yes -o $lyx_prerelease = yes ; then
|
||||
lyx_opt="-O"
|
||||
else
|
||||
lyx_opt="-O2"
|
||||
fi
|
||||
### set up optimization
|
||||
AC_ARG_ENABLE(optimization,
|
||||
[ --enable-optimization[=value] enable compiler optimisation],,
|
||||
enable_optimization=yes;)
|
||||
case $enable_optimization in
|
||||
yes) lyx_opt=-O;;
|
||||
no) lyx_opt=;;
|
||||
*) lyx_opt=${enable_optimization};;
|
||||
esac
|
||||
|
||||
# set the debug flags correctly.
|
||||
if test $ac_cv_prog_gxx = yes; then
|
||||
@ -226,18 +229,17 @@ dnl Check the version of g++
|
||||
else
|
||||
CXXFLAGS="$lyx_opt"
|
||||
fi
|
||||
if test x$with_warnings = xyes ; then
|
||||
if test x$enable_warnings = xyes ; then
|
||||
case $gxx_version in
|
||||
2.95.*) CXXFLAGS="$CXXFLAGS -W -Wall";;
|
||||
2.96*) CXXFLAGS="$CXXFLAGS -W -Wall";;
|
||||
2.97*) CXXFLAGS="$CXXFLAGS -W -Wall";;
|
||||
*) CXXFLAGS="$CXXFLAGS -W -Wall";;
|
||||
esac
|
||||
if test $lyx_devel_version = yes ; then
|
||||
case $gxx_version in
|
||||
2.95.*) ;;
|
||||
2.96*) ;;
|
||||
2.97*) CXXFLAGS="$CXXFLAGS -Wconversion -Winline";;
|
||||
2.97*) ;;
|
||||
*2.91*) ;;
|
||||
*) ;;
|
||||
esac
|
||||
|
39
configure.in
39
configure.in
@ -74,11 +74,6 @@ esac
|
||||
AC_LANG_CPLUSPLUS
|
||||
LYX_PROG_CXX
|
||||
AC_PROG_CXXCPP
|
||||
AC_DISABLE_SHARED
|
||||
AC_LIBTOOL_WIN32_DLL
|
||||
#AM_PROG_LIBTOOL
|
||||
LYX_PROG_LIBTOOL
|
||||
|
||||
### Some checks on what the C++ compiler can(not) do
|
||||
dnl we do not need that currently (and probably all our supported
|
||||
dnl compiler allow that)
|
||||
@ -94,6 +89,20 @@ dnl LYX_CXX_RTTI
|
||||
AC_CHECK_HEADERS(ostream istream sstream locale limits)
|
||||
LYX_CXX_STL_MODERN_STREAMS
|
||||
|
||||
### and now some special lyx flags.
|
||||
AC_ARG_ENABLE(assertions,
|
||||
[ --enable-assertions add runtime sanity checks in the program],,
|
||||
[if test $lyx_devel_version = yes -o $lyx_prerelease = yes ; then
|
||||
enable_assertions=yes;
|
||||
else
|
||||
enable_assertions=no;
|
||||
fi;])
|
||||
if test "x$enable_assertions" = xyes ; then
|
||||
lyx_flags="$lyx_flags assertions"
|
||||
AC_DEFINE(ENABLE_ASSERTIONS,1,
|
||||
[Define if you want assertions to be enabled in the code])
|
||||
fi
|
||||
|
||||
### We need a regex implementation, so we provide our own if none is found.
|
||||
LYX_REGEX
|
||||
|
||||
@ -129,6 +138,12 @@ if test x$lyx_use_liberty = xyes; then
|
||||
AC_CHECK_LIB(iberty,main)
|
||||
fi
|
||||
|
||||
### Setup libtool
|
||||
AC_DISABLE_SHARED
|
||||
AC_LIBTOOL_WIN32_DLL
|
||||
#AM_PROG_LIBTOOL
|
||||
LYX_PROG_LIBTOOL
|
||||
|
||||
### Check which libsigc++ we're using
|
||||
LYX_WITH_SIGC
|
||||
|
||||
@ -279,20 +294,6 @@ AC_REPLACE_FUNCS(strerror atexit)
|
||||
|
||||
LYX_CHECK_DECL_HDRS(mkstemp,[unistd.h stdlib.h])
|
||||
|
||||
### and now some special lyx flags.
|
||||
AC_ARG_ENABLE(assertions,
|
||||
[ --enable-assertions add runtime sanity checks in the program],,
|
||||
[if test $lyx_devel_version = yes -o $lyx_prerelease = yes ; then
|
||||
enable_assertions=yes;
|
||||
else
|
||||
enable_assertions=no;
|
||||
fi;])
|
||||
if test "x$enable_assertions" = xyes ; then
|
||||
lyx_flags="$lyx_flags assertions"
|
||||
AC_DEFINE(ENABLE_ASSERTIONS,1,
|
||||
[Define if you want assertions to be enabled in the code])
|
||||
fi
|
||||
|
||||
### Finish the work.
|
||||
AC_CONFIG_SUBDIRS(sigc++ lib lib/reLyX)
|
||||
AC_OUTPUT([Makefile \
|
||||
|
91
lib/configure
vendored
91
lib/configure
vendored
@ -1051,6 +1051,85 @@ case $TOHTML in
|
||||
hevea) latex_to_html_command="hevea -s \$\$i";;
|
||||
esac
|
||||
|
||||
#### Search for image conversion ####
|
||||
echo $ac_n "checking for an Image -> EPS converter""... $ac_c"
|
||||
echo "$ac_t""(convert pnmtops)"
|
||||
TOEPS=
|
||||
for ac_prog in convert pnmtops
|
||||
do
|
||||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog ; ac_word=$2
|
||||
if test -n "$ac_word"; then
|
||||
echo $ac_n "+checking for \"$ac_word\"""... $ac_c"
|
||||
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
|
||||
for ac_dir in $PATH; do
|
||||
test -z "$ac_dir" && ac_dir=.
|
||||
if test -x $ac_dir/$ac_word; then
|
||||
TOEPS="$ac_prog"
|
||||
break
|
||||
fi
|
||||
done
|
||||
IFS="$ac_save_ifs"
|
||||
|
||||
if test -n "$TOEPS"; then
|
||||
ac_result=yes
|
||||
else
|
||||
ac_result=no
|
||||
fi
|
||||
|
||||
echo "$ac_t""$ac_result"
|
||||
test -n "$TOEPS" && break
|
||||
fi
|
||||
done
|
||||
|
||||
if test -z "$TOEPS" ; then
|
||||
TOEPS=none
|
||||
fi
|
||||
|
||||
case $TOEPS in
|
||||
convert) gif_to_eps="convert GIF:\$\$i EPS:\$\$o" png_to_eps="convert PNG:\$\$i EPS:\$\$o" jpg_to_eps="convert JPG:\$\$i EPS:\$\$o";;
|
||||
pnmtops) gif_to_eps="giftopnm \$\$i | pnmtops > \$\$o" png_to_eps="pngtopnm \$\$i | pnmtops >\$\$o" jpg_to_eps="jpegtopnm \$\$i | pnmtops >\$\$o";;
|
||||
esac
|
||||
|
||||
echo $ac_n "checking for a GIF -> PNG converter""... $ac_c"
|
||||
echo "$ac_t""(convert pnmtopng)"
|
||||
TOPNG=
|
||||
for ac_prog in convert pnmtopng
|
||||
do
|
||||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog ; ac_word=$2
|
||||
if test -n "$ac_word"; then
|
||||
echo $ac_n "+checking for \"$ac_word\"""... $ac_c"
|
||||
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
|
||||
for ac_dir in $PATH; do
|
||||
test -z "$ac_dir" && ac_dir=.
|
||||
if test -x $ac_dir/$ac_word; then
|
||||
TOPNG="$ac_prog"
|
||||
break
|
||||
fi
|
||||
done
|
||||
IFS="$ac_save_ifs"
|
||||
|
||||
if test -n "$TOPNG"; then
|
||||
ac_result=yes
|
||||
else
|
||||
ac_result=no
|
||||
fi
|
||||
|
||||
echo "$ac_t""$ac_result"
|
||||
test -n "$TOPNG" && break
|
||||
fi
|
||||
done
|
||||
|
||||
if test -z "$TOPNG" ; then
|
||||
TOPNG=none
|
||||
fi
|
||||
|
||||
case $TOPNG in
|
||||
convert) gif_to_png="convert GIF:\$\$i PNG:\$\$o" eps_to_png="convert EPS:\$\$i PNG:\$\$o" jpg_to_png="convert JPG:\$\$i PNG:\$\$o";;
|
||||
pnmtopng) gif_to_png="giftopnm \$\$i | pnmtopng >\$\$o" eps_to_png="pstopnm \$\$i| pnmtopng >\$\$o" jpg_to_png="jpegtopnm \$\$i | pnmtopng >\$\$o";;
|
||||
esac
|
||||
|
||||
#### Explore the LaTeX configuration
|
||||
echo $ac_n "checking LaTeX configuration""... $ac_c"
|
||||
# First, remove the files that we want to re-create
|
||||
@ -1155,7 +1234,6 @@ cat >lyxrc.defaults <<EOF
|
||||
\\Format program "" Program ""
|
||||
\\Format word doc Word W
|
||||
|
||||
|
||||
\\converter latex dvi "$LATEX \$\$i" "latex"
|
||||
\\converter latex pdf2 "$PDFLATEX \$\$i" "latex"
|
||||
\\converter latex html "$latex_to_html_command" "originaldir,needaux"
|
||||
@ -1176,10 +1254,13 @@ cat >lyxrc.defaults <<EOF
|
||||
\\converter html latex "$html_to_latex_command" ""
|
||||
\\converter word latex "$word_to_latex_command" ""
|
||||
|
||||
\converter gif eps "$image_command" ""
|
||||
\converter png eps "$image_command" ""
|
||||
\converter jpg eps "$image_command" ""
|
||||
\converter gif png "$image_command" ""
|
||||
\\converter gif eps "$gif_to_eps" ""
|
||||
\\converter png eps "$png_to_eps" ""
|
||||
\\converter jpg eps "$jpg_to_eps" ""
|
||||
|
||||
\\converter gif png "$gif_to_png" ""
|
||||
\\converter eps png "$eps_to_png" ""
|
||||
\\converter jpg png "$jpg_to_png" ""
|
||||
|
||||
\\viewer dvi "$DVI_VIEWER"
|
||||
\\viewer html "$HTML_VIEWER"
|
||||
|
Loading…
Reference in New Issue
Block a user