From be9e0a889ad4b6551ae16df3324b2f7ebba0600c Mon Sep 17 00:00:00 2001 From: Hans Ulrich Niedermann Date: Sun, 16 Feb 2020 18:25:46 +0100 Subject: New set based camlib definition and --with-camlibs handling This uses proper set operations both for GP_CAMLIB and for handling the --with-camlibs value. This allows all GP_CAMLIB definitions to be present at autoreconf time (as m4 code) time while some camlib definitions being conditional at the time of the configure run (in the sh code). The ./configure output is still a bit verbose, but we can reduce that verbosity later when we have found out that this works well on people's different systems. Fixes: https://github.com/gphoto/libgphoto2/issues/467 --- libgphoto2/gphoto2-version.c | 45 ++++++++++++++++++++++++++++++++++++-------- 1 file changed, 37 insertions(+), 8 deletions(-) (limited to 'libgphoto2') diff --git a/libgphoto2/gphoto2-version.c b/libgphoto2/gphoto2-version.c index bacf06a34..6cf16254c 100644 --- a/libgphoto2/gphoto2-version.c +++ b/libgphoto2/gphoto2-version.c @@ -34,12 +34,23 @@ const char **gp_library_version(GPVersionVerbosity verbose) static const char *shrt[] = { PACKAGE_VERSION, -#ifdef INCOMPLETE_CAMLIB_SET - "INCOMPLETE CAMLIB SET (" - INCOMPLETE_CAMLIB_SET +#if GP_CAMLIB_SET_IS_NONSTANDARD + "NON-STANDARD CAMLIB SET" + " (" + GP_CAMLIB_SET +#ifdef GP_CAMLIB_SET_SKIPPING + " SKIPPING " + GP_CAMLIB_SET_SKIPPING +#endif ")", #else - "all camlibs", + "standard camlibs" +#ifdef GP_CAMLIB_SET_SKIPPING + " (SKIPPING " + GP_CAMLIB_SET_SKIPPING + ")" +#endif + , #endif #ifdef HAVE_CC HAVE_CC, @@ -61,12 +72,30 @@ const char **gp_library_version(GPVersionVerbosity verbose) static const char *verb[] = { PACKAGE_VERSION, -#ifdef INCOMPLETE_CAMLIB_SET - "INCOMPLETE CAMLIB SET (" - INCOMPLETE_CAMLIB_SET +#if GP_CAMLIB_SET_IS_NONSTANDARD + "NON-STANDARD CAMLIB SET" +#ifdef GP_CAMLIB_SET_SKIPPING + " SKIPPING SOME" +#endif + " (" + GP_CAMLIB_SET +#ifdef GP_CAMLIB_SET_SKIPPING + " SKIPPING " + GP_CAMLIB_SET_SKIPPING +#endif ")", #else - "all camlibs", + "standard camlib set" +#ifdef GP_CAMLIB_SET_SKIPPING + " SKIPPING SOME" +#endif + " (" + GP_CAMLIB_SET +#ifdef GP_CAMLIB_SET_SKIPPING + " SKIPPING " + GP_CAMLIB_SET_SKIPPING +#endif + ")", #endif #ifdef HAVE_CC HAVE_CC " (C compiler used)", -- cgit v1.2.1