head	1.7;
access;
symbols
	rpm-4_4_6-release:1.3.2.2
	rpm-4_4_5-release:1.3.2.2
	db-4_4_20:1.6
	rpm-4_4_4-release:1.3.2.1
	db-4_4_16:1.5
	rpm-4_4_3-release:1.3.2.1
	db-4_4_11:1.5
	db-4_3_29:1.3
	jbj_before_tklcpatches:1.3
	rpm-4_4_2-release:1.3
	pjones-sparse-experiment:1.4.0.2
	db-4_4_4:1.4
	rpm-4_4_1-release:1.3
	db-4_3_27:1.3
	rpm-4_4-release:1.3
	rpm-4_4:1.3.0.2
	db-4_3_21:1.3
	db-4_3_14:1.3
	db-4_2_52:1.2
	rpm-4_3_1-start:1.2
	rpm-4_3:1.2.0.2
	rpm-4_2_1-release:1.1.1.5
	rpm-4_1_1-release:1.1.1.5
	rpm-4_2-release:1.1.1.5
	rpm-4_2:1.1.1.5.0.2
	postmerge-db-4_1_24-release:1.1.1.5
	premerge-db-4_1_24-release:1.1.1.5
	db-4_1_24-release:1.1.1.5
	pre-db-4_1_24-release:1.1.1.5
	rpm-4_1-release:1.1.1.4
	postmerge-db-4_1_17:1.1.1.5
	premerge-db-4_1_17:1.1.1.5
	db-4_1_17:1.1.1.5
	pre-db-4_1_17:1.1.1.4
	rpm-4_1:1.1.1.4.0.2
	rpm-4_0_4-release:1.1.1.2.2.2
	jbj-before-beecrypt:1.1.1.2.2.2
	postmerge-db-4_0_14:1.1.1.4
	premerge-db-4_0_14:1.1.1.4
	db-4_0_14:1.1.1.4
	pre-db-4_0_14:1.1.1.4
	rpm-4_0_3-release:1.1.1.2.2.1
	postmerge-db-4_0_7:1.1.1.4
	premerge-db-4_0_7:1.1.1.4
	db-4_0_7:1.1.1.4
	pre-db-4_0_7:1.1.1.3
	jbj_b4_rollback:1.1.1.2.2.1
	postmerge-db-3_3_11-release:1.1.1.3
	premerge-db-3_3_11-release:1.1.1.3
	db-3_3_11-release:1.1.1.3
	pre-db-3_3_11-release:1.1.1.2
	rpm-4_0:1.1.1.2.0.2
	postmerge-db-3_3_4-release:1.1.1.2
	premerge-db-3_3_4-release:1.1.1.2
	db-3_3_4-release:1.1.1.2
	pre-db-3_3_4-release:1.1.1.1
	db-3_2_9-release:1.1.1.1
	db-3_2_9-vendor:1.1.1;
locks; strict;
comment	@# @;
expand	@o@;


1.7
date	2006.10.01.20.18.54;	author jbj;	state dead;
branches;
next	1.6;

1.6
date	2006.02.13.16.32.26;	author jbj;	state Exp;
branches;
next	1.5;

1.5
date	2005.10.28.17.13.18;	author jbj;	state Exp;
branches;
next	1.4;

1.4
date	2005.02.21.15.53.58;	author jbj;	state Exp;
branches;
next	1.3;

1.3
date	2004.10.16.01.31.55;	author jbj;	state Exp;
branches
	1.3.2.1;
next	1.2;

1.2
date	2003.12.15.21.42.42;	author jbj;	state Exp;
branches;
next	1.1;

1.1
date	2001.03.21.18.33.38;	author jbj;	state Exp;
branches
	1.1.1.1;
next	;

1.1.1.1
date	2001.03.21.18.33.38;	author jbj;	state Exp;
branches;
next	1.1.1.2;

1.1.1.2
date	2001.05.13.19.58.27;	author jbj;	state Exp;
branches
	1.1.1.2.2.1;
next	1.1.1.3;

1.1.1.3
date	2001.07.23.20.09.05;	author jbj;	state Exp;
branches;
next	1.1.1.4;

1.1.1.4
date	2001.10.15.03.47.23;	author jbj;	state Exp;
branches;
next	1.1.1.5;

1.1.1.5
date	2002.08.14.16.31.56;	author jbj;	state Exp;
branches;
next	;

1.1.1.2.2.1
date	2001.07.23.20.31.15;	author jbj;	state Exp;
branches;
next	1.1.1.2.2.2;

1.1.1.2.2.2
date	2002.01.08.04.07.17;	author jbj;	state Exp;
branches;
next	;

1.3.2.1
date	2005.10.28.18.44.32;	author jbj;	state Exp;
branches;
next	1.3.2.2;

1.3.2.2
date	2006.02.13.17.51.08;	author jbj;	state Exp;
branches;
next	1.3.2.3;

1.3.2.3
date	2006.10.01.22.29.21;	author jbj;	state dead;
branches;
next	;


desc
@@


1.7
log
@Update to db-4.5.20.
@
text
@#!/bin/sh -
#	$Id: s_win32_dsp,v 12.3 2005/10/20 01:45:53 mjc Exp $
#
# Build Windows/32 .dsp files.

. RELEASE

SRCFILES=srcfiles.in

create_dsp()
{
    projname="$1"       # name of the .dsp file
    match="$2"          # the string used to egrep the $sources file
    sources="$3"        # a modified version of $SRCFILES to facilitate matches
    dsptemplate="$4"    # overall template file for the .dsp
    extra_cppflags="$5" # extra flags to send to compiler
    release_libs="$6"   # libraries to link against in Release builds
    debug_libs="$7"     # libraries to link against in Debug builds
    lib_suffix="$8"     # the library name is libdb@@lib_suffix@@@@VERSION@@

    srctemplate="$BUILDDIR/srcfile_dsp.src"    # template file for the src file fragments
    dspoutput=$BUILDDIR/$projname.dsp


    postbuild=$dspoutput.postbuild
    if [ ! -f $postbuild ] ; then
	    postbuild=/dev/null
    fi

    rm -f $dspoutput.insert
    for srcpath in `egrep "$match" $sources | sed -e 's/[ 	].*//'`
    do
        # take the path name and break it up, converting / to \\.
        # so many backslashes needed because of shell quoting and
        # sed quoting -- we'll end up with two backslashes for every
        # forward slash, but we need that when feeding that to the
        # later sed command.
        set - `echo $srcpath | sed -e 's;\(.*\)/;../\\1 ;' \
            -e "s;$BUILDDIR;.;" \
            -e 's;/;\\\\\\\\;g'`
	srcdir="$1"
	srcfile="$2"
        sed -e "s/@@srcdir@@/$srcdir/g" \
            -e "s/@@srcfile@@/$srcfile/g" \
            < $srctemplate >> $dspoutput.insert
    done
    sed -e "/@@SOURCE_FILES@@/r$dspoutput.insert" \
        -e "/@@SOURCE_FILES@@/d" \
	-e "/@@POST_BUILD@@/r$postbuild" \
        -e "/@@POST_BUILD@@/d" \
        -e "s/@@project_name@@/$projname/g" \
        -e "s/@@bin_rel_dest@@/Release/g" \
        -e "s/@@lib_rel_dest@@/Release/g" \
        -e "s/@@bin_debug_dest@@/Debug/g" \
        -e "s/@@lib_debug_dest@@/Debug/g" \
        -e "s,@@extra_cppflags@@,$extra_cppflags,g" \
        -e "s,@@release_libs@@,$release_libs,g" \
        -e "s,@@debug_libs@@,$debug_libs,g" \
        -e "s,@@lib_suffix@@,$lib_suffix,g" \
        -e "s/@@DB_VERSION_MAJOR@@/$DB_VERSION_MAJOR/g" \
        -e "s/@@DB_VERSION_MINOR@@/$DB_VERSION_MINOR/g" \
      < $dsptemplate > $dspoutput.new

    # Set the file mode to 644 because the VC++ IDE needs a writeable file
    # in our development environment.
    cmp $dspoutput.new $dspoutput > /dev/null 2>&1 ||
	(echo "Building $dspoutput" && rm -f $dspoutput &&
	    cp $dspoutput.new $dspoutput && chmod 664 $dspoutput)
    rm -f $dspoutput.insert $dspoutput.new
}

TMPA=/tmp/swin32dsp$$a
trap "rm -f $TMPA; exit 1" 1 2 3 15

# create a copy of the srcfiles with comments and empty lines removed.
# add a space at the end of each list of modules so that each module
# can be unambiguously matched e.g. ' dynamic '
sed -e "s/#.*$//" \
    -e "/^[ 	]*$/d" \
    -e "s/[ 	][ 	]*/ /" \
    -e "s/[ 	]*$//" \
    -e "/[	 ]/!d" \
    -e "s/$/ /" < $SRCFILES > $TMPA

# get a list of all modules mentioned
#
MODULES="`sed -e 's/^[^ ]* //' < $TMPA \
    | tr ' ' '\012' | sort | uniq`"

for BUILDDIR in ../build_win32
do
    for module in $MODULES
    do
        case "$module" in
        dynamic )
            create_dsp db_dll " $module " $TMPA $BUILDDIR/dynamic_dsp.src
            ;;
        small )
            create_dsp db_small " $module " $TMPA $BUILDDIR/static_dsp.src \
                '/D "HAVE_SMALLBUILD"' '' '' _small
            ;;
        static )
            create_dsp db_static " $module " $TMPA $BUILDDIR/static_dsp.src
            ;;
        java )
            create_dsp db_java " $module " $TMPA $BUILDDIR/dynamic_dsp.src '' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@.lib' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@d.lib' _java
            ;;
        tcl )
            create_dsp db_tcl " $module " $TMPA $BUILDDIR/dynamic_dsp.src \
                '/D "DB_TCL_SUPPORT"' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@.lib tcl84.lib' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@d.lib tcl84g.lib' _tcl
            ;;
        testutil )
            create_dsp db_test " $module " $TMPA $BUILDDIR/app_dsp.src \
	        '' '/out:"dbkill.exe"' '/out:"dbkill.exe"'
            ;;
        app=ex_repquote )
            create_dsp ex_repquote " $module " $TMPA \
                    $BUILDDIR/app_dsp.src '' 'ws2_32.lib' 'ws2_32.lib'
            ;;
        app=* )
            appname=`echo $module | sed -e 's/^app=//'`
            create_dsp $appname " $module " $TMPA \
                    $BUILDDIR/app_dsp.src
            ;;
        vx|vxsmall )
            ;;
        * )
            echo "s_win32_dsp: module name $module in $SRCFILES is unknown type"
            ;;
        esac
    done
done

rm -f $TMPA
@


1.6
log
@Upgrade to db-4.4.20 - replace files and remove old cruft.
@
text
@@


1.5
log
@Update to db-4.4.11.
@
text
@d118 1
a118 1
	        '' '/out:"$(OUTDIR)/dbkill.exe"' '/out:"$(OUTDIR)/dbkill.exe"'
@


1.4
log
@Upgrade to db-4.4.4.
@
text
@d2 1
a2 1
#	$Id: s_win32_dsp,v 12.1 2005/01/25 12:40:51 mjc Exp $
d16 4
a19 1
    srctemplate="$5"    # template file for the src file fragments
d21 1
d24 6
d49 2
a53 2
        -e "s/@@bin_relstatic_dest@@/Release_Static/g" \
        -e "s/@@lib_relstatic_dest@@/Release_Static/g" \
d56 4
a59 2
        -e "s/@@bin_debugstatic_dest@@/Debug_Static/g" \
        -e "s/@@lib_debugstatic_dest@@/Debug_Static/g" \
d90 1
a90 1
for BUILDDIR in ../build_win32 ../build_win64
d96 1
a96 2
            create_dsp db_dll " $module " $TMPA \
                    $BUILDDIR/dynamic_dsp.src $BUILDDIR/srcfile_dsp.src
d99 2
a100 2
            create_dsp db_small " $module " $TMPA \
                    $BUILDDIR/small_dsp.src $BUILDDIR/srcfile_dsp.src
d103 1
a103 2
            create_dsp db_static " $module " $TMPA \
                    $BUILDDIR/static_dsp.src $BUILDDIR/srcfile_dsp.src
d106 3
a108 2
            create_dsp db_java " $module " $TMPA \
                    $BUILDDIR/java_dsp.src $BUILDDIR/srcfile_dsp.src
d111 4
a114 2
            create_dsp db_tcl " $module " $TMPA \
                    $BUILDDIR/tcl_dsp.src $BUILDDIR/srcfile_dsp.src
d117 6
a122 2
            create_dsp db_test " $module " $TMPA \
                    $BUILDDIR/db_test.src $BUILDDIR/srcfile_dsp.src
a125 5
            if [ -f $BUILDDIR/$appname.src ] ; then
                    srcname=$BUILDDIR/$appname.src
            else
                    srcname=$BUILDDIR/app_dsp.src
            fi
d127 1
a127 1
                    $srcname $BUILDDIR/srcfile_dsp.src
@


1.3
log
@... and in with the New ...
@
text
@d2 1
a2 1
#	$Id: s_win32_dsp,v 1.12 2004/08/20 15:01:06 mjc Exp $
d40 8
@


1.3.2.1
log
@Update to db-4.4.11.
@
text
@d2 1
a2 1
#	$Id: s_win32_dsp,v 12.3 2005/10/20 01:45:53 mjc Exp $
d16 1
a16 4
    extra_cppflags="$5" # extra flags to send to compiler
    release_libs="$6"   # libraries to link against in Release builds
    debug_libs="$7"     # libraries to link against in Debug builds
    lib_suffix="$8"     # the library name is libdb@@lib_suffix@@@@VERSION@@
a17 1
    srctemplate="$BUILDDIR/srcfile_dsp.src"    # template file for the src file fragments
a19 6

    postbuild=$dspoutput.postbuild
    if [ ! -f $postbuild ] ; then
	    postbuild=/dev/null
    fi

a38 2
	-e "/@@POST_BUILD@@/r$postbuild" \
        -e "/@@POST_BUILD@@/d" \
a39 8
        -e "s/@@bin_rel_dest@@/Release/g" \
        -e "s/@@lib_rel_dest@@/Release/g" \
        -e "s/@@bin_debug_dest@@/Debug/g" \
        -e "s/@@lib_debug_dest@@/Debug/g" \
        -e "s,@@extra_cppflags@@,$extra_cppflags,g" \
        -e "s,@@release_libs@@,$release_libs,g" \
        -e "s,@@debug_libs@@,$debug_libs,g" \
        -e "s,@@lib_suffix@@,$lib_suffix,g" \
d70 1
a70 1
for BUILDDIR in ../build_win32
d76 2
a77 1
            create_dsp db_dll " $module " $TMPA $BUILDDIR/dynamic_dsp.src
d80 2
a81 2
            create_dsp db_small " $module " $TMPA $BUILDDIR/static_dsp.src \
                '/D "HAVE_SMALLBUILD"' '' '' _small
d84 2
a85 1
            create_dsp db_static " $module " $TMPA $BUILDDIR/static_dsp.src
d88 2
a89 3
            create_dsp db_java " $module " $TMPA $BUILDDIR/dynamic_dsp.src '' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@.lib' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@d.lib' _java
d92 2
a93 4
            create_dsp db_tcl " $module " $TMPA $BUILDDIR/dynamic_dsp.src \
                '/D "DB_TCL_SUPPORT"' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@.lib tcl84.lib' \
                'libdb@@DB_VERSION_MAJOR@@@@DB_VERSION_MINOR@@d.lib tcl84g.lib' _tcl
d96 2
a97 6
            create_dsp db_test " $module " $TMPA $BUILDDIR/app_dsp.src \
	        '' '/out:"$(OUTDIR)/dbkill.exe"' '/out:"$(OUTDIR)/dbkill.exe"'
            ;;
        app=ex_repquote )
            create_dsp ex_repquote " $module " $TMPA \
                    $BUILDDIR/app_dsp.src '' 'ws2_32.lib' 'ws2_32.lib'
d101 5
d107 1
a107 1
                    $BUILDDIR/app_dsp.src
@


1.3.2.2
log
@Upgrade to db-4.4.20.
@
text
@d118 1
a118 1
	        '' '/out:"dbkill.exe"' '/out:"dbkill.exe"'
@


1.3.2.3
log
@Merge db-4.5.20 onto rpm-4_4 branch.
@
text
@@


1.2
log
@- upgrade to db-4.2.52.
@
text
@d2 1
a2 1
#	$Id: s_win32_dsp,v 1.10 2003/03/24 10:35:21 mjc Exp $
a7 1
BUILDDIR=../build_win32
d29 1
a29 1
            -e 's;../build_win32;.;' \
d70 1
a70 1
for module in $MODULES
d72 44
a115 41
    case "$module" in
    dynamic )
        create_dsp db_dll " $module " $TMPA \
		$BUILDDIR/dynamic_dsp.src $BUILDDIR/srcfile_dsp.src
        ;;
    small )
        create_dsp db_small " $module " $TMPA \
		$BUILDDIR/small_dsp.src $BUILDDIR/srcfile_dsp.src
        ;;
    static )
        create_dsp db_static " $module " $TMPA \
		$BUILDDIR/static_dsp.src $BUILDDIR/srcfile_dsp.src
        ;;
    java )
        create_dsp db_java " $module " $TMPA \
		$BUILDDIR/java_dsp.src $BUILDDIR/srcfile_dsp.src
        ;;
    tcl )
        create_dsp db_tcl " $module " $TMPA \
		$BUILDDIR/tcl_dsp.src $BUILDDIR/srcfile_dsp.src
        ;;
    testutil )
        create_dsp db_test " $module " $TMPA \
		$BUILDDIR/db_test.src $BUILDDIR/srcfile_dsp.src
        ;;
    app=* )
	appname=`echo $module | sed -e 's/^app=//'`
	if [ -f $BUILDDIR/$appname.src ] ; then
		srcname=$BUILDDIR/$appname.src
	else
		srcname=$BUILDDIR/app_dsp.src
	fi
        create_dsp $appname " $module " $TMPA \
		$srcname $BUILDDIR/srcfile_dsp.src
        ;;
    vx )
	;;
    * )
        echo "s_win32_dsp: module name $module in $SRCFILES is unknown type"
        ;;
    esac
@


1.1
log
@Initial revision
@
text
@d2 1
a2 1
#	$Id: s_win32_dsp,v 1.3 2000/12/02 04:36:47 dda Exp $
a20 1
    echo "Building $dspoutput"
d44 7
a50 2
    rm -f $dspoutput $dspoutput.insert
    mv $dspoutput.new $dspoutput
d54 1
a54 1
trap "rm -f $TMPA; exit 1" 1 2 3 15 
d56 1
a56 1
# create a copy of the srcfiles with comments and 'skip' lines removed.
a58 1
#
d63 1
a63 1
    -e "/ skip$/d" \
d78 8
d94 3
a96 3
    static )
        create_dsp db_static " $module " $TMPA \
		$BUILDDIR/static_dsp.src $BUILDDIR/srcfile_dsp.src
d100 5
d106 1
a106 1
		$BUILDDIR/app_dsp.src $BUILDDIR/srcfile_dsp.src
d108 2
@


1.1.1.1
log
@db-3.2.9
@
text
@@


1.1.1.2
log
@track: auto import
@
text
@d2 1
a2 1
#	Id: s_win32_dsp,v 1.4 2001/04/26 12:50:59 dda Exp 
a81 4
        ;;
    testutil )
        create_dsp db_test " $module " $TMPA \
		$BUILDDIR/db_test.src $BUILDDIR/srcfile_dsp.src
@


1.1.1.2.2.1
log
@Merge db-3.3.11 onto rpm-4_0 branch.
@
text
@d2 1
a2 1
#	$Id: s_win32_dsp,v 1.5 2001/05/27 14:03:33 bostic Exp $
d21 1
d45 2
a46 4
    cmp $dspoutput.new $dspoutput > /dev/null 2>&1 ||
	(echo "Building $dspoutput" && rm -f $dspoutput &&
	    cp $dspoutput.new $dspoutput && chmod 444 $dspoutput)
    rm -f $dspoutput.insert $dspoutput.new
@


1.1.1.2.2.2
log
@Update to db-4.0.14.
@
text
@d2 1
a2 1
#	Id: s_win32_dsp,v 1.7 2001/08/07 18:19:37 bostic Exp 
a43 3

    # Set the file mode to 644 because the VC++ IDE needs a writeable file
    # in our development environment.
d46 1
a46 1
	    cp $dspoutput.new $dspoutput && chmod 664 $dspoutput)
d51 1
a51 1
trap "rm -f $TMPA; exit 1" 1 2 3 15
@


1.1.1.3
log
@track: auto import
@
text
@d2 1
a2 1
#	Id: s_win32_dsp,v 1.5 2001/05/27 14:03:33 bostic Exp 
d21 1
d45 2
a46 4
    cmp $dspoutput.new $dspoutput > /dev/null 2>&1 ||
	(echo "Building $dspoutput" && rm -f $dspoutput &&
	    cp $dspoutput.new $dspoutput && chmod 444 $dspoutput)
    rm -f $dspoutput.insert $dspoutput.new
@


1.1.1.4
log
@track: auto import
@
text
@d2 1
a2 1
#	Id: s_win32_dsp,v 1.7 2001/08/07 18:19:37 bostic Exp 
a43 3

    # Set the file mode to 644 because the VC++ IDE needs a writeable file
    # in our development environment.
d46 1
a46 1
	    cp $dspoutput.new $dspoutput && chmod 664 $dspoutput)
d51 1
a51 1
trap "rm -f $TMPA; exit 1" 1 2 3 15
@


1.1.1.5
log
@track: auto import
@
text
@d2 1
a2 1
#	Id: s_win32_dsp,v 1.8 2002/03/26 23:37:55 bostic Exp 
d56 1
a56 1
# create a copy of the srcfiles with comments and empty lines removed.
d59 1
d64 1
a64 1
    -e "/[	 ]/!d" \
a99 2
    vx )
	;;
@


