aboutsummaryrefslogtreecommitdiff
path: root/libbutl-pkg-config/libpkg-config/config.h
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2024-05-06 08:45:22 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2024-05-06 09:41:51 +0200
commit2e21b218db0e979d56b7b6027854a86ad7ffc96b (patch)
treef0ebc7c223be1dd88f47cb3399e82659cda09ade /libbutl-pkg-config/libpkg-config/config.h
parenta54213a4ff48ecfa8fa3b416d12b1282158746dc (diff)
Add libbutl-pkg-config source subdirectory
This is an additional (to libbutl) utility library which contains the source code of libpkg-config configured and tuned for our needs.
Diffstat (limited to 'libbutl-pkg-config/libpkg-config/config.h')
-rw-r--r--libbutl-pkg-config/libpkg-config/config.h41
1 files changed, 41 insertions, 0 deletions
diff --git a/libbutl-pkg-config/libpkg-config/config.h b/libbutl-pkg-config/libpkg-config/config.h
new file mode 100644
index 0000000..c1c5e8d
--- /dev/null
+++ b/libbutl-pkg-config/libpkg-config/config.h
@@ -0,0 +1,41 @@
+/* file : libpkg-config/config.h.in -*- C -*-
+ * license : ISC; see accompanying COPYING file
+ */
+#ifndef LIBPKG_CONFIG_CONFIG_H
+#define LIBPKG_CONFIG_CONFIG_H
+
+#if defined(__linux__)
+# include <features.h> /* __GLIBC__, __GLIBC_MINOR__ */
+#endif
+
+/*
+ * strndup() is not present on Windows while strl*() are only present on
+ * *BSD and MacOS.
+ *
+ */
+#if !defined(_WIN32)
+# define HAVE_STRNDUP 1
+#endif
+
+/*
+ * GNU libc added strlcpy() and strlcat() in version 2.38 (in anticipation
+ * of their addition to POSIX).
+ */
+#if defined(__FreeBSD__) || \
+ defined(__OpenBSD__) || \
+ defined(__NetBSD__) || \
+ defined(__APPLE__) || \
+ (defined(__GLIBC__) && \
+ defined(__GLIBC_MINOR__) && \
+ (__GLIBC__ > 2 || __GLIBC__ == 2 && __GLIBC_MINOR__ >= 38))
+# define HAVE_STRLCPY 1
+# define HAVE_STRLCAT 1
+#endif
+
+#define LIBPKG_CONFIG_PROJECT_URL "https://github.com/build2/libpkg-config"
+
+#define PKG_CONFIG_DEFAULT_PATH ""
+#define SYSTEM_INCLUDEDIR ""
+#define SYSTEM_LIBDIR ""
+
+#endif /* LIBPKG_CONFIG_CONFIG_H */