Commit Graph

8977 Commits

Author SHA1 Message Date
Rosen Penev
5d11711db8 meson CI: add FreeBSD
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-04-04 11:23:17 -07:00
Rosen Penev
c42c7fa9ac meson: build iconv with FreeBSD
Bug was fixed.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-04-04 11:23:17 -07:00
Rosen Penev
9322f137aa don't compile WIN32 stuff when iconv is present
MinGW has iconv, so this block of code can go away.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-04-04 06:58:23 -07:00
Rosen Penev
b10f2d3e95 geotag: fix compilation with MSYS
using namespace std interferes with windows.h

stat defines interfere with internal headers.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-04-04 06:54:09 -07:00
Rosen Penev
cfc0ef0b65 meson: fix tests when zlib is disabled
This sometimes shows up in CI if zlib is not found.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-04-04 06:53:11 -07:00
Rosen Penev
3633f8d2c2 clang-tidy: remove const from data members
Found with cppcoreguidelines-avoid-const-or-ref-data-members

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-04-03 06:53:25 -07:00
Rosen Penev
233f404ac7 direct initialize some structs
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-04-03 06:51:13 -07:00
Miloš Komarčević
0dd06894b3 makernotes: workaround for Olympus header corruption 2023-03-30 12:09:23 -07:00
Miloš Komarčević
3403dabec2 Add Sony ZV-E1 ID 2023-03-29 10:29:15 -07:00
Miloš Komarčević
2f01f70eaf Add some more Nikon Z lenses 2023-03-29 10:02:32 -07:00
Rosen Penev
0fa22ed55d remove codecvt
Deprecated in C++17

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-27 06:28:11 -07:00
Rosen Penev
2e33dad1d1 easyaccess const changes
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-26 08:17:33 -07:00
Rosen Penev
b92b121532 meson: remove now unused checks
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-25 08:04:14 -07:00
Rosen Penev
632536a55a meson: build samples
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-25 08:04:14 -07:00
Rosen Penev
848da172da make runner.py executable
Otherwise meson will not find it.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-25 08:04:14 -07:00
Rosen Penev
0c0dabfcc7 geotag: add GCC7 support
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-25 08:04:14 -07:00
Rosen Penev
357d970425 get rid of EXV_CALL_MEMBER_FN
std::invoke can be used.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-25 08:03:39 -07:00
Eli Schwartz
2108ae671a meson: compile convert.cpp separately, with just iconv
Compiling this file with all dependencies as part of the main library
causes it to have the include directories of all dependencies, but iconv
is a bit of a special case: it can have a libc builtin or an external
library version. The external library might be installed to the same
directory as other dependencies, for example on FreeBSD -- but if exiv2
is not supposed to be built with GNU libiconv, then it will expect to
see the libc builtin.

The leaky include directories means that iconv.h gets pulled in from the
GNU libiconv version instead, though, which then forces -liconv to be
necessary for no reason.

There are two general solutions to ensuring that everything links
correctly:

- expect exiv2 to be built with *global* -I/usr/local/include -L/usr/local/lib
  thus forcing the use of GNU libiconv

- carefully compiling the iconv support without any other dependencies

Let's do the latter since it allows for more choice and is easier to
enforce.
2023-03-24 16:19:25 -07:00
Rosen Penev
05f2731d34 std::array removals
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-23 13:29:21 -07:00
Rosen Penev
8fe2ae6030 remove constexpr
const_iterator is not constexpr. clang 15 on MSYS2 fails to compile
because of this.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-23 13:29:21 -07:00
Rosen Penev
513b0e8bbd constexpr some constructors
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-22 06:11:10 -07:00
Rosen Penev
0aed79ff57 remove several constructors
Just direct initialize

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-22 06:11:10 -07:00
Rosen Penev
024e026bbb clang: small fixes
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-22 06:11:10 -07:00
Rosen Penev
9ae339d39f clang: fix various documentation errors
Found with -Wdocumentation

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-22 06:11:10 -07:00
Miloš Komarčević
18e11ac1b6
Explicitly include stdint (#2558) 2023-03-22 11:55:52 +01:00
Rosen Penev
22b12012a6 more SonarLint cleanups
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
d29001f2a4 clang-tidy: don't use non const refs
Found with: google-runtime-references

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
01aab49f6f don't assign an fs::path to a string
Seems to trip up MemorySanitizer on ARM32.

Also applied various simplifications to the code using std::filesystem

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
5ccb525dd3 remove inline function
Just make it part of the template

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
763cfaf2b4 MSVC warning fixes
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
1f3d1f066f extern to static
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
ca95edc6bd random fixes
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
d6c1059485 gcc: ifdef
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
0a8fedf249 gcc: noexcept
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
1f21164085 gcc: remove redundant struct
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
9a1f37ecbe get rid of Key() move operations
Because of Impl, there's no way this can work properly.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
a3baf7d3e9 clang-tidy: no _ in tests
Found with google-readability-avoid-underscore-in-googletest-name

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
e854d93841 replace enable_if with if constexpr
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
2fd523873b remove MSVC hacks
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
dc196e729e remove old MSVC workaround
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-20 08:01:22 -07:00
Rosen Penev
4a26eba0d9 fix compilation under FreeBSD
sys headers must come before libprocstat

meson is missing a libprocstat dependency. iconv is also broken with
meson and freebsd.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-19 11:08:30 -07:00
Rosen Penev
6a3025dd72 meson CI: use vc++latest
Potentially more warnings

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-18 13:08:23 -07:00
Rosen Penev
4831c65e39
Merge pull request #2551 from kevinbackhouse/fix-issue-2539
Minor refactorings to stop UBSAN from complaining
2023-03-18 12:10:45 -07:00
Kevin Backhouse
5d11208aa0
Minor refactorings to stop UBSAN from complaining. 2023-03-18 17:26:00 +00:00
Rosen Penev
66e904e61e
Merge pull request #2548 from neheb/fa
add various moves
2023-03-14 07:10:10 -07:00
Rosen Penev
e2bf207477 add various moves
More efficient

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2023-03-13 23:01:14 -07:00
Rosen Penev
518c52c2af
Merge pull request #2544 from kevinbackhouse/fix-matroska-null-pointer-deref
Check that the pointer isn't NULL
2023-03-12 08:38:48 -07:00
Kevin Backhouse
e0ac920c87
Suggestion from @neheb 2023-03-12 10:54:01 +00:00
Kevin Backhouse
244799f480 Convert tail-recursion to loop to avoid stack exhaustion. 2023-03-11 22:47:47 -08:00
Kevin Backhouse
a783320520 Use enforce, not assert, to avoid crash. 2023-03-11 21:50:33 -08:00