head	1.3;
access;
symbols
	ansi-20040405-merged:1.2.6.1
	premerge-autoconf:1.2
	postmerge-20040315-windows:1.2
	premerge-20040315-windows:1.2
	windows-20040315-freeze:1.2.4.1
	autoconf-20031203:1.2
	autoconf-20031202:1.2
	phong-branch:1.1.0.4
	photonmap-branch:1.1.0.2
	windows-branch:1.2.0.4
	ansi-branch:1.2.0.6
	AUTOCONF:1.2.0.2;
locks; strict;
comment	@# @;


1.3
date	2004.03.18.18.16.36;	author erikg;	state dead;
branches;
next	1.2;

1.2
date	2003.09.27.00.30.46;	author morrison;	state Exp;
branches
	1.2.2.1
	1.2.4.1
	1.2.6.1;
next	1.1;

1.1
date	2003.03.13.20.03.39;	author jra;	state Exp;
branches;
next	;

1.2.2.1
date	2004.03.18.18.10.30;	author erikg;	state dead;
branches;
next	;

1.2.4.1
date	2004.03.12.09.59.37;	author morrison;	state Exp;
branches;
next	;

1.2.6.1
date	2004.03.17.21.20.21;	author morrison;	state Exp;
branches;
next	;


desc
@@


1.3
log
@merge of AUTOCONF branch in to HEAD
@
text
@/*
 *			libtk/Cakefile
 */
#define SRCDIR	[[echo libtk''TCLTK_VERS]]
#define	SRCSUFF	.c
#define MANSECTION	3

#include "../Cakefile.defs"

#if !defined(NO_LIBTK)

/* Since we're building a library, we can't also list a regular
 * program (like tclsh) in the PRODUCTS rule, it will confuse
 * the BUILD_LIBRARY rule in Cakefile.defs.
 * Hence the EXTRA_PRODUCTS dodge
 */

#if !defined(BUILD_LIBRARY)
#define BUILD_LIBRARY	ar r
#define TK_OPTS	--srcdir=[[pwd]]/../SRCDIR/"unix" --cache-file cache.MTYPE \
			 --exec-prefix=BASEDIR --prefix=BASEDIR \
			 --x-includes=XINCDIR --x-libraries=XLIBDIR \
			 --with-tcl=[[pwd]]/LIBTCL_DIR \
			 --disable-shared --quiet
#define PRODUCTS	[[echo libtk''TCLTK_VERS.a]]
#define	AFTER_MAKE	rm -f libtk.a ; ln -s PRODUCTS libtk.a
#else
#define TK_OPTS	--srcdir=[[pwd]]/../SRCDIR/"unix" --enable-shared \
			 --cache-file cache.MTYPE --exec-prefix=BASEDIR --prefix=BASEDIR \
			 --x-includes=XINCDIR --x-libraries=XLIBDIR \
			 --with-tcl=[[pwd]]/LIBTCL_DIR \
			 --quiet
#define PRODUCTS	[[echo libtk''TCLTK_VERS.''ARCH_SUF]]
#define	SHARED_PRODUCT  libtk''TCLTK_VERS.''ARCH_SUF''[[LIBVERS]]
#define	AFTER_MAKE	mv -f libtk''TCLTK_VERS.''ARCH_SUF SHARED_PRODUCT ; sharedliblink.sh SHARED_PRODUCT ; rm -f libtk.''ARCH_SUF ; ln -s SHARED_PRODUCT libtk.''ARCH_SUF
#endif
#define EXTRA_PRODUCTS	wish

#if defined(USE_64)
#define ENABLE_64 --enable-64bit
#else
#define ENABLE_64 /**/
#endif

/* Rule to see if cake is running with -s flag */
#define MINUS_S	[[echo CAKEFLAGS | tr '\040' '\012' | sed -n -e /-s/p ]]

PRODUCTS: Makefile.MTYPE cache.MTYPE
	make MINUS_S -f Makefile.MTYPE CAKEFLAGS EXTRA_PRODUCTS
	AFTER_MAKE

EXTRA_PRODUCTS: Makefile.MTYPE cache.MTYPE
	make MINUS_S -f Makefile.MTYPE CAKEFLAGS EXTRA_PRODUCTS
	AFTER_MAKE

Makefile.MTYPE cache.MTYPE:		if not exist Makefile.MTYPE or not exist cache.MTYPE
	( \C\F\L\A\G\S=\"GFLAG OPTIMIZER PROFILER\"; \
		\A\F\T\E\R\_\M\A\K\E=\"AFTER_MAKE\"; \
		\R\A\N\L\I\B=\"RANLIB\";\
		\L\D\F\L\A\G\S=\"LDFLAGS\"; \
		\B\U\I\L\D\_\L\I\B\R\A\R\Y=\"BUILD_LIBRARY\"; \
		\C\C=\"CC\"; \
		 export \C\F\L\A\G\S \R\A\N\L\I\B \L\D\F\L\A\G\S \B\U\I\L\D\_\L\I\B\R\A\R\Y \C\C \A\F\T\E\R\_\M\A\K\E; \
		 ../SRCDIR/"unix"/configure TK_OPTS ENABLE_64; \
		../SRCDIR/fix_makefile.sh > Makefile.MTYPE)

clean&:	Makefile.MTYPE
	make -f Makefile.MTYPE clean

noprod&:
	rm -f *.ARCH_SUF libtk*.a wish tktest

clobber&:
	rm -f *.o libtk* wish gmon.out tktest *.MTYPE tkConfig.sh config.log config.status Makefile lib.exp

install&: Makefile.MTYPE
	make -f Makefile.MTYPE install
	(cd BASEDIR/lib; AFTER_MAKE)

install-nobak&: Makefile.MTYPE
	make -f Makefile.MTYPE install
	(cd BASEDIR/lib; AFTER_MAKE)

tktest: Makefile.MTYPE
	make -f Makefile.MTYPE tktest

test&: Makefile.MTYPE
	make -f Makefile.MTYPE test

/* dltest:			if not exist dltest
	cp -r ../SRCDIR/"unix"/dltest .
*/
#else
all&:
	@@echo "SRCDIR:  all done"

clean&:
	@@echo "" > /dev/null

noprod&:
	@@echo "" > /dev/null

clobber&:
	@@echo "" > /dev/null
#endif
@


1.2
log
@added a hook to force 64-bit mode compilation if USE_64 is set in Cakefile.defs; added hacks to configure script to get sp3 to work right -- autogenerated code fails to detect libraries properly for aix
@
text
@@


1.2.2.1
log
@merge from head
@
text
@@


1.2.6.1
log
@sync branch with HEAD
@
text
@@


1.2.4.1
log
@merge from HEAD
@
text
@@


1.1
log
@Update to tk 8.4
@
text
@d39 6
d64 1
a64 1
		 ../SRCDIR/"unix"/configure TK_OPTS; \
d74 1
a74 1
	rm -f *.o libtk* wish gmon.out tktest *.MTYPE tkConfig.sh config.log config.status Makefile 
@

