35 Commits (537cdad99e973278c7e38cdb31951ea857a6384f)

Author SHA1 Message Date
Miloš Komarčević 8d06265470 Fix MinGW build for Ninja generator 4 years ago
Luis Díaz Más 30773c92a3 WIN32_LEAN_AND_MEAN propagated with exiv2lib target 5 years ago
Robin Mills a82bcebaab fix_cygwin_stack_protection_0.27 5 years ago
Luis Diaz Mas bfd0e0593b Use check_cxx_compiler_flags instead of C version 5 years ago
Robin Mills 0005edf2f9 fix_solaris_stack_protection_0.27 5 years ago
Thomas Petazzoni bbe0b70840
Properly detect availability of flags in cmake/compilerFlags.cmake (#1252)
Instead of relying on fragile and complex logic to decide if a
compiler flag is available or not, use the check_c_compiler_flag()
macro provided by the CMake standard library.

This for example avoids using -fcf-protection on architectures that
don't support this option.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>

(cherry picked from commit dd2d181755a6e642c0a8e3225ef5407fff49eb3a)

When resolving the conflict from applying the patch, I also took the liberty
of re-indenting the snippet correcly and fixing mismatching
HAS_FCF_PROTECTION and HAS_FSTACK_PROTECTOR_STRONG variables
(the conditionals used GCC_ prefix but the variables were definded without it).

Signed-off-by: Jan Tojnar <jtojnar@gmail.com>
5 years ago
Luis Díaz Más 6667e13c4b Only use __cplusplus trick from VS2017 5 years ago
clanmills 4511817028 MSVC Changes. Leave CMake to set /std:. Only set /Zc:__cplusplus for VS2019+. Updated README.md 5 years ago
Robin Mills cd5512e761 WIP. C++11 support 5 years ago
clanmills b22d1de8b1 Remove add_compile_options(-std=gnu++98) 5 years ago
clanmills 65dde52cf9 Updated documentation. Removed -DEXIV2_BUILD_USE_C++11 5 years ago
clanmills 63a13e8620 Adding option -DEXIV2_BUILD_USE_C++11 5 years ago
Robin Mills c51a8aa8ed Explicitly set compiler option -std=gnu++98 on Solaris 5 years ago
clanmills 5f36bf46e8 Fix for issue identified in #1175 5 years ago
clanmills b50d6503bc fix_1102_msysGCC93_0.27 5 years ago
clanmills 13565be3d2 Change for solaris. 5 years ago
Robin Mills d3444d4547 fix_GCC48 5 years ago
Luis Diaz a62e35edb6 Remove compiler flag which is causing issues in Fedora_MinGW 6 years ago
Luis Diaz 907a5aef3b clang guard for -fstack-protector-strong 6 years ago
Luis Díaz Más 9a0889c744 FORTIFY not used on OSX 6 years ago
Luis Díaz Más 006dcde403 Better usage of --coverage flags 6 years ago
Luis Díaz Más 9c7c3c6d22 Allow to use new compiler flags in clang 6 years ago
Luis Díaz Más 1fa5839c8e cmake: use add_compile_option & add new security flags
- Replacement of CMAKE_CXX_FLAGS by add_compile_option where it was
  possible
- Addition of new compiler flags which are interesting in terms of
  software security
- Do not mix coverage flags with -O0 and -g
6 years ago
Robin Mills c32b413f74 Fix: https://github.com/Exiv2/exiv2/issues/575 7 years ago
Luis Díaz Más f92030d650 CMake: remove XMPSRC variable. 7 years ago
Luis Diaz Mas d6c6d469a9 CMake: Use add_definitions instead of add_compile_definitions 7 years ago
Luis Díaz Más 38ed6de05d MSVC: Move compile definitions from config.h to CMake.
+ Also remove inclusion of <Windows.h> from config.h
7 years ago
Luis Díaz Más 274ef04f7e CMake: Proper way to require c++98 standard 7 years ago
Robin Mills 42084f2563 Add support for MinGW/msys2 in 32 bits + Updates in buildserver 7 years ago
Luis Díaz Más dc086d2ebb Default to /MD(d) even for STATIC builds.
We had issues to compile exiv2 due to a undefined symbol referenced in expat.lib (Explained in #487).
Static builds in Windows need to use msvcrt.lib where the missing symbol ("__imp__mbspbrk") was
defined. We can still decide to use the STATIC CRT  library by using:

cmake -DBUILD_SHARED_LIBS=OFF -DEXIV2_ENABLE_DYNAMIC_RUNTIME=OFF
7 years ago
Luis Díaz Más a6d82633c3 Enable WARNINGS_AS_ERRORS in CI jobs.
- Move the settings to other cmake file. This will not be used for XMP code
- Disable WARNINGS_AS_ERRORS for VS2008 and VS2010
7 years ago
Dan Čermák 10929cec7a [CMake] Add EXIV2_TEAM_USE_SANITIZERS option
Setting this option enables address sanitizer and undefined behavior
sanitizer, when available for the given compiler & platform.
It does not currently check whether the architecture is supported,
as CMake does not offer an easy way how to check it. Since we are
mostly developing for x86 & amd64 this is not a huge problem and it's
also a developer only setting.
7 years ago
Luis Diaz Mas 6521f7c4f9 cmake: new option to enable compilations with coverage flags
Note that this will only work with gcc and clang.
7 years ago
Luis Díaz Más 5eee072089 Enable clcache usage and use it in appveyor
* [appveyor] Install clcache with nuget
* [appveyor] Keep clcache in the appveyor jobs
* [appveyor] Print clcache stats after compiling the project
* Use CLCACHE_PATH env variable to find clcache
7 years ago
Luis Diaz Mas a3444f055e Rename config folder to cmake 7 years ago