[MacPorts] #72471: djvulibre @ 3.5.28: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
MacPorts
noreply at macports.org
Tue May 13 02:53:09 UTC 2025
#72471: djvulibre @ 3.5.28: error: ISO C++17 does not allow 'register' storage
class specifier [-Wregister]
----------------------+-----------------------
Reporter: acjones8 | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.10.7
Keywords: | Port: djvulibre
----------------------+-----------------------
Aloha everyone,
I was building djvulibre as a dependency for emacs-mac-app, and the build
failed with a compliant about C++17 no longer allowing the register
keyword to be used. I'm using macports-clang-20 as my compiler for
Macports on MacOS 15, with an M4 Mac Mini if that helps. I'll paste the
exact error messages below:
{{{
In file included from GBitmap.cpp:63:
./GBitmap.h:623:3: error: ISO C++17 does not allow 'register' storage
class specifier [-Wregister]
623 | register int z=*data++;
| ^~~~~~~~
./GBitmap.h:631:3: error: ISO C++17 does not allow 'register' storage
class specifier [-Wregister]
631 | register int z=*data++;
| ^~~~~~~~
In file included from DjVuToPS.cpp:71:
./GBitmap.h:623:3: error: ISO C++17 does not allow 'register' storage
class specifier [-Wregister]
623 | register int z=*data++;
| ^~~~~~~~
./GBitmap.h:631:3: error: ISO C++17 does not allow 'register' storage
class specifier [-Wregister]
631 | register int z=*data++;
| ^~~~~~~~
}}}
My understanding is the permanent fix might be to submit a patch that
removes the use of the register keyword, but in the meantime, I wonder if
setting the port to an older C++ standard version might work? I'll give
that a try soon...
--
Ticket URL: <https://trac.macports.org/ticket/72471>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list