forked from Unity-Technologies/crunch
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
crnlib: make CRNLIB_FORCE_INLINE functions extern because the compile…
…r will override anyway Avoids errors on macOS like: duplicate symbol __ZN6crnlib5utils10write_le64EPvy in: crn_arealist.o crn_assert.o Setting static instead of extern would also workaround the error but it's wrong and would raise warnings on other systems like FreeBSD: In file included from crunch/crnlib/crn_core.h:174: crunch/crnlib/crn_utils.h:235:8: warning: 'gnu_inline' attribute without 'extern' in C++ treated as externally available, this changed in Clang 10 [-Wgnu-inline-cpp-without-extern] static CRNLIB_FORCE_INLINE void write_be64(void* p, uint64 x) { ^ crunch/crnlib/crn_core.h:85:70: note: expanded from macro 'CRNLIB_FORCE_INLINE' #define CRNLIB_FORCE_INLINE inline __attribute__((__always_inline__, __gnu_inline__)) ^ Setting extern fixes the duplicate symbols error on macOS without introducing warnings on FreeBSD.
- Loading branch information
Showing
1 changed file
with
23 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters