[117621] trunk/base

cal at macports.org cal at macports.org
Wed Mar 5 14:19:14 PST 2014


Revision: 117621
          https://trac.macports.org/changeset/117621
Author:   cal at macports.org
Date:     2014-03-05 14:19:14 -0800 (Wed, 05 Mar 2014)
Log Message:
-----------
macports: use a local copy of Tcl 8.5, mostly fix out-of-source build (#28001)

This change switches MacPorts to a private copy of Tcl 8.5 that will be extracted, configured, built
and installed along with MacPorts. This will allow us to drop Tcl 8.4-compatibility for older OS
releases that didn't ship Tcl 8.5 and is an important step towards Tcl 8.6 compatibility.

Most of the changes to make this happen were in aclocal.m4 (where I re-implemented a custom version
of AC_CONFIG_SUBDIRS similar to what was proposed upstream in
http://lists.gnu.org/archive/html/autoconf/2011-04/msg00000.html but never actually merged),
configure.ac and the vendor directory.

Since we want to build MacPorts against the headers of our custom Tcl, this change also required
adjusting Mk/macports.autoconf.mk.in to pass the correct path to the headers. However, we cannot use
the build directory containing the public headers, because this directory is also clobbered with
other headers such as regex.h, breaking the build later on when this file is included in pextlib1.0.
Fortunately, the Tcl autoconf macros take care of all the other details required to build against
a private Tcl.

Not having the blessed copy of Tcl around during configure lead to some other difficulties such as
the MP_TCL_PLATFORM macro, which uses $TCLSH to read the $tcl_platform variable. I have
re-implemented this as MP_PLATFORM using uname in the same way as the $tcl_platform variable is set
up in the Tcl source code.

Besides a standard Tcl distribution, this change also installs the Tcl Thread package (required for
trace mode) and Tcllib, a package containing various helpful modules for Tcl (such as an
8.6-compatible try implementation). It also drops support for the Tcl sqlite3 extension that is
present on OS X and was previously picked up by configure, but isn't used in the source.

While I was refactoring the build system I also mostly fixed out-of-source builds (see #28001,
caused all Makefile -> Makefile.in moves). The remaining issue is that the pkgIndex.tcl files
generated by pkg_mkIndex only list the files present in the build directory (i.e. all files that
have been re-inplaced or built from source), but not those from the source directory. That currently
causes the Tcl scripts in the install target to fail.

I also unified indentation in aclocal.m4.

Modified Paths:
--------------
    trunk/base/Makefile.in
    trunk/base/Mk/macports.autoconf.mk.in
    trunk/base/aclocal.m4
    trunk/base/configure.ac
    trunk/base/src/Makefile.in
    trunk/base/src/macports1.0/macports_fastload.tcl.in
    trunk/base/src/pkg_mkindex.sh.in

Added Paths:
-----------
    trunk/base/doc/Makefile.in
    trunk/base/src/cflib1.0/Makefile.in
    trunk/base/src/cregistry/Makefile.in
    trunk/base/src/darwintracelib1.0/Makefile.in
    trunk/base/src/macports1.0/Makefile.in
    trunk/base/src/package1.0/Makefile.in
    trunk/base/src/port/Makefile.in
    trunk/base/src/port1.0/Makefile.in
    trunk/base/src/registry2.0/Makefile.in
    trunk/base/tests/Makefile.in
    trunk/base/vendor/
    trunk/base/vendor/Makefile.in
    trunk/base/vendor/tcl8.5.15-src.tar.gz
    trunk/base/vendor/tcllib-1.15.tar.gz
    trunk/base/vendor/thread2.7.0.tar.gz

Removed Paths:
-------------
    trunk/base/doc/Makefile
    trunk/base/src/cflib1.0/Makefile
    trunk/base/src/cregistry/Makefile
    trunk/base/src/darwintracelib1.0/Makefile
    trunk/base/src/macports1.0/Makefile
    trunk/base/src/package1.0/Makefile
    trunk/base/src/port/Makefile
    trunk/base/src/port1.0/Makefile
    trunk/base/src/registry2.0/Makefile
    trunk/base/src/thread2.6.diff
    trunk/base/src/thread2.6.tar.gz
    trunk/base/tests/Makefile

Property Changed:
----------------
    trunk/base/doc/
    trunk/base/src/cflib1.0/
    trunk/base/src/cregistry/
    trunk/base/src/darwintracelib1.0/
    trunk/base/src/package1.0/
    trunk/base/src/port/
    trunk/base/src/port1.0/
    trunk/base/src/registry2.0/
    trunk/base/tests/

Modified: trunk/base/Makefile.in
===================================================================
--- trunk/base/Makefile.in	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,7 +1,10 @@
 # $Id$
 
+srcdir      = @srcdir@
+VPATH       = @srcdir@
+
 PATH		= @PATH_CLEANED@
-SUBDIR		= doc src tests
+SUBDIR		= vendor doc src tests
 DISTDIR		= dist
 DISTVER		=
 DISTTAG		= release_${subst .,_,${DISTVER}}
@@ -29,13 +32,13 @@
 		echo "Source tree not configured. Use ./configure" ; \
 	fi
 
-include Mk/macports.subdir.mk
+include $(srcdir)/Mk/macports.subdir.mk
 
 install::
 	[ ! -f "$(DESTDIR)${sysconfdir}/macports/mp_version" ] || rm -vf "$(DESTDIR)${sysconfdir}/macports/mp_version"
 	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "$(DESTDIR)${datadir}/macports/"
 	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 setupenv.bash  "$(DESTDIR)${datadir}/macports/"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 macports-pubkey.pem  "$(DESTDIR)${datadir}/macports/"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $(srcdir)/macports-pubkey.pem  "$(DESTDIR)${datadir}/macports/"
 # Only run these scripts when not building in a destroot
 ifeq ($(DESTDIR),)
 # create run user if it doesn't exist
@@ -91,10 +94,10 @@
         echo "Can't find ${DSCL} / ${DSEDITGROUP}, not creating user \"${RUNUSR}\"" ; \
     fi
 # Add [default] tag to the central MacPorts repository, if it isn't already
-	$(TCLSH) src/upgrade_sources_conf_default.tcl "${prefix}"
+	$(TCLSH) $(srcdir)/src/upgrade_sources_conf_default.tcl "${prefix}"
 # Convert image directories (and direct mode installs) to image archives
-	$(TCLSH) src/images_to_archives.tcl "${macports_tcl_dir}"
-	$(TCLSH) src/dedup_portfiles.tcl "${macports_tcl_dir}"
+	$(TCLSH) $(srcdir)/src/images_to_archives.tcl "${macports_tcl_dir}"
+	$(TCLSH) $(srcdir)/src/dedup_portfiles.tcl "${macports_tcl_dir}"
 endif
 ifndef SELFUPDATING
 	@echo ""; echo "Congratulations, you have successfully installed the MacPorts system. To get the Portfiles and update the system, add ${prefix}/bin to your PATH and run:"; echo ""

Modified: trunk/base/Mk/macports.autoconf.mk.in
===================================================================
--- trunk/base/Mk/macports.autoconf.mk.in	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/Mk/macports.autoconf.mk.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,17 +1,12 @@
 # $Id$
+# vim:ts=8:noet:sts=8:sw=8
 
 SHELL			= @SHELL@
 
-
-srcdir			= @srcdir@
-VPATH			= @srcdir@
-
 CC			= @CC@
 CFLAGS			= @CFLAGS@ -std=c99 $(CFLAGS_QUICHEEATERS) $(CFLAGS_PEDANTIC) $(CFLAGS_WERROR)
 OBJCFLAGS		= @OBJCFLAGS@ $(CFLAGS_QUICHEEATERS) $(CFLAGS_PEDANTIC) $(CFLAGS_WERROR)
-CPPFLAGS		= @CPPFLAGS@ @DEFS@ @INCLUDES@ @TCL_INCLUDES@
-TCL_DEFS		= @TCL_DEFS@
-SHLIB_CFLAGS		= @SHLIB_CFLAGS@
+CPPFLAGS		= @CPPFLAGS@ @DEFS@ -I at abs_top_builddir@/src -I at abs_top_srcdir@/src -I. -I at abs_top_builddir@/@VENDOR_DESTROOT@/@TCL_PREFIX@/include
 CFLAGS_QUICHEEATERS	= @CFLAGS_QUICHEEATERS@
 CFLAGS_PEDANTIC		= @CFLAGS_PEDANTIC@
 CFLAGS_WERROR		= @CFLAGS_WERROR@
@@ -32,11 +27,11 @@
 OBJC_FOUNDATION_LDFLAGS		= @OBJC_FOUNDATION_LDFLAGS@
 OBJC_FOUNDATION_LIBS		= @OBJC_FOUNDATION_LIBS@
 
-TCL_CC			= @TCL_CC@
+LDFLAGS			= @LDFLAGS@
 SHLIB_LD		= @SHLIB_LD@
 STLIB_LD		= @STLIB_LD@
-LDFLAGS			= @LDFLAGS@
-SHLIB_LDFLAGS		= @SHLIB_LDFLAGS@ ${LDFLAGS}
+SHLIB_CFLAGS		= @SHLIB_CFLAGS@
+SHLIB_LDFLAGS		= @LDFLAGS@
 SHLIB_SUFFIX		= @SHLIB_SUFFIX@
 TCL_STUB_LIB_SPEC	= @TCL_STUB_LIB_SPEC@
 
@@ -51,8 +46,9 @@
 XCODEBUILD		= @XCODEBUILD@
 BZIP2			= @BZIP2@
 
+INTREE_TCLSH		= @INTREE_TCLSH@
 TCLSH			= @TCLSH@
-TCL_PACKAGE_DIR		= @TCL_PACKAGE_DIR@
+TCL_PACKAGE_PATH	= @TCL_PACKAGE_PATH@
 macports_tcl_dir	= @macports_tcl_dir@
 
 DSCL			= @DSCL@

Modified: trunk/base/aclocal.m4
===================================================================
--- trunk/base/aclocal.m4	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/aclocal.m4	2014-03-05 22:19:14 UTC (rev 117621)
@@ -3,6 +3,288 @@
 builtin(include,m4/pthread.m4)
 builtin(include,m4/foundation.m4)
 
+dnl Search for a variable in a list. Run ACTION-IF-FOUND if it is in the list,
+dnl ACTION-IF-NOT-FOUND otherwise.
+dnl
+dnl Parameters:
+dnl  - The name of the list.
+dnl  - The name of the variable that should be searched in the list.
+dnl  - An optional action to be run if found
+dnl  - An optional action to be run if not found
+dnl
+dnl _MP_LIST_CONTAINS_QUOTED([listname], [varname], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
+AC_DEFUN([_MP_LIST_CONTAINS], [dnl
+	mp_list_contains_present=
+	eval "mp_list_contains_list=\"$$1\""
+	for mp_list_contains_entry in $mp_list_contains_list; do
+		test -z "$mp_list_contains_entry" && continue
+		if test "x$$2" = "x$mp_list_contains_entry"; then
+			mp_list_contains_present=1
+			break
+		fi
+	done
+	if test "x$mp_list_contains_present" = "x"; then
+		m4_ifvaln([$3], [$3], [:])dnl
+		m4_ifvaln([$4], [else $4])dnl
+	fi
+])
+
+dnl Quote a variable and prepend it to a list.
+dnl
+dnl Parameters:
+dnl  - The name of the list.
+dnl  - The name of the variable that should be quoted and prepended to the
+dnl    list.
+AC_DEFUN([_MP_LIST_PREPEND_QUOTED], [dnl
+	_MP_QUOTE([$2])
+	_MP_VAR_PREPEND([$1], ["$$2 "])
+])
+
+
+dnl Quote a variable and append it to a list.
+dnl
+dnl Parameters:
+dnl  - The name of the list.
+dnl  - The name of the variable that should be quoted and appended to the list.
+AC_DEFUN([_MP_LIST_APPEND_QUOTED], [dnl
+	_MP_QUOTE([$2])
+	AS_VAR_APPEND([$1], [" $$2"])
+])
+
+dnl Prepend the shell expansion of a value to a variable.
+dnl
+dnl Parameters:
+dnl  - The name of the variable to which the second argument should be
+dnl    prepended.
+dnl  - The value that should be expanded using the shell expansion rules and
+dnl    prepended to the variable given in the first argument.
+AC_DEFUN([_MP_VAR_PREPEND], [dnl
+	AC_REQUIRE([_MP_VAR_PREPEND_PREPARE])dnl
+	mp_fn_var_prepend $1 $2
+])
+
+dnl Define the function required for _MP_VAR_PREPEND
+AC_DEFUN([_MP_VAR_PREPEND_PREPARE], [dnl
+	mp_fn_var_prepend() {
+		eval "$[]1=\"$[]2\$$[]1\""
+	}
+])
+
+dnl Quote a variable in single quotes (escaping any existing single quotes) and
+dnl store it in itself.
+dnl
+dnl Parameters:
+dnl  - The name of the variable that should be quoted using single quotes.
+AC_DEFUN([_MP_QUOTE], [dnl
+	case $$1 in
+		*\'*)
+			$1=$(AS_ECHO(["$$1"]) | sed "s/'/'\\\\\\\\''/g")
+		;;
+	esac
+	$1="'$$1'"dnl
+])
+
+
+dnl Extract the key part of a key-value pair given as string in the form
+dnl  --key=value or
+dnl   -key=value
+dnl
+dnl Parameters:
+dnl  - The variable name to assign to
+dnl  - The (quoted, if necessary) key-value pair
+AC_DEFUN([_MP_EXTRACT_KEY], [dnl
+	$1=$(AS_ECHO([$2]) | sed -E 's/^--?([^=]+)=.*$/\1/')dnl
+])
+
+dnl Configure a project contained in a .tar.gz (or .tgz) tarball, extracting it
+dnl previously, if necessary. Different from AC_CONFIG_SUBDIRS (on which this
+dnl macro is based), you can pass parameters to the sub-configure script.
+dnl
+dnl Parameters:
+dnl  - The relative path to the tarball
+dnl  - The relative path to the directory that will be extracted from the
+dnl    tarball and contains the configure script to be run (can be a sub directory of the extracted directory)
+dnl  - Parameters to pass to the configure script
+dnl
+dnl MP_CONFIG_TARBALL([path-to-tarball], [dir-extracted-from-tarball-with-configure], [configure-parameters])
+AC_DEFUN([MP_CONFIG_TARBALL], [
+	mp_tarball="$1"
+	ac_dir=$2
+
+	if test "$no_recursion" != yes; then
+		mp_popdir=$(pwd)
+		if ! test -d "$ac_dir"; then
+			mp_tarball_vendordir="$(dirname "$mp_tarball")"
+			AS_MKDIR_P(["$mp_tarball_vendordir"])
+			AC_MSG_NOTICE([=== extracting $mp_tarball])
+			(cd "$mp_tarball_vendordir"; gzip -d < "$ac_abs_confdir/$mp_tarball" | tar xf - || AC_MSG_ERROR([failed to extract $mp_tarball]))
+		fi
+		if ! test -d "$ac_dir"; then
+			AC_MSG_ERROR([tarball $mp_tarball did not extract to $ac_dir])
+		fi
+	
+		AC_MSG_NOTICE([=== configuring in $ac_dir ($mp_popdir/$ac_dir)])
+		AS_MKDIR_P(["$ac_dir"])
+		_AC_SRCDIRS(["$ac_dir"])
+		cd "$ac_dir"
+		if test -f "$ac_srcdir/configure"; then
+			mp_sub_configure_args=
+			mp_sub_configure_keys=
+			# Compile a list of keys that have been given to the MP_CONFIG_TARBALL
+			# macro; we want to skip copying those parameters from the original
+			# configure invocation.
+			for mp_arg in $3; do
+				case $mp_arg in
+					--*=* | -*=*)
+						_MP_EXTRACT_KEY([mp_arg_key], ["$mp_arg"])
+						_MP_LIST_APPEND_QUOTED([mp_sub_configure_keys], [mp_arg_key])
+					;;
+				esac
+				_MP_LIST_APPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+			done
+			# Walk the list of arguments given to the original configure script;
+			# filter out a few common ones we likely would not want to pass along,
+			# add --disable-option-checking and filter those already given as
+			# argument to MP_CONFIG_TARBALL.
+			# Most of this code is adapted from _AC_OUTPUT_SUBDIRS in
+			# $prefix/share/autoconf/autoconf/status.m4.
+			mp_prev=
+			eval "set x $ac_configure_args"
+			shift
+			for mp_arg; do
+				if test -n "$mp_prev"; then
+					mp_prev=
+					continue
+				fi
+				case $mp_arg in
+					  -cache-file \
+					| --cache-file \
+					| --cache-fil \
+					| --cache-fi \
+					| --cache-f \
+					| --cache- \
+					| --cache \
+					| --cach \
+					| --cac \
+					| --ca \
+					| --c)
+						mp_prev=cache_file
+					;;
+					  -cache-file=* \
+					| --cache-file=* \
+					| --cache-fil=* \
+					| --cache-fi=* \
+					| --cache-f=* \
+					| --cache-=* \
+					| --cache=* \
+					| --cach=* \
+					| --cac=* \
+					| --ca=* \
+					| --c=*)
+						# ignore --cache-file
+					;;
+					  --config-cache \
+					| -C)
+						# ignore -C
+					;;
+					  -srcdir \
+					| --srcdir \
+					| -srcdi \
+					| -srcd \
+					| -src \
+					| -sr)
+						mp_prev=srcdir
+					;;
+					  -srcdir=* \
+					| --srcdir=* \
+					| --srcdi=* \
+					| --srcd=* \
+					| --src=* \
+					| --sr=*)
+						# ignore --srcdir
+					;;
+					  -prefix \
+					| --prefix \
+					| --prefi \
+					| --pref \
+					| --pre \
+					| --pr \
+					| --p)
+						mp_prev=prefix
+					;;
+					  -prefix=* \
+					| --prefix=* \
+					| --prefi=* \
+					| --pref=* \
+					| --pre=* \
+					| --pr=* \
+					| --p=*)
+						# ignore --prefix
+					;;
+					--disable-option-checking)
+						# ignore --disable-option-checking
+					;;
+					--*=* | -*=*)
+						_MP_EXTRACT_KEY([mp_arg_key], ["$mp_arg"])
+						_MP_LIST_CONTAINS([mp_sub_configure_keys], [mp_arg_key], [], [
+							_MP_LIST_APPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+						])
+					;;
+					*)
+						# always pass positional arguments
+						_MP_LIST_APPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+					;;
+				esac
+			done
+
+			# Now prepend some arguments that should always be present unless
+			# overriden, such as --prefix, --silent, --disable-option-checking,
+			# --cache-file, --srcdir
+			# Pass --prefix unless already given
+			mp_arg_key=prefix
+			_MP_LIST_CONTAINS([mp_sub_configure_args], [mp_arg_key], [], [
+				mp_arg="--prefix=$prefix"
+				_MP_LIST_PREPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+			])
+
+			# Pass --silent
+			if test "$silent" = yes; then
+				mp_arg="--silent"
+				_MP_LIST_PREPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+			fi
+
+			# Always prepend --disable-option-checking to silence warnings, since
+			# different subdirs can have different --enable and --with options.
+			mp_arg="--disable-option-checking"
+			_MP_LIST_PREPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+
+			# Make the cache file name correct relative to the subdirectory.
+			case $cache_file in
+				[[\\/]]* | ?:[[\\/]]* )
+					mp_sub_cache_file=$cache_file
+				;;
+				*) # Relative name.
+					mp_sub_cache_file=$ac_top_build_prefix$cache_file
+				;;
+			esac
+			mp_arg="--cache-file=$mp_sub_cache_file"
+			_MP_LIST_PREPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+
+			mp_arg="--srcdir=$ac_srcdir"
+			_MP_LIST_APPEND_QUOTED([mp_sub_configure_args], [mp_arg])
+
+			AC_MSG_NOTICE([running $SHELL $ac_srcdir/configure $mp_sub_configure_args in $ac_dir])
+			eval "\$SHELL \$ac_srcdir/configure $mp_sub_configure_args" || AC_MSG_ERROR([configure failed for $ac_dir])
+		else
+			AC_MSG_ERROR([no configure script found in $ac_dir])
+		fi
+		AC_MSG_NOTICE([=== finished configuring in $ac_dir ($mp_popdir/$ac_dir)])
+
+		cd "$mp_popdir"
+	fi
+])
+
+
 #------------------------------------------------------------------------
 # MP_CHECK_FRAMEWORK_COREFOUNDATION --
 #
@@ -309,18 +591,17 @@
 	dnl if with user specifies --with-no-root-privileges,
 	dnl use current user and group.
 	dnl use ~/Library/Tcl as Tcl package directory
-		AC_REQUIRE([MP_PATH_MPCONFIGDIR])
+	AC_REQUIRE([MP_PATH_MPCONFIGDIR])
 
 	AC_ARG_WITH(no-root-privileges, [AS_HELP_STRING([--with-no-root-privileges],[Specify that MacPorts should be installed in your home directory])], [ROOTPRIVS=$withval] )
 
 	if test "${ROOTPRIVS+set}" = set; then
-
 		# Set install-user to current user
 		AC_MSG_CHECKING([for install user])
 		DSTUSR=`id -un`
 		AC_MSG_RESULT([$DSTUSR])
 		AC_SUBST(DSTUSR)
-		
+
 		# Set install-group to current user
 		AC_MSG_CHECKING([for install group])
 		DSTGRP=`id -gn`
@@ -332,19 +613,6 @@
 		RUNUSR=`id -un`
 		AC_MSG_RESULT([$RUNUSR])
 		AC_SUBST(RUNUSR)
-
-		# Set Tcl package directory to ~/Library/Tcl
-	    AC_MSG_CHECKING(for Tcl package directory)
-		ac_cv_c_tclpkgd=`eval echo ~$DSTUSR/Library/Tcl`
-	    # Convert to a native path and substitute into the output files.
-	    PACKAGE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclpkgd}`
-	    TCL_PACKAGE_DIR=${PACKAGE_DIR_NATIVE}
-	    AC_SUBST(TCL_PACKAGE_DIR)
-		if test x"${ac_cv_c_tclpkgd}" = x ; then
-			AC_MSG_ERROR(Tcl package directory not found.  Please specify its location with --with-tclpackage)
-	    else
-			AC_MSG_RESULT(${ac_cv_c_tclpkgd})
-	    fi
 	fi
 
 ])
@@ -354,13 +622,13 @@
 AC_DEFUN([MP_CHECK_RUNUSER],[
 	dnl if with user specifies --with-macports-user,
 	dnl use it. otherwise default to platform defaults
-       AC_REQUIRE([MP_PATH_MPCONFIGDIR])
+	AC_REQUIRE([MP_PATH_MPCONFIGDIR])
 
 	AC_ARG_WITH(macports-user, [AS_HELP_STRING([--with-macports-user=USER],[Specify user to drop privileges to, if possible, during compiles etc.])], [ RUNUSR=$withval ] )
 	
 	AC_MSG_CHECKING([for macports user])
 	if test "x$RUNUSR" = "x" ; then
-	   RUNUSR=macports
+		RUNUSR=macports
 	fi
 
 	AC_MSG_RESULT([$RUNUSR])
@@ -373,13 +641,13 @@
 AC_DEFUN([MP_SHARED_DIRECTORY],[
 	dnl if with user specifies --with-shared-directory,
 	dnl use 0775 permissions for ${prefix} directories
-        AC_REQUIRE([MP_PATH_MPCONFIGDIR])
+	AC_REQUIRE([MP_PATH_MPCONFIGDIR])
 
 	AC_ARG_WITH(shared-directory, [AS_HELP_STRING([--with-shared-directory],[Use 0775 permissions for installed directories])], [ SHAREDIR=$withval ] )
 
 	if test "${SHAREDIR+set}" = set; then	
 		AC_MSG_CHECKING([whether to share the install directory with all members of the install group])
-	    DSTMODE=0775
+		DSTMODE=0775
 
 		AC_MSG_RESULT([$DSTMODE])
 		AC_SUBST(DSTMODE)
@@ -391,13 +659,13 @@
 AC_DEFUN([MP_CHECK_INSTALLUSER],[
 	dnl if with user specifies --with-install-user,
 	dnl use it. otherwise default to platform defaults
-        AC_REQUIRE([MP_PATH_MPCONFIGDIR])
+	AC_REQUIRE([MP_PATH_MPCONFIGDIR])
 
 	AC_ARG_WITH(install-user, [AS_HELP_STRING([--with-install-user=USER],[Specify user ownership of installed files])], [ DSTUSR=$withval ] )
 	
 	AC_MSG_CHECKING([for install user])
 	if test "x$DSTUSR" = "x" ; then
-	   DSTUSR=root
+		DSTUSR=root
 	fi
 
 	AC_MSG_RESULT([$DSTUSR])
@@ -409,27 +677,26 @@
 AC_DEFUN([MP_CHECK_INSTALLGROUP],[
 	dnl if with user specifies --with-install-group,
 	dnl use it. otherwise default to platform defaults
-        AC_REQUIRE([MP_CHECK_INSTALLUSER])
+	AC_REQUIRE([MP_CHECK_INSTALLUSER])
 
 	AC_ARG_WITH(install-group, [AS_HELP_STRING([--with-install-group=GROUP],[Specify group ownership of installed files])], [ DSTGRP=$withval ] )
 
 	AC_MSG_CHECKING([for install group])
 	if test "x$DSTGRP" = "x" ; then
-	   
-	   case $host_os in
-	   darwin*)
-		DSTGRP="admin"
-		;;
-	   freebsd*)
-		DSTGRP="wheel"
-		;;
-	   linux*)
-		DSTGRP="root"
-		;;
-	   *)
-		DSTGRP="wheel"
-		;;
-	   esac
+		case $host_os in
+			darwin*)
+				DSTGRP="admin"
+			;;
+			freebsd*)
+				DSTGRP="wheel"
+			;;
+			linux*)
+				DSTGRP="root"
+			;;
+			*)
+				DSTGRP="wheel"
+			;;
+		esac
 	fi
 
 	AC_MSG_RESULT([$DSTGRP])
@@ -442,13 +709,13 @@
 	dnl if with user specifies --with-directory-mode,
 	dnl use the specified permissions for ${prefix} directories
 	dnl otherwise use 0755
-        AC_REQUIRE([MP_PATH_MPCONFIGDIR])
+	AC_REQUIRE([MP_PATH_MPCONFIGDIR])
 
 	AC_ARG_WITH(directory-mode, [AS_HELP_STRING([--with-directory-mode=MODE],[Specify directory mode of installed directories])], [ DSTMODE=$withval ] )
 	
 	AC_MSG_CHECKING([what permissions to use for installation directories])
 	if test "x$DSTMODE" = "x" ; then
-	   DSTMODE=0755
+		DSTMODE=0755
 	fi
 
 	AC_MSG_RESULT([$DSTMODE])
@@ -458,87 +725,85 @@
 # MP_PATH_APPLICATIONS
 #---------------------------------------
 AC_DEFUN([MP_PATH_APPLICATIONS],[
-        AC_REQUIRE([MP_CHECK_INSTALLUSER])
+	AC_REQUIRE([MP_CHECK_INSTALLUSER])
 
-    AC_ARG_WITH(applications-dir,[AS_HELP_STRING([--with-applications-dir],[Applications installation directory.])], MPAPPLICATIONSDIR=${withval})
+	AC_ARG_WITH(applications-dir,[AS_HELP_STRING([--with-applications-dir],[Applications installation directory.])], MPAPPLICATIONSDIR=${withval})
 
-    oldprefix=$prefix
-    if test "x$prefix" = "xNONE" ; then
-	prefix=$ac_default_prefix
-    fi
-    AC_MSG_CHECKING([for Applications installation directory])
+	oldprefix=$prefix
+	if test "x$prefix" = "xNONE" ; then
+		prefix=$ac_default_prefix
+	fi
+	AC_MSG_CHECKING([for Applications installation directory])
 
 	if test "x$MPAPPLICATIONSDIR" = "x" ; then
-	    if test "$DSTUSR" = "root" ; then
-		MPAPPLICATIONSDIR="/Applications/MacPorts"
-	    else
-		MPAPPLICATIONSDIR="$(eval echo ~$DSTUSR)/Applications/MacPorts"
-	    fi
+		if test "$DSTUSR" = "root" ; then
+			MPAPPLICATIONSDIR="/Applications/MacPorts"
+		else
+			MPAPPLICATIONSDIR="$(eval echo ~$DSTUSR)/Applications/MacPorts"
+		fi
 	fi
 
 	AC_MSG_RESULT([$MPAPPLICATIONSDIR])
-    AC_SUBST(MPAPPLICATIONSDIR)
-    prefix=$oldprefix
+	AC_SUBST(MPAPPLICATIONSDIR)
+	prefix=$oldprefix
 ])
 
 # MP_PATH_FRAMEWORKS
 #---------------------------------------
 AC_DEFUN([MP_PATH_FRAMEWORKS],[
-        AC_REQUIRE([MP_CHECK_INSTALLUSER])
+	AC_REQUIRE([MP_CHECK_INSTALLUSER])
 
-    AC_ARG_WITH(frameworks-dir,[AS_HELP_STRING([--with-frameworks-dir],[Frameworks installation directory.])], MPFRAMEWORKSDIR=${withval})
+	AC_ARG_WITH(frameworks-dir,[AS_HELP_STRING([--with-frameworks-dir],[Frameworks installation directory.])], MPFRAMEWORKSDIR=${withval})
 
-    oldprefix=$prefix
-    if test "x$prefix" = "xNONE" ; then
-	prefix=$ac_default_prefix
-    fi
-    AC_MSG_CHECKING([for Frameworks installation directory])
+	oldprefix=$prefix
+	if test "x$prefix" = "xNONE" ; then
+		prefix=$ac_default_prefix
+	fi
+	AC_MSG_CHECKING([for Frameworks installation directory])
 
 	if test "x$MPFRAMEWORKSDIR" = "x" ; then
 		MPFRAMEWORKSDIR="${prefix}/Library/Frameworks"
 	fi
 
 	AC_MSG_RESULT([$MPFRAMEWORKSDIR])
-    AC_SUBST(MPFRAMEWORKSDIR)
-    prefix=$oldprefix
+	AC_SUBST(MPFRAMEWORKSDIR)
+	prefix=$oldprefix
 ])
 
-
 # MP_UNIVERSAL_OPTIONS
 #---------------------------------------
 AC_DEFUN([MP_UNIVERSAL_OPTIONS],[
-  AC_ARG_WITH(universal-archs,[AS_HELP_STRING([--with-universal-archs="CPU"],[Universal CPU architectures (space separated)])], UNIVERSAL_ARCHS=${withval})
+	AC_ARG_WITH(universal-archs,[AS_HELP_STRING([--with-universal-archs="CPU"],[Universal CPU architectures (space separated)])], UNIVERSAL_ARCHS=${withval})
 
-  if test "x$UNIVERSAL_ARCHS" = "x"; then
-    case "$MACOSX_VERSION" in
-      10.1[[0-9]]*)
-        UNIVERSAL_ARCHS="x86_64 i386"
-        ;;
-      10.[[0-5]]*)
-        UNIVERSAL_ARCHS="i386 ppc"
-        ;;
-      *)
-        UNIVERSAL_ARCHS="x86_64 i386"
-        ;;
-    esac
-  fi
+	if test "x$UNIVERSAL_ARCHS" = "x"; then
+		case "$MACOSX_VERSION" in
+			10.1[[0-9]]*)
+				UNIVERSAL_ARCHS="x86_64 i386"
+			;;
+			10.[[0-5]]*)
+				UNIVERSAL_ARCHS="i386 ppc"
+			;;
+			*)
+				UNIVERSAL_ARCHS="x86_64 i386"
+			;;
+		esac
+	fi
 
-  UNIVERSAL_ARCHFLAGS=
-  for arch in $UNIVERSAL_ARCHS; do
-    UNIVERSAL_ARCHFLAGS="$UNIVERSAL_ARCHFLAGS -arch $arch"
-  done
+	UNIVERSAL_ARCHFLAGS=
+	for arch in $UNIVERSAL_ARCHS; do
+		UNIVERSAL_ARCHFLAGS="$UNIVERSAL_ARCHFLAGS -arch $arch"
+	done
 
-  AC_MSG_CHECKING([for Universal CPU architectures])
-  AC_MSG_RESULT([$UNIVERSAL_ARCHS])
-  AC_SUBST(UNIVERSAL_ARCHS)
-  AC_SUBST(UNIVERSAL_ARCHFLAGS)
+	AC_MSG_CHECKING([for Universal CPU architectures])
+	AC_MSG_RESULT([$UNIVERSAL_ARCHS])
+	AC_SUBST(UNIVERSAL_ARCHS)
+	AC_SUBST(UNIVERSAL_ARCHFLAGS)
 ])
 
 # MP_LIB_MD5
 #---------------------------------------
 # Check for an md5 implementation
 AC_DEFUN([MP_LIB_MD5],[
-
 	# Check for libmd from FreeBSD, which is preferred
 	AC_CHECK_LIB([md], [MD5File],[
 		AC_CHECK_HEADERS([md5.h sha.h], ,[
@@ -581,181 +846,24 @@
 	AC_REQUIRE([MP_CHECK_FRAMEWORK_IOKIT])
 	AC_REQUIRE([MP_CHECK_FUNCTION_CFNOTIFICATIONCENTERGETDARWINNOTIFYCENTER])
 	
-    AC_MSG_CHECKING(for whether we will build daemondo)
-    result=no
+	AC_MSG_CHECKING(for whether we will build daemondo)
+	result=no
 	case $host_os in
-	darwin*)
-		if test "x$mp_cv_have_framework_corefoundation" == "xyes" &&
-		   test "x$mp_cv_have_framework_systemconfiguration" == "xyes" &&
-		   test "x$mp_cv_have_framework_iokit" == "xyes" &&
-		   test "x$mp_cv_have_function_cfnotificationcentergetdarwinnotifycenter" == "xyes"; then
-			result=yes
-			EXTRA_PROGS="$EXTRA_PROGS daemondo"
-			AC_CONFIG_FILES([src/programs/daemondo/Makefile])
-		fi
+		darwin*)
+			if test "x$mp_cv_have_framework_corefoundation" == "xyes" &&
+			   test "x$mp_cv_have_framework_systemconfiguration" == "xyes" &&
+			   test "x$mp_cv_have_framework_iokit" == "xyes" &&
+			   test "x$mp_cv_have_function_cfnotificationcentergetdarwinnotifycenter" == "xyes"; then
+				result=yes
+				EXTRA_PROGS="$EXTRA_PROGS daemondo"
+				AC_CONFIG_FILES([src/programs/daemondo/Makefile])
+			fi
 		;;
-	*)
+		*)
 	esac
 	AC_MSG_RESULT(${result})
 ])
 
-#------------------------------------------------------------------------
-# MP_TCL_PACKAGE_DIR --
-#
-#	Locate the correct directory for Tcl package installation
-#
-# Arguments:
-#	None.
-#
-# Requires:
-#	TCLVERSION must be set
-#	CYGPATH must be set
-#	TCLSH must be set
-#
-# Results:
-#
-#	Adds a --with-tclpackage switch to configure.
-#	Result is cached.
-#
-#	Substs the following vars:
-#		TCL_PACKAGE_DIR
-#------------------------------------------------------------------------
-
-AC_DEFUN(MP_TCL_PACKAGE_DIR, [
-	AC_REQUIRE([MP_CHECK_INSTALLUSER])
-
-    AC_MSG_CHECKING(for Tcl package directory)
-
-    AC_ARG_WITH(tclpackage, [  --with-tclpackage       Tcl package installation directory.], with_tclpackagedir=${withval})
-
-    if test x"${with_tclpackagedir}" != x ; then
-	ac_cv_c_tclpkgd=${with_tclpackagedir}
-    else
-	AC_CACHE_VAL(ac_cv_c_tclpkgd, [
-	    # Use the value from --with-tclpackage, if it was given
-
-	    if test x"${with_tclpackagedir}" != x ; then
-		echo "tclpackagedir"
-		ac_cv_c_tclpkgd=${with_tclpackagedir}
-	    else
-		# On darwin we can do some intelligent guessing
-		case $host_os in
-		    darwin*)
-		    	tcl_autopath=`echo 'puts -nonewline \$auto_path' | $TCLSH`
-			for path in $tcl_autopath; do
-			if test "$DSTUSR" = "root" ; then
-			    if test "$path" = "/Library/Tcl"; then
-				ac_cv_c_tclpkgd="$path"
-				break
-			    fi
-			    if test "$path" = "/System/Library/Tcl"; then
-				if test -d "$path"; then
-				    ac_cv_c_tclpkgd="$path"
-				    break
-			        fi
-			    fi
-			elif test "$path" = "~/Library/Tcl"; then
-			    ac_cv_c_tclpkgd=`eval echo ~$DSTUSR/Library/Tcl`
-			    break
-			fi
-			done
-		    ;;
-		esac
-    		if test x"${ac_cv_c_tclpkgd}" = x ; then
-		    # Fudge a path from the first entry in the auto_path
-		    tcl_pkgpath=`echo 'puts -nonewline [[lindex \$auto_path 0]]' | $TCLSH`
-		    if test -d "$tcl_pkgpath"; then
-			ac_cv_c_tclpkgd="$tcl_pkgpath"
-		    fi
-		    # If the first entry does not exist, do nothing
-		fi
-	    fi
-	])
-    fi
-
-    if test x"${ac_cv_c_tclpkgd}" = x ; then
-	AC_MSG_ERROR(Tcl package directory not found.  Please specify its location with --with-tclpackage)
-    else
-	AC_MSG_RESULT(${ac_cv_c_tclpkgd})
-    fi
-
-    # Convert to a native path and substitute into the output files.
-
-    PACKAGE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclpkgd}`
-
-    TCL_PACKAGE_DIR=${PACKAGE_DIR_NATIVE}
-
-    AC_SUBST(TCL_PACKAGE_DIR)
-])
-
-# MP_PROG_TCLSH
-#---------------------------------------
-AC_DEFUN([MP_PROG_TCLSH],[
-
-
-	case $host_os in
-		freebsd*)
-			# FreeBSD installs a dummy tclsh (annoying)
-			# Look for a real versioned tclsh with threads first
-			# Look for a real versioned tclsh without threads second
-			AC_PATH_PROG([TCLSH], [tclsh${TCL_VERSION}-threads tclsh${TCL_VERSION} tclsh])
-			;;
-		*)
-			# Otherwise, look for a non-versioned tclsh
-			AC_PATH_PROG([TCLSH], [tclsh tclsh${TCL_VERSION}])
-			;;
-	esac
-	if test "x$TCLSH" = "x" ; then
-		AC_MSG_ERROR([Could not find tclsh])
-	fi
-
-	AC_SUBST(TCLSH)
-])
-
-# MP_TCL_PACKAGE
-#	Determine if a Tcl package is present.
-#
-# Arguments:
-#	Package name (may include the version)
-#
-# Syntax:
-#   MP_TCL_PACKAGE (package, [action-if-found], [action-if-not-found])
-#
-# Requires:
-#	TCLSH must be set
-#
-# Results:
-#	Execute action-if-found or action-if-not-found
-#---------------------------------------
-AC_DEFUN([MP_TCL_PACKAGE],[
-	AC_MSG_CHECKING([for Tcl $1 package])
-	package_present=`echo 'if {[[catch {package require $1}]]} {puts -nonewline 0} else {puts -nonewline 1}' | $TCLSH`
-	AS_IF([test "$package_present" = "1"], [$2], [$3])[]
-])
-
-# MP_TCL_THREAD_SUPPORT
-#	Determine if thread support is available in tclsh.
-#
-# Arguments:
-#	None.
-#
-# Requires:
-#	TCLSH must be set
-#
-# Results:
-#   Fails if thread support isn't available.
-#---------------------------------------
-AC_DEFUN([MP_TCL_THREAD_SUPPORT],[
-	AC_MSG_CHECKING([whether tclsh was compiled with threads])
-	tcl_threadenabled=`echo 'puts -nonewline [[info exists tcl_platform(threaded)]]' | $TCLSH`
-	if test "$tcl_threadenabled" = "1" ; then
-		AC_MSG_RESULT([yes])
-	else
-		AC_MSG_RESULT([no])
-		AC_MSG_ERROR([tcl wasn't compiled with threads enabled])
-	fi
-])
-
 # MP_LIBCURL_FLAGS
 #	Sets the flags to compile with libcurl.
 #
@@ -841,42 +949,14 @@
 		LDFLAGS_SQLITE3="-L${sqlite3prefix}/lib -lsqlite3"
 	fi
 
-    # check if we have sqlite3ext.h, using the appropriate cppflags
-    CPPFLAGS_OLD="${CPPFLAGS}"
-    CPPFLAGS="${CPPFLAGS} ${CFLAGS_SQLITE3}"
-    AC_CHECK_HEADERS(sqlite3ext.h)
-    CPPFLAGS="${CPPFLAGS_OLD}"
+	# check if we have sqlite3ext.h, using the appropriate cppflags
+	CPPFLAGS_OLD="${CPPFLAGS}"
+	CPPFLAGS="${CPPFLAGS} ${CFLAGS_SQLITE3}"
+	AC_CHECK_HEADERS(sqlite3ext.h)
+	CPPFLAGS="${CPPFLAGS_OLD}"
 
 	AC_SUBST(CFLAGS_SQLITE3)
 	AC_SUBST(LDFLAGS_SQLITE3)
-
-	# now the sqlite Tcl bindings
-	AC_ARG_WITH(tcl-sqlite3,
-		AS_HELP_STRING([--with-tcl-sqlite3=DIR],
-			[directory for Tcl sqlite3 (default /usr/lib/sqlite3)]),
-		[mp_sqlite3_dir=$withval])
-
-    if test "x$mp_sqlite3_dir" = "x"; then
-        case $host_os in
-            darwin*)
-                mp_sqlite3_dir="/usr/lib/sqlite3"
-                ;;
-            freebsd*)
-                mp_sqlite3_dir="/usr/local/lib/sqlite"
-                ;;
-            *)
-                mp_sqlite3_dir="/usr/share/tcl${TCL_VERSION}/sqlite3"
-                ;;
-        esac
-    fi
-
-	AC_CACHE_CHECK([for Tcl sqlite3 location], [mp_cv_sqlite3_dir],
-		[mp_cv_sqlite3_dir=
-		test -r "${mp_sqlite3_dir}/pkgIndex.tcl" && mp_cv_sqlite3_dir=$mp_sqlite3_dir
-		])
-
-	SQLITE3_TCL_DIR=$mp_cv_sqlite3_dir
-	AC_SUBST(SQLITE3_TCL_DIR)
 ])
 
 dnl This macro tests if the compiler supports GCC's
@@ -1151,7 +1231,7 @@
 ])
 
 #------------------------------------------------------------------------
-# MP_TCL_PLATFORM --
+# MP_PLATFORM --
 #
 #       Export target platform and major version
 #
@@ -1159,7 +1239,7 @@
 #       none.
 #
 # Requires:
-#       TCLSH must be set.
+#       none.
 #
 # Depends:
 #       none.
@@ -1168,10 +1248,10 @@
 #       Defines OS_PLATFORM and OS_MAJOR.
 #
 #------------------------------------------------------------------------
-AC_DEFUN([MP_TCL_PLATFORM],[
-        AC_MSG_CHECKING([for Tcl target platform])
-        OS_PLATFORM=`echo 'puts -nonewline [[string tolower \$tcl_platform(os)]]' | $TCLSH`
-        OS_MAJOR=`echo 'puts -nonewline [[lindex [split \$tcl_platform(osVersion) .] 0]]' | $TCLSH`
+AC_DEFUN([MP_PLATFORM],[
+        AC_MSG_CHECKING([for target platform])
+        OS_PLATFORM=`uname -s | tr '[[:upper:]]' '[[:lower:]]'`
+		OS_MAJOR=`uname -r | cut -d '.' -f 1`
         AC_MSG_RESULT($OS_PLATFORM $OS_MAJOR)
         AC_SUBST(OS_PLATFORM)
         AC_SUBST(OS_MAJOR)
@@ -1186,7 +1266,7 @@
 #       none.
 #
 # Requires:
-#       OS_PLATOFRM and OS_MAJOR from MP_TCL_PLATFORM.
+#       OS_PLATOFRM and OS_MAJOR from MP_PLATFORM.
 #
 # Depends:
 #       none.
@@ -1197,7 +1277,7 @@
 #
 #------------------------------------------------------------------------
 AC_DEFUN([MP_TRACEMODE_SUPPORT],[
-		AC_REQUIRE([MP_TCL_PLATFORM])
+		AC_REQUIRE([MP_PLATFORM])
 
 		AC_CHECK_FUNCS([kqueue kevent])
 

Modified: trunk/base/configure.ac
===================================================================
--- trunk/base/configure.ac	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/configure.ac	2014-03-05 22:19:14 UTC (rev 117621)
@@ -241,8 +241,6 @@
 	readline/history.h readline/readline.h spawn.h sys/cdefs.h sys/event.h sys/fcntl.h sys/file.h \
 	sys/paths.h sys/socket.h sys/sysctl.h utime.h])
 
-INCLUDES="-I.. -I. $INCLUDES"
-
 # Checks for library functions.
 AC_CHECK_FUNCS([OSAtomicCompareAndSwap32 OSAtomicCompareAndSwap64 OSAtomicCompareAndSwapPtr bzero \
 	clearenv copyfile fgetln flock fls kqueue lockf memset posix_spawn setmode strcasecmp strlcat \
@@ -275,27 +273,9 @@
 AC_DEFINE([MIN_USABLE_UID], [500], [Lowest non-system-reserved UID.])
 AC_DEFINE([MIN_USABLE_GID], [500], [Lowest non-system-reserved GID.])
 
-# Load tclConfig.sh
-SC_PATH_TCLCONFIG
-SC_LOAD_TCLCONFIG
+# Substitute platform for base compatibility check
+MP_PLATFORM
 
-# Check for Tcl public headers
-dnl XXX	 hardwire CYGPATH (CYGPATH must be set for SC_PUBLIC_TCL_HEADERS)
-CYGPATH=echo
-SC_PUBLIC_TCL_HEADERS
-
-# Check for tclsh binary
-MP_PROG_TCLSH
-
-# Substitute Tcl platform for base compatibility check
-MP_TCL_PLATFORM
-
-# Check for Tcl package path
-MP_TCL_PACKAGE_DIR
-
-# Check if thread is enabled.
-MP_TCL_THREAD_SUPPORT
-
 ## libcurl
 MP_LIBCURL_FLAGS
 
@@ -310,91 +290,112 @@
 # check whether trace mode is supported on this platform
 MP_TRACEMODE_SUPPORT
 
+# misc variables that need to be expanded for substitution into tcl
+oldprefix=$prefix
+oldexec_prefix=$exec_prefix
+if test "x$prefix" = "xNONE" ; then
+   prefix=$ac_default_prefix
+fi
+if test "x$exec_prefix" = "xNONE" ; then
+	exec_prefix=$prefix
+fi
+eval "prefix_expanded=$prefix"
+eval "exec_prefix_expanded=$exec_prefix"
+AC_SUBST(prefix_expanded)
+# do this twice, since there is a nested variable of
+# ${prefix} inside of ${sysconfdir}
+eval "MPCONFIGDIR_EXPANDED=$MPCONFIGDIR"
+eval "MPCONFIGDIR_EXPANDED=$MPCONFIGDIR_EXPANDED"
+AC_SUBST(MPCONFIGDIR_EXPANDED)
+eval "localstatedir_expanded=$localstatedir"
+AC_SUBST(localstatedir_expanded)
+eval "macports_tcl_dir=${datadir}/macports/Tcl"
+eval "macports_tcl_dir=$macports_tcl_dir"
+AC_SUBST(macports_tcl_dir)
+# Compute the libexec dir for the vendor packages
+eval "macports_libexec_dir=${libexecdir}/macports"
+eval "macports_libexec_dir=$macports_libexec_dir"
+prefix=$oldprefix
+exec_prefix=$oldexec_prefix
+
 # Determine if we need to install some bundled packages
-OUR_INCLUDED_PACKAGES=
+VENDOR_PACKAGES=
 
-## Thread package.
-AC_ARG_WITH(
-		included-tclthread,
-		AS_HELP_STRING([--with-included-tclthread],
-			[install included Thread package.]),
-		[with_included_tclthread=$withval],
-		[with_included_tclthread="unspecified"])
+## Tcl package
+tcl_version=8.5.15
+tcl_thread_version=2.7.0
+tcllib_version=1.15
+MP_CONFIG_TARBALL([vendor/tcl${tcl_version}-src.tar.gz], [vendor/tcl${tcl_version}/unix], [--prefix=${macports_libexec_dir} --enable-threads])
+VENDOR_TCL_SUBDIR=tcl${tcl_version}/unix
+VENDOR_TCL_INSTALL="install-binaries install-libraries"
+AC_SUBST(VENDOR_TCL_SUBDIR)
+AC_SUBST(VENDOR_TCL_INSTALL)
 
-# Check if thread package is already installed.
-if test "x$with_included_tclthread" = "xunspecified" ; then
-	MP_TCL_PACKAGE(
-		[Thread],
-		[AC_MSG_RESULT([yes]); with_included_tclthread=no],
-		[AC_MSG_RESULT([no]); with_included_tclthread=yes])
-fi
+# Set up some variables needed by MacPorts' Tcl setup
+VENDOR_DESTROOT=vendor/vendor-destroot
+AC_SUBST(VENDOR_DESTROOT)
 
-# If thread package isn't installed, configure and install thread package.
-if test "$with_included_tclthread" = "yes"; then
-	OUR_INCLUDED_PACKAGES="$OUR_INCLUDED_PACKAGES thread2.6"
-	AC_CONFIG_SUBDIRS([src/thread2.6])
-	# Extract thread package
-	(cd src/; gzip -d < thread2.6.tar.gz | tar xf -)
-	# Patch thread package (so thread2.6 is the vanilla distribution directory)
-	patch -p0 < src/thread2.6.diff
-fi
+## Tcl Thread package
+# Tcl supports Threads internally, but to use threads from Tcl code we need
+# this package
+MP_CONFIG_TARBALL([vendor/thread${tcl_thread_version}.tar.gz], [vendor/thread${tcl_thread_version}], [--prefix=${macports_libexec_dir}])
+VENDOR_TCLTHREAD_SUBDIR=thread${tcl_thread_version}
+VENDOR_TCLTHREAD_INSTALL="install-binaries install-libraries"
+AC_SUBST(VENDOR_TCLTHREAD_SUBDIR)
+AC_SUBST(VENDOR_TCLTHREAD_INSTALL)
 
-# Allows building of shared libraries
+## Tcllib package
+# Note that Tcllib needs a Tcl interpreter during installation; it will *not*
+# be the one we configure above, because that one isn't built yet. That's not
+# a problem, though -- it's only used during installation.
+MP_CONFIG_TARBALL([vendor/tcllib-${tcllib_version}.tar.gz], [vendor/tcllib-${tcllib_version}], [--prefix=${macports_libexec_dir}])
+VENDOR_PACKAGES="$VENDOR_PACKAGES tcllib-${tcllib_version}"
+VENDOR_TCLLIB_SUBDIR=tcllib-${tcllib_version}
+VENDOR_TCLLIB_INSTALL="install-libraries"
+AC_SUBST(VENDOR_TCLLIB_SUBDIR)
+AC_SUBST(VENDOR_TCLLIB_INSTALL)
+
+# Load tclConfig.sh from our private install of Tcl
+AC_MSG_CHECKING([for Tcl configuration])
+TCL_BIN_DIR=`(cd vendor/tcl${tcl_version}/unix; pwd)`
+AC_MSG_RESULT([found $TCL_BIN_DIR/tclConfig.sh])
+SC_LOAD_TCLCONFIG
 SC_ENABLE_SHARED
 
-# Pull compiler / linker values from tclConfig.sh
-LDFLAGS_DEBUG=${TCL_LDFLAGS_DEBUG}
-LDFLAGS_OPTIMIZE=${TCL_LDFLAGS_OPTIMIZE}
+# Pull compiler/linker values from tclConfig.sh
 SHLIB_LD=${TCL_SHLIB_LD}
 STLIB_LD=${TCL_STLIB_LD}
 SHLIB_CFLAGS=${TCL_SHLIB_CFLAGS}
 SHLIB_SUFFIX=${TCL_SHLIB_SUFFIX}
+TCLSH=${TCL_EXEC_PREFIX}/bin/tclsh${TCL_VERSION}
+INTREE_TCLSH=${TCL_BIN_DIR}/tclsh
+# strip possible whitespace at the end of TCL_PACKAGE_PATH
+eval "TCL_PACKAGE_PATH=${TCL_PACKAGE_PATH}"
 
-AC_SUBST(INCLUDES)
+AC_SUBST(SHLIB_LD)
 AC_SUBST(STLIB_LD)
-AC_SUBST(SHLIB_LD)
 AC_SUBST(SHLIB_CFLAGS)
-AC_SUBST(SHLIB_LDFLAGS)
 AC_SUBST(SHLIB_SUFFIX)
-AC_SUBST(TCL_DEFS)
+AC_SUBST(TCL_PREFIX)
+AC_SUBST(TCL_VERSION)
+AC_SUBST(TCL_PACKAGE_PATH)
 AC_SUBST(TCL_STUB_LIB_SPEC)
-AC_SUBST(TCL_CC)
-AC_SUBST(OUR_INCLUDED_PACKAGES)
+AC_SUBST(TCL_SRC_DIR)
+AC_SUBST(TCLSH)
+AC_SUBST(INTREE_TCLSH)
 
-# misc variables that need to be expanded for substitution into tcl
+INCLUDES="-I.. -I. $INCLUDES"
+AC_SUBST(INCLUDES)
 
-oldprefix=$prefix
-if test "x$prefix" = "xNONE" ; then
-   prefix=$ac_default_prefix
-fi
-
 # Check if there's an existing DP/MP install too old to upgrade
 MP_CHECK_OLDLAYOUT
 
-eval "prefix_expanded=$prefix"
-AC_SUBST(prefix_expanded)
-# do this twice, since there is a nested variable of
-# ${prefix} inside of ${sysconfdir}
-eval "MPCONFIGDIR_EXPANDED=$MPCONFIGDIR"
-eval "MPCONFIGDIR_EXPANDED=$MPCONFIGDIR_EXPANDED"
-AC_SUBST(MPCONFIGDIR_EXPANDED)
-eval "localstatedir_expanded=$localstatedir"
-AC_SUBST(localstatedir_expanded)
-eval "macports_tcl_dir=${datadir}/macports/Tcl"
-eval "macports_tcl_dir=$macports_tcl_dir"
-AC_SUBST(macports_tcl_dir)
-
-prefix=$oldprefix
-
-dnl man page settings (compressed, links, etc)
-dnl
-dnl SC_CONFIG_MANPAGES
-
 # Output
 AC_CONFIG_FILES([
 	Doxyfile
 	Makefile
 	Mk/macports.autoconf.mk
+	doc/Makefile
 	doc/base.mtree
 	doc/macosx.mtree
 	doc/macports.conf
@@ -403,16 +404,26 @@
 	portmgr/freebsd/Makefile
 	setupenv.bash
 	src/Makefile
+	src/cflib1.0/Makefile
+	src/cregistry/Makefile
+	src/darwintracelib1.0/Makefile
 	src/machista1.0/Makefile
+	src/macports1.0/Makefile
 	src/macports1.0/macports_autoconf.tcl
+	src/macports1.0/macports_fastload.tcl
 	src/macports1.0/macports_test_autoconf.tcl
-	src/macports1.0/macports_fastload.tcl
+	src/package1.0/Makefile
 	src/package1.0/package_test_autoconf.tcl
 	src/pextlib1.0/Makefile
+	src/port/Makefile
+	src/port1.0/Makefile
 	src/port1.0/port_autoconf.tcl
 	src/port1.0/port_test_autoconf.tcl
 	src/programs/Makefile
+	src/registry2.0/Makefile
 	src/registry2.0/registry_autoconf.tcl
+	tests/Makefile
+	vendor/Makefile
 ])
 
 AC_CONFIG_FILES([src/pkg_mkindex.sh], [chmod +x src/pkg_mkindex.sh])


Property changes on: trunk/base/doc
___________________________________________________________________
Modified: svn:ignore
   - macports.conf
pubkeys.conf
base.mtree
prefix.mtree
macosx.mtree
*[0-9].gz

   + Makefile
macports.conf
pubkeys.conf
base.mtree
prefix.mtree
macosx.mtree
*[0-9].gz


Deleted: trunk/base/doc/Makefile
===================================================================
--- trunk/base/doc/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/doc/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,60 +0,0 @@
-MAN1=		port.1
-MAN5=		macports.conf.5
-MAN7=		portfile.7 portstyle.7 porthier.7 portgroup.7
-CONF=       archive_sites.conf macports.conf pubkeys.conf sources.conf variants.conf
-INSTALLDIR=	${DESTDIR}${prefix}
-TOPSRCDIR=	..
-
-ifneq ($(MAKECMDGOALS),distclean)
-include ../Mk/macports.autoconf.mk
-endif
-
-all: ${MAN1:.1=.1.gz} ${MAN5:.5=.5.gz} ${MAN7:.7=.7.gz}
-
-clean:
-	rm -f *.{1,5,7}.gz
-
-test:
-
-distclean: clean
-	rm -f macports.conf base.mtree macosx.mtree prefix.mtree pubkeys.conf
-
-%.1.gz: %.1
-	gzip -c $^ > $@
-
-%.5.gz: %.5
-	gzip -c $^ > $@
-
-%.7.gz: %.7
-	gzip -c $^ > $@
-
-install: all
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${INSTALLDIR}"
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${DESTDIR}${mpconfigdir}"
-
-	< prefix.mtree $(MTREE) -U -e -p "${INSTALLDIR}" > /dev/null
-	< base.mtree $(MTREE) -U -e -p "${INSTALLDIR}" > /dev/null
-
-	for f in ${CONF}; do \
-		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$f "${DESTDIR}${mpconfigdir}/$${f}.default"; \
-		if test ! -e "${DESTDIR}${mpconfigdir}/$$f" ; then \
-			set -x; \
-			$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 $$f "${DESTDIR}${mpconfigdir}"; \
-		fi; \
-	done
-
-	# delete old uncompressed man pages if they exist
-	for m in ${MAN1}; do rm -f "${INSTALLDIR}/share/man/man1/$$m" ; done
-	for m in ${MAN5}; do rm -f "${INSTALLDIR}/share/man/man5/$$m" ; done
-	for m in ${MAN7}; do rm -f "${INSTALLDIR}/share/man/man7/$$m" ; done
-
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${INSTALLDIR}/share/macports/install"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 base.mtree "${INSTALLDIR}/share/macports/install/"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 prefix.mtree "${INSTALLDIR}/share/macports/install/"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 macosx.mtree "${INSTALLDIR}/share/macports/install/"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 port.1.gz "${INSTALLDIR}/share/man/man1"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 macports.conf.5.gz "${INSTALLDIR}/share/man/man5"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portfile.7.gz "${INSTALLDIR}/share/man/man7"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portstyle.7.gz "${INSTALLDIR}/share/man/man7"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 porthier.7.gz "${INSTALLDIR}/share/man/man7"
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portgroup.7.gz "${INSTALLDIR}/share/man/man7"

Copied: trunk/base/doc/Makefile.in (from rev 117613, trunk/base/doc/Makefile)
===================================================================
--- trunk/base/doc/Makefile.in	                        (rev 0)
+++ trunk/base/doc/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,63 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+MAN1=		port.1
+MAN5=		macports.conf.5
+MAN7=		portfile.7 portstyle.7 porthier.7 portgroup.7
+CONF=       archive_sites.conf macports.conf pubkeys.conf sources.conf variants.conf
+INSTALLDIR=	${DESTDIR}${prefix}
+TOPSRCDIR=	..
+
+ifneq ($(MAKECMDGOALS),distclean)
+include ../Mk/macports.autoconf.mk
+endif
+
+all: ${MAN1:.1=.1.gz} ${MAN5:.5=.5.gz} ${MAN7:.7=.7.gz}
+
+clean:
+	rm -f *.{1,5,7}.gz
+
+test:
+
+distclean: clean
+	rm -f macports.conf base.mtree macosx.mtree prefix.mtree pubkeys.conf
+
+%.1.gz: %.1
+	gzip -c $^ > $@
+
+%.5.gz: %.5
+	gzip -c $^ > $@
+
+%.7.gz: %.7
+	gzip -c $^ > $@
+
+install: all
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${INSTALLDIR}"
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${DESTDIR}${mpconfigdir}"
+
+	< prefix.mtree $(MTREE) -U -e -p "${INSTALLDIR}" > /dev/null
+	< base.mtree $(MTREE) -U -e -p "${INSTALLDIR}" > /dev/null
+
+	for f in ${CONF}; do \
+		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$f "${DESTDIR}${mpconfigdir}/$${f}.default"; \
+		if test ! -e "${DESTDIR}${mpconfigdir}/$$f" ; then \
+			set -x; \
+			$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 $$f "${DESTDIR}${mpconfigdir}"; \
+		fi; \
+	done
+
+	# delete old uncompressed man pages if they exist
+	for m in ${MAN1}; do rm -f "${INSTALLDIR}/share/man/man1/$$m" ; done
+	for m in ${MAN5}; do rm -f "${INSTALLDIR}/share/man/man5/$$m" ; done
+	for m in ${MAN7}; do rm -f "${INSTALLDIR}/share/man/man7/$$m" ; done
+
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${INSTALLDIR}/share/macports/install"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 base.mtree "${INSTALLDIR}/share/macports/install/"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 prefix.mtree "${INSTALLDIR}/share/macports/install/"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 macosx.mtree "${INSTALLDIR}/share/macports/install/"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 port.1.gz "${INSTALLDIR}/share/man/man1"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 macports.conf.5.gz "${INSTALLDIR}/share/man/man5"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portfile.7.gz "${INSTALLDIR}/share/man/man7"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portstyle.7.gz "${INSTALLDIR}/share/man/man7"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 porthier.7.gz "${INSTALLDIR}/share/man/man7"
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portgroup.7.gz "${INSTALLDIR}/share/man/man7"

Modified: trunk/base/src/Makefile.in
===================================================================
--- trunk/base/src/Makefile.in	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,5 +1,7 @@
-TCLPKG=		@OUR_INCLUDED_PACKAGES@ \
-			cregistry \
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+TCLPKG=		cregistry \
 			registry2.0 \
 			macports1.0 \
 			port1.0 \
@@ -21,4 +23,4 @@
 
 test::
 
-include ../Mk/macports.subdir.mk
+include $(srcdir)/../Mk/macports.subdir.mk


Property changes on: trunk/base/src/cflib1.0
___________________________________________________________________
Added: svn:ignore
   + Makefile


Deleted: trunk/base/src/cflib1.0/Makefile
===================================================================
--- trunk/base/src/cflib1.0/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/cflib1.0/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,7 +0,0 @@
-OBJS=		CFLib.o
-SHLIB_NAME=	CFLib${SHLIB_SUFFIX}
-LIBS+=		-framework CoreFoundation
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/cflib1.0
-
-include ../../Mk/macports.autoconf.mk
-include ../../Mk/macports.tea.mk

Copied: trunk/base/src/cflib1.0/Makefile.in (from rev 117487, trunk/base/src/cflib1.0/Makefile)
===================================================================
--- trunk/base/src/cflib1.0/Makefile.in	                        (rev 0)
+++ trunk/base/src/cflib1.0/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,10 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+OBJS=		CFLib.o
+SHLIB_NAME=	CFLib${SHLIB_SUFFIX}
+LIBS+=		-framework CoreFoundation
+INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/cflib1.0
+
+include ../../Mk/macports.autoconf.mk
+include $(srcdir)/../../Mk/macports.tea.mk


Property changes on: trunk/base/src/cregistry
___________________________________________________________________
Modified: svn:ignore
   - cregistry.a
macports.sqlext

   + Makefile
cregistry.a
macports.sqlext


Deleted: trunk/base/src/cregistry/Makefile
===================================================================
--- trunk/base/src/cregistry/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/cregistry/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,31 +0,0 @@
-# $Id$
-
-OBJS = registry.o entry.o sql.o vercomp.o util.o file.o portgroup.o
-STLIB_NAME = cregistry.a
-RANLIB = ranlib
-
-SQLEXT_NAME = macports.sqlext
-SQLEXT_OBJS = sqlext.o vercomp.o
-
-include ../../Mk/macports.autoconf.mk
-
-all:: ${STLIB_NAME} ${SQLEXT_NAME}
-
-.c.o:
-	${CC} -c -DUSE_TCL_STUBS ${CFLAGS} ${CPPFLAGS} ${SHLIB_CFLAGS} $< -o $@
-
-${STLIB_NAME}:: ${OBJS}
-	${STLIB_LD} ${STLIB_NAME} ${OBJS}
-	${RANLIB} ${STLIB_NAME}
-
-${SQLEXT_NAME}: ${SQLEXT_OBJS}
-	${SHLIB_LD} ${SQLEXT_OBJS} -o $@
-
-clean::
-	rm -f ${STLIB_NAME} ${SQLEXT_NAME} ${SQLEXT_OBJS} ${OBJS}
-
-distclean:: clean
-
-test:
-
-install:: all

Copied: trunk/base/src/cregistry/Makefile.in (from rev 117487, trunk/base/src/cregistry/Makefile)
===================================================================
--- trunk/base/src/cregistry/Makefile.in	                        (rev 0)
+++ trunk/base/src/cregistry/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,34 @@
+# $Id$
+
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+OBJS = registry.o entry.o sql.o vercomp.o util.o file.o portgroup.o
+STLIB_NAME = cregistry.a
+RANLIB = ranlib
+
+SQLEXT_NAME = macports.sqlext
+SQLEXT_OBJS = sqlext.o vercomp.o
+
+include ../../Mk/macports.autoconf.mk
+
+all:: ${STLIB_NAME} ${SQLEXT_NAME}
+
+.c.o:
+	${CC} -c -DUSE_TCL_STUBS ${CFLAGS} ${CPPFLAGS} ${SHLIB_CFLAGS} $< -o $@
+
+${STLIB_NAME}:: ${OBJS}
+	${STLIB_LD} ${STLIB_NAME} ${OBJS}
+	${RANLIB} ${STLIB_NAME}
+
+${SQLEXT_NAME}: ${SQLEXT_OBJS}
+	${SHLIB_LD} ${SQLEXT_OBJS} -o $@
+
+clean::
+	rm -f ${STLIB_NAME} ${SQLEXT_NAME} ${SQLEXT_OBJS} ${OBJS}
+
+distclean:: clean
+
+test:
+
+install:: all


Property changes on: trunk/base/src/darwintracelib1.0
___________________________________________________________________
Modified: svn:ignore
   - darwintrace.dylib

   + Makefile
darwintrace.dylib


Deleted: trunk/base/src/darwintracelib1.0/Makefile
===================================================================
--- trunk/base/src/darwintracelib1.0/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/darwintracelib1.0/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,30 +0,0 @@
-# This Makefile will only be run on Darwin systems; we can safely use
-# Apple-specifics here
-SRCS=		$(wildcard *.c)
-OBJS=		$(SRCS:%.c=%.o)
-SHLIB_NAME=	darwintrace${SHLIB_SUFFIX}
-INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/darwintrace1.0
-
-include ../../Mk/macports.autoconf.mk
-
-# Yes, we know having $ signs in identifiers is not a very good idea; in the
-# case of darwintrace we still need them, though.
-CFLAGS_PEDANTIC=
-CFLAGS+= -fPIC ${UNIVERSAL_ARCHFLAGS}
-SHLIB_LDFLAGS+=${UNIVERSAL_ARCHFLAGS}
-
-all:: ${SHLIB_NAME}
-
-$(SHLIB_NAME):: ${OBJS}
-	${SHLIB_LD} ${OBJS} -o ${SHLIB_NAME} ${SHLIB_LDFLAGS} ${LIBS}
-
-clean::
-	rm -f ${OBJS} ${SHLIB_NAME} so_locations
-
-distclean:: clean
-
-install:: all
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 ${SHLIB_NAME} ${INSTALLDIR}
-
-test::

Copied: trunk/base/src/darwintracelib1.0/Makefile.in (from rev 117487, trunk/base/src/darwintracelib1.0/Makefile)
===================================================================
--- trunk/base/src/darwintracelib1.0/Makefile.in	                        (rev 0)
+++ trunk/base/src/darwintracelib1.0/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,33 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+# This Makefile will only be run on Darwin systems; we can safely use
+# Apple-specifics here
+SRCS=		$(wildcard *.c)
+OBJS=		$(SRCS:%.c=%.o)
+SHLIB_NAME=	darwintrace${SHLIB_SUFFIX}
+INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/darwintrace1.0
+
+include ../../Mk/macports.autoconf.mk
+
+# Yes, we know having $ signs in identifiers is not a very good idea; in the
+# case of darwintrace we still need them, though.
+CFLAGS_PEDANTIC=
+CFLAGS+= -fPIC ${UNIVERSAL_ARCHFLAGS}
+SHLIB_LDFLAGS+=${UNIVERSAL_ARCHFLAGS}
+
+all:: ${SHLIB_NAME}
+
+$(SHLIB_NAME):: ${OBJS}
+	${SHLIB_LD} ${OBJS} -o ${SHLIB_NAME} ${SHLIB_LDFLAGS} ${LIBS}
+
+clean::
+	rm -f ${OBJS} ${SHLIB_NAME} so_locations
+
+distclean:: clean
+
+install:: all
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 ${SHLIB_NAME} ${INSTALLDIR}
+
+test::

Deleted: trunk/base/src/macports1.0/Makefile
===================================================================
--- trunk/base/src/macports1.0/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/macports1.0/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,46 +0,0 @@
-SRCS=		macports.tcl macports_dlist.tcl macports_util.tcl \
-		macports_autoconf.tcl macports_fastload.tcl
-OBJS=		macports.o get_systemconfiguration_proxies.o sysctl.o
-SHLIB_NAME=	MacPorts${SHLIB_SUFFIX}
-
-INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/macports1.0
-INSTALLPKGLINK=	${TCL_PACKAGE_DIR}/macports1.0
-
-include ../../Mk/macports.autoconf.mk
-include ../../Mk/macports.tea.mk
-
-ifeq ($(OBJC_RUNTIME), APPLE_RUNTIME)
-	LIBS+= -framework CoreFoundation -framework SystemConfiguration
-endif
-
-pkgIndex.tcl: $(SRCS)
-
-test::
-	$(TCLSH) ./tests/test.tcl -nocolor
-
-distclean:: clean
-	rm -f macports_autoconf.tcl macports_fastload.tcl macports_test_autoconf.tcl ${SHLIB_NAME}
-
-install:: all
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
-
-	$(SILENT) set -x; for file in ${SRCS}; do \
-		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$file ${INSTALLDIR}/$$file; \
-	done
-
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}
-
-	echo "${TCL_PACKAGE_DIR}" > ${DESTDIR}${prefix}/var/macports/.tclpackage
-	if test -z "${DESTDIR}" -a "${INSTALLPKGLINK}" != "${INSTALLDIR}"; then \
-		if test ! -L "${INSTALLPKGLINK}"; then \
-            if test ! -e "${TCL_PACKAGE_DIR}"; then \
-                $(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${TCL_PACKAGE_DIR}" || true; \
-            fi; \
-            if test -d "${INSTALLPKGLINK}"; then \
-                rm -vrf "${INSTALLPKGLINK}" || true; \
-            fi; \
-            if test ! -e "${INSTALLPKGLINK}"; then \
-                ln -vs "${INSTALLDIR}" "${INSTALLPKGLINK}" || true; \
-            fi; \
-        fi; \
-	fi

Copied: trunk/base/src/macports1.0/Makefile.in (from rev 117487, trunk/base/src/macports1.0/Makefile)
===================================================================
--- trunk/base/src/macports1.0/Makefile.in	                        (rev 0)
+++ trunk/base/src/macports1.0/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,49 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+SRCS=		macports.tcl macports_dlist.tcl macports_util.tcl \
+		macports_autoconf.tcl macports_fastload.tcl
+OBJS=		macports.o get_systemconfiguration_proxies.o sysctl.o
+SHLIB_NAME=	MacPorts${SHLIB_SUFFIX}
+
+INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/macports1.0
+INSTALLPKGLINK=	${TCL_PACKAGE_PATH}/macports1.0
+
+include ../../Mk/macports.autoconf.mk
+include $(srcdir)/../../Mk/macports.tea.mk
+
+ifeq ($(OBJC_RUNTIME), APPLE_RUNTIME)
+	LIBS+= -framework CoreFoundation -framework SystemConfiguration
+endif
+
+pkgIndex.tcl: $(SRCS)
+
+test::
+	$(TCLSH) $(srcdir)/tests/test.tcl -nocolor
+
+distclean:: clean
+	rm -f macports_autoconf.tcl macports_fastload.tcl macports_test_autoconf.tcl ${SHLIB_NAME}
+
+install:: all
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
+
+	$(SILENT) set -x; for file in ${SRCS}; do \
+		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$file ${INSTALLDIR}/$$file; \
+	done
+
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}
+
+	echo "${TCL_PACKAGE_PATH}" > ${DESTDIR}${prefix}/var/macports/.tclpackage
+	if test -z "${DESTDIR}" -a "${INSTALLPKGLINK}" != "${INSTALLDIR}"; then \
+		if test ! -L "${INSTALLPKGLINK}"; then \
+            if test ! -e "${TCL_PACKAGE_PATH}"; then \
+                $(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${TCL_PACKAGE_PATH}" || true; \
+            fi; \
+            if test -d "${INSTALLPKGLINK}"; then \
+                rm -vrf "${INSTALLPKGLINK}" || true; \
+            fi; \
+            if test ! -e "${INSTALLPKGLINK}"; then \
+                ln -vs "${INSTALLDIR}" "${INSTALLPKGLINK}" || true; \
+            fi; \
+        fi; \
+	fi

Modified: trunk/base/src/macports1.0/macports_fastload.tcl.in
===================================================================
--- trunk/base/src/macports1.0/macports_fastload.tcl.in	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/macports1.0/macports_fastload.tcl.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -81,11 +81,3 @@
         }
     }
 }
-
-if { "@SQLITE3_TCL_DIR@" != "" } {
-    set dir "@SQLITE3_TCL_DIR@"
-    set pkgindex [file join $dir pkgIndex.tcl]
-    if [file exists $pkgindex] {
-        source $pkgindex
-    }
-}


Property changes on: trunk/base/src/package1.0
___________________________________________________________________
Modified: svn:ignore
   - pkgIndex.tcl
package_test_autoconf.tcl

   + Makefile
package_test_autoconf.tcl
pkgIndex.tcl


Deleted: trunk/base/src/package1.0/Makefile
===================================================================
--- trunk/base/src/package1.0/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/package1.0/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,29 +0,0 @@
-INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/package1.0
-
-SRCS=	package.tcl portdmg.tcl portmdmg.tcl portmpkg.tcl portpkg.tcl \
-	portrpm.tcl portsrpm.tcl portdpkg.tcl portunarchive.tcl \
-	portarchivefetch.tcl
-
-include ../../Mk/macports.autoconf.mk
-
-all:: pkgIndex.tcl
-
-pkgIndex.tcl: $(SRCS)
-	$(SILENT) ../pkg_mkindex.sh .
-
-clean::
-	rm -f pkgIndex.tcl
-
-distclean:: clean
-	rm -f package_test_autoconf.tcl
-
-test::
-	-$(prefix)/bin/port sync
-	$(TCLSH) ./tests/test.tcl -nocolor
-
-install:: all
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
-	$(SILENT)set -x; for file in ${SRCS}; do \
-		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$file ${INSTALLDIR}; \
-	done
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}

Copied: trunk/base/src/package1.0/Makefile.in (from rev 117487, trunk/base/src/package1.0/Makefile)
===================================================================
--- trunk/base/src/package1.0/Makefile.in	                        (rev 0)
+++ trunk/base/src/package1.0/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,32 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/package1.0
+
+SRCS=	package.tcl portdmg.tcl portmdmg.tcl portmpkg.tcl portpkg.tcl \
+	portrpm.tcl portsrpm.tcl portdpkg.tcl portunarchive.tcl \
+	portarchivefetch.tcl
+
+include ../../Mk/macports.autoconf.mk
+
+all:: pkgIndex.tcl
+
+pkgIndex.tcl: $(SRCS)
+	$(SILENT) ../pkg_mkindex.sh .
+
+clean::
+	rm -f pkgIndex.tcl
+
+distclean:: clean
+	rm -f package_test_autoconf.tcl
+
+test::
+	-$(prefix)/bin/port sync
+	$(TCLSH) $(srcdir)/tests/test.tcl -nocolor
+
+install:: all
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
+	$(SILENT)set -x; for file in ${SRCS}; do \
+		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $(srcdir)/$$file ${INSTALLDIR}; \
+	done
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}

Modified: trunk/base/src/pkg_mkindex.sh.in
===================================================================
--- trunk/base/src/pkg_mkindex.sh.in	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/pkg_mkindex.sh.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -28,7 +28,7 @@
 # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 # POSSIBILITY OF SUCH DAMAGE.
 
-TCLSH=@TCLSH@
+TCLSH=@INTREE_TCLSH@
 GREP=@GREP@
 
 if [ $# = 0 ]; then


Property changes on: trunk/base/src/port
___________________________________________________________________
Modified: svn:ignore
   - port
portall
portindex
portmirror

   + Makefile
port
portall
portindex
portmirror


Deleted: trunk/base/src/port/Makefile
===================================================================
--- trunk/base/src/port/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/port/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,40 +0,0 @@
-INSTALLDIR=	${DESTDIR}${prefix}
-TOPSRCDIR=	../..
-SCRIPTS=	portmirror portindex port
-
-edit = sed \
-	-e 's, at TCLSH\@,$(TCLSH),g' \
-	-e 's, at macports_tcl_dir\@,$(macports_tcl_dir),g'
-
-include ../../Mk/macports.autoconf.mk
-
-.PHONY: mkdirs
-
-all: ${SCRIPTS}
-
-portmirror: portmirror.tcl ../../Mk/macports.autoconf.mk
-	${edit} portmirror.tcl > $@
-
-portindex: portindex.tcl ../../Mk/macports.autoconf.mk
-	${edit} portindex.tcl > $@
-
-port: port.tcl ../../Mk/macports.autoconf.mk
-	${edit} port.tcl > $@
-
-mkdirs:
-	< ../../doc/prefix.mtree $(MTREE) -U -d -e -p ${INSTALLDIR} > /dev/null
-	< ../../doc/base.mtree $(MTREE) -U -d -e -p ${INSTALLDIR} > /dev/null
-
-clean:
-	rm -f ${SCRIPTS}
-
-test:
-
-distclean: clean
-
-install: all mkdirs
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}/bin
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}/var/macports
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 555 port portindex portmirror ${INSTALLDIR}/bin/
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 port-help.tcl  ${INSTALLDIR}/var/macports/
-	cd ${INSTALLDIR}/bin && $(LN_S) -f port portf

Copied: trunk/base/src/port/Makefile.in (from rev 117487, trunk/base/src/port/Makefile)
===================================================================
--- trunk/base/src/port/Makefile.in	                        (rev 0)
+++ trunk/base/src/port/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,43 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+INSTALLDIR=	${DESTDIR}${prefix}
+TOPSRCDIR=	../..
+SCRIPTS=	portmirror portindex port
+
+edit = sed \
+	-e 's, at TCLSH\@,$(TCLSH),g' \
+	-e 's, at macports_tcl_dir\@,$(macports_tcl_dir),g'
+
+include ../../Mk/macports.autoconf.mk
+
+.PHONY: mkdirs
+
+all: ${SCRIPTS}
+
+portmirror: portmirror.tcl ../../Mk/macports.autoconf.mk
+	${edit} $(srcdir)/portmirror.tcl > $@
+
+portindex: portindex.tcl ../../Mk/macports.autoconf.mk
+	${edit} $(srcdir)/portindex.tcl > $@
+
+port: port.tcl ../../Mk/macports.autoconf.mk
+	${edit} $(srcdir)/port.tcl > $@
+
+mkdirs:
+	< ../../doc/prefix.mtree $(MTREE) -U -d -e -p ${INSTALLDIR} > /dev/null
+	< ../../doc/base.mtree $(MTREE) -U -d -e -p ${INSTALLDIR} > /dev/null
+
+clean:
+	rm -f ${SCRIPTS}
+
+test:
+
+distclean: clean
+
+install: all mkdirs
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}/bin
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}/var/macports
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 555 port portindex portmirror ${INSTALLDIR}/bin/
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $(srcdir)/port-help.tcl  ${INSTALLDIR}/var/macports/
+	cd ${INSTALLDIR}/bin && $(LN_S) -f port portf


Property changes on: trunk/base/src/port1.0
___________________________________________________________________
Modified: svn:ignore
   - port_autoconf.tcl
port_test_autoconf.tcl
pkgIndex.tcl

   + Makefile
pkgIndex.tcl
port_autoconf.tcl
port_test_autoconf.tcl


Deleted: trunk/base/src/port1.0/Makefile
===================================================================
--- trunk/base/src/port1.0/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/port1.0/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,36 +0,0 @@
-INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/port1.0
-
-SRCS=	port.tcl portchecksum.tcl portconfigure.tcl portextract.tcl	    \
-	portfetch.tcl portmain.tcl portbuild.tcl portpatch.tcl portutil.tcl \
-	portinstall.tcl portuninstall.tcl portdepends.tcl portdestroot.tcl \
-	portlint.tcl portclean.tcl porttest.tcl portactivate.tcl \
-	portdeactivate.tcl port_autoconf.tcl portstartupitem.tcl \
-	porttrace.tcl portlivecheck.tcl portdistcheck.tcl portmirror.tcl \
-	portload.tcl portunload.tcl portdistfiles.tcl fetch_common.tcl \
-	portsandbox.tcl
-
-include ../../Mk/macports.subdir.mk
-include ../../Mk/macports.autoconf.mk
-
-.PHONY: test
-
-all:: pkgIndex.tcl
-
-pkgIndex.tcl: $(SRCS)
-	$(SILENT) ../pkg_mkindex.sh . || ( rm -rf $@ && exit 1 )
-
-clean::
-	rm -f pkgIndex.tcl
-
-distclean:: clean
-	rm -f port_autoconf.tcl port_test_autoconf.tcl
-
-install:: all
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
-	$(SILENT)set -x; for file in ${SRCS}; do \
-		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$file ${INSTALLDIR}; \
-	done
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}
-
-test::
-	$(TCLSH) ./tests/test.tcl -nocolor

Copied: trunk/base/src/port1.0/Makefile.in (from rev 117487, trunk/base/src/port1.0/Makefile)
===================================================================
--- trunk/base/src/port1.0/Makefile.in	                        (rev 0)
+++ trunk/base/src/port1.0/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,42 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+INSTALLDIR=	${DESTDIR}${datadir}/macports/Tcl/port1.0
+
+SRCS_AUTOCONF= port_autoconf.tcl
+SRCS=	port.tcl portchecksum.tcl portconfigure.tcl portextract.tcl	    \
+	portfetch.tcl portmain.tcl portbuild.tcl portpatch.tcl portutil.tcl \
+	portinstall.tcl portuninstall.tcl portdepends.tcl portdestroot.tcl \
+	portlint.tcl portclean.tcl porttest.tcl portactivate.tcl \
+	portdeactivate.tcl portstartupitem.tcl porttrace.tcl portlivecheck.tcl \
+	portdistcheck.tcl portmirror.tcl portload.tcl portunload.tcl \
+	portdistfiles.tcl fetch_common.tcl portsandbox.tcl
+
+include $(srcdir)/../../Mk/macports.subdir.mk
+include ../../Mk/macports.autoconf.mk
+
+.PHONY: test
+
+all:: pkgIndex.tcl
+
+pkgIndex.tcl: $(SRCS) $(SRCS_AUTOCONF)
+	$(SILENT) ../pkg_mkindex.sh . || ( rm -rf $@ && exit 1 )
+
+clean::
+	rm -f pkgIndex.tcl
+
+distclean:: clean
+	rm -f port_autoconf.tcl port_test_autoconf.tcl
+
+install:: all
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
+	$(SILENT)set -x; for file in ${SRCS}; do \
+		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $(srcdir)/$$file ${INSTALLDIR}; \
+	done
+	$(SILENT)set -x; for file in ${SRCS_AUTOCONF}; do \
+		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$file ${INSTALLDIR}; \
+	done
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}
+
+test::
+	$(TCLSH) $(srcdir)/tests/test.tcl -nocolor


Property changes on: trunk/base/src/registry2.0
___________________________________________________________________
Modified: svn:ignore
   - pkgIndex.tcl
registry.dylib
registry_autoconf.tcl

   + Makefile
pkgIndex.tcl
registry.dylib
registry_autoconf.tcl


Deleted: trunk/base/src/registry2.0/Makefile
===================================================================
--- trunk/base/src/registry2.0/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/registry2.0/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,42 +0,0 @@
-# $Id$
-
-SRCS = registry.tcl registry_autoconf.tcl registry_util.tcl receipt_flat.tcl receipt_sqlite.tcl portimage.tcl portuninstall.tcl
-OBJS = registry.o util.o \
-	entry.o entryobj.o \
-	file.o fileobj.o \
-	portgroup.o portgroupobj.o
-	#graph.o graphobj.o
-
-SHLIB_NAME= registry${SHLIB_SUFFIX}
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/registry2.0
-
-include ../../Mk/macports.autoconf.mk
-include ../../Mk/macports.tea.mk
-
-pkgIndex.tcl: $(SRCS)
-
-CFLAGS+=	${SQLITE3_CFLAGS}
-LIBS+=	${SQLITE3_LIBS} ../cregistry/cregistry.a
-ifeq ($(shell uname), Darwin)
-SHLIB_LDFLAGS+= -install_name @loader_path/../registry2.0/${SHLIB_NAME}
-endif
-
-${SHLIB_NAME}: ../cregistry/cregistry.a
-
-.PHONY: test
-
-test:: ${SHLIB_NAME}
-	${TCLSH} tests/entry.tcl ./${SHLIB_NAME}
-	${TCLSH} tests/depends.tcl ./${SHLIB_NAME}
-
-distclean:: clean
-	rm -f registry_autoconf.tcl
-
-install:: all
-	[ ! -d $(DESTDIR)${datadir}/macports/Tcl/registry1.0 ] || rm -vrf $(DESTDIR)${datadir}/macports/Tcl/registry1.0
-	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 ${SHLIB_NAME} ${INSTALLDIR}
-	$(SILENT) set -x; for file in ${SRCS}; do \
-		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$file ${INSTALLDIR}/$$file; \
-	done
-	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}

Copied: trunk/base/src/registry2.0/Makefile.in (from rev 117487, trunk/base/src/registry2.0/Makefile)
===================================================================
--- trunk/base/src/registry2.0/Makefile.in	                        (rev 0)
+++ trunk/base/src/registry2.0/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,49 @@
+# $Id$
+
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+SRCS_AUTOCONF = registry_autoconf.tcl
+SRCS = registry.tcl registry_util.tcl receipt_flat.tcl receipt_sqlite.tcl portimage.tcl portuninstall.tcl
+OBJS = registry.o util.o \
+	entry.o entryobj.o \
+	file.o fileobj.o \
+	portgroup.o portgroupobj.o
+	#graph.o graphobj.o
+
+SHLIB_NAME= registry${SHLIB_SUFFIX}
+INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/registry2.0
+
+include ../../Mk/macports.autoconf.mk
+include $(srcdir)/../../Mk/macports.tea.mk
+
+pkgIndex.tcl: $(SRCS) $(SRCS_AUTOCONF)
+
+CFLAGS+=	${SQLITE3_CFLAGS}
+LIBS+=	${SQLITE3_LIBS} ../cregistry/cregistry.a
+ifeq ($(shell uname), Darwin)
+SHLIB_LDFLAGS+= -install_name @loader_path/../registry2.0/${SHLIB_NAME}
+endif
+
+${SHLIB_NAME}: ../cregistry/cregistry.a
+
+.PHONY: test
+
+test:: ${SHLIB_NAME}
+	${TCLSH} $(srcdir)/tests/entry.tcl ./${SHLIB_NAME}
+	${TCLSH} $(srcdir)/tests/depends.tcl ./${SHLIB_NAME}
+
+distclean:: clean
+	rm -f registry_autoconf.tcl
+
+install:: all $(SHLIB_NAME)
+	[ ! -d $(DESTDIR)${datadir}/macports/Tcl/registry1.0 ] || rm -vrf $(DESTDIR)${datadir}/macports/Tcl/registry1.0
+	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 ${SHLIB_NAME} ${INSTALLDIR}
+	$(SILENT) set -x; for file in ${SRCS}; do \
+		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $(srcdir)/$$file ${INSTALLDIR}/$$file; \
+	done
+	$(SILENT) set -x; for file in ${SRCS_AUTOCONF}; do \
+		$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 $$file ${INSTALLDIR}/$$file; \
+	done
+	$(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 pkgIndex.tcl ${INSTALLDIR}

Deleted: trunk/base/src/thread2.6.diff
===================================================================
--- trunk/base/src/thread2.6.diff	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/src/thread2.6.diff	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,79 +0,0 @@
-diff -ru src/thread2.6/Makefile.in src/thread2.6.mine/Makefile.in
---- src/thread2.6/Makefile.in	Sat Dec 18 09:26:02 2004
-+++ src/thread2.6.mine/Makefile.in	Mon Apr 17 02:42:43 2006
-@@ -67,12 +67,12 @@
- 
- srcdir		= @srcdir@
- prefix		= @prefix@
--exec_prefix	= @exec_prefix@
-+exec_prefix	= @prefix@
- 
- bindir		= @bindir@
--libdir		= @libdir@
-+libdir		= @prefix@/share/macports/Tcl
- datadir		= @datadir@
--mandir		= @mandir@
-+mandir		= @prefix@/share/macports/man
- includedir	= @includedir@
- 
- DESTDIR		=
-diff -ru src/thread2.6/configure src/thread2.6.mine/configure
---- src/thread2.6/configure	Thu Dec 23 05:48:44 2004
-+++ src/thread2.6.mine/configure	Mon Apr 17 02:27:46 2006
-@@ -6374,13 +6374,11 @@
-    { (exit 1); exit 1; }; }
- 	    fi
- 	else
--	    # Check order: pkg --prefix location, Tcl's --prefix location,
-+	    # Check order:
- 	    # directory of tclConfig.sh, and Tcl source directory.
- 	    # Looking in the source dir is not ideal, but OK.
- 
--	    eval "temp_includedir=${includedir}"
--	    list="`ls -d ${temp_includedir}      2>/dev/null` \
--		`ls -d ${TCL_PREFIX}/include     2>/dev/null` \
-+	    list="`ls -d ${TCL_PREFIX}/include     2>/dev/null` \
- 		`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null` \
- 		`ls -d ${TCL_SRC_DIR}/generic    2>/dev/null`"
- 	    if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
-diff -ru src/thread2.6/lib/ttrace.tcl src/thread2.6.mine/lib/ttrace.tcl
---- src/thread2.6/lib/ttrace.tcl	Fri Jul 30 01:37:50 2004
-+++ src/thread2.6.mine/lib/ttrace.tcl	Mon Apr 17 02:27:46 2006
-@@ -50,8 +50,8 @@
-         variable mutex ns_mutex
-         variable elock [$mutex create traceepochmutex]
-         variable store nsv_
--    } elseif {![catch {package require Thread} version]} {
--        variable tvers $version
-+    } elseif {![catch {package require Thread} thread_pkg_version]} {
-+        variable tvers $thread_pkg_version
-         variable mutex thread::mutex
-         variable elock [$mutex create]
-         variable store tsv::
-# tcl-64/tcl_ext/thread/thread.diff
---- src/thread2.6/generic/threadPoolCmd.c.orig	2003-11-27 11:54:19.000000000 -0800
-+++ src/thread2.6/generic/threadPoolCmd.c	2005-07-20 23:10:12.000000000 -0700
-@@ -1710,18 +1710,21 @@
-  *
-  *----------------------------------------------------------------------
-  */
-+#ifdef __WIN32__
-+#include <sys/timeb.h>
-+#else
-+#include <sys/time.h>
-+#endif
- static void
- GetTime(timePtr)
-     Tcl_Time *timePtr;
- {
- #ifdef __WIN32__
--#include <sys/timeb.h>
-     struct timeb tb;
-     (void)ftime(&tb);
-     timePtr->sec  = tb.time;
-     timePtr->usec = tb.millitm * 1000;
- #else
--#include <sys/time.h>
-     struct timeval tv;
-     (void)gettimeofday(&tv, NULL);
-     timePtr->sec  = tv.tv_sec;

Deleted: trunk/base/src/thread2.6.tar.gz
===================================================================
(Binary files differ)


Property changes on: trunk/base/tests
___________________________________________________________________
Added: svn:ignore
   + Makefile


Deleted: trunk/base/tests/Makefile
===================================================================
--- trunk/base/tests/Makefile	2014-03-05 20:54:19 UTC (rev 117620)
+++ trunk/base/tests/Makefile	2014-03-05 22:19:14 UTC (rev 117621)
@@ -1,14 +0,0 @@
-include ../Mk/macports.autoconf.mk
-
-all:: ../Mk/macports.autoconf.mk
-
-install::
-
-# Run all regression tests
-# tclsh test.tcl -h for more options.
-test::
-	$(TCLSH) test.tcl -nocolor
-
-clean::
-
-distclean:: clean

Copied: trunk/base/tests/Makefile.in (from rev 117487, trunk/base/tests/Makefile)
===================================================================
--- trunk/base/tests/Makefile.in	                        (rev 0)
+++ trunk/base/tests/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,17 @@
+srcdir = @srcdir@
+VPATH  = @srcdir@
+
+include ../Mk/macports.autoconf.mk
+
+all:: ../Mk/macports.autoconf.mk
+
+install::
+
+# Run all regression tests
+# tclsh test.tcl -h for more options.
+test::
+	$(TCLSH) $(srcdir)/test.tcl -nocolor
+
+clean::
+
+distclean:: clean


Property changes on: trunk/base/vendor
___________________________________________________________________
Added: svn:ignore
   + Makefile
tcl8.5.[0-9]*
tcllib-1.[0-9]*
thread2.[0-9]*.[0-9]*
vendor-destroot


Added: trunk/base/vendor/Makefile.in
===================================================================
--- trunk/base/vendor/Makefile.in	                        (rev 0)
+++ trunk/base/vendor/Makefile.in	2014-03-05 22:19:14 UTC (rev 117621)
@@ -0,0 +1,66 @@
+TCL_SUBDIR=			@VENDOR_TCL_SUBDIR@
+TCL_TARGETS=		@VENDOR_TCL_INSTALL@
+
+TCLTHREAD_SUBDIR=	@VENDOR_TCLTHREAD_SUBDIR@
+TCLTREHAD_TARGETS=	@VENDOR_TCLTHREAD_INSTALL@
+
+TCLLIB_SUBDIR=		@VENDOR_TCLLIB_SUBDIR@
+TCLLIB_TARGETS= 	@VENDOR_TCLLIB_INSTALL@
+
+DESTROOT=   		@abs_top_builddir@/vendor/vendor-destroot
+
+.PHONY: all clean distclean install destroot test
+.PHONY: destroot-tcl destroot-tcllthread destroot-tcllib
+.PHONY: install-tcl install-tcllthread install-tcllib
+.PHONY: %-tcl %-tcllthread %-tcllib
+
+# for make all, run destroot (where destroot will depend on all of each
+# subpackage)
+all: destroot
+
+%-tcl:
+	@echo ===\> making $(@:%-tcl=%) in ${DIRPRFX}@VENDOR_TCL_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCL_SUBDIR@ $(@:%-tcl=%)
+
+%-tclthread:
+	@echo ===\> making $(@:%-tclthrad=%) in ${DIRPRFX}@VENDOR_TCLTHREAD_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCLTHREAD_SUBDIR@ $(@:%-tclthread=%)
+
+%-tcllib:
+	@echo ===\> making $(@:%-tcllib=%) in ${DIRPRFX}@VENDOR_TCLLIB_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCLLIB_SUBDIR@ $(@:%-tcllib=%)
+
+destroot: destroot-tcl destroot-tclthread destroot-tcllib
+destroot-tcl: all-tcl
+	@echo ===\> staging to destroot in ${DIRPRFX}@VENDOR_TCL_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCL_SUBDIR@ DESTDIR=${DESTROOT} @VENDOR_TCL_INSTALL@
+
+destroot-tclthread: all-tclthread
+	@echo ===\> staging to destroot in ${DIRPRFX}@VENDOR_TCLTHREAD_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCLTHREAD_SUBDIR@ DESTDIR=${DESTROOT} @VENDOR_TCLTHREAD_INSTALL@
+
+destroot-tcllib: all-tcllib
+	@echo ===\> staging to destroot in ${DIRPRFX}@VENDOR_TCLLIB_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCLLIB_SUBDIR@ DESTDIR=${DESTROOT} @VENDOR_TCLLIB_INSTALL@
+
+install: install-tcl install-tclthread install-tcllib
+install-tcl:
+	@echo ===\> making $(@:%-tcl=%) in ${DIRPRFX}@VENDOR_TCL_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCL_SUBDIR@ @VENDOR_TCL_INSTALL@
+
+install-tclthread:
+	@echo ===\> making $(@:%-tclthrad=%) in ${DIRPRFX}@VENDOR_TCLTHREAD_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCLTHREAD_SUBDIR@ @VENDOR_TCLTHREAD_INSTALL@
+
+install-tcllib:
+	@echo ===\> making $(@:%-tcllib=%) in ${DIRPRFX}@VENDOR_TCLLIB_SUBDIR@
+	@$(MAKE) -C @VENDOR_TCLLIB_SUBDIR@ @VENDOR_TCLLIB_INSTALL@
+
+test:
+
+clean: clean-tcl clean-tcllib clean-tclthread
+	rm -rf ${DESTROOT}
+
+distclean:
+	rm -f Makefile
+	rm -rf $(TCL_SUBDIR:/unix=) $(TCLTHREAD_SUBDIR) $(TCLLIB_SUBDIR)

Added: trunk/base/vendor/tcl8.5.15-src.tar.gz
===================================================================
(Binary files differ)


Property changes on: trunk/base/vendor/tcl8.5.15-src.tar.gz
___________________________________________________________________
Added: svn:mime-type
   + application/x-gzip

Added: trunk/base/vendor/tcllib-1.15.tar.gz
===================================================================
(Binary files differ)


Property changes on: trunk/base/vendor/tcllib-1.15.tar.gz
___________________________________________________________________
Added: svn:mime-type
   + application/x-gzip

Added: trunk/base/vendor/thread2.7.0.tar.gz
===================================================================
(Binary files differ)


Property changes on: trunk/base/vendor/thread2.7.0.tar.gz
___________________________________________________________________
Added: svn:mime-type
   + application/x-gzip
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20140305/4ad3d81b/attachment-0001.html>


More information about the macports-changes mailing list