Skip to content

Commit

Permalink
ctest: fix building on apple silicone
Browse files Browse the repository at this point in the history
  • Loading branch information
mochaaP committed Oct 11, 2024
1 parent 7adb592 commit 5d1e96a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions misc/tests/ctest.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,11 @@ struct ctest {
#define CTEST_IMPL_TEARDOWN_TPNAME(sname, tname) CTEST_IMPL_NAME(sname##_##tname##_teardown_ptr)

#ifdef __APPLE__
#ifdef __arm64__
#define CTEST_IMPL_SECTION __attribute__ ((used, section ("__DATA, .ctest"), aligned(8)))
#else
#define CTEST_IMPL_SECTION __attribute__ ((used, section ("__DATA, .ctest"), aligned(1)))
#endif
#elif !defined _MSC_VER
#define CTEST_IMPL_SECTION __attribute__ ((used, section (".ctest"), aligned(1)))
#else
Expand Down

0 comments on commit 5d1e96a

Please sign in to comment.