mirror of
https://github.com/Kitware/CMake.git
synced 2026-03-01 12:18:36 -06:00
libarchive: Workaround case-insensitive symbols on Borland
Mangle the open_FILE symbols to avoid conflict with open_file:
Warning: public '_archive_read_open_file'
in module 'archive_read_open_filename.c' clashes with
prior module 'archive_read_open_file.c'
Warning: public '_archive_write_open_file'
in module 'archive_write_open_filename.c' clashes with
prior module 'archive_write_open_file.c'
This workaround should not go upstream because it will break when
mixing compilers.
This commit is contained in:
@@ -45,6 +45,13 @@
|
||||
# include <inttypes.h>
|
||||
#endif
|
||||
|
||||
/* Borland symbols are case-insensitive. This workaround only works
|
||||
within CMake because we do not mix compilers. */
|
||||
#if defined(__BORLANDC__)
|
||||
# define archive_read_open_FILE archive_read_open_FILE_
|
||||
# define archive_write_open_FILE archive_write_open_FILE_
|
||||
#endif
|
||||
|
||||
/* Get appropriate definitions of standard POSIX-style types. */
|
||||
/* These should match the types used in 'struct stat' */
|
||||
#if defined(_WIN32) && !defined(__CYGWIN__)
|
||||
|
||||
Reference in New Issue
Block a user