[PATCH modular] Delete scripts written in 2005 to generate modular configuration

Gaetan Nadon memsize at videotron.ca
Sun Sep 19 07:11:45 PDT 2010


These scripts generated configure.ac and other Autoconf files
for apps, libs and drivers.

Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
---
 modularizeapp.sh         |  217 ----------------------------
 modularizelibrary.sh     |  306 ---------------------------------------
 modularizevideodriver.sh |  354 ----------------------------------------------
 3 files changed, 0 insertions(+), 877 deletions(-)
 delete mode 100755 modularizeapp.sh
 delete mode 100755 modularizelibrary.sh
 delete mode 100755 modularizevideodriver.sh

diff --git a/modularizeapp.sh b/modularizeapp.sh
deleted file mode 100755
index 258ffec..0000000
--- a/modularizeapp.sh
+++ /dev/null
@@ -1,217 +0,0 @@
-#!/bin/bash
-
-# Variables
-
-if [ -z $1 ] ; then
-    echo
-    echo Usage: $0 \<directory\>
-    echo
-    exit
-fi
-
-# fixme: modular dir should 
-
-MODULAR_DIR=`( cd $1 ; cd ../.. ; pwd )`
-MODULE_DIR=`( cd $1 ; pwd )`
-MODULE_NAME=`( basename $MODULE_DIR )`
-modulename=`echo $MODULE_NAME | tr "[:upper:]" "[:lower:]"`
-
-if [ -z foo ]  ; then
-    echo Modular dir: $MODULAR_DIR
-    echo Module dir : $MODULE_DIR
-    echo Name: $MODULE_NAME
-    echo lower: $modulename
-    echo Man dir: $HAS_MAN_DIR
-    echo Include dir: $HAS_INCLUDE_DIR
-fi
-
-cd $MODULE_DIR
-
-touch		AUTHORS
-touch		ChangeLog
-touch		COPYING
-touch		INSTALL
-touch		NEWS
-touch		README
-
-#			touch
-#		Generate README
-#			touch
-#		Generate Makefile.am
-
-rm -f Makefile.am
-
-cat <<EOF >> Makefile.am
-# 
-#  Copyright 2005  Red Hat, Inc.
-# 
-#  Permission to use, copy, modify, distribute, and sell this software and its
-#  documentation for any purpose is hereby granted without fee, provided that
-#  the above copyright notice appear in all copies and that both that
-#  copyright notice and this permission notice appear in supporting
-#  documentation, and that the name of Red Hat not be used in
-#  advertising or publicity pertaining to distribution of the software without
-#  specific, written prior permission.  Red Hat makes no
-#  representations about the suitability of this software for any purpose.  It
-#  is provided "as is" without express or implied warranty.
-# 
-#  RED HAT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
-#  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
-#  EVENT SHALL RED HAT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
-#  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
-#  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
-#  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-#  PERFORMANCE OF THIS SOFTWARE.
-
-bin_PROGRAMS = $modulename
-
-${modulename}_CFLAGS = \$(DEP_CFLAGS)
-${modulename}_LDADD = \$(DEP_LIBS)
-
-${modulename}_SOURCES =	\\
-EOF
-
-# Source files
-
-for x in `ls *.[ch]` ; do
-    LAST=$x
-done
-
-for x in `ls *.[ch]`; do
-    if [ $x = $LAST ] ; then
-	echo \ \ \ \ \ \ \ \ $x			>> Makefile.am
-    else
-	echo \ \ \ \ \ \ \ \ $x \\			>> Makefile.am
-    fi
-done
-
-echo >> Makefile.am
-
-# Man files
-
-LAST=
-for x in `ls *.man` ; do
-    LAST=$x
-done
-
-if [ ! -z $LAST ] ; then
-    echo dist_man_MANS =			\\	>> Makefile.am
-    for x in `ls *.man` ; do
-	if [ $x = $LAST ] ; then
-	    echo \ \ \ \ \ \ \ \ $x		>> Makefile.am
-	else
-	    echo \ \ \ \ \ \ \ \ $x	\\	>> Makefile.am
-	fi
-    done
-
-    echo >> Makefile.am
-fi
-
-# .ad files
-
-LAST=
-for x in `ls *.ad` ; do
-    LAST=$x
-done
-
-if [ ! -z $LAST ] ; then
-    cat <<EOF >> Makefile.am
-# App default files  (*.ad)
-
-appdefaultdir = \$(sysconfdir)/X11/app-defaults
-
-EOF
-
-    cat <<EOF >> Makefile.am
-
-APPDEFAULTFILES = \\
-EOF
-    
-    for x in `ls *.ad` ; do
-	FILE=`echo $x | sed 's/\.ad//'`
-	if [ $x = $LAST ] ; then
-	    echo \ \ \ \ \ \ \ \ $FILE		>> Makefile.am
-	else
-	    echo \ \ \ \ \ \ \ \ $FILE	\\	>> Makefile.am
-	fi
-    done
-
-    cat <<EOF >> Makefile.am
-
-SUFFIXES = .ad
-
-.ad:
-	cp \$< \$@
-
-appdefault_DATA = \$(APPDEFAULTFILES)
-
-EXTRA_DIST = \$(APPDEFAULTFILES:%=%.ad)
-
-CLEANFILES = \$(APPDEFAULTFILES)
-
-EOF
-fi
-
-#		Generate configure.ac
-rm -f configure.ac
-
-cat <<EOF >> $MODULE_DIR/configure.ac
-
-dnl  Copyright 2005 Red Hat, Inc.
-dnl 
-dnl  Permission to use, copy, modify, distribute, and sell this software and its
-dnl  documentation for any purpose is hereby granted without fee, provided that
-dnl  the above copyright notice appear in all copies and that both that
-dnl  copyright notice and this permission notice appear in supporting
-dnl  documentation, and that the name of Red Hat not be used in
-dnl  advertising or publicity pertaining to distribution of the software without
-dnl  specific, written prior permission.  Red Hat makes no
-dnl  representations about the suitability of this software for any purpose.  It
-dnl  is provided "as is" without express or implied warranty.
-dnl 
-dnl  RED HAT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
-dnl  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
-dnl  EVENT SHALL RED HAT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
-dnl  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
-dnl  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
-dnl  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-dnl  PERFORMANCE OF THIS SOFTWARE.
-dnl
-dnl Process this file with autoconf to create configure.
-
-AC_PREREQ([2.57])
-AC_INIT($modulename,[7.0], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],$modulename)
-AM_INIT_AUTOMAKE([dist-bzip2])
-AM_MAINTAINER_MODE
-
-AM_CONFIG_HEADER(config.h)
-
-AC_PROG_CC
-AC_PROG_INSTALL
-
-# Checks for pkg-config packages
-PKG_CHECK_MODULES(DEP, x11)
-AC_SUBST(DEP_CFLAGS)
-AC_SUBST(DEP_LIBS)
-
-AC_OUTPUT([Makefile])
-EOF
-
-
-rm -f autogen.sh
-cat <<EOF >> autogen.sh
-#! /bin/sh
-
-srcdir=\`dirname \$0\`
-test -z "\$srcdir" && srcdir=.
-
-ORIGDIR=\`pwd\`
-cd \$srcdir
-
-autoreconf -v --install || exit 1
-cd \$ORIGDIR || exit \$?
-
-\$srcdir/configure --enable-maintainer-mode "\$@"
-
-EOF
-chmod a+x autogen.sh
diff --git a/modularizelibrary.sh b/modularizelibrary.sh
deleted file mode 100755
index d7329f9..0000000
--- a/modularizelibrary.sh
+++ /dev/null
@@ -1,306 +0,0 @@
-#!/bin/bash
-
-# Variables
-
-if [ -z $1 ] ; then
-    echo
-    echo Usage: $0 \<directory\>
-    echo
-    exit
-fi
-
-# fixme: modular dir should 
-
-MODULAR_DIR=`( cd $1 ; cd ../.. ; pwd )`
-MODULE_DIR=`( cd $1 ; pwd )`
-MODULE_NAME=`( basename $MODULE_DIR )`
-modulename=`echo $MODULE_NAME | tr "[:upper:]" "[:lower:]"`
-
-if [ -x $MODULE_DIR/man ] ; then
-    HAS_MAN_DIR="yes"
-else
-    HAS_MAN_DIR="no"
-fi
-
-if [ -x $MODULE_DIR/include ] ; then
-    HAS_INCLUDE_DIR="yes"
-else
-    HAS_INCLUDE_DIR="no"
-fi
-
-if [ -z foo ]  ; then
-    echo Modular dir: $MODULAR_DIR
-    echo Module dir : $MODULE_DIR
-    echo Name: $MODULE_NAME
-    echo lower: $modulename
-    echo Man dir: $HAS_MAN_DIR
-    echo Include dir: $HAS_INCLUDE_DIR
-fi
-
-# 
-#	Generate build files
-#		Generate autogen.sh
-#			Copy from Xfixes
-cp $MODULAR_DIR/lib/Xfixes/autogen.sh $MODULAR_DIR/lib/$MODULE_NAME
-
-cd $MODULE_DIR
-
-touch		AUTHORS
-touch		ChangeLog
-touch		COPYING
-touch		INSTALL
-touch		NEWS
-touch		README
-
-#			touch
-#		Generate README
-#			touch
-#		Generate Makefile.am
-
-rm -f Makefile.am
-
-cat <<EOF >> Makefile.am
-# 
-#  Copyright 2005  Red Hat, Inc.
-# 
-#  Permission to use, copy, modify, distribute, and sell this software and its
-#  documentation for any purpose is hereby granted without fee, provided that
-#  the above copyright notice appear in all copies and that both that
-#  copyright notice and this permission notice appear in supporting
-#  documentation, and that the name of Red Hat not be used in
-#  advertising or publicity pertaining to distribution of the software without
-#  specific, written prior permission.  Red Hat makes no
-#  representations about the suitability of this software for any purpose.  It
-#  is provided "as is" without express or implied warranty.
-# 
-#  RED HAT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
-#  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
-#  EVENT SHALL RED HAT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
-#  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
-#  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
-#  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-#  PERFORMANCE OF THIS SOFTWARE.
-
-EOF
-
-if [ $HAS_MAN_DIR = "yes" ] ; then
-    cat << EOF >> Makefile.am
-SUBDIRS = src man
-EOF
-else
-    cat <<EOF >> Makefile.am
-SUBDIRS = src
-EOF
-fi
-
-cat <<EOF >> Makefile.am
-
-pkgconfigdir = \$(libdir)/pkgconfig
-pkgconfig_DATA = $modulename.pc
-
-EXTRA_DIST = $modulename.pc.in autogen.sh
-
-EOF
-
-#		Generate configure.ac
-
-rm -f configure.ac
-
-cat <<EOF >> $MODULE_DIR/configure.ac
-
-dnl  Copyright 2005 Red Hat, Inc.
-dnl 
-dnl  Permission to use, copy, modify, distribute, and sell this software and its
-dnl  documentation for any purpose is hereby granted without fee, provided that
-dnl  the above copyright notice appear in all copies and that both that
-dnl  copyright notice and this permission notice appear in supporting
-dnl  documentation, and that the name of Red Hat not be used in
-dnl  advertising or publicity pertaining to distribution of the software without
-dnl  specific, written prior permission.  Red Hat makes no
-dnl  representations about the suitability of this software for any purpose.  It
-dnl  is provided "as is" without express or implied warranty.
-dnl 
-dnl  RED HAT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
-dnl  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
-dnl  EVENT SHALL RED HAT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
-dnl  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
-dnl  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
-dnl  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-dnl  PERFORMANCE OF THIS SOFTWARE.
-dnl
-dnl Process this file with autoconf to create configure.
-
-AC_PREREQ([2.57])
-
-AC_INIT(lib$MODULE_NAME, 7.0.0, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], lib$MODULE_NAME)
-AM_INIT_AUTOMAKE([dist-bzip2])
-AM_MAINTAINER_MODE
-
-AM_CONFIG_HEADER(config.h)
-
-# Check for progs
-AC_PROG_CC
-AC_PROG_LIBTOOL
-
-# Check for dependencies
-PKG_CHECK_MODULES(DEP, x11)
-
-AC_SUBST(DEP_CFLAGS)
-AC_SUBST(DEP_LIBS)
-		  
-AC_OUTPUT([Makefile
-	   src/Makefile
-EOF
-
-if [ $HAS_MAN_DIR = yes ] ; then
-    cat <<EOF >> configure.ac
-	   man/Makefile
-EOF
-fi
-
-cat <<EOF >> configure.ac
-           $modulename.pc])
-EOF
-
-#		Generate .pc.in
-
-cat <<EOF > $modulename.pc.in
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: $MODULE_NAME
-Description: The $MODULE_NAME Library
-Version: @PACKAGE_VERSION@
-Cflags: -I\${includedir} @DEP_CFLAGS@
-Libs: -L\${libdir} -l$MODULE_NAME @DEP_LIBS@
-
-EOF
-
-#
-#		src/Makefile
-#
-
-cd src
-
-rm -f Makefile.am
-
-cat <<EOF > Makefile.am
-lib_LTLIBRARIES = lib$MODULE_NAME.la
-
-lib${MODULE_NAME}_la_SOURCES = \ 
-EOF
-
-for x in `ls *.[ch]` ; do
-    LAST=$x
-done
-
-for x in `ls *.[ch]`; do
-    if [ $x = $LAST ] ; then
-	echo \ \ \ \ \ \ \ \ \ $x			>> Makefile.am
-    else
-	echo \ \ \ \ \ \ \ \ \ $x \\			>> Makefile.am
-    fi
-done
-
-if [ $HAS_INCLUDE_DIR = yes ] ; then
-    
-    HEADERFILE=`find ../include -name "*.h" | head -n 1`
-
-    INCLUDE_SRC_DIR=`dirname $HEADERFILE | sed "s/../\\$(top_srcdir)/"`
-
-    INCLUDE_INSTALL_DIR=`dirname $HEADERFILE | sed "s/..\/include/\\$(includedir)/"`
-
-    cat <<EOF >> Makefile.am
-
-INCLUDES = -I$INCLUDE_SRC_DIR
-
-EOF
-
-fi
-
-cat <<EOF >> Makefile.am
-
-lib${MODULE_NAME}_la_LIBADD = @DEP_LIBS@
-
-lib${MODULE_NAME}_la_LDFLAGS = -version-info 7:0:0 -no-undefined
-
-EOF
-
-
-if [ $HAS_INCLUDE_DIR = yes ] ; then
-
-    cat <<EOF >> Makefile.am
-
-lib${MODULE_NAME}includedir = $INCLUDE_INSTALL_DIR
-lib${MODULE_NAME}include_HEADERS = \\
-EOF
-
-    for f in `find ../include -name "*.h"` ; do
-	LAST=$f
-    done
-
-    for f in `find ../include -name "*.h"` ; do
-
-	NAME=`echo $f | sed "s/../\\$(top_srcdir)/"`
-
-	echo -n \ \ \ \ $NAME				>> Makefile.am
-
-	if [ $LAST = $f ] ; then
-	    echo					>> Makefile.am
-	else
-	    echo \\					>> Makefile.am
-	fi
-    done
-fi
-
-echo >> Makefile.am
-
-#
-#		man/Makefile
-#
-
-if [ $HAS_MAN_DIR = yes ] ; then
-
-    cd ../man
-    rm -f Makefile.am
-    cat <<EOF > Makefile.am
-#  Copyright 2005  Red Hat, Inc.
-# 
-#  Permission to use, copy, modify, distribute, and sell this software and its
-#  documentation for any purpose is hereby granted without fee, provided that
-#  the above copyright notice appear in all copies and that both that
-#  copyright notice and this permission notice appear in supporting
-#  documentation, and that the name of Red Hat not be used in
-#  advertising or publicity pertaining to distribution of the software without
-#  specific, written prior permission.  Red Hat makes no representations about
-#  the suitability of this software for any purpose.  It is provided "as is" without
-#  express or implied warranty.
-# 
-#  RED HAT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
-#  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
-#  EVENT SHALL RED HAT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
-#  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
-#  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
-#  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-#  PERFORMANCE OF THIS SOFTWARE.
-#
-
-man_MANS = \\
-EOF
-    
-    for x in `ls *.3` ; do
-	LAST=$x
-    done
-    
-    for x in `ls *.3`; do
-	if [ $x = $LAST ] ; then
-	    echo \ \ \ \ \ \ \ \ \ $x			>> Makefile.am
-	else
-	    echo \ \ \ \ \ \ \ \ \ $x \\			>> Makefile.am
-	fi
-    done
-    
-    echo "EXTRA_DIST = \$(man3_MANS)"			>> Makefile.am
-fi
diff --git a/modularizevideodriver.sh b/modularizevideodriver.sh
deleted file mode 100755
index 6bf7250..0000000
--- a/modularizevideodriver.sh
+++ /dev/null
@@ -1,354 +0,0 @@
-#!/bin/bash
-
-###########################
-#
-#	Variables and setup
-#
-
-if [ -z $1 ] ; then
-    echo
-    echo Usage: $0 \<directory\>
-    echo
-    exit
-fi
-
-if [ ! -z $2 ] ; then
-    if [ $2="dri" ] ; then
-	has_dri="yes"
-    fi
-fi
-
-MODULAR_DIR=`( cd $1 ; cd ../.. ; pwd )`
-MODULE_DIR=`( cd $1 ; pwd )`
-MODULE_NAME=`( basename $MODULE_DIR )`
-modulename=`echo $MODULE_NAME | tr "[:upper:]" "[:lower:]"`
-drivername=`echo $MODULE_NAME | sed s/xf86-video-//`
-
-if [ -z foo ]  ; then
-    echo Modular dir: $MODULAR_DIR
-    echo Module dir : $MODULE_DIR
-    echo Name: $MODULE_NAME
-    echo lower: $modulename
-    echo Man dir: $HAS_MAN_DIR
-    echo Include dir: $HAS_INCLUDE_DIR
-fi
-
-cd $MODULE_DIR
-
-#
-# man pages?
-#
-
-for x in `ls man/*` ; do
-    man_pages=true
-done
-
-
-###############################
-#
-#	Generate autogen.sh
-#
-
-rm -f autogen.sh
-
-cat <<EOF >> autogen.sh
-#! /bin/sh
-
-srcdir=\`dirname \$0\`
-test -z "\$srcdir" && srcdir=.
-
-ORIGDIR=\`pwd\`
-cd \$srcdir
-
-autoreconf -v --install || exit 1
-cd \$ORIGDIR || exit \$?
-
-\$srcdir/configure --enable-maintainer-mode "\$@"
-
-EOF
-
-chmod a+x autogen.sh
-
-
-###################################
-#
-#     Generate toplevel Makefile.am
-#
-
-rm -f Makefile.am
-
-cat <<EOF >> Makefile.am
-#  Copyright 2005 Adam Jackson.
-#
-#  Permission is hereby granted, free of charge, to any person obtaining a
-#  copy of this software and associated documentation files (the "Software"),
-#  to deal in the Software without restriction, including without limitation
-#  on the rights to use, copy, modify, merge, publish, distribute, sub
-#  license, and/or sell copies of the Software, and to permit persons to whom
-#  the Software is furnished to do so, subject to the following conditions:
-#
-#  The above copyright notice and this permission notice (including the next
-#  paragraph) shall be included in all copies or substantial portions of the
-#  Software.
-#
-#  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-#  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-#  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
-#  ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
-#  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
-#  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-AUTOMAKE_OPTIONS = foreign
-EOF
-
-if [ -z $man_pages ]  ; then 
-    echo SUBDIRS = src				>> Makefile.am
-else
-    echo SUBDIRS = src man			>> Makefile.am
-fi
-
-#
-#	Generate configure.ac
-#
-
-rm -f configure.ac
-
-cat <<EOF >> configure.ac
-#  Copyright 2005 Adam Jackson.
-#
-#  Permission is hereby granted, free of charge, to any person obtaining a
-#  copy of this software and associated documentation files (the "Software"),
-#  to deal in the Software without restriction, including without limitation
-#  on the rights to use, copy, modify, merge, publish, distribute, sub
-#  license, and/or sell copies of the Software, and to permit persons to whom
-#  the Software is furnished to do so, subject to the following conditions:
-#
-#  The above copyright notice and this permission notice (including the next
-#  paragraph) shall be included in all copies or substantial portions of the
-#  Software.
-#
-#  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-#  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-#  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
-#  ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
-#  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
-#  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-# Process this file with autoconf to produce a configure script
-
-AC_PREREQ(2.57)
-AC_INIT([xf86-video-$drivername],
-        0.1.0,
-        [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
-        xf86-video-$drivername)
-
-AC_CONFIG_SRCDIR([Makefile.am])
-AM_CONFIG_HEADER([config.h])
-AC_CONFIG_AUX_DIR(.)
-
-AM_INIT_AUTOMAKE([dist-bzip2])
-
-AM_MAINTAINER_MODE
-
-# Checks for programs.
-AC_PROG_LIBTOOL
-AC_PROG_CC
-
-AH_TOP([#include "xorg-server.h"])
-
-AC_ARG_WITH(xorg-module-dir,
-            AC_HELP_STRING([--with-xorg-module-dir=DIR],
-                           [Default xorg module directory [[default=\$libdir/xorg/modules]]]),
-            [moduledir="\$withval"],
-            [moduledir="\$libdir/xorg/modules"])
-EOF
-
-if [ ! -z $has_dri ] ; then
-    cat <<EOF >> configure.ac
-
-AC_ARG_ENABLE(dri, AC_HELP_STRING([--disable-dri],
-                                  [Disable DRI support [[default=auto]]]),
-              [DRI="\$enableval"],
-              [DRI=auto])
-EOF
-fi
-
-cat <<EOF  >> configure.ac
-# Checks for pkg-config packages
-PKG_CHECK_MODULES(XORG, [xorg-server xproto])
-sdkdir=\$(pkg-config --variable=sdkdir xorg-server)
-
-# Checks for libraries.
-
-# Checks for header files.
-AC_HEADER_STDC
-
-EOF
-
-if [ ! -z $has_dri ] ; then
-    cat <<EOF >> configure.ac
-if test "\$DRI" != no; then
-        AC_CHECK_FILE([\${sdkdir}/dri.h],
-                      [have_dri_h="yes"], [have_dri_h="no"])
-        AC_CHECK_FILE([\${sdkdir}/sarea.h],
-                      [have_sarea_h="yes"], [have_sarea_h="no"])
-        AC_CHECK_FILE([\${sdkdir}/dristruct.h],
-                      [have_dristruct_h="yes"], [have_dristruct_h="no"])
-fi
-
-AC_MSG_CHECKING([whether to include DRI support])
-if test x\$DRI = xauto; then
-        if test "\$ac_cv_header_dri_h" = yes -a \\
-                "\$ac_cv_header_sarea_h" = yes -a \\
-                "\$ac_cv_header_dristruct_h" = yes; then
-                DRI="yes"
-        else
-                DRI="no"
-        fi
-fi
-AC_MSG_RESULT([\$DRI])
-
-AM_CONDITIONAL(DRI, test x\$DRI = xyes)
-if test "\$DRI" = yes; then
-        PKG_CHECK_MODULES(DRI, [libdrm])
-        AC_DEFINE(XF86DRI,1,[Enable DRI driver support])
-        AC_DEFINE(XF86DRI_DEVEL,1,[Enable developmental DRI driver support])
-fi
-
-AC_SUBST([DRI_CFLAGS])
-EOF
-fi
-cat <<EOF >> configure.ac
-AC_SUBST([XORG_CFLAGS])
-AC_SUBST([moduledir])
-
-AC_OUTPUT([
-	Makefile
-	src/Makefile
-EOF
-
-if [ ! -z $man_pages ]  ; then 
-    cat <<EOF >> configure.ac
-	man/Makefile
-EOF
-fi
-
-cat <<EOF >> configure.ac
-])
-EOF
-
-##############################
-#
-#	man/Makefile.am
-#
-if [ ! -z $man_pages ] ; then
-    cd man
-
-    rm -f Makefile.am
-
-    cat <<EOF >> Makefile.am
-#  Copyright 2005 Adam Jackson.
-#
-#  Permission is hereby granted, free of charge, to any person obtaining a
-#  copy of this software and associated documentation files (the "Software"),
-#  to deal in the Software without restriction, including without limitation
-#  on the rights to use, copy, modify, merge, publish, distribute, sub
-#  license, and/or sell copies of the Software, and to permit persons to whom
-#  the Software is furnished to do so, subject to the following conditions:
-#
-#  The above copyright notice and this permission notice (including the next
-#  paragraph) shall be included in all copies or substantial portions of the
-#  Software.
-#
-#  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-#  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-#  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
-#  ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
-#  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
-#  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-dist_man_MANS = \\
-EOF
-
-    for x in `ls *.4` ; do
-	LAST=$x ;
-    done
-    
-    for x in `ls *.4` ; do
-	if [ $x = $LAST ] ; then
-	    echo \ \ \ \ \ \ \ \ \ $x		>> Makefile.am
-	else
-	    echo \ \ \ \ \ \ \ \ \ $x \\	>> Makefile.am
-	fi
-    done ;
-    cd ..
-fi
-
-############################
-#
-#	src/Makefile.am
-#
-
-cd src
-
-rm -f Makefile.am
-
-cat <<EOF >> Makefile.am
-#  Copyright 2005 Adam Jackson.
-#
-#  Permission is hereby granted, free of charge, to any person obtaining a
-#  copy of this software and associated documentation files (the "Software"),
-#  to deal in the Software without restriction, including without limitation
-#  on the rights to use, copy, modify, merge, publish, distribute, sub
-#  license, and/or sell copies of the Software, and to permit persons to whom
-#  the Software is furnished to do so, subject to the following conditions:
-#
-#  The above copyright notice and this permission notice (including the next
-#  paragraph) shall be included in all copies or substantial portions of the
-#  Software.
-#
-#  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-#  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-#  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
-#  ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
-#  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
-#  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-# this is obnoxious:
-# -module lets us name the module exactly how we want
-# -avoid-version prevents gratuitous .0.0.0 version numbers on the end
-# _ladir passes a dummy rpath to libtool so the thing will actually link
-# TODO: -nostdlib/-Bstatic/-lgcc platform magic, not installing the .a, etc.
-EOF
-
-if [ ! -z $has_dri ]; then
-    cat <<EOF >> Makefile.am
-AM_CFLAGS = @XORG_CFLAGS@ @DRI_CFLAGS@
-EOF
-else
-    cat <<EOF >> Makefile.am
-AM_CFLAGS = @XORG_CFLAGS@
-EOF
-fi
-
-cat <<EOF >> Makefile.am
-${drivername}_drv_la_LTLIBRARIES = ${drivername}_drv.la
-${drivername}_drv_la_LDFLAGS = -module -avoid-version
-${drivername}_drv_ladir = @moduledir@/drivers
-
-${drivername}_drv_la_SOURCES = \\
-EOF
-
-for x in `ls *.[ch]` ; do
-    LAST=$x
-done
-
-for x in `ls *.[ch]` ; do
-    if [ $x = $LAST ] ; then
-	echo \ \ \ \ \ \ \ \ \ $x	>> Makefile.am
-    else
-	echo \ \ \ \ \ \ \ \ \ $x \\	>> Makefile.am
-    fi
-done
-
-cd ..
-- 
1.6.0.4



More information about the xorg-devel mailing list