[119170] branches/release_2_3/base
cal at macports.org
cal at macports.org
Fri Apr 18 14:57:35 PDT 2014
Revision: 119170
https://trac.macports.org/changeset/119170
Author: cal at macports.org
Date: 2014-04-18 14:57:35 -0700 (Fri, 18 Apr 2014)
Log Message:
-----------
merge r118559, r118563-r118569, r119169 from trunk:
Remove macports_fastload.tcl, provide port-tclsh
Revision Links:
--------------
https://trac.macports.org/changeset/118559
https://trac.macports.org/changeset/118563
https://trac.macports.org/changeset/118569
https://trac.macports.org/changeset/119169
Modified Paths:
--------------
branches/release_2_3/base/Makefile.in
branches/release_2_3/base/Mk/macports.autoconf.mk.in
branches/release_2_3/base/configure
branches/release_2_3/base/configure.ac
branches/release_2_3/base/portmgr/dmg/postflight.in
branches/release_2_3/base/portmgr/jobs/Makefile
branches/release_2_3/base/portmgr/jobs/PortIndex2MySQL.tcl
branches/release_2_3/base/src/Makefile.in
branches/release_2_3/base/src/cflib1.0/Makefile.in
branches/release_2_3/base/src/darwintracelib1.0/Makefile.in
branches/release_2_3/base/src/machista1.0/Makefile.in
branches/release_2_3/base/src/macports1.0/Makefile.in
branches/release_2_3/base/src/macports1.0/macports.tcl
branches/release_2_3/base/src/macports1.0/macports_test_autoconf.tcl.in
branches/release_2_3/base/src/macports1.0/tests/macports.test
branches/release_2_3/base/src/macports1.0/tests/macports_dlist.test
branches/release_2_3/base/src/macports1.0/tests/macports_util.test
branches/release_2_3/base/src/package1.0/Makefile.in
branches/release_2_3/base/src/package1.0/package_test_autoconf.tcl.in
branches/release_2_3/base/src/package1.0/tests/portarchivefetch.test
branches/release_2_3/base/src/package1.0/tests/portdmg.test
branches/release_2_3/base/src/package1.0/tests/portdpkg.test
branches/release_2_3/base/src/package1.0/tests/portmdmg.test
branches/release_2_3/base/src/package1.0/tests/portmpkg.test
branches/release_2_3/base/src/package1.0/tests/portpkg.test
branches/release_2_3/base/src/pextlib1.0/Makefile.in
branches/release_2_3/base/src/pkg_mkindex.sh.in
branches/release_2_3/base/src/port/Makefile.in
branches/release_2_3/base/src/port/port.tcl
branches/release_2_3/base/src/port/portindex.tcl
branches/release_2_3/base/src/port/portmirror.tcl
branches/release_2_3/base/src/port1.0/Makefile.in
branches/release_2_3/base/src/port1.0/port_autoconf.tcl.in
branches/release_2_3/base/src/port1.0/port_test_autoconf.tcl.in
branches/release_2_3/base/src/port1.0/porttrace.tcl
branches/release_2_3/base/src/port1.0/tests/portactivate.test
branches/release_2_3/base/src/port1.0/tests/portchecksum.test
branches/release_2_3/base/src/port1.0/tests/portclean.test
branches/release_2_3/base/src/port1.0/tests/portdeactivate.test
branches/release_2_3/base/src/port1.0/tests/portdepends.test
branches/release_2_3/base/src/port1.0/tests/portdistcheck.test
branches/release_2_3/base/src/port1.0/tests/portinstall.test
branches/release_2_3/base/src/port1.0/tests/portload.test
branches/release_2_3/base/src/port1.0/tests/portmain.test
branches/release_2_3/base/src/port1.0/tests/portpatch.test
branches/release_2_3/base/src/port1.0/tests/porttest.test
branches/release_2_3/base/src/port1.0/tests/portuninstall.test
branches/release_2_3/base/src/port1.0/tests/portutil.test
branches/release_2_3/base/src/registry2.0/Makefile.in
branches/release_2_3/base/src/tclobjc1.0/Makefile.in
Added Paths:
-----------
branches/release_2_3/base/src/dedup_portfiles.tcl.in
branches/release_2_3/base/src/images_to_archives.tcl.in
branches/release_2_3/base/src/upgrade_sources_conf_default.tcl.in
Removed Paths:
-------------
branches/release_2_3/base/src/dedup_portfiles.tcl
branches/release_2_3/base/src/images_to_archives.tcl
branches/release_2_3/base/src/macports1.0/macports_fastload.tcl.in
branches/release_2_3/base/src/upgrade_sources_conf_default.tcl
Property Changed:
----------------
branches/release_2_3/base/
branches/release_2_3/base/src/
branches/release_2_3/base/src/pextlib1.0/Makefile.in
Property changes on: branches/release_2_3/base
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/gsoc08-privileges/base:37343-46937
/branches/gsoc09-logging/base:51231-60371
/branches/gsoc11-rev-upgrade/base:78828-88375
/branches/gsoc11-statistics/base:79520,79666
/branches/gsoc13-tests:106692-111324
/branches/universal-sanity/base:51872-52323
/branches/variant-descs-14482/base:34469-34855,34900-37508,37511-37512,41040-41463,42575-42626,42640-42659
/trunk/base:118038-118039,118056,118161,118598-118599,118602-118603,118606-118607,118640
/users/perry/base-bugs_and_notes:45682-46060
/users/perry/base-select:44044-44692
+ /branches/gsoc08-privileges/base:37343-46937
/branches/gsoc09-logging/base:51231-60371
/branches/gsoc11-rev-upgrade/base:78828-88375
/branches/gsoc11-statistics/base:79520,79666
/branches/gsoc13-tests:106692-111324
/branches/universal-sanity/base:51872-52323
/branches/variant-descs-14482/base:34469-34855,34900-37508,37511-37512,41040-41463,42575-42626,42640-42659
/trunk/base:118038-118039,118056,118161,118559,118562-118569,118598-118599,118602-118603,118606-118607,118640,119169
/users/perry/base-bugs_and_notes:45682-46060
/users/perry/base-select:44044-44692
Modified: branches/release_2_3/base/Makefile.in
===================================================================
--- branches/release_2_3/base/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -96,8 +96,8 @@
# Add [default] tag to the central MacPorts repository, if it isn't already
$(TCLSH) $(srcdir)/src/upgrade_sources_conf_default.tcl "${prefix}"
# Convert image directories (and direct mode installs) to image archives
- $(TCLSH) $(srcdir)/src/images_to_archives.tcl "${macports_tcl_dir}"
- $(TCLSH) $(srcdir)/src/dedup_portfiles.tcl "${macports_tcl_dir}"
+ $(TCLSH) $(srcdir)/src/images_to_archives.tcl
+ $(TCLSH) $(srcdir)/src/dedup_portfiles.tcl
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: branches/release_2_3/base/Mk/macports.autoconf.mk.in
===================================================================
--- branches/release_2_3/base/Mk/macports.autoconf.mk.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/Mk/macports.autoconf.mk.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -49,7 +49,6 @@
INTREE_TCLSH = @INTREE_TCLSH@
TCLSH = @TCLSH@
TCL_PACKAGE_PATH = @TCL_PACKAGE_PATH@
-macports_tcl_dir = @macports_tcl_dir@
DSCL = @DSCL@
DSEDITGROUP = @DSEDITGROUP@
Modified: branches/release_2_3/base/configure
===================================================================
--- branches/release_2_3/base/configure 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/configure 2014-04-18 21:57:35 UTC (rev 119170)
@@ -650,7 +650,6 @@
VENDOR_DESTROOT
VENDOR_TCL_INSTALL
VENDOR_TCL_SUBDIR
-macports_tcl_dir
localstatedir_expanded
MPCONFIGDIR_EXPANDED
prefix_expanded
@@ -9494,9 +9493,6 @@
eval "localstatedir_expanded=$localstatedir"
-eval "macports_tcl_dir=${datadir}/macports/Tcl"
-eval "macports_tcl_dir=$macports_tcl_dir"
-
# Compute the libexec dir for the vendor packages
eval "macports_libexec_dir=${libexecdir}/macports"
eval "macports_libexec_dir=$macports_libexec_dir"
Modified: branches/release_2_3/base/configure.ac
===================================================================
--- branches/release_2_3/base/configure.ac 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/configure.ac 2014-04-18 21:57:35 UTC (rev 119170)
@@ -311,9 +311,6 @@
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"
@@ -413,7 +410,6 @@
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/package1.0/Makefile
src/package1.0/package_test_autoconf.tcl
@@ -430,6 +426,9 @@
vendor/Makefile
])
+AC_CONFIG_FILES([src/dedup_portfiles.tcl], [chmod +x src/dedup_portfiles.tcl])
+AC_CONFIG_FILES([src/images_to_archives.tcl], [chmod +x src/images_to_archives.tcl])
AC_CONFIG_FILES([src/pkg_mkindex.sh], [chmod +x src/pkg_mkindex.sh])
+AC_CONFIG_FILES([src/upgrade_sources_conf_default.tcl], [chmod +x src/upgrade_sources_conf_default.tcl])
AC_OUTPUT
Modified: branches/release_2_3/base/portmgr/dmg/postflight.in
===================================================================
--- branches/release_2_3/base/portmgr/dmg/postflight.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/portmgr/dmg/postflight.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -44,16 +44,17 @@
SBINPATH=${PREFIX}/sbin
CONFIGPATH=${PREFIX}/etc/macports
MANPAGES=${PREFIX}/share/man
-MACPORTS_TCL_DIR=${PREFIX}/share/macports/Tcl
-REG1DIR=${MACPORTS_TCL_DIR}/registry1.0
DSCL=/usr/bin/dscl
RUNUSR=macports
TCLSH=@TCLSH@
-TCL_PACKAGE_DIR=/Library/Tcl
+TCL_PACKAGE_PATH=@TCL_PACKAGE_PATH@
TIMESTAMP=$(date +"%Y-%m-%d_at_%H:%M:%S")
BACKUP_SUFFIX=macports-saved_${TIMESTAMP}
OUR_STRING="MacPorts Installer addition on ${TIMESTAMP}"
+OLD_MACPORTS_TCL_DIR=${PREFIX}/share/macports/Tcl
+OLD_TCL_PACKAGE_DIR=/Library/Tcl
+
# Create config files from defaults if not present
function setup_configs {
for f in archive_sites.conf macports.conf pubkeys.conf sources.conf variants.conf ; do
@@ -73,8 +74,8 @@
${TCLSH} ${SCRIPT_DIR}/upgrade_sources_conf_default.tcl ${PREFIX}
# Convert image directories (and direct mode installs) to image archives
echo "Updating port image format..."
- ${TCLSH} ${SCRIPT_DIR}/images_to_archives.tcl ${MACPORTS_TCL_DIR}
- ${TCLSH} ${SCRIPT_DIR}/dedup_portfiles.tcl ${MACPORTS_TCL_DIR}
+ ${TCLSH} ${SCRIPT_DIR}/images_to_archives.tcl
+ ${TCLSH} ${SCRIPT_DIR}/dedup_portfiles.tcl
echo "Synchronizing the MacPorts installation with the project's rsync server..."
if ! ${BINPATH}/port -v selfupdate; then
@@ -117,27 +118,24 @@
echo -e "Done.\n"
}
-# Delete the old registry1.0 directory
-function delete_reg1 {
- if [[ -d ${REG1DIR} ]]; then
- rm -vrf ${REG1DIR}
+# delete macports1.0 link from old tcl package dir
+function delete_old_tcl_package_link {
+ # delete old link if present
+ if [[ -e "${OLD_TCL_PACKAGE_DIR}/macports1.0" ]]; then
+ rm -vrf "${OLD_TCL_PACKAGE_DIR}/macports1.0"
+ fi
+
+ # delete old macports1.0 link from new tcl package dir if present
+ if [[ -L "${TCL_PACKAGE_PATH}/macports1.0" ]]; then
+ rm -vrf "${TCL_PACKAGE_PATH}/macports1.0"
fi
}
-# link macports1.0 into tcl package dir if possible
-function link_tcl_package {
- # delete old directory if present
- if [[ ! -L "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
- if [[ ! -e "${TCL_PACKAGE_DIR}" ]]; then
- /usr/bin/install -d "${TCL_PACKAGE_DIR}" || true
- fi
- if [[ -d "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
- rm -vrf "${TCL_PACKAGE_DIR}/macports1.0" || true
- fi
- if [[ ! -e "${TCL_PACKAGE_DIR}/macports1.0" && -d "${TCL_PACKAGE_DIR}" ]]; then
- ln -vs "${MACPORTS_TCL_DIR}/macports1.0" "${TCL_PACKAGE_DIR}/macports1.0" || true
- fi
- fi
+# delete the old tcl package location in share/macports/Tcl
+function delete_old_tcl_packages {
+ if [[ -d "${OLD_MACPORTS_TCL_DIR}" ]]; then
+ rm -vrf "${OLD_MACPORTS_TCL_DIR}"
+ fi
}
# create the user to use for privilege dropping
@@ -190,12 +188,11 @@
create_run_user
# Set up config files
setup_configs
-# link macports1.0 pkg
-link_tcl_package
# Remove old stuff
cleanup_man
-delete_reg1
+delete_old_tcl_package_link
+delete_old_tcl_packages
# Determine the user's shell, in order to choose an appropriate configuration file we'll be tweaking.
# Exit nicely if the shell is any other than bash or tcsh, as that's considered non-standard.
Modified: branches/release_2_3/base/portmgr/jobs/Makefile
===================================================================
--- branches/release_2_3/base/portmgr/jobs/Makefile 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/portmgr/jobs/Makefile 2014-04-18 21:57:35 UTC (rev 119170)
@@ -3,7 +3,7 @@
SCRIPTS= PortIndex2MySQL
edit = sed \
- -e 's, at macports_tcl_dir@,$(macports_tcl_dir),g'
+ -e 's, at TCLSH@,$(TCLSH),g'
include ../../Mk/macports.autoconf.mk
Modified: branches/release_2_3/base/portmgr/jobs/PortIndex2MySQL.tcl
===================================================================
--- branches/release_2_3/base/portmgr/jobs/PortIndex2MySQL.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/portmgr/jobs/PortIndex2MySQL.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,4 +1,4 @@
-#!/opt/local/bin/tclsh
+#!@TCLSH@
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
#
# PortIndex2MySQL.tcl
@@ -178,12 +178,6 @@
}
# Load macports1.0 so that we can use some of its procs and the portinfo array.
-if {[catch { source [file join "@macports_tcl_dir@" macports1.0 macports_fastload.tcl] } errstr]} {
- puts $runlog_fd "${::errorInfo}"
- puts $runlog_fd "Failed to locate the macports1.0 Tcl package file: $errstr"
- cleanup lockfile
- terminate 1
-}
if {[catch { package require macports } errstr]} {
puts $runlog_fd "${::errorInfo}"
puts $runlog_fd "Failed to load the macports1.0 Tcl package: $errstr"
Property changes on: branches/release_2_3/base/src
___________________________________________________________________
Modified: svn:ignore
- config.h
Makefile
pkg_mkindex.sh
+ config.h
Makefile
pkg_mkindex.sh
dedup_portfiles.tcl
images_to_archives.tcl
upgrade_sources_conf_default.tcl
Modified: branches/release_2_3/base/src/Makefile.in
===================================================================
--- branches/release_2_3/base/src/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -20,6 +20,7 @@
rm -f config.h
rm -f Makefile
rm -f pkg_mkindex.sh
+ rm -f dedup_portfiles.tcl images_to_archives.tcl
test::
Modified: branches/release_2_3/base/src/cflib1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/cflib1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/cflib1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,10 +1,11 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
OBJS= CFLib.o
SHLIB_NAME= CFLib${SHLIB_SUFFIX}
LIBS+= -framework CoreFoundation
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/cflib1.0
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/cflib1.0
-include ../../Mk/macports.autoconf.mk
include $(srcdir)/../../Mk/macports.tea.mk
Modified: branches/release_2_3/base/src/darwintracelib1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/darwintracelib1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/darwintracelib1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,15 +1,15 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
# 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
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/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=
Deleted: branches/release_2_3/base/src/dedup_portfiles.tcl
===================================================================
--- branches/release_2_3/base/src/dedup_portfiles.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/dedup_portfiles.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,47 +0,0 @@
-#!/usr/bin/env tclsh
-# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
-# $Id$
-
-# move portfiles from sqlite db to filesystem, while deduplicating
-# Takes one argument, which should be TCL_PACKAGE_DIR.
-
-source [file join [lindex $argv 0] macports1.0 macports_fastload.tcl]
-package require macports 1.0
-package require registry2 2.0
-package require Pextlib 1.0
-
-umask 022
-
-array set ui_options {ports_verbose yes}
-
-mportinit ui_options
-
-if {[registry::metadata get portfiles_update_needed] == 1} {
- set portfiles_dir [file join ${macports::registry.path} registry portfiles]
-
- registry::write {
- set installed_ports [registry::entry imaged]
- foreach portref $installed_ports {
- set portfile_contents [$portref portfile]
- if {$portfile_contents ne "" && $portfile_contents ne "0"} {
- set portfile_partial_dir [file join $portfiles_dir [$portref name]-[$portref version]_[$portref revision]]
- file mkdir $portfile_partial_dir
- set portfile_temp_path ${portfile_partial_dir}/Portfile
- set fd [open $portfile_temp_path w]
- puts $fd $portfile_contents
- close $fd
-
- set hash_size [sha256 file $portfile_temp_path]-[file size $portfile_temp_path]
- set portfile_dir [file join $portfile_partial_dir $hash_size]
- file mkdir $portfile_dir
- file rename -force $portfile_temp_path $portfile_dir
- file mtime ${portfile_dir}/Portfile [$portref date]
-
- $portref portfile $hash_size
- }
- }
- registry::metadata del portfiles_update_needed
- }
-}
-
-exit 0
Copied: branches/release_2_3/base/src/dedup_portfiles.tcl.in (from rev 118559, trunk/base/src/dedup_portfiles.tcl.in)
===================================================================
--- branches/release_2_3/base/src/dedup_portfiles.tcl.in (rev 0)
+++ branches/release_2_3/base/src/dedup_portfiles.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -0,0 +1,46 @@
+#!@TCLSH@
+# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
+# $Id$
+
+# move portfiles from sqlite db to filesystem, while deduplicating
+# Takes one argument, which should be TCL_PACKAGE_DIR.
+
+package require macports 1.0
+package require registry2 2.0
+package require Pextlib 1.0
+
+umask 022
+
+array set ui_options {ports_verbose yes}
+
+mportinit ui_options
+
+if {[registry::metadata get portfiles_update_needed] == 1} {
+ set portfiles_dir [file join ${macports::registry.path} registry portfiles]
+
+ registry::write {
+ set installed_ports [registry::entry imaged]
+ foreach portref $installed_ports {
+ set portfile_contents [$portref portfile]
+ if {$portfile_contents ne "" && $portfile_contents ne "0"} {
+ set portfile_partial_dir [file join $portfiles_dir [$portref name]-[$portref version]_[$portref revision]]
+ file mkdir $portfile_partial_dir
+ set portfile_temp_path ${portfile_partial_dir}/Portfile
+ set fd [open $portfile_temp_path w]
+ puts $fd $portfile_contents
+ close $fd
+
+ set hash_size [sha256 file $portfile_temp_path]-[file size $portfile_temp_path]
+ set portfile_dir [file join $portfile_partial_dir $hash_size]
+ file mkdir $portfile_dir
+ file rename -force $portfile_temp_path $portfile_dir
+ file mtime ${portfile_dir}/Portfile [$portref date]
+
+ $portref portfile $hash_size
+ }
+ }
+ registry::metadata del portfiles_update_needed
+ }
+}
+
+exit 0
Deleted: branches/release_2_3/base/src/images_to_archives.tcl
===================================================================
--- branches/release_2_3/base/src/images_to_archives.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/images_to_archives.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,160 +0,0 @@
-#!/usr/bin/env tclsh
-# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
-# $Id$
-
-# convert existing port image directories into compressed archive versions
-# Takes one argument, which should be TCL_PACKAGE_DIR.
-
-source [file join [lindex $argv 0] macports1.0 macports_fastload.tcl]
-package require macports 1.0
-package require registry 1.0
-package require registry2 2.0
-package require Pextlib 1.0
-
-umask 022
-
-array set ui_options {ports_verbose yes}
-
-mportinit ui_options
-
-# always converting to tbz2 should be fine as both these programs are
-# needed elsewhere and assumed to be available
-set tarcmd [macports::findBinary tar ${macports::autoconf::tar_path}]
-set bzip2cmd [macports::findBinary bzip2 ${macports::autoconf::bzip2_path}]
-
-if {[catch {set ilist [registry::installed]}]} {
- # no ports installed
- puts "No ports installed to convert."
- exit 0
-}
-
-puts "This could take a while..."
-
-# list of ports we successfully create an archive of, to be used to update
-# the registry only after we know all creation attempts were successful.
-set archived_list {}
-set installed_len [llength $ilist]
-set counter 0
-
-foreach installed $ilist {
- incr counter
- set iname [lindex $installed 0]
- set iversion [lindex $installed 1]
- set irevision [lindex $installed 2]
- set ivariants [lindex $installed 3]
- set iepoch [lindex $installed 5]
- set iref [registry::open_entry $iname $iversion $irevision $ivariants $iepoch]
- set installtype [registry::property_retrieve $iref installtype]
- if {$installtype eq "image"} {
- set location [registry::property_retrieve $iref location]
- if {$location == 0} {
- set location [registry::property_retrieve $iref imagedir]
- }
- } else {
- set location ""
- }
-
- if {$location eq "" || ![file isfile $location]} {
- # no image archive present, so make one
- set archs [registry::property_retrieve $iref archs]
- if {$archs eq "" || $archs == 0} {
- set archs ${macports::os_arch}
- }
- # look for any existing archive in the old location
- set oldarchiverootname "${iname}-${iversion}_${irevision}${ivariants}.[join $archs -]"
- set archivetype tbz2
- set oldarchivedir [file join ${macports::portdbpath} packages ${macports::os_platform}_${macports::os_major}]
- set olderarchivedir [file join ${macports::portdbpath} packages ${macports::os_platform}]
- if {[llength $archs] == 1} {
- set oldarchivedir [file join $oldarchivedir $archs $iname]
- set olderarchivedir [file join $olderarchivedir $archs]
- } else {
- set oldarchivedir [file join $oldarchivedir universal $iname]
- set olderarchivedir [file join $olderarchivedir universal]
- }
- set found 0
- foreach adir [list $oldarchivedir $olderarchivedir] {
- foreach type {tbz2 tbz tgz tar txz tlz xar zip cpgz cpio} {
- set oldarchivefullpath "[file join $adir $oldarchiverootname].${type}"
- if {[file isfile $oldarchivefullpath]} {
- set found 1
- set archivetype $type
- break
- }
- }
- if {$found} {break}
- }
-
- # compute new name and location of archive
- set archivename "${iname}-${iversion}_${irevision}${ivariants}.${macports::os_platform}_${macports::os_major}.[join $archs -].${archivetype}"
- ui_msg "Processing ${counter} of ${installed_len}: ${archivename}"
- if {$installtype eq "image"} {
- set targetdir [file dirname $location]
- } else {
- set targetdir [file join ${macports::registry.path} software ${iname}]
- }
- if {$location eq "" || ![file isdirectory $location]} {
- set contents [$iref imagefiles]
- }
- file mkdir $targetdir
- set newlocation [file join $targetdir $archivename]
-
- if {$found} {
- file rename $oldarchivefullpath $newlocation
- } elseif {$installtype eq "image" && [file isdirectory $location]} {
- # create archive from image dir
- system -W $location "$tarcmd -cjf $newlocation * > ${targetdir}/error.log 2>&1"
- file delete -force ${targetdir}/error.log
- } else {
- # direct mode (or missing image dir), create archive from installed files
- # we tell tar to read filenames from a file so as not to run afoul of command line length limits
- set fd [open ${targetdir}/tarlist w]
- foreach entry $contents {
- puts $fd $entry
- }
- close $fd
- system "$tarcmd -cjf $newlocation -T ${targetdir}/tarlist > ${targetdir}/error.log 2>&1"
- file delete -force ${targetdir}/tarlist ${targetdir}/error.log
- }
-
- lappend archived_list [list $installtype $iref $location $newlocation]
- }
-}
-
-set archived_len [llength $archived_list]
-set counter 0
-
-registry::write {
- foreach archived $archived_list {
- incr counter
- ui_msg "Updating registry: ${counter} of ${archived_len}"
- set installtype [lindex $archived 0]
- set iref [lindex $archived 1]
- set newlocation [lindex $archived 3]
-
- if {$installtype eq "direct"} {
- # change receipt to image
- $iref installtype image
- $iref state imaged
- $iref activate [$iref imagefiles]
- $iref state installed
- }
-
- # set the new location in the registry and delete the old dir
- $iref location $newlocation
- }
-}
-
-set counter 0
-foreach archived $archived_list {
- incr counter
- set location [lindex $archived 2]
- ui_msg "Deleting ${counter} of ${archived_len}: ${location}"
- if {$location ne "" && [file isdirectory $location]} {
- if {[catch {file delete -force $location} result]} {
- ui_warn "Failed to delete ${location}: $result"
- }
- }
-}
-
-exit 0
Copied: branches/release_2_3/base/src/images_to_archives.tcl.in (from rev 118559, trunk/base/src/images_to_archives.tcl.in)
===================================================================
--- branches/release_2_3/base/src/images_to_archives.tcl.in (rev 0)
+++ branches/release_2_3/base/src/images_to_archives.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -0,0 +1,159 @@
+#!@TCLSH@
+# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
+# $Id$
+
+# convert existing port image directories into compressed archive versions
+# Takes one argument, which should be TCL_PACKAGE_DIR.
+
+package require macports 1.0
+package require registry 1.0
+package require registry2 2.0
+package require Pextlib 1.0
+
+umask 022
+
+array set ui_options {ports_verbose yes}
+
+mportinit ui_options
+
+# always converting to tbz2 should be fine as both these programs are
+# needed elsewhere and assumed to be available
+set tarcmd [macports::findBinary tar ${macports::autoconf::tar_path}]
+set bzip2cmd [macports::findBinary bzip2 ${macports::autoconf::bzip2_path}]
+
+if {[catch {set ilist [registry::installed]}]} {
+ # no ports installed
+ puts "No ports installed to convert."
+ exit 0
+}
+
+puts "This could take a while..."
+
+# list of ports we successfully create an archive of, to be used to update
+# the registry only after we know all creation attempts were successful.
+set archived_list {}
+set installed_len [llength $ilist]
+set counter 0
+
+foreach installed $ilist {
+ incr counter
+ set iname [lindex $installed 0]
+ set iversion [lindex $installed 1]
+ set irevision [lindex $installed 2]
+ set ivariants [lindex $installed 3]
+ set iepoch [lindex $installed 5]
+ set iref [registry::open_entry $iname $iversion $irevision $ivariants $iepoch]
+ set installtype [registry::property_retrieve $iref installtype]
+ if {$installtype eq "image"} {
+ set location [registry::property_retrieve $iref location]
+ if {$location == 0} {
+ set location [registry::property_retrieve $iref imagedir]
+ }
+ } else {
+ set location ""
+ }
+
+ if {$location eq "" || ![file isfile $location]} {
+ # no image archive present, so make one
+ set archs [registry::property_retrieve $iref archs]
+ if {$archs eq "" || $archs == 0} {
+ set archs ${macports::os_arch}
+ }
+ # look for any existing archive in the old location
+ set oldarchiverootname "${iname}-${iversion}_${irevision}${ivariants}.[join $archs -]"
+ set archivetype tbz2
+ set oldarchivedir [file join ${macports::portdbpath} packages ${macports::os_platform}_${macports::os_major}]
+ set olderarchivedir [file join ${macports::portdbpath} packages ${macports::os_platform}]
+ if {[llength $archs] == 1} {
+ set oldarchivedir [file join $oldarchivedir $archs $iname]
+ set olderarchivedir [file join $olderarchivedir $archs]
+ } else {
+ set oldarchivedir [file join $oldarchivedir universal $iname]
+ set olderarchivedir [file join $olderarchivedir universal]
+ }
+ set found 0
+ foreach adir [list $oldarchivedir $olderarchivedir] {
+ foreach type {tbz2 tbz tgz tar txz tlz xar zip cpgz cpio} {
+ set oldarchivefullpath "[file join $adir $oldarchiverootname].${type}"
+ if {[file isfile $oldarchivefullpath]} {
+ set found 1
+ set archivetype $type
+ break
+ }
+ }
+ if {$found} {break}
+ }
+
+ # compute new name and location of archive
+ set archivename "${iname}-${iversion}_${irevision}${ivariants}.${macports::os_platform}_${macports::os_major}.[join $archs -].${archivetype}"
+ ui_msg "Processing ${counter} of ${installed_len}: ${archivename}"
+ if {$installtype eq "image"} {
+ set targetdir [file dirname $location]
+ } else {
+ set targetdir [file join ${macports::registry.path} software ${iname}]
+ }
+ if {$location eq "" || ![file isdirectory $location]} {
+ set contents [$iref imagefiles]
+ }
+ file mkdir $targetdir
+ set newlocation [file join $targetdir $archivename]
+
+ if {$found} {
+ file rename $oldarchivefullpath $newlocation
+ } elseif {$installtype eq "image" && [file isdirectory $location]} {
+ # create archive from image dir
+ system -W $location "$tarcmd -cjf $newlocation * > ${targetdir}/error.log 2>&1"
+ file delete -force ${targetdir}/error.log
+ } else {
+ # direct mode (or missing image dir), create archive from installed files
+ # we tell tar to read filenames from a file so as not to run afoul of command line length limits
+ set fd [open ${targetdir}/tarlist w]
+ foreach entry $contents {
+ puts $fd $entry
+ }
+ close $fd
+ system "$tarcmd -cjf $newlocation -T ${targetdir}/tarlist > ${targetdir}/error.log 2>&1"
+ file delete -force ${targetdir}/tarlist ${targetdir}/error.log
+ }
+
+ lappend archived_list [list $installtype $iref $location $newlocation]
+ }
+}
+
+set archived_len [llength $archived_list]
+set counter 0
+
+registry::write {
+ foreach archived $archived_list {
+ incr counter
+ ui_msg "Updating registry: ${counter} of ${archived_len}"
+ set installtype [lindex $archived 0]
+ set iref [lindex $archived 1]
+ set newlocation [lindex $archived 3]
+
+ if {$installtype eq "direct"} {
+ # change receipt to image
+ $iref installtype image
+ $iref state imaged
+ $iref activate [$iref imagefiles]
+ $iref state installed
+ }
+
+ # set the new location in the registry and delete the old dir
+ $iref location $newlocation
+ }
+}
+
+set counter 0
+foreach archived $archived_list {
+ incr counter
+ set location [lindex $archived 2]
+ ui_msg "Deleting ${counter} of ${archived_len}: ${location}"
+ if {$location ne "" && [file isdirectory $location]} {
+ if {[catch {file delete -force $location} result]} {
+ ui_warn "Failed to delete ${location}: $result"
+ }
+ }
+}
+
+exit 0
Modified: branches/release_2_3/base/src/machista1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/machista1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/machista1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,9 +1,11 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
OBJS= libmachista.o hashmap.o machista_wrap.o
SHLIB_NAME= machista${SHLIB_SUFFIX}
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/machista1.0
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/machista1.0
SWIG = @SWIG@
SWIG_FLAGS = -tcl8 -pkgversion 1.0 -namespace
@@ -15,7 +17,6 @@
TESTS = ./tests/libmachista-test
-include ../../Mk/macports.autoconf.mk
include $(srcdir)/../../Mk/macports.tea.mk
CFLAGS+= -fPIC
Modified: branches/release_2_3/base/src/macports1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/macports1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/macports1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,17 +1,16 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
SRCS= macports.tcl macports_dlist.tcl macports_util.tcl \
- macports_autoconf.tcl macports_fastload.tcl
+ macports_autoconf.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
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/macports1.0
+OLDINSTALLDIR= ${datadir}/macports/Tcl
-include ../../Mk/macports.autoconf.mk
-include $(srcdir)/../../Mk/macports.tea.mk
-
ifeq ($(OBJC_RUNTIME), APPLE_RUNTIME)
LIBS+= -framework CoreFoundation -framework SystemConfiguration
endif
@@ -22,9 +21,16 @@
$(TCLSH) $(srcdir)/tests/test.tcl -nocolor
distclean:: clean
- rm -f macports_autoconf.tcl macports_fastload.tcl macports_test_autoconf.tcl ${SHLIB_NAME}
+ rm -f macports_autoconf.tcl macports_test_autoconf.tcl ${SHLIB_NAME}
install:: all
+ @# Clean up old instances of the MacPorts Tcl packages
+ if test -z "${DESTDIR}"; then rm -rf "${OLDINSTALLDIR}"; fi
+
+ @# Remove the previously installed link if it still exists. Without this,
+ @# creating the directory will fail.
+ if test -L "${INSTALLDIR}"; then rm -rf "${INSTALLDIR}"; fi
+
$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
$(SILENT) set -x; for file in ${SRCS}; do \
@@ -33,17 +39,5 @@
$(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
+
+include $(srcdir)/../../Mk/macports.tea.mk
Modified: branches/release_2_3/base/src/macports1.0/macports.tcl
===================================================================
--- branches/release_2_3/base/src/macports1.0/macports.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/macports1.0/macports.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -40,7 +40,7 @@
namespace eval macports {
namespace export bootstrap_options user_options portinterp_options open_mports ui_priorities port_phases
variable bootstrap_options "\
- portdbpath libpath binpath auto_path extra_env sources_conf prefix portdbformat \
+ portdbpath binpath auto_path extra_env sources_conf prefix portdbformat \
portarchivetype portautoclean \
porttrace portverbose keeplogs destroot_umask variants_conf rsync_server rsync_options \
rsync_dir startupitem_type startupitem_install place_worksymlink xcodeversion xcodebuildcmd \
@@ -541,6 +541,10 @@
macports::ui_init $priority
}
+ package require Pextlib 1.0
+ package require registry 1.0
+ package require registry2 2.0
+ package require machista 1.0
global auto_path env tcl_platform \
macports::autoconf::macports_conf_path \
@@ -554,7 +558,6 @@
macports::sources \
macports::sources_default \
macports::destroot_umask \
- macports::libpath \
macports::prefix \
macports::macportsuser \
macports::prefix_frozen \
@@ -871,10 +874,6 @@
return -code error "Data files directory '$portsharepath' must exist"
}
- if {![info exists libpath]} {
- set libpath ${prefix}/share/macports/Tcl
- }
-
if {![info exists binpath]} {
set env(PATH) ${prefix}/bin:${prefix}/sbin:/bin:/sbin:/usr/bin:/usr/sbin
} else {
@@ -1017,21 +1016,6 @@
set keepenvkeys [concat $keepenvkeys $extra_env]
}
- if {[file isdirectory $libpath]} {
- lappend auto_path $libpath
- set macports::auto_path $auto_path
-
- # XXX: not sure if this the best place, but it needs to happen
- # early, and after auto_path has been set. Or maybe Pextlib
- # should ship with macports1.0 API?
- package require Pextlib 1.0
- package require registry 1.0
- package require registry2 2.0
- package require machista 1.0
- } else {
- return -code error "Library directory '$libpath' must exist"
- }
-
# set the hidden flag on $portdbpath to avoid spotlight indexing, which
# might slow builds down considerably. You can avoid this by touching
# $portdbpath/.nohide.
@@ -3375,10 +3359,10 @@
# selfupdate procedure
proc macports::selfupdate {{optionslist {}} {updatestatusvar {}}} {
- global macports::prefix macports::portdbpath macports::libpath \
- macports::rsync_server macports::rsync_dir macports::rsync_options \
- macports::autoconf::macports_version macports::autoconf::rsync_path \
- tcl_platform macports::autoconf::openssl_path macports::autoconf::tar_path
+ global macports::prefix macports::portdbpath macports::rsync_server macports::rsync_dir \
+ macports::rsync_options macports::autoconf::macports_version \
+ macports::autoconf::rsync_path tcl_platform macports::autoconf::openssl_path \
+ macports::autoconf::tar_path
array set options $optionslist
# variable that indicates whether we actually updated base
@@ -3503,17 +3487,7 @@
}
ui_debug "Permissions OK"
- # where to install a link to our macports1.0 tcl package
- set mp_tclpackage_path [file join $portdbpath .tclpackage]
- if {[file exists $mp_tclpackage_path]} {
- set fd [open $mp_tclpackage_path r]
- gets $fd tclpackage
- close $fd
- } else {
- set tclpackage $libpath
- }
-
- set configure_args "--prefix=$prefix --with-tclpackage=$tclpackage --with-install-user=$owner --with-install-group=$group --with-directory-mode=$perms"
+ set configure_args "--prefix=$prefix --with-install-user=$owner --with-install-group=$group --with-directory-mode=$perms"
# too many users have an incompatible readline in /usr/local, see ticket #10651
if {$tcl_platform(os) ne {Darwin} || $prefix eq {/usr/local}
|| ([glob -nocomplain /usr/local/lib/lib{readline,history}*] eq {} && [glob -nocomplain /usr/local/include/readline/*.h] eq {})} {
@@ -3533,7 +3507,7 @@
}
# do the actual configure, build and installation of new base
- ui_msg "Installing new MacPorts release in $prefix as ${owner}:${group}; permissions ${perms}; Tcl-Package in $tclpackage\n"
+ ui_msg "Installing new MacPorts release in $prefix as ${owner}:${group}; permissions ${perms}\n"
if {[catch {system "cd $mp_source_path && ${cc_arg}./configure $configure_args && make SELFUPDATING=1 && make install SELFUPDATING=1"} result]} {
return -code error "Error installing new MacPorts base: $result"
}
Deleted: branches/release_2_3/base/src/macports1.0/macports_fastload.tcl.in
===================================================================
--- branches/release_2_3/base/src/macports1.0/macports_fastload.tcl.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/macports1.0/macports_fastload.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,83 +0,0 @@
-# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
-# macports_fastload.tcl.in
-# $Id$
-#
-# Copyright (c) 2005-2007, 2009-2010 The MacPorts Project
-# Copyright (c) 2004-2005 Paul Guyot, The MacPorts Project.
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-# 3. Neither the name of The MacPorts Project nor the names of its contributors
-# may be used to endorse or promote products derived from this software
-# without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-# POSSIBILITY OF SUCH DAMAGE.
-#
-
-# This script is here to fast load all the MacPorts related packages.
-# This avoids the very expensive globbing of Tcl' package mechanism.
-# Please note that this is not required and base/ should work even if some
-# packages are moved as long as their new location is in Tcl's package paths.
-# However, this file also defines a workaround to avoid conflicts between a /
-# installation of MacPorts and a user installation of MacPorts (on the same box).
-# (this workaround isn't required on 10.4.2).
-#
-# The package command that's replaced in this code works somewhat differently
-# than the original version. In particular, users with multiple copies of a
-# package such as portuninstall (due to obsolete files being left from previous
-# installations) may experience problems due to different package loading
-# behavior.
-#
-if { [regexp {\d+\.\d+\.\d+} [info patchlevel]] &&
- ([package vcompare [info patchlevel] 8.4.7] < 0) } {
- global allpackages
- if {![info exists allpackages]} {
- # Only patch once.
- array set allpackages {}
- rename package package_native
- proc package {args} {
- global allpackages
- if {([lindex $args 0] == "ifneeded") && ([llength $args] == 4)} {
- set package_name [lindex $args 1]
- set package_version [lindex $args 2]
- set package_key ${package_name}::${package_version}
- if {![info exists allpackages($package_key)]} {
- set allpackages($package_key) 1
- set result [eval package_native $args]
- } else {
- set result ""
- }
- } else {
- set result [eval package_native $args]
- }
- return $result
- }
- }
-}
-
-set sharetcldir [file normalize [file join [file dirname [info script]] ..]]
-if {[file exists $sharetcldir]} {
- foreach dir [glob -directory $sharetcldir *] {
- set pkgindex [file join $dir pkgIndex.tcl]
- if [file exists $pkgindex] {
- source $pkgindex
- }
- }
-}
Modified: branches/release_2_3/base/src/macports1.0/macports_test_autoconf.tcl.in
===================================================================
--- branches/release_2_3/base/src/macports1.0/macports_test_autoconf.tcl.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/macports1.0/macports_test_autoconf.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -32,6 +32,5 @@
#
namespace eval macports::autoconf {
- variable macports_tcl_dir "@macports_tcl_dir@"
variable prefix "@prefix@"
}
Modified: branches/release_2_3/base/src/macports1.0/tests/macports.test
===================================================================
--- branches/release_2_3/base/src/macports1.0/tests/macports.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/macports1.0/tests/macports.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -7,7 +7,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../macports_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
# clean leftovers from interrupted tests
Modified: branches/release_2_3/base/src/macports1.0/tests/macports_dlist.test
===================================================================
--- branches/release_2_3/base/src/macports1.0/tests/macports_dlist.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/macports1.0/tests/macports_dlist.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -4,7 +4,6 @@
namespace import tcltest::*
source ../macports_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
# Debug options
Modified: branches/release_2_3/base/src/macports1.0/tests/macports_util.test
===================================================================
--- branches/release_2_3/base/src/macports1.0/tests/macports_util.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/macports1.0/tests/macports_util.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -4,7 +4,6 @@
namespace import tcltest::*
source ../macports_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
Modified: branches/release_2_3/base/src/package1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/package1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,14 +1,14 @@
srcdir = @srcdir@
VPATH = @srcdir@
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/package1.0
+include ../../Mk/macports.autoconf.mk
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/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)
Modified: branches/release_2_3/base/src/package1.0/package_test_autoconf.tcl.in
===================================================================
--- branches/release_2_3/base/src/package1.0/package_test_autoconf.tcl.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/package_test_autoconf.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -32,7 +32,6 @@
#
namespace eval macports::autoconf {
- variable macports_tcl_dir "@macports_tcl_dir@"
variable prefix "@prefix@"
}
Modified: branches/release_2_3/base/src/package1.0/tests/portarchivefetch.test
===================================================================
--- branches/release_2_3/base/src/package1.0/tests/portarchivefetch.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/tests/portarchivefetch.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../package_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/package1.0/tests/portdmg.test
===================================================================
--- branches/release_2_3/base/src/package1.0/tests/portdmg.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/tests/portdmg.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../package_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/package1.0/tests/portdpkg.test
===================================================================
--- branches/release_2_3/base/src/package1.0/tests/portdpkg.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/tests/portdpkg.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../package_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/package1.0/tests/portmdmg.test
===================================================================
--- branches/release_2_3/base/src/package1.0/tests/portmdmg.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/tests/portmdmg.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../package_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/package1.0/tests/portmpkg.test
===================================================================
--- branches/release_2_3/base/src/package1.0/tests/portmpkg.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/tests/portmpkg.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../package_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/package1.0/tests/portpkg.test
===================================================================
--- branches/release_2_3/base/src/package1.0/tests/portpkg.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/package1.0/tests/portpkg.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../package_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/pextlib1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/pextlib1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/pextlib1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,6 +1,8 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
OBJS= \
Pextlib.o strsed.o fgetln.o md5cmd.o setmode.o xinstall.o \
fs-traverse.o strcasecmp.o vercomp.o filemap.o base32cmd.o \
@@ -12,16 +14,15 @@
endif
SHLIB_NAME= Pextlib${SHLIB_SUFFIX}
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/pextlib1.0
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/pextlib1.0
-include ../../Mk/macports.autoconf.mk
include $(srcdir)/../../Mk/macports.tea.mk
CFLAGS+= ${CURL_CFLAGS} ${MD5_CFLAGS} ${READLINE_CFLAGS}
LIBS+= ${CURL_LIBS} ${MD5_LIBS} ${READLINE_LIBS}
ifeq ($(shell uname), Darwin)
LIBS+= ../registry2.0/registry${SHLIB_SUFFIX}
-SHLIB_LDFLAGS+= -install_name ${datadir}/macports/Tcl/pextlib1.0/${SHLIB_NAME}
+SHLIB_LDFLAGS+= -install_name ${TCL_PACKAGE_PATH}/pextlib1.0/${SHLIB_NAME}
${SHLIB_NAME}: ../registry2.0/registry${SHLIB_SUFFIX}
endif
Property changes on: branches/release_2_3/base/src/pextlib1.0/Makefile.in
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/gsoc08-privileges/base/src/pextlib1.0/Makefile:37343-46937
/branches/gsoc09-logging/base/src/pextlib1.0/Makefile:51231-60371
/branches/gsoc11-rev-upgrade/base/src/pextlib1.0/Makefile:78828-88375
/branches/gsoc13-tests/src/pextlib1.0/Makefile.in:106692-111324
/branches/universal-sanity/base/src/pextlib1.0/Makefile:51872-52323
/branches/variant-descs-14482/base/src/pextlib1.0/Makefile:34469-34855,34900-37508,37511-37512,41040-41463,42575-42626,42640-42659
/users/perry/base-bugs_and_notes/src/pextlib1.0/Makefile:45682-46060
/users/perry/base-select/src/pextlib1.0/Makefile:44044-44692
+ /branches/gsoc08-privileges/base/src/pextlib1.0/Makefile:37343-46937
/branches/gsoc09-logging/base/src/pextlib1.0/Makefile:51231-60371
/branches/gsoc11-rev-upgrade/base/src/pextlib1.0/Makefile:78828-88375
/branches/gsoc13-tests/src/pextlib1.0/Makefile.in:106692-111324
/branches/universal-sanity/base/src/pextlib1.0/Makefile:51872-52323
/branches/variant-descs-14482/base/src/pextlib1.0/Makefile:34469-34855,34900-37508,37511-37512,41040-41463,42575-42626,42640-42659
/trunk/base/src/pextlib1.0/Makefile.in:118562-118569,119169
/users/perry/base-bugs_and_notes/src/pextlib1.0/Makefile:45682-46060
/users/perry/base-select/src/pextlib1.0/Makefile:44044-44692
Modified: branches/release_2_3/base/src/pkg_mkindex.sh.in
===================================================================
--- branches/release_2_3/base/src/pkg_mkindex.sh.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/pkg_mkindex.sh.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -30,6 +30,7 @@
TCLSH=@INTREE_TCLSH@
GREP=@GREP@
+LIB_PATH=`dirname $TCLSH`
if [ $# = 0 ]; then
echo "Usage: $0 <directory list>"
@@ -37,7 +38,8 @@
fi
for dir in $@; do
- echo "pkg_mkIndex -verbose -- $dir *.tcl *.dylib *.so" | env DYLD_LIBRARY_PATH=`dirname $TCLSH` $TCLSH 2>&1 \
+ echo "pkg_mkIndex -verbose -- $dir *.tcl *.dylib *.so" \
+ | env DYLD_LIBRARY_PATH=$LIB_PATH LD_LIBRARY_PATH=$LIB_PATH $TCLSH 2>&1 \
| $GREP "^warning: " && exit 1
done
Modified: branches/release_2_3/base/src/port/Makefile.in
===================================================================
--- branches/release_2_3/base/src/port/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,16 +1,14 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
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'
+edit = sed -e 's, at TCLSH\@,$(TCLSH),g'
-include ../../Mk/macports.autoconf.mk
-
.PHONY: mkdirs
all: ${SCRIPTS}
@@ -41,3 +39,4 @@
$(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
+ cd ${INSTALLDIR}/bin && $(LN_S) -f ${TCLSH} port-tclsh
Modified: branches/release_2_3/base/src/port/port.tcl
===================================================================
--- branches/release_2_3/base/src/port/port.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port/port.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -43,7 +43,6 @@
set portclient::progress::hasTermAnsiSend yes
}
-source [file join "@macports_tcl_dir@" macports1.0 macports_fastload.tcl]
package require macports
package require Pextlib 1.0
Modified: branches/release_2_3/base/src/port/portindex.tcl
===================================================================
--- branches/release_2_3/base/src/port/portindex.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port/portindex.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -4,7 +4,6 @@
# if requested
# $Id$
-source [file join "@macports_tcl_dir@" macports1.0 macports_fastload.tcl]
package require macports
package require Pextlib
Modified: branches/release_2_3/base/src/port/portmirror.tcl
===================================================================
--- branches/release_2_3/base/src/port/portmirror.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port/portmirror.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -8,7 +8,6 @@
# Updates the distfiles to current distfiles by deleting old stuff.
# Uses the database.
-source [file join "@macports_tcl_dir@" macports1.0 macports_fastload.tcl]
package require macports
package require Pextlib
Modified: branches/release_2_3/base/src/port1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/port1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,8 +1,10 @@
srcdir = @srcdir@
VPATH = @srcdir@
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/port1.0
+include ../../Mk/macports.autoconf.mk
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/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 \
@@ -13,7 +15,6 @@
portdistfiles.tcl fetch_common.tcl portsandbox.tcl
include $(srcdir)/../../Mk/macports.subdir.mk
-include ../../Mk/macports.autoconf.mk
.PHONY: test
Modified: branches/release_2_3/base/src/port1.0/port_autoconf.tcl.in
===================================================================
--- branches/release_2_3/base/src/port1.0/port_autoconf.tcl.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/port_autoconf.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -80,4 +80,5 @@
variable install_user "@DSTUSR@"
variable install_group "@DSTGRP@"
variable prefix "@prefix_expanded@"
+ variable tcl_package_path "@TCL_PACKAGE_PATH@"
}
Modified: branches/release_2_3/base/src/port1.0/port_test_autoconf.tcl.in
===================================================================
--- branches/release_2_3/base/src/port1.0/port_test_autoconf.tcl.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/port_test_autoconf.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -32,6 +32,5 @@
#
namespace eval macports::autoconf {
- variable macports_tcl_dir "@macports_tcl_dir@"
variable prefix "@prefix@"
}
Modified: branches/release_2_3/base/src/port1.0/porttrace.tcl
===================================================================
--- branches/release_2_3/base/src/port1.0/porttrace.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/porttrace.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -57,7 +57,7 @@
# Launch darwintrace.dylib.
- set tracelib_path [file join ${portutil::autoconf::prefix} share macports Tcl darwintrace1.0 darwintrace.dylib]
+ set tracelib_path [file join ${portutil::autoconf::tcl_package_path} darwintrace1.0 darwintrace.dylib]
if {[info exists env(DYLD_INSERT_LIBRARIES)] && [string length "$env(DYLD_INSERT_LIBRARIES)"] > 0} {
set env(DYLD_INSERT_LIBRARIES) "${env(DYLD_INSERT_LIBRARIES)}:${tracelib_path}"
Modified: branches/release_2_3/base/src/port1.0/tests/portactivate.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portactivate.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portactivate.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portchecksum.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portchecksum.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portchecksum.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portclean.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portclean.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portclean.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portdeactivate.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portdeactivate.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portdeactivate.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portdepends.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portdepends.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portdepends.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portdistcheck.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portdistcheck.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portdistcheck.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portinstall.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portinstall.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portinstall.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portload.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portload.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portload.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portmain.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portmain.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portmain.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portpatch.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portpatch.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portpatch.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/porttest.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/porttest.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/porttest.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portuninstall.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portuninstall.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portuninstall.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -6,7 +6,6 @@
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/port1.0/tests/portutil.test
===================================================================
--- branches/release_2_3/base/src/port1.0/tests/portutil.test 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/port1.0/tests/portutil.test 2014-04-18 21:57:35 UTC (rev 119170)
@@ -3,12 +3,10 @@
package require tcltest 2
namespace import tcltest::*
-source ../../macports1.0/macports_fastload.tcl
set pwd [file dirname [file normalize $argv0]]
source ../port_test_autoconf.tcl
-source $macports::autoconf::macports_tcl_dir/macports1.0/macports_fastload.tcl
package require macports 1.0
array set ui_options {}
Modified: branches/release_2_3/base/src/registry2.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/registry2.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/registry2.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -3,6 +3,8 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
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 \
@@ -12,9 +14,8 @@
#graph.o graphobj.o
SHLIB_NAME= registry${SHLIB_SUFFIX}
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/registry2.0
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/registry2.0
-include ../../Mk/macports.autoconf.mk
include $(srcdir)/../../Mk/macports.tea.mk
pkgIndex.tcl: $(SRCS) $(SRCS_AUTOCONF)
@@ -37,7 +38,6 @@
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 \
Modified: branches/release_2_3/base/src/tclobjc1.0/Makefile.in
===================================================================
--- branches/release_2_3/base/src/tclobjc1.0/Makefile.in 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/tclobjc1.0/Makefile.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,11 +1,12 @@
srcdir = @srcdir@
VPATH = @srcdir@
+include ../../Mk/macports.autoconf.mk
+
OBJS= tclobjc.o tclobjc_types.o MPMethodSignatureExtensions.o objc_encoding.o
SHLIB_NAME= tclobjc${SHLIB_SUFFIX}
-INSTALLDIR= ${DESTDIR}${datadir}/macports/Tcl/tclobjc1.0
+INSTALLDIR= ${DESTDIR}${TCL_PACKAGE_PATH}/tclobjc1.0
-include ../../Mk/macports.autoconf.mk
include $(srcdir)/../../Mk/macports.tea.mk
LDFLAGS+= ${OBJC_FOUNDATION_LDFLAGS}
Deleted: branches/release_2_3/base/src/upgrade_sources_conf_default.tcl
===================================================================
--- branches/release_2_3/base/src/upgrade_sources_conf_default.tcl 2014-04-18 21:38:45 UTC (rev 119169)
+++ branches/release_2_3/base/src/upgrade_sources_conf_default.tcl 2014-04-18 21:57:35 UTC (rev 119170)
@@ -1,121 +0,0 @@
-#!/usr/bin/env tclsh
-#
-# $Id$
-#
-# Upgrade sources.conf for a given prefix (passed as the first and only
-# argument).
-#
-# For an rsync: repository, if it is the standard MacPorts one and not
-# already tagged, then make it default, if another wasn't already default.
-# For a file:// respository, if it is an svn checkout from the MacPorts
-# server, then make it default if another hasn't already been tagged.
-#
-
-if {[llength $::argv] == 0} {
- puts "Usage: ${::argv0} <prefix>"
- exit 1
-}
-
-set prefix [lindex $::argv 0]
-set sourcesConf ${prefix}/etc/macports/sources.conf
-if {[catch {set sourcesConfChannel [open $sourcesConf r]}]} {
- exit 0
-}
-
-if {[file executable /usr/bin/mktemp]} {
- set mktemp /usr/bin/mktemp
-} elseif {[file executable /bin/mktemp]} {
- set mktemp /bin/mktemp
-} else {
- set mktemp mktemp
-}
-
-set mktempChannel [open "|$mktemp -t macports_sources_upgrade.XXXXXXXXXX" r]
-set tempfile [read -nonewline $mktempChannel]
-close $mktempChannel
-
-set tempfileChannel [open $tempfile w]
-set defaultSeen false
-set defaultWritten false
-
-while {[gets $sourcesConfChannel line] >= 0} {
- set addDefault false
- if {!$defaultSeen && ![regexp {^\s*#|^$} $line]} {
- if {[regexp {^([\w-]+://\S+)(?:\s+\[(\w+(?:,\w+)*)\])?$} $line -> url flags]} {
- set flags [split $flags ,]
- if {[lsearch $flags default] >= 0} {
- set defaultSeen true
- } elseif {[regexp {rsync://rsync\.(macports|darwinports)\.org/(release|dpupdate)/d?ports} $url]} {
- set addDefault true
- } elseif {[regexp {file://(/.+)} $url -> filepath]} {
- if {[file exists [file join ${filepath} .svn]]} {
- if {![info exists svnCmd]} {
- set svnCmd ""
- foreach path [concat [list ${prefix}/bin] [split $env(PATH) :]] {
- if {[file executable ${path}/svn]} {
- set svnCmd ${path}/svn
- break
- }
- }
- }
- if {$svnCmd eq ""} {
- puts "WARNING: Unable to check svn URL for '$filepath' because no svn command could be found; please manually verify $sourcesConf!"
- continue
- }
- if {![catch {set svnChannel [open "|$svnCmd info ${filepath}" r]} err]} {
- set svnURL {}
- while {[gets $svnChannel svnLine] >= 0} {
- regexp {^URL: (.*)} $svnLine -> svnURL
- }
- if {[catch {close $svnChannel} err]} {
- puts $err
- puts "WARNING: Unable to check svn URL for '$filepath'; please manually verify $sourcesConf!"
- }
- if {[regexp {^https?://svn\.(macports|macosforge)\.org/repository/macports/trunk/dports} $svnURL]} {
- set addDefault true
- }
- } else {
- puts $err
- puts "WARNING: Unable to check svn URL for '$filepath'; please manually verify $sourcesConf!"
- }
- }
- }
- if {$addDefault} {
- lappend flags default
- set line "$url \[[join $flags ,]\]"
- set defaultSeen true
- set defaultWritten true
- }
- }
- }
- puts $tempfileChannel $line
-}
-close $tempfileChannel
-close $sourcesConfChannel
-
-if {$defaultWritten} {
- set attributes [file attributes ${sourcesConf}]
- if {[catch {file rename ${sourcesConf} "${sourcesConf}.mpsaved"}]} {
- file rename -force ${sourcesConf} "${sourcesConf}.mpsaved_[clock seconds]"
- }
- file rename ${tempfile} ${sourcesConf}
- eval file attributes ${sourcesConf} $attributes
-} else {
- file delete ${tempfile}
- if {!$defaultSeen} {
- puts "[string repeat - 72]
-Warning, your source config file at:
-
- $sourcesConf
-
-needs to have a \[default\] tag added to the primary MacPorts repository,
-however the proper entry could not be determined. Please add the tag
-manually by either appending \[default\] to the end of the correct line,
-or if there are already tags, adding it to the list, e.g.
-\[nosync,default\].
-[string repeat - 72]"
- }
-}
-
-exit 0
-
Copied: branches/release_2_3/base/src/upgrade_sources_conf_default.tcl.in (from rev 118559, trunk/base/src/upgrade_sources_conf_default.tcl.in)
===================================================================
--- branches/release_2_3/base/src/upgrade_sources_conf_default.tcl.in (rev 0)
+++ branches/release_2_3/base/src/upgrade_sources_conf_default.tcl.in 2014-04-18 21:57:35 UTC (rev 119170)
@@ -0,0 +1,121 @@
+#!@TCLSH@
+#
+# $Id$
+#
+# Upgrade sources.conf for a given prefix (passed as the first and only
+# argument).
+#
+# For an rsync: repository, if it is the standard MacPorts one and not
+# already tagged, then make it default, if another wasn't already default.
+# For a file:// respository, if it is an svn checkout from the MacPorts
+# server, then make it default if another hasn't already been tagged.
+#
+
+if {[llength $::argv] == 0} {
+ puts "Usage: ${::argv0} <prefix>"
+ exit 1
+}
+
+set prefix [lindex $::argv 0]
+set sourcesConf ${prefix}/etc/macports/sources.conf
+if {[catch {set sourcesConfChannel [open $sourcesConf r]}]} {
+ exit 0
+}
+
+if {[file executable /usr/bin/mktemp]} {
+ set mktemp /usr/bin/mktemp
+} elseif {[file executable /bin/mktemp]} {
+ set mktemp /bin/mktemp
+} else {
+ set mktemp mktemp
+}
+
+set mktempChannel [open "|$mktemp -t macports_sources_upgrade.XXXXXXXXXX" r]
+set tempfile [read -nonewline $mktempChannel]
+close $mktempChannel
+
+set tempfileChannel [open $tempfile w]
+set defaultSeen false
+set defaultWritten false
+
+while {[gets $sourcesConfChannel line] >= 0} {
+ set addDefault false
+ if {!$defaultSeen && ![regexp {^\s*#|^$} $line]} {
+ if {[regexp {^([\w-]+://\S+)(?:\s+\[(\w+(?:,\w+)*)\])?$} $line -> url flags]} {
+ set flags [split $flags ,]
+ if {[lsearch $flags default] >= 0} {
+ set defaultSeen true
+ } elseif {[regexp {rsync://rsync\.(macports|darwinports)\.org/(release|dpupdate)/d?ports} $url]} {
+ set addDefault true
+ } elseif {[regexp {file://(/.+)} $url -> filepath]} {
+ if {[file exists [file join ${filepath} .svn]]} {
+ if {![info exists svnCmd]} {
+ set svnCmd ""
+ foreach path [concat [list ${prefix}/bin] [split $env(PATH) :]] {
+ if {[file executable ${path}/svn]} {
+ set svnCmd ${path}/svn
+ break
+ }
+ }
+ }
+ if {$svnCmd eq ""} {
+ puts "WARNING: Unable to check svn URL for '$filepath' because no svn command could be found; please manually verify $sourcesConf!"
+ continue
+ }
+ if {![catch {set svnChannel [open "|$svnCmd info ${filepath}" r]} err]} {
+ set svnURL {}
+ while {[gets $svnChannel svnLine] >= 0} {
+ regexp {^URL: (.*)} $svnLine -> svnURL
+ }
+ if {[catch {close $svnChannel} err]} {
+ puts $err
+ puts "WARNING: Unable to check svn URL for '$filepath'; please manually verify $sourcesConf!"
+ }
+ if {[regexp {^https?://svn\.(macports|macosforge)\.org/repository/macports/trunk/dports} $svnURL]} {
+ set addDefault true
+ }
+ } else {
+ puts $err
+ puts "WARNING: Unable to check svn URL for '$filepath'; please manually verify $sourcesConf!"
+ }
+ }
+ }
+ if {$addDefault} {
+ lappend flags default
+ set line "$url \[[join $flags ,]\]"
+ set defaultSeen true
+ set defaultWritten true
+ }
+ }
+ }
+ puts $tempfileChannel $line
+}
+close $tempfileChannel
+close $sourcesConfChannel
+
+if {$defaultWritten} {
+ set attributes [file attributes ${sourcesConf}]
+ if {[catch {file rename ${sourcesConf} "${sourcesConf}.mpsaved"}]} {
+ file rename -force ${sourcesConf} "${sourcesConf}.mpsaved_[clock seconds]"
+ }
+ file rename ${tempfile} ${sourcesConf}
+ eval file attributes ${sourcesConf} $attributes
+} else {
+ file delete ${tempfile}
+ if {!$defaultSeen} {
+ puts "[string repeat - 72]
+Warning, your source config file at:
+
+ $sourcesConf
+
+needs to have a \[default\] tag added to the primary MacPorts repository,
+however the proper entry could not be determined. Please add the tag
+manually by either appending \[default\] to the end of the correct line,
+or if there are already tags, adding it to the list, e.g.
+\[nosync,default\].
+[string repeat - 72]"
+ }
+}
+
+exit 0
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20140418/6ad2999d/attachment-0001.html>
More information about the macports-changes
mailing list