autogen.sh is reporting some warnings as below
./autogen.sh 2>&1 |grep "obsolete"
libtoolize: copying file 'm4/lt~obsolete.m4'
configure.ac:115: warning: The macro `AC_LANG_C' is obsolete.
configure.ac:115: warning: The macro `AC_TRY_COMPILE' is obsolete.
configure.ac:134: warning: The macro `AC_LANG_C' is obsolete.
configure.ac:134: warning: The macro `AC_TRY_COMPILE' is obsolete.
configure.ac:135: warning: The macro `AC_LANG_C' is obsolete.
configure.ac:135: warning: The macro `AC_TRY_COMPILE' is obsolete.
configure.ac:146: warning: The macro `AC_LANG_C' is obsolete.
configure.ac:146: warning: The macro `AC_TRY_COMPILE' is obsolete.
configure.ac:146: warning: The macro `AC_LANG_C' is obsolete.
configure.ac:146: warning: The macro `AC_TRY_COMPILE' is obsolete.
configure.ac:373: warning: The macro `AC_LANG_C' is obsolete.
configure.ac:373: warning: The macro `AC_TRY_COMPILE' is obsolete.
configure.ac:458: warning: The macro `AC_HEADER_TIME' is obsolete.
configure.ac:681: warning: The macro `AC_TRY_LINK' is obsolete.
configure.ac:807: warning: The macro `AC_TRY_LINK' is obsolete.
As the minimum autoconf version required is v2.69,
we need to make sure to update obsolete macros as described at
https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Obsolete-Macros.html
The autotool provides a simple mechanism which allows us to move ("divert")
the checks we do on the user arguments to the beginning of the script, yet
without needing to scatter the code.
This is good because we can raise errors very fast, user do not have to
wait until many other checks have passed before knowing he has to correct
his argument list; yet on our side we can keep related things together.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
When running the 'make website' command, it will call groff to convert the
man pages into HTML and post-process them to get them in the style of the
site, then place them in the Website Git Repository.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
When the new configure option '--with-web-repo' is used, the new target
'make website' becomes available and will generate HTML pages to be placed
in the Homepage Repository.
This patch does not generate any content yet but it prepares the skeleton
to handle everything.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Make use of the standard macro for PKG_CONFIG; the default behaviour is now
to use Pango if present, instead of requiring explicit user request, yet
still not making it mandatory.
The detection code was moved to a macro to keep the configure.ac script
(relatively) small, and consistent with what is done for most other libs.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The original macro used over-complicated things, like:
- useless uses of 'eval',
- split AC_CACHE_CHECK construct (AC_MSG_CHECKING + AC_CACHE_VAL +
AC_MSG_RESULT)
- dubious variable name (CPPFLAGS_old, which is not the "old" value but
the "saved" value for a temporary change)
- variable CPPFLAGS was changed at wrong hierarchy level
- calculate the integer value for XFT_VERSION in m4 instead generating
shell commands that had to do it on user side
- indentation was missing
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The goal is to use standard macros, which make code easier to maintain
(smaller, more consistent). We still keep the legacy "xfg-config" method
because we don't want to drop support for old hardware/software.
A side effect is the change in the name of the variables for the makefile,
but this goes in favour of consistency.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This patch brings more consistency in the presentation of comments,
including:
- 2 line spaces between blocks (M4 macro tend to make the file look quite
bulky, so it is making the file more aerated)
- fixes in the length of underlining
- adding a few comments on the reason of the check to ease maintainance
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Some macros have evolved, so this patch brings the appropriate updates:
- AC_OUTPUT(...) is now split in AC_CONFIG_FILES(...) and AC_OUTPUT, took
the opportunity to sort the list of files so it is easier to maintain
- the macro AC_DECL_SYS_SIGLIST is now replaced by the more generic
AC_CHECK_DECLS([sys_siglist]), but as it turns out that we're not using it,
the check was just removed
- autoconf assumes that AC_TYPE_SIGNAL is deprecated because the type was
fixed since C89, but as we expect to still run on old hardware, we keep the
macro given by autoupdate on our side for when Autoconf will stop providing
the macro
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
As discovered by Douglas Torrance, this flag is not really portable, so
this patch adds a check in the configure script to detect if any known
define could help. If no value works, we fall back to defining it with the
neutral value '0', so the compilation will not fail.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
As pointed by Coverity (#50226), the function getenv can return unreliable
data, so if a sensitive application makes uses of the function 'wgethomedir'
or 'wusergnusteppath' we'd better use the GNU function secure_getenv which
ignore environment variable when used in a known critical cases.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
There are a number of steps in the library check procedure that are a bit
repetitive, and have been placed into the macro WM_LIB_CHECK to make the
code simpler to write.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The function can have a wider use, so moved then to a more neutral place
and gave them more generic names.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
When autoconf encounters a macro name that it does not know, it assumes
that it is just a standard keyword that needs to end up in the generated
configure script.
This patch teaches m4 about the syntax used for our macros so it can now
that it is supposed to be a macro, and then it can stop and report the
problem.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
- according to the automake manual, `acinclude.m4' is the old style
of doing stuff, putting local macros in their own directory is the
way to go, so move acincluce.m4 to m4/windowmaker.m4
- reflect this in autogen.sh and Makefile.am
- while there, add a `conditionally set cflags' macro from the
autoconf macro archive
- use this to slightly pump warning levels up if we are on gcc