Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
Checksums are correct:
Code:
macmini:macports-base svacchanda$ sudo port clean --all libsdl2-cocoa
--->  Cleaning libsdl2-cocoa
macmini:macports-base svacchanda$ sudo port -v extract libsdl2-cocoa
--->  Fetching distfiles for libsdl2-cocoa
--->  SDL2-2.32.6.tar.gz does not exist in /opt/local/var/macports/distfiles/libsdl2-cocoa
--->  Attempting to fetch SDL2-2.32.6.tar.gz from https://github.com/libsdl-org/SDL/releases/download/release-2.32.6
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 7448k  100 7448k    0     0   362k      0  0:00:20  0:00:20 --:--:--  469k
--->  release-2.0.3.tar.gz does not exist in /opt/local/var/macports/distfiles/libsdl2-cocoa
--->  Attempting to fetch release-2.0.3.tar.gz from https://github.com/libsdl-org/SDL/releases/download/release-2.32.6
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
--->  Attempting to fetch release-2.0.3.tar.gz from https://github.com/libsdl-org/SDL/archive/refs/tags/
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 5574k    0 5574k    0     0  1375k      0 --:--:--  0:00:04 --:--:-- 1554k
--->  Verifying checksums for libsdl2-cocoa
--->  Checksumming SDL2-2.32.6.tar.gz
--->  Checksumming release-2.0.3.tar.gz
--->  Extracting libsdl2-cocoa
--->  Extracting SDL2-2.32.6.tar.gz
Executing:  cd "/opt/local/var/macports/build/libsf4KyXd/work" && /usr/bin/gzip -dc '/opt/local/var/macports/distfiles/libsdl2-cocoa/SDL2-2.32.6.tar.gz' | /usr/bin/gnutar --no-same-owner -xf -
--->  Extracting release-2.0.3.tar.gz
Executing:  cd "/opt/local/var/macports/build/libsf4KyXd/work" && /usr/bin/gzip -dc '/opt/local/var/macports/distfiles/libsdl2-cocoa/release-2.0.3.tar.gz' | /usr/bin/gnutar --no-same-owner -xf -

Could you show what exactly fails?
I do not have updated curl, so I was trying to place the source files into /opt/local/var/macports/distfiles/libsdl2-cocoa
I cannot find release-2.0.3.tar.gz from https://github.com/libsdl-org/SDL/archive/refs/tags/
I found a file manually that was SDL 2.0.3, but that is clearly not the right file.
I was posting here to see if anyone had release-2.0.3 so I don't have to rebuild my whole system against modern curl
 
I do not have updated curl, so I was trying to place the source files into /opt/local/var/macports/distfiles/libsdl2-cocoa
I cannot find release-2.0.3.tar.gz from https://github.com/libsdl-org/SDL/archive/refs/tags/
I found a file manually that was SDL 2.0.3, but that is clearly not the right file.
I was posting here to see if anyone had release-2.0.3 so I don't have to rebuild my whole system against modern curl

Sure, though you can actually do it yourself from any other machine (assuming 10.4 is not the only one).
`sudo port fetch` downloads tarballs and places into `/opt/local/var/macports/distfiles/some_port`.

Here you go: https://www.mediafire.com/file/vawypbss0i1my2n/release-2.0.3.tar.gz/file (likewise, place into distfiles/libsdl2-cocoa).
 
Sure, though you can actually do it yourself from any other machine (assuming 10.4 is not the only one).
`sudo port fetch` downloads tarballs and places into `/opt/local/var/macports/distfiles/some_port`.

Here you go: https://www.mediafire.com/file/vawypbss0i1my2n/release-2.0.3.tar.gz/file (likewise, place into distfiles/libsdl2-cocoa).
Thank you! My only machines not on 10.4/10.5 are Windows, where macports obviously doesn't work and curl gives me headaches
 

Attachments

  • main.txt
    478.4 KB · Views: 12
Thank you for all the helpful links. I may use leopard as a "sudo port extract" partition and then move the tarballs to my Tiger partition in the future.
Unfortunately, I got a build failure. I have attached the log as a txt file. Hopefully not caused by me putting the tarballs in by hand.

Nah, that’s a bug in Apple headers LOL

Try this first: https://github.com/macports/macport...3ef/graphics/wxWidgets-3.0/Portfile#L139-L145
(In effect, just pass `-faltivec` to cflags – there is no C++ code here.)

If that fails, a dirty hack would be to add `#undef __APPLE_ALTIVEC__` prior to the Carbon header which causes the breakage. See discussion for details: https://github.com/wxWidgets/wxWidgets/pull/25321
 
Nah, that’s a bug in Apple headers LOL

Try this first: https://github.com/macports/macport...3ef/graphics/wxWidgets-3.0/Portfile#L139-L145
(In effect, just pass `-faltivec` to cflags – there is no C++ code here.)

If that fails, a dirty hack would be to add `#undef __APPLE_ALTIVEC__` prior to the Carbon header which causes the breakage. See discussion for details: https://github.com/wxWidgets/wxWidgets/pull/25321
Okay, I will try adding this to the Portfile first and let you know if that fixes it
platform darwin powerpc {
if {![catch {sysctl hw.vectorunit} result] && $result > 0} {
# Work around buggy header. https://trac.macports.org/ticket/55251
configure.cxxflags-append -faltivec
configure.cflags-append -faltivec
}
}
 
Nah, that’s a bug in Apple headers LOL

Try this first: https://github.com/macports/macport...3ef/graphics/wxWidgets-3.0/Portfile#L139-L145
(In effect, just pass `-faltivec` to cflags – there is no C++ code here.)

If that fails, a dirty hack would be to add `#undef __APPLE_ALTIVEC__` prior to the Carbon header which causes the breakage. See discussion for details: https://github.com/wxWidgets/wxWidgets/pull/25321
Thank you! The first suggestion fixed the build. I created a pull request to add the fix to PPCPorts on Github.
Unfortunately, I do not have an app to test libsdl2-cocoa, as I got a build failure about sixty percent through on qmplay2-devel. The log is attached. Thank you again for your help.
 

Attachments

  • main.txt
    411.3 KB · Views: 11
Thank you! The first suggestion fixed the build. I created a pull request to add the fix to PPCPorts on Github.
Unfortunately, I do not have an app to test libsdl2-cocoa, as I got a build failure about sixty percent through on qmplay2-devel. The log is attached. Thank you again for your help.

You can test libsdl2 with ffmpeg. Make sure to use a version with libsdl2 enabled or enable it yourself in the portfile.
Also mpv uses libsdl2.

Re QMPlay2: just disable OpenGL in the port file configure options, it is straightforward. OpenGL is optional and was disabled until very recently anyway.
 
I will disable OpenGL for Tiger in the port now and push an update.

P. S. Or I can try a blind fix, if you wanna test. Let me know.
Sadly, I got my PowerBook wrapped up in compiling tenfourfox-devel, so I will be unable to test anything for quite a while. Please go ahead with whatever fixes you think best and hopefully I can confirm if they work on Tiger this weekend
 
Thank you! The first suggestion fixed the build. I created a pull request to add the fix to PPCPorts on Github.
Unfortunately, I do not have an app to test libsdl2-cocoa, as I got a build failure about sixty percent through on qmplay2-devel. The log is attached. Thank you again for your help.
FYI SDL2 itself comes with extensive tests in the "test" folder (at the same level as src and include). If you have SDL2 installed you can just "configure" and "make". If OpenGL is disabled it won't built tests for it, obviously.
 
I forgot you were talking about -devel subport, but anyway, now I also disabled GL for Tiger in qmplay2-devel.
That does help the build progress further! I went ahead and attached the new logs in case there are fixes you could recommend to the last part of the builds.
FYI SDL2 itself comes with extensive tests in the "test" folder (at the same level as src and include). If you have SDL2 installed you can just "configure" and "make". If OpenGL is disabled it won't built tests for it, obviously.
I'm really struggling to find these with how Macports does its file locations, but thank you for the advice and it is good to see you back!
 

Attachments

  • Qmplay2.txt
    533.7 KB · Views: 9
  • qmplay2-devel.txt
    398.7 KB · Views: 7
That does help the build progress further! I went ahead and attached the new logs in case there are fixes you could recommend to the last part of the builds.

1. For the error in QMPlay2-devel either just replace macros in the source as compiler suggests (perhaps that gonna work) or try adding this to the portfile:
Code:
configure.cppflags-append \
                    -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES=0
Make sure that the flag is actually passed and used in particular with ObjC++ sources.

You can even hack the build: do not modify portfile, but do this:
Code:
cd /opt/local/var/macports/build/_Users_powerbook_powerpc-ports_multimedia_QMPlay2-devel/QMPlay2-devel/work/build/src/modules/PortAudio

sudo /opt/local/bin/g++-mp-14 -DPortAudio_EXPORTS -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NO_DEBUG -DQT_SVG_LIB -DQT_USE_FAST_OPERATOR_PLUS -DQ_OS_MACOS -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES=0 -I/opt/local/var/macports/build/_Users_powerbook_powerpc-ports_multimedia_QMPlay2-devel/QMPlay2-devel/work/build/src/modules/PortAudio -I/opt/local/var/macports/build/_Users_powerbook_powerpc-ports_multimedia_QMPlay2-devel/QMPlay2-devel/work/QMPlay2-19.09.03/src/modules/PortAudio -I/opt/local/var/macports/build/_Users_powerbook_powerpc-ports_multimedia_QMPlay2-devel/QMPlay2-devel/work/build/src/modules/PortAudio/PortAudio_autogen/include -I/opt/local/var/macports/build/_Users_powerbook_powerpc-ports_multimedia_QMPlay2-devel/QMPlay2-devel/work/QMPlay2-19.09.03/src/modules/PortAudio/../../qmplay2/headers -I/opt/local/include -isystem /opt/local/libexec/qt4/include -isystem /opt/local/libexec/qt4/include/QtGui -isystem /opt/local/libexec/qt4/include/QtCore -isystem /opt/local/libexec/qt4/share/mkspecs/default -isystem /opt/local/libexec/qt4/include/QtSvg -Wall -Wno-deprecated-declarations -pipe -Os -DNDEBUG -I/opt/local/include -I/opt/local/libexec/ffmpeg5/include -DUSE_QRAWFONT -D_GLIBCXX_USE_CXX11_ABI=0 -std=gnu++11 -arch ppc -mmacosx-version-min=10.4 -fPIC -MD -MT src/modules/PortAudio/CMakeFiles/PortAudio.dir/3rdparty/CoreAudio/AudioDevice.mm.o -MF CMakeFiles/PortAudio.dir/3rdparty/CoreAudio/AudioDevice.mm.o.d -o CMakeFiles/PortAudio.dir/3rdparty/CoreAudio/AudioDevice.mm.o -c /opt/local/var/macports/build/_Users_powerbook_powerpc-ports_multimedia_QMPlay2-devel/QMPlay2-devel/work/QMPlay2-19.09.03/src/modules/PortAudio/3rdparty/CoreAudio/AudioDevice.mm

If that compiles, just resume the build normally.

2. For the error in ScreenSaver.cpp: if you want a proper fix, check if 10.4 has equivalents for what is undefined, if it does not, then put breaking stuff inside `#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1050` (make sure the code makes sense after that).
If you don’t care about fixing this correctly but simply want to compile the app somehow, convert failing functions into stubs or exclude ScreenSaver.cpp from the build altogether. The latter will likely require a minor change to some other file, if something calls a function from ScreenSaver.cpp (you will get an error at linking in that case). Use BBEdit/TextWrangler to find a missing symbol and comment out a chunk calling it.
 
Last edited:
@lauland In a case it is relevant, I added a patch (completely trivial one) to libsdl2_mixer port to allow it build on 10.5. May as well fix it for 10.4.
 
Looks like that AudioUnit stuff is 10.5+: https://developer.apple.com/documentation/audiotoolbox/augraphnodeinfo(_:_:_:_:)?language=objc

If you will want to fix this for 10.4, perhaps just look what the older versions had and add a fallback. We can’t do much, if the SDK has no support for needed functions.
I went ahead and attached a log of the build failure for the first libsdl2_mixer version available in Macports. If it is the same issue, then there likely isn't a solution. It's fine if it never gets working for Tiger, it is a dependency for a lot of things (including pygame, which I know someone asked about), but nothing important to me personally. I have claws-mail, which is what I started my Macports journey to get. Everything else is just a bonus.
 

Attachments

  • libsdl2_mixerold.txt
    62.3 KB · Views: 2
I went ahead and attached a log of the build failure for the first libsdl2_mixer version available in Macports. If it is the same issue, then there likely isn't a solution. It's fine if it never gets working for Tiger, it is a dependency for a lot of things (including pygame, which I know someone asked about), but nothing important to me personally. I have claws-mail, which is what I started my Macports journey to get. Everything else is just a bonus.

Here is the fix, I guess: https://discourse.libsdl.org/t/sdl-mixer-compilation-fix-for-os-x-powerpc/35313
Can you try it?
 
Great find! I turned the fix into a patch and got libsdl2_mixer 2.0.4 to build with the following files (converted into .txt so I can attach to this post). The patch file should be .diff not .txt. Blobwars builds with it, but fails to launch. I will do more testing, but probably libsdl2_mixer is working
P.S. I also have patches for ninja (as discussed in a different thread), but one causes more problems because it deals with variables no longer in the code. Given a couple more weeks to get better at updating patches by hand I am hopeful I will figure it out.
 

Attachments

  • Portfile.txt
    1.7 KB · Views: 2
  • patch-tiger-midi-macosx.txt
    599 bytes · Views: 2
Great find! I turned the fix into a patch and got libsdl2_mixer 2.0.4 to build with the following files (converted into .txt so I can attach to this post). The patch file should be .diff not .txt. Blobwars builds with it, but fails to launch. I will do more testing, but probably libsdl2_mixer is working

To be merged this should be done as a fallback. (If you will do that, please verify that those configure options actually exist and dependencies are sensible. Both differ from the current version.)
 
To be merged this should be done as a fallback. (If you will do that, please verify that those configure options actually exist and dependencies are sensible. Both differ from the current version.)
I agree. If testing reveals that it works as it should, I will do that. I hope putting it here will enable people to use it until I have time to test, add a fallback, and then test the modified Portfile. Btw, I tested the new gawk Portfile and the GUI programs that depend on it still work, so that one is a success
 
Last edited:
  • Like
Reactions: barracuda156
Not that I am hugely surprised, but throwing it old joystick sources did not work:
Code:
In file included from /opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/../SDL_sysjoystick.h:21,
                 from /opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:52:
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/../../SDL_internal.h:53:1: warning: "DECLSPEC" redefined
In file included from include/SDL_platform.h:243,
                 from include/SDL_config.h:33,
                 from /opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:21:
include/begin_code.h:70:1: warning: this is the location of the previous definition
In file included from include/SDL_video.h:33,
                 from include/SDL_events.h:33,
                 from /opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:55:
include/SDL_rect.h: In function ‘SDL_FRectEqualsEpsilon’:
include/SDL_rect.h:255: warning: implicit declaration of function ‘SDL_fabsf_REAL’
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c: In function ‘HIDReportErrorNum’:
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:75: warning: implicit declaration of function ‘SDL_SetError_REAL’
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c: In function ‘HIDGetDeviceInfo’:
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:543: warning: implicit declaration of function ‘SDL_strlcpy_REAL’
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c: In function ‘SDL_SYS_JoystickInit’:
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:816: warning: implicit declaration of function ‘SDL_SYS_NumJoysticks’
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c: In function ‘SDL_SYS_JoystickDetect’:
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:846: warning: ISO C90 forbids mixed declarations and code
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:854: warning: ISO C90 forbids mixed declarations and code
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:859: error: ‘SDL_EventOK’ undeclared (first use in this function)
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:859: error: (Each undeclared identifier is reported only once
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:859: error: for each function it appears in.)
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:860: error: ‘SDL_EventOKParam’ undeclared (first use in this function)
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:888: warning: ISO C90 forbids mixed declarations and code
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c: In function ‘SDL_SYS_JoystickUpdate’:
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:1006: error: ‘SDL_Joystick’ has no member named ‘closed’
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:1007: error: ‘SDL_Joystick’ has no member named ‘uncentered’
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:1027: warning: ISO C90 forbids mixed declarations and code
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:1032: error: ‘SDL_EventOK’ undeclared (first use in this function)
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:1033: error: ‘SDL_EventOKParam’ undeclared (first use in this function)
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:1046: error: invalid operands to binary != (have ‘SInt32’ and ‘SDL_JoystickAxisInfo’)
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c: In function ‘SDL_SYS_JoystickClose’:
/opt/local/var/macports/build/libsdl2-cocoa-09e2978a/work/SDL2-2.32.8/src/joystick/darwin/SDL_iokitjoystick.c:1121: error: ‘SDL_Joystick’ has no member named ‘closed’

I leave it to whomever may be interested.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.