Using MacPorts "Offline"

Jepeway, Chris Chris.Jepeway at JTV.com
Tue Jan 30 00:15:49 UTC 2018


I'm looking to use & build ports offline, without any direct internet access.

Is this possible?

I've got a recent install of MacPorts via the v2.4.2 disk image.

I've got a copy of ports.tar.

I've got an rsync'ed set of distfiles obtained on an online system that I've copied to the MacBook that won't have access to the internet.

I've got the command-line development tools.

Eventually, I'll have a copy of Xcode.

What sort of config do I need?

This is the last line of sources.conf:

	file:///Users/chrjep2/share/macports/ports.tar [default] [nosync]

When I try a simple test like:

	sudo port version

I get this:

	Warning: /opt/local/etc/macports/sources.conf specifies invalid source 'file:///Users/chrjep2/share/macports/ports.tar [default] [nosync]', ignored.
	No sources defined in /opt/local/etc/macports/sources.conf
	    while executing "mportinit ui_options global_options global_variations"
	Error: /opt/local/bin/port: Failed to initialize MacPorts, No sources defined in /opt/local/etc/macports/sources.conf

FWIW, the tarball seems OK:

	nickel% sudo tar tvf /Users/chrjep2/share/macports/ports.tar | head
	drwxr-xr-x  0 buildbot buildbot    0 Dec 17 11:41 ports/
	-rw-r--r--  0 buildbot buildbot  234 Aug 22 17:13 ports/.gitattributes
	drwxr-xr-x  0 buildbot buildbot    0 Nov  5 10:54 ports/.github/
	-rw-r--r--  0 buildbot buildbot   38 Aug 22 17:13 ports/.gitignore
	-rw-r--r--  0 buildbot buildbot 1273 Aug 22 17:13 ports/.mailmap
	-rw-r--r--  0 buildbot buildbot  189 Oct 30 22:14 ports/.travis.yml
	-rw-r--r--  0 buildbot buildbot 1996 Aug 22 17:13 ports/LICENSE
	drwxr-xr-x  0 buildbot buildbot    0 Jan 17 04:01 ports/PortIndex_darwin_10_i386/
	drwxr-xr-x  0 buildbot buildbot    0 Jan 17 04:01 ports/PortIndex_darwin_11_i386/
	drwxr-xr-x  0 buildbot buildbot    0 Jan 17 04:01 ports/PortIndex_darwin_12_i386/

Any and all help much appreciated.

Chris.
--
Chris Jepeway
Principal Engineer, Technical Operations
Jewelry Television



More information about the macports-users mailing list