Re: SDL2 for older systems: which components we need enabled? Cocoa vs X11
That was my point: X11 does not require violating sources much. What does is essentially one file: SDL_cocoamodes.m. It is used by cocoa video, otherwise it is not built. I did not have to throw chunks of code away, aside of cocoa video case (which still fails to build so far). And miniupnp and your patches are adaptable: again, leaving off cocoa video part. (I didn’t bother with joystick at all yet, aside of seeing it gets ICE akin to hidapi, which only Iain can fix, but it has been many months since it was filed to Bugzilla, and here we are.) I will review my patches today to make sure nothing silly creeped in, and what I suggest is I make a PR with X11 backend and no cocoa video, and you or someone interested take a look. It is easy to switch portfile logic to use X11 on ppc and old Intel, while keeping existing settings for 10.6 Intel. On Jul 20, 2023 07:15 +0800, Ken Cunningham , wrote: > As far as I know, we don't have any ports that use SDL2 via X11/Xquartz. All > the ports use the Cocoa interface. > > The modifications that were made to SDL2 by miniupnp to run on Tiger and > Leopard were fairly extensive, to an older version of SDL2, but they worked > to allow a number of ports that required libsdl2 to work on those systems. I > have those mods tucked away in the archives of the TigerPorts and > LeopardPorts repos. > > Any newer version of libsdl2/SDL2 was not able to be adjusted to be useful on > those older systems. We did have one newer version that would build, but was > so broken by the hacks needed to make it build that it was useless in > practical use. > > Which brings me to the next point. > > It is quite possible to make hacks/patches to software that will allow it to > build -- at an extreme, you and #if 0 / #endif out that entire source, and it > will compile just fine. > > But especially for things like SDL2, what is needed is more than that -- you > have to see if software built against such patched versions will actually > work, and this sometimes takes some fairly extensive testing to see what the > warts might be. > > > > Ken > > > > > On Jul 19, 2023, at 8:32 AM, Sergey Fedorov wrote: > > > > libsdl 2.0.22 (our Snow Leopard port) builds on PowerPC with unoffensive > > fixes, however I had to disable cocoa video and joystick for that. > > They are likely fixable (though no idea whether and how they gonna work), > > but at least cocoa video gonna require a massive rewrite – or perhaps > > falling back to an earlier implementation. (Well, this is not a kind of > > code I can genuinely rewrite – only adapt patches and maybe improve > > something a bit.) > > > > However, if X11 implementation is a meaningful replacement, it builds fine > > with no trickery. > > > > Any thoughts? > > > > P. S. ICE on hidapi is trivially fixable – I just reverted a commit which > > has broken that. After that, hidapi builds fine. >
Re: SDL2 for older systems: which components we need enabled? Cocoa vs X11
Of course, we could also make a separate -legacy port using 2.0.9, for example (last version miniupnp patched was 2.0.8 but we know 2.0.9 builds and likely gonna work), but it will be disappointing to having wasted many hours on 2.0.22 without a positive outcome LOL There is also no harm in switching to X11 for systems which it does not build at all presently. With that option enabled, other ports can be tested to see if X11 can be likewise used for old systems with SDL2. On Jul 20, 2023 17:41 +0800, Sergio Had , wrote: > That was my point: X11 does not require violating sources much. What does is > essentially one file: SDL_cocoamodes.m. It is used by cocoa video, otherwise > it is not built. > > I did not have to throw chunks of code away, aside of cocoa video case (which > still fails to build so far). And miniupnp and your patches are adaptable: > again, leaving off cocoa video part. (I didn’t bother with joystick at all > yet, aside of seeing it gets ICE akin to hidapi, which only Iain can fix, but > it has been many months since it was filed to Bugzilla, and here we are.) > > I will review my patches today to make sure nothing silly creeped in, and > what I suggest is I make a PR with X11 backend and no cocoa video, and you or > someone interested take a look. > It is easy to switch portfile logic to use X11 on ppc and old Intel, while > keeping existing settings for 10.6 Intel. > On Jul 20, 2023 07:15 +0800, Ken Cunningham > , wrote: > > As far as I know, we don't have any ports that use SDL2 via X11/Xquartz. > > All the ports use the Cocoa interface. > > > > The modifications that were made to SDL2 by miniupnp to run on Tiger and > > Leopard were fairly extensive, to an older version of SDL2, but they worked > > to allow a number of ports that required libsdl2 to work on those systems. > > I have those mods tucked away in the archives of the TigerPorts and > > LeopardPorts repos. > > > > Any newer version of libsdl2/SDL2 was not able to be adjusted to be useful > > on those older systems. We did have one newer version that would build, but > > was so broken by the hacks needed to make it build that it was useless in > > practical use. > > > > Which brings me to the next point. > > > > It is quite possible to make hacks/patches to software that will allow it > > to build -- at an extreme, you and #if 0 / #endif out that entire source, > > and it will compile just fine. > > > > But especially for things like SDL2, what is needed is more than that -- > > you have to see if software built against such patched versions will > > actually work, and this sometimes takes some fairly extensive testing to > > see what the warts might be. > > > > > > > > Ken > > > > > > > > > On Jul 19, 2023, at 8:32 AM, Sergey Fedorov wrote: > > > > > > libsdl 2.0.22 (our Snow Leopard port) builds on PowerPC with unoffensive > > > fixes, however I had to disable cocoa video and joystick for that. > > > They are likely fixable (though no idea whether and how they gonna work), > > > but at least cocoa video gonna require a massive rewrite – or perhaps > > > falling back to an earlier implementation. (Well, this is not a kind of > > > code I can genuinely rewrite – only adapt patches and maybe improve > > > something a bit.) > > > > > > However, if X11 implementation is a meaningful replacement, it builds > > > fine with no trickery. > > > > > > Any thoughts? > > > > > > P. S. ICE on hidapi is trivially fixable – I just reverted a commit which > > > has broken that. After that, hidapi builds fine. > >
Re: SDL2 for older systems: which components we need enabled? Cocoa vs X11
P. S. I wonder now if the current SDL2 gonna build with X11 backend and Cocoa off. Given that upstream concentrated efforts on skillfully breaking Cocoa beyond repair, everything else might be intact. On Jul 20, 2023 07:15 +0800, Ken Cunningham , wrote: > As far as I know, we don't have any ports that use SDL2 via X11/Xquartz. All > the ports use the Cocoa interface. > > The modifications that were made to SDL2 by miniupnp to run on Tiger and > Leopard were fairly extensive, to an older version of SDL2, but they worked > to allow a number of ports that required libsdl2 to work on those systems. I > have those mods tucked away in the archives of the TigerPorts and > LeopardPorts repos. > > Any newer version of libsdl2/SDL2 was not able to be adjusted to be useful on > those older systems. We did have one newer version that would build, but was > so broken by the hacks needed to make it build that it was useless in > practical use. > > Which brings me to the next point. > > It is quite possible to make hacks/patches to software that will allow it to > build -- at an extreme, you and #if 0 / #endif out that entire source, and it > will compile just fine. > > But especially for things like SDL2, what is needed is more than that -- you > have to see if software built against such patched versions will actually > work, and this sometimes takes some fairly extensive testing to see what the > warts might be. > > > > Ken > > > > > On Jul 19, 2023, at 8:32 AM, Sergey Fedorov wrote: > > > > libsdl 2.0.22 (our Snow Leopard port) builds on PowerPC with unoffensive > > fixes, however I had to disable cocoa video and joystick for that. > > They are likely fixable (though no idea whether and how they gonna work), > > but at least cocoa video gonna require a massive rewrite – or perhaps > > falling back to an earlier implementation. (Well, this is not a kind of > > code I can genuinely rewrite – only adapt patches and maybe improve > > something a bit.) > > > > However, if X11 implementation is a meaningful replacement, it builds fine > > with no trickery. > > > > Any thoughts? > > > > P. S. ICE on hidapi is trivially fixable – I just reverted a commit which > > has broken that. After that, hidapi builds fine. >
Re: SDL2 for older systems: which components we need enabled? Cocoa vs X11
As I recall, 2.08 built with his patches, but did not actually work, using the cocoa interface. This was about 5 years ago, so you’d have to find the ticket. I kept the last version that DID work in Leopardports. If you believe that using sdl2 via x11 will allow some port requiring a newish sdl to run usefully on ppc, have a try and see what happens. No need to have a long discussion about whether it will or won’t here…. you’ll know soon enough. My point is that it needs actual testing for FUNCTION, not just building. K > On Jul 20, 2023, at 03:36, Sergio Had wrote: > > > P. S. I wonder now if the current SDL2 gonna build with X11 backend and Cocoa > off. Given that upstream concentrated efforts on skillfully breaking Cocoa > beyond repair, everything else might be intact. >> On Jul 20, 2023 07:15 +0800, Ken Cunningham >> , wrote: >> As far as I know, we don't have any ports that use SDL2 via X11/Xquartz. All >> the ports use the Cocoa interface. >> >> The modifications that were made to SDL2 by miniupnp to run on Tiger and >> Leopard were fairly extensive, to an older version of SDL2, but they worked >> to allow a number of ports that required libsdl2 to work on those systems. I >> have those mods tucked away in the archives of the TigerPorts and >> LeopardPorts repos. >> >> Any newer version of libsdl2/SDL2 was not able to be adjusted to be useful >> on those older systems. We did have one newer version that would build, but >> was so broken by the hacks needed to make it build that it was useless in >> practical use. >> >> Which brings me to the next point. >> >> It is quite possible to make hacks/patches to software that will allow it to >> build -- at an extreme, you and #if 0 / #endif out that entire source, and >> it will compile just fine. >> >> But especially for things like SDL2, what is needed is more than that -- you >> have to see if software built against such patched versions will actually >> work, and this sometimes takes some fairly extensive testing to see what the >> warts might be. >> >> >> >> Ken >> >> >> >>> On Jul 19, 2023, at 8:32 AM, Sergey Fedorov wrote: >>> >>> libsdl 2.0.22 (our Snow Leopard port) builds on PowerPC with unoffensive >>> fixes, however I had to disable cocoa video and joystick for that. >>> They are likely fixable (though no idea whether and how they gonna work), >>> but at least cocoa video gonna require a massive rewrite – or perhaps >>> falling back to an earlier implementation. (Well, this is not a kind of >>> code I can genuinely rewrite – only adapt patches and maybe improve >>> something a bit.) >>> >>> However, if X11 implementation is a meaningful replacement, it builds fine >>> with no trickery. >>> >>> Any thoughts? >>> >>> P. S. ICE on hidapi is trivially fixable – I just reverted a commit which >>> has broken that. After that, hidapi builds fine. >>
Re: SDL2 for older systems: which components we need enabled? Cocoa vs X11
Useful to know, thank you. BTW, given it worked, why wasn’t it merged as a fallback for Leopard and Tiger? We can make a legacy port from the one you had, if Cocoa is preferable to X11 (even if not, it does not hurt to have both and let the user choose). What Macports has now – setting libsdl2-snowleopard for all <= 10 – clearly cannot work correctly, since upstream has broken gcc builds by switching to @autoreleasepool *to save a few lines of code*. On Thu, Jul 20, 2023 at 7:43 PM Ken Cunningham < ken.cunningham.web...@gmail.com> wrote: > As I recall, 2.08 built with his patches, but did not actually work, using > the cocoa interface. This was about 5 years ago, so you’d have to find the > ticket. I kept the last version that DID work in Leopardports. > > If you believe that using sdl2 via x11 will allow some port requiring a > newish sdl to run usefully on ppc, have a try and see what happens. No need > to have a long discussion about whether it will or won’t here…. you’ll know > soon enough. > > My point is that it needs actual testing for FUNCTION, not just building. > > K > > > > > > > On Jul 20, 2023, at 03:36, Sergio Had wrote: > > > > > > P. S. I wonder now if the current SDL2 gonna build with X11 backend and > Cocoa off. Given that upstream concentrated efforts on skillfully breaking > Cocoa beyond repair, everything else might be intact. > >> On Jul 20, 2023 07:15 +0800, Ken Cunningham < > ken.cunningham.web...@gmail.com>, wrote: > >> As far as I know, we don't have any ports that use SDL2 via > X11/Xquartz. All the ports use the Cocoa interface. > >> > >> The modifications that were made to SDL2 by miniupnp to run on Tiger > and Leopard were fairly extensive, to an older version of SDL2, but they > worked to allow a number of ports that required libsdl2 to work on those > systems. I have those mods tucked away in the archives of the TigerPorts > and LeopardPorts repos. > >> > >> Any newer version of libsdl2/SDL2 was not able to be adjusted to be > useful on those older systems. We did have one newer version that would > build, but was so broken by the hacks needed to make it build that it was > useless in practical use. > >> > >> Which brings me to the next point. > >> > >> It is quite possible to make hacks/patches to software that will allow > it to build -- at an extreme, you and #if 0 / #endif out that entire > source, and it will compile just fine. > >> > >> But especially for things like SDL2, what is needed is more than that > -- you have to see if software built against such patched versions will > actually work, and this sometimes takes some fairly extensive testing to > see what the warts might be. > >> > >> > >> > >> Ken > >> > >> > >> > >>> On Jul 19, 2023, at 8:32 AM, Sergey Fedorov > wrote: > >>> > >>> libsdl 2.0.22 (our Snow Leopard port) builds on PowerPC with > unoffensive fixes, however I had to disable cocoa video and joystick for > that. > >>> They are likely fixable (though no idea whether and how they gonna > work), but at least cocoa video gonna require a massive rewrite – or > perhaps falling back to an earlier implementation. (Well, this is not a > kind of code I can genuinely rewrite – only adapt patches and maybe improve > something a bit.) > >>> > >>> However, if X11 implementation is a meaningful replacement, it builds > fine with no trickery. > >>> > >>> Any thoughts? > >>> > >>> P. S. ICE on hidapi is trivially fixable – I just reverted a commit > which has broken that. After that, hidapi builds fine. > >> >
macports-legacy-support PR 61 could be the end of Tiger support for MacPorts....
Some interested users discovered a deficiency in a part of legacy-support’s fdopendir implementation, and have come up with a fix. due to the way the system on 10.4 works, however, it looks like this fix will not work on Tiger. Unless someone comes up with a trick for this, this could be the end of Tiger support for MacPorts. We all know this is coming one day, but there are some dedicated Tiger users out there who will be disappointed by this. Ken