Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
Ok, I was able to bootstrap an install using this script:

Code:
#!/bin/bash

set -e
set -x

# grab a copy of curl with moderl SSL
if ! test -e /opt/tigersh-deps-0.1 ; then
    cd /opt
    url=https://leopard.sh/binpkgs/tigersh-deps-0.1.tiger.g3.tar.gz
    curl -f $url | gunzip | tar x
fi
export PATH="/opt/tigersh-deps-0.1/bin:$PATH"

# grab the ppcports src
url=https://github.com/macos-powerpc/macports-base/archive/refs/heads/master.tar.gz
curl -fL $url | gunzip | tar x

cd macports-base-master
CFLAGS="-mcpu=750 -Os" ./configure
make
sudo make install

I made a small change to macports.tcl:

Code:
                set tar_version [exec tar --version | head -n1]
                if [regexp { 1\.14} $tar_version] {
                    # Tiger shipped with tar 1.14.
                    set striparg "--strip-path=1"
                } else {
                    set striparg "--strip-components=1"
                }

However, now I am encountering hundreds of PortGroup errors:

Code:
$ sudo port -v sync
--->  Updating the ports tree
Synchronizing local ports tree from rsync://macos-powerpc.org/macos-powerpc/PPCPorts/powerpc-ports.tar
receiving file list ... done
./

sent 90 bytes  received 54 bytes  41.14 bytes/sec
total size is 0  speedup is 0.00
receiving file list ... done

sent 78 bytes  received 93 bytes  68.40 bytes/sec
total size is 17889536  speedup is 104617.17
receiving file list ... rsync: [sender] change_dir "/PPCPorts/PortIndex_darwin_8_powerpc" (in macos-powerpc) failed: No such file or directory (2)
done

sent 50 bytes  received 9 bytes  23.60 bytes/sec
total size is 0  speedup is 0.00
rsync error: some files could not be transferred (code 23) at /SourceCache/rsync/rsync-35.2/rsync/main.c(1400) [receiver=2.6.9]
Command failed: /usr/bin/rsync -rtzvl --delete-after --include=/PortIndex.rmd160 --include=/PortIndex --exclude=* rsync://macos-powerpc.org/macos-powerpc/PPCPorts/PortIndex_darwin_8_powerpc/ /opt/local/var/macports/sources/macos-powerpc.org/macos-powerpc/PPCPorts/remote
Exit code: 23
Creating port index in /opt/local/var/macports/sources/macos-powerpc.org/macos-powerpc/PPCPorts/ports
Error: LimeChat: PortGroup xcode 1.0 could not be located. xcode-1.0.tcl does not exist.
Failed to parse file aqua/LimeChat/Portfile: PortGroup not found
Error: MenuMeters: PortGroup github 1.0 could not be located. github-1.0.tcl does not exist.
Failed to parse file aqua/MenuMeters/Portfile: PortGroup not found
Error: fltk: PortGroup github 1.0 could not be located. github-1.0.tcl does not exist.
Failed to parse file aqua/fltk/Portfile: PortGroup not found
Error: iTerm2: PortGroup github 1.0 could not be located. github-1.0.tcl does not exist.
Failed to parse file aqua/iTerm2/Portfile: PortGroup not found
Error: qlipper: PortGroup cmake 1.0 could not be located. cmake-1.0.tcl does not exist.
Failed to parse file aqua/qlipper/Portfile: PortGroup not found
Warning: Using the mainstream/official Qt4 portgroup
Error: qt4-mac: PortGroup xcodeversion 1.0 could not be located. xcodeversion-1.0.tcl does not exist.
Failed to parse file aqua/qt4-mac/Portfile: PortGroup not found
Error: qt4-mac-devel: PortGroup xcodeversion 1.0 could not be located. xcodeversion-1.0.tcl does not exist.
Failed to parse file aqua/qt4-mac-devel/Portfile: PortGroup not found

(snip)

Code:
Error: xorg-server-legacy: PortGroup compiler_blacklist_versions 1.0 could not be located. compiler_blacklist_versions-1.0.tcl does not exist.
Failed to parse file x11/xorg-server-legacy/Portfile: PortGroup not found

Total number of ports parsed:    598
Ports successfully parsed:    0
Ports failed:            598
Up-to-date ports skipped:    254

Synchronizing local ports tree from rsync://rsync.macports.org/macports/release/tarballs/ports.tar.gz


I have a bit more learning to do here, to get up to speed on how MacPorts works.

Could you just run port sync again? All these are mainstream portgroups, they do not exist in my repos. So perhaps they are not found, because this is the first sync, and powerpc-power are indexed first, when upstream ports are not yet indexed.

This is ugly, I agree, and should be solved somehow in a better way. But probably another port sync will do for now.

P. S. Well, obvious and quick fix would be just to duplicate all portgroups, regardless of whether they are modified or not. Not sure it is the optimal solution, but perhaps it’s okay, and better than a failing 1st sync, that will freak users out LOL
 
  • Like
Reactions: cellularmitosis
However, now I am encountering hundreds of PortGroup errors:

I have pushed a change to include all portgroups which are used in MacPorts and re-uploaded a new ports tarball.
Hopefully this fixes the issue for now.

P. S. You will see 4 ports of mainstream ones failing to parse, that is expected (they are irrelevant for us anyway, since they require Qt5).
 
  • Like
Reactions: cellularmitosis
I have pushed a change to include all portgroups which are used in MacPorts and re-uploaded a new ports tarball.
Hopefully this fixes the issue for now.

P. S. You will see 4 ports of mainstream ones failing to parse, that is expected (they are irrelevant for us anyway, since they require Qt5).

Thanks! Setting this up on a second machine now to test this change (the first machine is churning through an apple-gcc-4.2 build)
 
  • Like
Reactions: barracuda156
Great, it is syncing now!

There was one error, it looks like PortIndex_darwin_8_powerpc isn't being generated?

Code:
receiving file list ... rsync: [sender] change_dir "/PPCPorts/PortIndex_darwin_8_powerpc" (in macos-powerpc) failed: No such file or directory (2)
done
client: nothing to do: perhaps you need to specify some filenames or the --recursive option?
rsync error: some files could not be transferred (code 23) at /SourceCache/rsync/rsync-24.1/rsync/main.c(738)
Command failed: /usr/bin/rsync -rtzvl --delete-after --include=/PortIndex.rmd160 --include=/PortIndex --exclude=* rsync://macos-powerpc.org/macos-powerpc/PPCPorts/PortIndex_darwin_8_powerpc/ /opt/local/var/macports/sources/macos-powerpc.org/macos-powerpc/PPCPorts/remote
Exit code: 23
 
Here is an initial PR with a proposed fix for tar 1.14: https://github.com/macos-powerpc/macports-base/pull/1

However, I am not sure how to trigger the code path to test this. When I built macports-base from source, I initially didn't include this patch (to reproduce the failure) and yet for some reason it didn't trigger the failure. I need to look closer at the source and figure out an invocation which will trigger this code path.
 
Great, it is syncing now!

There was one error, it looks like PortIndex_darwin_8_powerpc isn't being generated?

Code:
receiving file list ... rsync: [sender] change_dir "/PPCPorts/PortIndex_darwin_8_powerpc" (in macos-powerpc) failed: No such file or directory (2)
done
client: nothing to do: perhaps you need to specify some filenames or the --recursive option?
rsync error: some files could not be transferred (code 23) at /SourceCache/rsync/rsync-24.1/rsync/main.c(738)
Command failed: /usr/bin/rsync -rtzvl --delete-after --include=/PortIndex.rmd160 --include=/PortIndex --exclude=* rsync://macos-powerpc.org/macos-powerpc/PPCPorts/PortIndex_darwin_8_powerpc/ /opt/local/var/macports/sources/macos-powerpc.org/macos-powerpc/PPCPorts/remote
Exit code: 23

It is expected, I just did not upload indices :)
Don’t see much need for that for the primary overlay (it is just some 500 ports vs 40k in MacPorts, costs of local syncing are negligible). Once/if I add R ports repo by default, I will see how to make indices in a way rsync picks them.

P. S. Ah, for 10.4 I am not gonna make indices anyway. If you or someone does that, we can upload those.
 
A bit off-topic, but has anyone looked at building a replacement libSystem.dylib which directly incorporates a lot of the fixes from the MacPorts Legacy Support library? It occurs to me that it might be easier to modernize the base system rather than have a bunch of workarounds in the port files.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.