From 35364e13de7f992baaed35916dc1ef8a0b4d3edd Mon Sep 17 00:00:00 2001 From: W-Mark Kubacki Date: Tue, 25 May 2010 23:07:35 +0200 Subject: fcgiwrap to rely on definitions provided by autoconf/autoreconf --- .gitignore | 2 ++ Makefile.in | 2 +- README.rst | 2 +- configure.ac | 5 ++++- fcgiwrap.c | 8 ++++---- 5 files changed, 12 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index 1925144..728cc03 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,6 @@ *.cache +config.h +config.h.in config.log config.status configure diff --git a/Makefile.in b/Makefile.in index 7a6904b..bd0da97 100644 --- a/Makefile.in +++ b/Makefile.in @@ -17,7 +17,7 @@ clean: #>+ 21 distclean: clean -rm -rf config.log config.status autom4te.cache - -rm -f configure Makefile + -rm -f configure Makefile config.h config.h.in #>+ 21 uninstall: diff --git a/README.rst b/README.rst index 4302ab4..8ca3471 100644 --- a/README.rst +++ b/README.rst @@ -27,7 +27,7 @@ procedure --------- To install:: - autoconf + autoreconf -i ./configure make make install diff --git a/configure.ac b/configure.ac index 24c0a6e..06d1ed4 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.61) -AC_INIT(fcgiwrap, 1.0, root@localdomain.pl) +AC_INIT([fcgiwrap], [1.0.1], [root@localdomain.pl]) AM_CFLAGS="-std=gnu99 -Wall -Wextra -Werror -pedantic" if test x"$CFLAGS" = x""; then AM_CFLAGS="$AM_CFLAGS -O2 -g3" @@ -15,6 +15,9 @@ AC_SUBST([AM_CFLAGS]) # Checks for programs. AC_PROG_CC +# Create the config.h. +AC_CONFIG_HEADERS([config.h]) + # Checks for libraries. AC_CHECK_LIB([fcgi], [FCGX_Init],, [AC_MSG_ERROR([FastCGI library is missing])]) diff --git a/fcgiwrap.c b/fcgiwrap.c index e030f91..cd58ca1 100644 --- a/fcgiwrap.c +++ b/fcgiwrap.c @@ -24,8 +24,8 @@ */ #define NO_FCGI_DEFINES -#define FCGIWRAP_VERSION "1.0" +#include "config.h" #include #include #include @@ -628,12 +628,12 @@ int main(int argc, char **argv) switch (c) { case 'h': printf("Usage: %s [OPTION]\nInvokes CGI scripts as FCGI.\n\n" - "fcgiwrap version "FCGIWRAP_VERSION"\n\n" + PACKAGE_NAME" version "PACKAGE_VERSION"\n\n" "Options are:\n" " -c 1..x\t\tNumber of processes to prefork\n" " -h\t\t\tShow this help message and exit\n" - "\nReport bugs to Grzegorz Nosek .\n" - "fcgiwrap home page: \n", + "\nReport bugs to Grzegorz Nosek <"PACKAGE_BUGREPORT">.\n" + PACKAGE_NAME" home page: \n", argv[0] ); return 0; -- cgit v1.2.3