Replace patch from openSUSE by the Debian one to not only build kyotocabinet with GCC >= 6 but also with GCC >= 7 (#1307706 #c15)
This commit is contained in:
parent
2ef6cad773
commit
1e16abdf7f
@ -1,4 +1,5 @@
|
|||||||
Patch from openSUSE to work around build failures with GCC >= 6 like:
|
Patch from Andreas Stührk <andy@hammerhartes.de> to work around build
|
||||||
|
failures with GCC >= 6 like:
|
||||||
|
|
||||||
In file included from kcdbext.cc:16:0:
|
In file included from kcdbext.cc:16:0:
|
||||||
kcdbext.h: In member function 'char* kyotocabinet::IndexDB::get(const char*, size_t, size_t*)':
|
kcdbext.h: In member function 'char* kyotocabinet::IndexDB::get(const char*, size_t, size_t*)':
|
||||||
@ -11,10 +12,25 @@ kcdbext.h:1281:14: error: cannot convert 'bool' to 'char*' in return
|
|||||||
return false;
|
return false;
|
||||||
^~~~~
|
^~~~~
|
||||||
|
|
||||||
|
Note that using '\0' rather nullptr (like the patch from openSUSE is
|
||||||
|
doing) just leads to new build failures with GCC >= 7 like:
|
||||||
|
|
||||||
|
In file included from kcdbext.cc:16:0:
|
||||||
|
kcdbext.h: In member function 'char* kyotocabinet::IndexDB::get(const char*, size_t, size_t*)':
|
||||||
|
kcdbext.h:1281:14: error: invalid conversion from 'char' to 'char*' [-fpermissive]
|
||||||
|
return '\0';
|
||||||
|
^~~~
|
||||||
|
In file included from kclangc.cc:17:0:
|
||||||
|
kcdbext.h: In member function 'char* kyotocabinet::IndexDB::get(const char*, size_t, size_t*)':
|
||||||
|
kcdbext.h:1281:14: error: invalid conversion from 'char' to 'char*' [-fpermissive]
|
||||||
|
return '\0';
|
||||||
|
^~~~
|
||||||
|
|
||||||
See also:
|
See also:
|
||||||
|
|
||||||
- https://bugzilla.redhat.com/show_bug.cgi?id=1307706
|
- https://bugzilla.redhat.com/show_bug.cgi?id=1307706
|
||||||
- https://build.opensuse.org/package/view_file/devel:libraries:c_c++/kyotocabinet/gcc6-fix-errors.patch?expand=1
|
- https://build.opensuse.org/package/view_file/devel:libraries:c_c++/kyotocabinet/gcc6-fix-errors.patch?expand=1
|
||||||
|
- https://bugs.debian.org/811627
|
||||||
|
|
||||||
--- kyotocabinet-1.2.76/kcdbext.h 2016-05-25 11:32:53.591866016 +0200
|
--- kyotocabinet-1.2.76/kcdbext.h 2016-05-25 11:32:53.591866016 +0200
|
||||||
+++ kyotocabinet-1.2.76/kcdbext.h 2012-05-24 18:27:59.000000000 +0200
|
+++ kyotocabinet-1.2.76/kcdbext.h 2012-05-24 18:27:59.000000000 +0200
|
||||||
@ -23,7 +39,7 @@ See also:
|
|||||||
set_error(_KCCODELINE_, BasicDB::Error::INVALID, "not opened");
|
set_error(_KCCODELINE_, BasicDB::Error::INVALID, "not opened");
|
||||||
*sp = 0;
|
*sp = 0;
|
||||||
- return false;
|
- return false;
|
||||||
+ return '\0';
|
+ return nullptr;
|
||||||
}
|
}
|
||||||
if (!cache_) return db_.get(kbuf, ksiz, sp);
|
if (!cache_) return db_.get(kbuf, ksiz, sp);
|
||||||
size_t dvsiz = 0;
|
size_t dvsiz = 0;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
Summary: A straightforward implementation of DBM
|
Summary: A straightforward implementation of DBM
|
||||||
Name: kyotocabinet
|
Name: kyotocabinet
|
||||||
Version: 1.2.76
|
Version: 1.2.76
|
||||||
Release: 12%{?dist}
|
Release: 13%{?dist}
|
||||||
License: GPLv3
|
License: GPLv3
|
||||||
Group: Applications/Databases
|
Group: Applications/Databases
|
||||||
URL: http://fallabs.com/%{name}/
|
URL: http://fallabs.com/%{name}/
|
||||||
@ -135,7 +135,9 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
|
|
||||||
%files libs
|
%files libs
|
||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
%doc ChangeLog COPYING FOSSEXCEPTION LINKEXCEPTION
|
%{!?_licensedir:%global license %%doc}
|
||||||
|
%license COPYING FOSSEXCEPTION LINKEXCEPTION
|
||||||
|
%doc ChangeLog
|
||||||
%{_libdir}/libkyotocabinet.so.*
|
%{_libdir}/libkyotocabinet.so.*
|
||||||
|
|
||||||
%files devel
|
%files devel
|
||||||
@ -170,6 +172,10 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
%doc COPYING doc/api/* kyotocabinet.idl
|
%doc COPYING doc/api/* kyotocabinet.idl
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sun Feb 12 2017 Robert Scheck <robert@fedoraproject.org> 1.2.76-13
|
||||||
|
- Replace patch from openSUSE by the Debian one to not only build
|
||||||
|
kyotocabinet with GCC >= 6 but also with GCC >= 7 (#1307706 #c15)
|
||||||
|
|
||||||
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.76-12
|
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.76-12
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user