forked from pool/doxygen
- Add reproducible.patch to make doxytags output reproducible (boo#1201579)
OBS-URL: https://build.opensuse.org/package/show/devel:tools/doxygen?expand=0&rev=198
This commit is contained in:
parent
821beef252
commit
5228d02d93
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Jul 17 17:14:00 UTC 2023 - Bernhard Wiedemann <bwiedemann@suse.com>
|
||||
|
||||
- Add reproducible.patch to make doxytags output reproducible (boo#1201579)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Apr 24 12:16:18 UTC 2023 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
|
@ -39,6 +39,7 @@ Patch20: https://github.com/doxygen/doxygen/commit/966d69c603b5.patch#/Fi
|
||||
Patch21: https://github.com/doxygen/doxygen/commit/7b2a6027775b.patch#/Fix-boundingbox-parsing_part2.patch
|
||||
Patch22: https://github.com/doxygen/doxygen/commit/f3514d578633.patch#/Fix-boundingbox-parsing_part3.patch
|
||||
Patch23: https://github.com/doxygen/doxygen/commit/8129939c312e.patch#/Fix-boundingbox-parsing_part4.patch
|
||||
Patch24: reproducible.patch
|
||||
BuildRequires: bison
|
||||
BuildRequires: cmake >= 2.8.12
|
||||
BuildRequires: flex
|
||||
@ -77,6 +78,7 @@ as well.
|
||||
%patch21 -p1
|
||||
%patch22 -p1
|
||||
%patch23 -p1
|
||||
%patch24 -p1
|
||||
|
||||
%build
|
||||
%cmake \
|
||||
|
75
reproducible.patch
Normal file
75
reproducible.patch
Normal file
@ -0,0 +1,75 @@
|
||||
Index: doxygen-1.9.6/filesystem/filesystem.hpp
|
||||
===================================================================
|
||||
--- doxygen-1.9.6.orig/filesystem/filesystem.hpp
|
||||
+++ doxygen-1.9.6/filesystem/filesystem.hpp
|
||||
@@ -5548,12 +5548,13 @@ public:
|
||||
impl(const path& path, directory_options options)
|
||||
: _base(path)
|
||||
, _options(options)
|
||||
- , _dir(nullptr)
|
||||
+ , _namelist(nullptr)
|
||||
+ , _namelisti(-1)
|
||||
, _entry(nullptr)
|
||||
{
|
||||
if (!path.empty()) {
|
||||
- _dir = ::opendir(path.native().c_str());
|
||||
- if (!_dir) {
|
||||
+ _namelisti = _namelistn = ::scandir(path.native().c_str(), &_namelist, NULL, alphasort);
|
||||
+ if (_namelistn == -1) {
|
||||
auto error = errno;
|
||||
_base = filesystem::path();
|
||||
if ((error != EACCES && error != EPERM) || (options & directory_options::skip_permission_denied) == directory_options::none) {
|
||||
@@ -5568,19 +5569,23 @@ public:
|
||||
impl(const impl& other) = delete;
|
||||
~impl()
|
||||
{
|
||||
- if (_dir) {
|
||||
- ::closedir(_dir);
|
||||
+ if (_namelist) {
|
||||
+ for (int i=_namelistn-1; i>=0; i--) {
|
||||
+ free(_namelist[i]);
|
||||
+ }
|
||||
+ free(_namelist);
|
||||
+ _namelist = nullptr;
|
||||
}
|
||||
}
|
||||
void increment(std::error_code& ec)
|
||||
{
|
||||
- if (_dir) {
|
||||
+ if (_namelist) {
|
||||
bool skip;
|
||||
do {
|
||||
skip = false;
|
||||
errno = 0;
|
||||
- _entry = ::readdir(_dir);
|
||||
- if (_entry) {
|
||||
+ if (_namelisti > 0 ) {
|
||||
+ _entry = _namelist[--_namelisti];
|
||||
_dir_entry._path = _base;
|
||||
_dir_entry._path.append_name(_entry->d_name);
|
||||
copyToDirEntry();
|
||||
@@ -5590,8 +5595,11 @@ public:
|
||||
}
|
||||
}
|
||||
else {
|
||||
- ::closedir(_dir);
|
||||
- _dir = nullptr;
|
||||
+ for (int i=_namelistn-1; i>=0; i--) {
|
||||
+ free(_namelist[i]);
|
||||
+ }
|
||||
+ free(_namelist);
|
||||
+ _namelist = nullptr;
|
||||
_dir_entry._path.clear();
|
||||
if (errno) {
|
||||
ec = detail::make_system_error();
|
||||
@@ -5634,7 +5642,9 @@ public:
|
||||
}
|
||||
path _base;
|
||||
directory_options _options;
|
||||
- DIR* _dir;
|
||||
+ int _namelisti;
|
||||
+ int _namelistn;
|
||||
+ struct dirent **_namelist;
|
||||
struct ::dirent* _entry;
|
||||
directory_entry _dir_entry;
|
||||
std::error_code _ec;
|
Loading…
Reference in New Issue
Block a user