Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to build with GDAL 3.8.0 #32

Closed
sebastic opened this issue Nov 8, 2023 · 1 comment
Closed

Fails to build with GDAL 3.8.0 #32

sebastic opened this issue Nov 8, 2023 · 1 comment

Comments

@sebastic
Copy link
Contributor

sebastic commented Nov 8, 2023

As reported in Debian Bug #1055602:

Your package FTBFS with GDAL 3.8.0 from experimental:

g++ -Wall -fPIC -DUSE_CPL -DGRASS_GISBASE=\"/usr/lib/grass83\" -I/usr/include/gdal -I/usr/lib/grass83/include -I/usr/include/postgresql -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/libgdal-grass-1.0.2=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -c -o ogrgrasslayer.o ogrgrasslayer.cpp
In file included from /usr/include/gdal/ogr_geometry.h:36,
                 from /usr/include/gdal/ogr_feature.h:36,
                 from /usr/include/gdal/ogrsf_frmts.h:35,
                 from ogrgrass.h:33,
                 from ogrgrassdriver.cpp:29:
/usr/include/gdal/cpl_json.h:97:36: error: expected ')' before 'nVal'
   97 |     explicit CPLJSONObject(uint64_t nVal);
      |                           ~        ^~~~~
      |                                    )
/usr/include/gdal/cpl_json.h:119:41: error: 'uint64_t' has not been declared
  119 |     void Add(const std::string &osName, uint64_t nValue);
      |                                         ^~~~~~~~
/usr/include/gdal/cpl_json.h:119:10: error: 'void CPLJSONObject::Add(const std::string&, int)' cannot be overloaded with 'void CPLJSONObject::Add(const std::string&, int)'
  119 |     void Add(const std::string &osName, uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:117:10: note: previous declaration 'void CPLJSONObject::Add(const std::string&, int)'
  117 |     void Add(const std::string &osName, int nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:131:41: error: 'uint64_t' has not been declared
  131 |     void Set(const std::string &osName, uint64_t nValue);
      |                                         ^~~~~~~~
/usr/include/gdal/cpl_json.h:131:10: error: 'void CPLJSONObject::Set(const std::string&, int)' cannot be overloaded with 'void CPLJSONObject::Set(const std::string&, int)'
  131 |     void Set(const std::string &osName, uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:129:10: note: previous declaration 'void CPLJSONObject::Set(const std::string&, int)'
  129 |     void Set(const std::string &osName, int nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:245:14: error: 'uint64_t' has not been declared
  245 |     void Add(uint64_t nValue);
      |              ^~~~~~~~
/usr/include/gdal/cpl_json.h:245:10: error: 'void CPLJSONArray::Add(int)' cannot be overloaded with 'void CPLJSONArray::Add(int)'
  245 |     void Add(uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:243:10: note: previous declaration 'void CPLJSONArray::Add(int)'
  243 |     void Add(int nValue);
      |          ^~~
In file included from /usr/include/gdal/ogr_geometry.h:36,
                 from /usr/include/gdal/ogr_feature.h:36,
                 from /usr/include/gdal/ogrsf_frmts.h:35,
                 from ogrgrass.h:33,
                 from ogrgrassdatasource.cpp:30:
/usr/include/gdal/cpl_json.h:97:36: error: expected ')' before 'nVal'
   97 |     explicit CPLJSONObject(uint64_t nVal);
      |                           ~        ^~~~~
      |                                    )
/usr/include/gdal/cpl_json.h:119:41: error: 'uint64_t' has not been declared
  119 |     void Add(const std::string &osName, uint64_t nValue);
      |                                         ^~~~~~~~
/usr/include/gdal/cpl_json.h:119:10: error: 'void CPLJSONObject::Add(const std::string&, int)' cannot be overloaded with 'void CPLJSONObject::Add(const std::string&, int)'
  119 |     void Add(const std::string &osName, uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:117:10: note: previous declaration 'void CPLJSONObject::Add(const std::string&, int)'
  117 |     void Add(const std::string &osName, int nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:131:41: error: 'uint64_t' has not been declared
  131 |     void Set(const std::string &osName, uint64_t nValue);
      |                                         ^~~~~~~~ 
/usr/include/gdal/cpl_json.h:131:10: error: 'void CPLJSONObject::Set(const std::string&, int)' cannot be overloaded with 'void CPLJSONObject::Set(const std::string&, int)'
  131 |     void Set(const std::string &osName, uint64_t nValue);
      |          ^~~                        
/usr/include/gdal/cpl_json.h:129:10: note: previous declaration 'void CPLJSONObject::Set(const std::string&, int)'
  129 |     void Set(const std::string &osName, int nValue);
      |          ^~~                             
/usr/include/gdal/cpl_json.h:245:14: error: 'uint64_t' has not been declared
  245 |     void Add(uint64_t nValue);
      |              ^~~~~~~~
/usr/include/gdal/cpl_json.h:245:10: error: 'void CPLJSONArray::Add(int)' cannot be overloaded with 'void CPLJSONArray::Add(int)'
  245 |     void Add(uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:243:10: note: previous declaration 'void CPLJSONArray::Add(int)'
  243 |     void Add(int nValue);
      |          ^~~
In file included from /usr/include/gdal/ogr_geometry.h:36,
                 from /usr/include/gdal/ogr_feature.h:36,
                 from /usr/include/gdal/ogrsf_frmts.h:35,
                 from ogrgrass.h:33,
                 from ogrgrasslayer.cpp:31:
/usr/include/gdal/cpl_json.h:97:36: error: expected ')' before 'nVal'
   97 |     explicit CPLJSONObject(uint64_t nVal);
      |                           ~        ^~~~~
      |                                    )
/usr/include/gdal/cpl_json.h:119:41: error: 'uint64_t' has not been declared
  119 |     void Add(const std::string &osName, uint64_t nValue);
      |                                         ^~~~~~~~
/usr/include/gdal/cpl_json.h:119:10: error: 'void CPLJSONObject::Add(const std::string&, int)' cannot be overloaded with 'void CPLJSONObject::Add(const std::string&, int)'
  119 |     void Add(const std::string &osName, uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:117:10: note: previous declaration 'void CPLJSONObject::Add(const std::string&, int)'
  117 |     void Add(const std::string &osName, int nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:131:41: error: 'uint64_t' has not been declared
  131 |     void Set(const std::string &osName, uint64_t nValue);
      |                                         ^~~~~~~~
/usr/include/gdal/cpl_json.h:131:10: error: 'void CPLJSONObject::Set(const std::string&, int)' cannot be overloaded with 'void CPLJSONObject::Set(const std::string&, int)'
  131 |     void Set(const std::string &osName, uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:129:10: note: previous declaration 'void CPLJSONObject::Set(const std::string&, int)'
  129 |     void Set(const std::string &osName, int nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:245:14: error: 'uint64_t' has not been declared
  245 |     void Add(uint64_t nValue);
      |              ^~~~~~~~
/usr/include/gdal/cpl_json.h:245:10: error: 'void CPLJSONArray::Add(int)' cannot be overloaded with 'void CPLJSONArray::Add(int)'
  245 |     void Add(uint64_t nValue);
      |          ^~~
/usr/include/gdal/cpl_json.h:243:10: note: previous declaration 'void CPLJSONArray::Add(int)'
  243 |     void Add(int nValue);
      |          ^~~
ogrgrassdriver.cpp: In function 'void RegisterOGRGRASS()':
ogrgrassdriver.cpp:99:39: warning: 'static OGRSFDriverRegistrar* OGRSFDriverRegistrar::GetRegistrar()' is deprecated [-Wdeprecated-declarations]
   99 |     OGRSFDriverRegistrar::GetRegistrar()->RegisterDriver( poDriver );
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
/usr/include/gdal/ogrsf_frmts.h:592:34: note: declared here
  592 |     static OGRSFDriverRegistrar *GetRegistrar()
      |                                  ^~~~~~~~~~~~
ogrgrassdriver.cpp:99:57: warning: 'void OGRSFDriverRegistrar::RegisterDriver(OGRSFDriver*)' is deprecated [-Wdeprecated-declarations]
   99 |     OGRSFDriverRegistrar::GetRegistrar()->RegisterDriver( poDriver );
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
/usr/include/gdal/ogrsf_frmts.h:596:10: note: declared here
  596 |     void RegisterDriver(OGRSFDriver *poDriver)
      |          ^~~~~~~~~~~~~~

The full buildlog is attached.

libgdal-grass_1.0.2-7_amd64.build

@sebastic
Copy link
Contributor Author

sebastic commented Nov 8, 2023

This is fixed by patching GDAL: OSGeo/gdal#8682

@sebastic sebastic closed this as completed Nov 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant