Bug 440091 - htmlparser doctypes.gperf ISO C++17 does not allow 'register' storage class specifier
Summary: htmlparser doctypes.gperf ISO C++17 does not allow 'register' storage class s...
Status: RESOLVED NOT A BUG
Alias: None
Product: frameworks-khtml
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: MacPorts macOS
: NOR normal
Target Milestone: ---
Assignee: Martin Sandsmark
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-07-20 23:58 UTC by Kurt Hindenburg
Modified: 2021-09-24 08:48 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kurt Hindenburg 2021-07-20 23:58:54 UTC
I build KF5 from current source.  This is the first git change that doesn't build  8540c72b29cc48e9e6ba14807e4e6180e3f62fce which is confusing to me.  I would have assume it as the 2 earlier registry changes that would have caused it: 9901089fd067b361583b165727ff56107dcd3b87 and b8a1f65d07c58f57e83f2a50344a374de137410b

AppleClang 12.0.5.12050022; 


In file included from /Volumes/Devel/KDE/src/frameworks/khtml/src/html/htmlparse
r.cpp:67:
/Volumes/Devel/KDE/src/frameworks/khtml/src/html/doctypes.gperf:33:21: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
Perfect_Hash::hash (register const char *str, register unsigned int len)
                    ^~~~~~~~~
/Volumes/Devel/KDE/src/frameworks/khtml/src/html/doctypes.gperf:33:47: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
Perfect_Hash::hash (register const char *str, register unsigned int len)
                                              ^~~~~~~~~
/Volumes/Devel/KDE/src/frameworks/khtml/src/html/doctypes.gperf:64:3: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
  register unsigned int hval = len;
  ^~~~~~~~~
/Volumes/Devel/KDE/src/frameworks/khtml/src/html/doctypes.gperf:313:33: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
Perfect_Hash::findDoctypeEntry (register const char *str, register unsigned int len)
   /Volumes/Devel/KDE/src/frameworks/khtml/src/html/doctypes.gperf:313:33: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
Perfect_Hash::findDoctypeEntry (register const char *str, register unsigned int len)
                                ^~~~~~~~~
/Volumes/Devel/KDE/src/frameworks/khtml/src/html/doctypes.gperf:313:59: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
Perfect_Hash::findDoctypeEntry (register const char *str, register unsigned int len)
                                                          ^~~~~~~~~
/Volumes/Devel/KDE/src/frameworks/khtml/src/html/doctypes.gperf:81:11: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
          register const char *s = wordlist[key].name;                             ^~~~~~~~~
Comment 1 Nicolas Fella 2021-07-21 17:49:38 UTC
Most likely your gperf version is too old and hasn't got the relevant C++17 fix yet
Comment 2 Kurt Hindenburg 2021-07-21 18:46:08 UTC
Is gperf from outside KF5?  I don't have it installed anywhere that I can find.
Comment 3 Nicolas Fella 2021-07-21 18:47:59 UTC
yes, gperf is an external thing

I did find https://ports.macports.org/port/gperf/
Comment 4 Kurt Hindenburg 2021-07-21 18:52:43 UTC
Yes, but I don't have it installed.
Comment 5 Dawid Wróbel 2021-09-24 08:48:42 UTC
I can confirm that this is an issue with gperf 3.0.3 shipped by default with macOS, up to the current Big Sur 1.6 (20G165). That version was released in 2007 (!):  http://ftp.gnu.org/pub/gnu/gperf

Please install gperf 3.1 (from 2017) with brew or macPorts.