[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [libredwg] avoiding pkg-config
From: |
Thien-Thi Nguyen |
Subject: |
Re: [libredwg] avoiding pkg-config |
Date: |
Mon, 20 Oct 2014 22:06:38 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
() Piyush Parkash <address@hidden>
() Mon, 20 Oct 2014 23:51:55 +0530
Is there a way to compile on make check?
Yes, in fact the current testsuite/xmlsuite/Makefile.am
already has the correct formulation:
check_PROGRAMS = testsuite
This snippet means "make" does not build program ‘testsuite’
(from testsuite.c), but "make check" does, prior to running
the tests defined in makefile var ‘TESTS’.
So, no worries; all is well on that count.
The problematic part is this:
LIBXML = `pkg-config libxml-2.0 --cflags`
This is problematic for two reasons: (a) the variable name
‘LIBXML’ is not descriptive of the variable's value, namely
compiler flags particular to libxml; (b) using backticks to
find those flags at "make check" time is inefficient should
there be more than one program that needs to link against
libxml. Admittedly, (b) is a potential concern and not an
immediate one (hence in my patch i retained their usage),
but since we are doing proper long-term thinking (evidenced
by going w/ pkg-config over foo-config), we might as well
avoid planting in the first place a minor convenience that
will only grow into a problem (to be re-fixed) in the future.
Rather than fully explain now what i meant by:
the pkg-config(1) invocation should anyway be moved from
"make check" time to configure.ac.
i will post a patch shortly that should make things concretely
clear (and if not, that's more room for improvement :-D). At
the moment, i await resolution of:
http://lists.gnu.org/archive/html/hydra-users/2014-10/msg00001.html
so that i can simply add ‘pkgconfig’ to ‘vdeps’. Hydra
(actually Nix) syntax is still somewhat strange to me...
I can do this or I can make testsuite independent?
I think only a small bit of the Makefile.am needs to change;
let's leave the rest alone -- "if it works, don't fix it!"
--
Thien-Thi Nguyen
GPG key: 4C807502
(if you're human and you know it)
read my lisp: (responsep (questions 'technical)
(not (via 'mailing-list)))
=> nil
signature.asc
Description: PGP signature