From 1ed336759fdf3bfbb1f233e5a5c5b611530436ef Mon Sep 17 00:00:00 2001 From: Chun-wei Fan Date: Fri, 16 Oct 2015 13:02:55 +0800 Subject: build: Add a pre-configure config.h template for MSVC builds This adds a pre-configured config.h(.win32.in) that can be used for builds on Visual Studio, where autotools is normally not available, so that we can build pkg-config on Visual Studio. --- Makefile.am | 4 ++- config.h.win32.in | 98 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ configure.ac | 1 + 3 files changed, 102 insertions(+), 1 deletion(-) create mode 100644 config.h.win32.in diff --git a/Makefile.am b/Makefile.am index be35ee2..b7ead64 100644 --- a/Makefile.am +++ b/Makefile.am @@ -45,7 +45,9 @@ m4dir = $(datadir)/aclocal m4_DATA = pkg.m4 dist_doc_DATA = pkg-config-guide.html dist_man_MANS = pkg-config.1 -EXTRA_DIST = README.win32 +EXTRA_DIST = \ + README.win32 \ + config.h.win32 # gcov test coverage gcov: diff --git a/config.h.win32.in b/config.h.win32.in new file mode 100644 index 0000000..697130f --- /dev/null +++ b/config.h.win32.in @@ -0,0 +1,98 @@ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Define ${prefix} in .pc files at runtime */ +#define ENABLE_DEFINE_PREFIX 1 + +/* Link library to all dependent libraries, not only directly needed ones */ +#define ENABLE_INDIRECT_DEPS 1 + +/* Define to 1 if you have the header file. */ +#ifndef _MSC_VER +#define HAVE_DIRENT_H 1 +#endif + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_DLFCN_H */ + +/* Define to 1 if you have the header file. */ +#if !defined (_MSC_VER) || (_MSC_VER >= 1800) +#define HAVE_INTTYPES_H 1 +#endif + +/* Define to 1 if you have the header file. */ +#define HAVE_MALLOC_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_MEMORY_H 1 + +/* Define to 1 if you have the header file. */ +#if (!defined(_MSC_VER) || (_MSC_VER >= 1600)) +#define HAVE_STDINT_H 1 +#endif + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the header file. */ +#ifndef _MSC_VER +#define HAVE_STRINGS_H 1 +#endif + +/* Define to 1 if you have the header file. */ +#define HAVE_STRING_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_SYS_WAIT_H */ + +/* Define to 1 if you have the header file. */ +#ifndef _MSC_VER +#define HAVE_UNISTD_H 1 +#endif + +/* Define to the sub-directory in which libtool stores uninstalled libraries. + */ +#define LT_OBJDIR ".libs/" + +/* Name of package */ +#define PACKAGE "pkg-config" + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "@PACKAGE_BUGREPORT@" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "@PACKAGE_NAME@" + +/* Define to the full name and version of this package. */ +#define PACKAGE_STRING "@PACKAGE_NAME@ @PACKAGE_VERSION@" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "@PACKAGE_TARNAME@" + +/* Define to the home page for this package. */ +#define PACKAGE_URL "" + +/* Define to the version of this package. */ +#define PACKAGE_VERSION "@PACKAGE_VERSION@" + +/* Define to 1 if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Version number of package */ +#define VERSION "@PACKAGE_VERSION@" + +/* Enable large inode numbers on Mac OS X 10.5. */ +#ifndef _DARWIN_USE_64_BIT_INODE +# define _DARWIN_USE_64_BIT_INODE 1 +#endif + +/* Number of bits in a file offset, on hosts where this is settable. */ +/* #undef _FILE_OFFSET_BITS */ + +/* Define for large files, on AIX-style hosts. */ +/* #undef _LARGE_FILES */ diff --git a/configure.ac b/configure.ac index af2172c..fd44b59 100644 --- a/configure.ac +++ b/configure.ac @@ -258,5 +258,6 @@ Makefile pkg.m4 check/Makefile check/config.sh +config.h.win32 ]) AC_OUTPUT -- cgit v1.2.1