5 ms·
Well, yeah, for maintained upstreams. I sometimes need to build older versions of software and simply use unmaintained software, for which these changes are a b
by mid-kid 2y ago
Well, yeah, for maintained upstreams. I sometimes need to build older versions of software and simply use unmaintained software, for which these changes are a bit of a pain, along with -fno-common before it.
- mikepurvis 2y agoAt a certain point, it's probably easier to build and run the unmaintained software in a container running an OS of corresponding vintage. Obviously that has security ramifications, but hopefully this software isn't facing the internet and being in a container at least means you're on a modern kernel and can isolate things at a port and filesystem level.
- withzombies 2y agoDebian is super good for this. Most of their apt mirrors are still up and running, so you can easily download and build software from 2002 if you use the appropriate Debian release to do it. I usually do this first to make sure the software builds and works, then I try to figure out how to get it working on a newer OS.
- mid-kid 2y agoYou're right, but it's also significantly more inconvenient.
- cozzyd 2y agoit would be nice if they provided a gcc-ancient-compat or something though it's easy enough to create an alias with the correct flags.
- Phyx 2y ago-std=gnu98 works. ie explicitly telling it your code is not modern C.
- mid-kid 2y agoThe new flags apply regardless of -std value, as does -fno-common
- Phyx 2y agoUhh no they don't, and it's explicitly documented under https://gcc.gnu.org/gcc-14/porting_to.html https://gcc.gnu.org/gcc-14/porting_to.html in "Turning errors back into warnings". Futher more every warning Explains why the std value affects them.