Commit [883855]  Maximize  Restore  History

From: mstsxfx@gmail.com

To: pdfedit-devel@lists.sourceforge.net
Subject: [PATCH @num@/@total@] Configurable variables consolidation

It is rather long time since I have started Unified makefiles patchset and
there were several things I was lazy work on those days. Most of them were
marked as "TODO from autoconf" and the main motivation was to make almost
everything configurable from configure script rather than having them
hard-coded.

This patch sets all those variable (in Makefile.flags.in) from configure.
In the result it means that we can modify them during configuration when
necessary (e.g. ./configure COPY="something else than cp" will use given
"something else than cp" instead of default "cp -f".

The second important thing which is done here, is the consolidation of all
these variables with those coming out of qmake when it generates makefile.
Qmake has its own idea about COPY, MKDIR, ... variables and we have to force
it to use our configured values.

I have used the same trick which is already used for unification of
compiler - make all configurable variables used by qmake 2 layered:
CONFIG_NAME is set by configured and used in pro file and NAME used in our
makefiles is initialized from CONFIG_NAME.

* config/env.m4
- CHK_OR_DEFINE_VAR(PARAM1, PARAM2) macro added
- PARAM1 stands for variable we want to check and set
- PARAM2 default value if PARAM1 isn't defined yet
- it should be used for all configurable variables because
we can push such a variable by ./configure NAME=value or
from configure itself when needed (just define such
variable)
-TODO - maybe we could include also AC_SUBST into this
macro. Any idea how Martin? (I have tried AC_SUBS($[]$1 but
it didn't work)
* configure.in
- all hard-coded variables from Makefile.flags.in defined by CHK_OR_DEFINE_VAR
* Makefile.flags.in
- all hard-coded variables are set from configure now (except for
C*FLAGS and our headers and libraries paths
* gui/pdfedit.pro, kpdf-kde-3.3.2/qoutputdevices.pro
- All variables which might affect installation replaced initialized
from CONFIG_* equivalents
- TODO I wasn't able to force SYMLINK initialization
QMAKE_SYMLINK = $(CONFIG_SYMLINK) doesn't seem to work - I have tried
even SYMLINK = $(CONFIG_SYMLINK) withou success
* README
- information about compilation flags added

Changelog v1 -> v2
==================
* ARCH, C{XX}_FLAGS, EXTRA_*C{XX}FLAGS set from configurable by configure
parameters in the same way like all others - hopefully no more hardcoded
variables in the Makefile.flags.in
* README updated to contain information about compilation flags

Michal Hocko Michal Hocko 2008-11-13

changed Makefile.flags.in
changed README
changed config/env.m4
changed configure.in
changed src/gui/pdfedit.pro
changed src/kpdf-kde-3.3.2/qoutputdevices.pro
Makefile.flags.in Diff Switch to side-by-side view
Loading...
README Diff Switch to side-by-side view
Loading...
config/env.m4 Diff Switch to side-by-side view
Loading...
configure.in Diff Switch to side-by-side view
Loading...
src/gui/pdfedit.pro Diff Switch to side-by-side view
Loading...
src/kpdf-kde-3.3.2/qoutputdevices.pro Diff Switch to side-by-side view
Loading...

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks