OSDN Git Service

Add configure script checks for prerequisite library headers.
authorKeith Marshall <keithmarshall@users.sourceforge.net>
Sat, 17 Apr 2010 22:18:08 +0000 (22:18 +0000)
committerKeith Marshall <keithmarshall@users.sourceforge.net>
Sat, 17 Apr 2010 22:18:08 +0000 (22:18 +0000)
ChangeLog
aclocal.m4 [new file with mode: 0644]
configure.ac

index c759d8c..fbc5f2d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,17 @@
 2010-04-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
 
+       Add configure script checks for prerequisite library headers.
+       (Thanks to Cesar Strauss for proposing a rudimentary implementation).
+
+       * aclocal.m4: New file; it does no more than include...
+       * m4/missing.m4: ...this; new file incorporated from build-aux module.
+
+       * configure.ac: Add AC_CHECK_HEADER assertions for...
+       (zlib.h, bzlib.h, lzma.h): ...these; invoke MINGW_AC_ASSERT_MISSING in
+       respect of each failing assertion.
+
+2010-04-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
+
        Case-insensitive subsystem name matching revisited.
 
        * src/pkgfind.cpp (pkgXmlDocument::FindPackageByName): Use...
diff --git a/aclocal.m4 b/aclocal.m4
new file mode 100644 (file)
index 0000000..f72dccd
--- /dev/null
@@ -0,0 +1,27 @@
+# aclocal.m4 -*- autoconf -*- vim: filetype=config
+#
+# $Id$
+#
+# Written by Keith Marshall <keithmarshall@users.sourceforge.net>
+# Copyright (C) 2009, 2010, MinGW Project
+#
+#
+# Configuration script for mingw-get
+#
+#
+# This is free software.  Permission is granted to copy, modify and
+# redistribute this software, under the provisions of the GNU General
+# Public License, Version 3, (or, at your option, any later version),
+# as published by the Free Software Foundation; see the file COPYING
+# for licensing details.
+#
+# Note, in particular, that this software is provided "as is", in the
+# hope that it may prove useful, but WITHOUT WARRANTY OF ANY KIND; not
+# even an implied WARRANTY OF MERCHANTABILITY, nor of FITNESS FOR ANY
+# PARTICULAR PURPOSE.  Under no circumstances will the author, or the
+# MinGW Project, accept liability for any damages, however caused,
+# arising from the use of this software.
+#
+  m4_include([m4/missing.m4])
+#
+# $RCSfile$: end of file
index 1c5a001..ac44a24 100644 (file)
 #
   AC_PROG_LEX
 
+# Ensure that (at least the headers for) prerequisite libraries,
+# zlib, libbz2 and liblzma are available
+#
+  AC_CHECK_HEADER([zlib.h],,MINGW_AC_ASSERT_MISSING([zlib],
+    [libz-1.2.3-1-mingw32-dev.tar.gz]))
+  AC_CHECK_HEADER([bzlib.h],,MINGW_AC_ASSERT_MISSING([libbz2],
+    [bzip2-1.0.5-2-mingw32-dev.tar.gz]))
+  AC_CHECK_HEADER([lzma.h],,MINGW_AC_ASSERT_MISSING([liblzma],
+    [liblzma-4.999.9beta_20091209-3-mingw32-dev.tar.bz2]))
+
 # Set up the archive librarian, to match our compiler settings
 #
   AC_CHECK_TOOL([AR],[ar],[ar])