Merge pull request #242094 from reckenrode/djvulibre-clang16
djvulibre: fix build with clang 16
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
diff -ur a/libdjvu/GBitmap.h b/libdjvu/GBitmap.h
|
||||
--- a/libdjvu/GBitmap.h 2020-11-20 09:57:32.000000000 -0700
|
||||
+++ b/libdjvu/GBitmap.h 2023-07-07 07:07:45.519912414 -0600
|
||||
@@ -620,7 +620,7 @@
|
||||
inline int
|
||||
GBitmap::read_run(unsigned char *&data)
|
||||
{
|
||||
- register int z=*data++;
|
||||
+ int z=*data++;
|
||||
return (z>=RUNOVERFLOWVALUE)?
|
||||
((z&~RUNOVERFLOWVALUE)<<8)|(*data++):z;
|
||||
}
|
||||
@@ -628,7 +628,7 @@
|
||||
inline int
|
||||
GBitmap::read_run(const unsigned char *&data)
|
||||
{
|
||||
- register int z=*data++;
|
||||
+ int z=*data++;
|
||||
return (z>=RUNOVERFLOWVALUE)?
|
||||
((z&~RUNOVERFLOWVALUE)<<8)|(*data++):z;
|
||||
}
|
||||
@@ -30,6 +30,10 @@ stdenv.mkDerivation rec {
|
||||
bash
|
||||
];
|
||||
|
||||
# Remove uses of the `register` storage class specifier, which was removed in C++17.
|
||||
# Fixes compilation with clang 16, which defaults to C++17.
|
||||
patches = [ ./c++17-register-class.patch ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with lib; {
|
||||
|
||||
Reference in New Issue
Block a user