diff options
| author | John "Lameguy" Wilbert Villamor <lameguy64@gmail.com> | 2021-10-25 08:18:23 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-10-25 08:18:23 +0800 |
| commit | 8d17a5abe3c600b603f1910239d5df0fff9f4eed (patch) | |
| tree | 20d3110363ab468e99502337c0a46852662bb365 /libpsn00b/CMakeLists.txt | |
| parent | 0a7f59de1eb079930e7c25ad35adc39c9946958c (diff) | |
| parent | 4e0d5bceb24042a6d31c76958ce2c6157369ac68 (diff) | |
| download | psn00bsdk-8d17a5abe3c600b603f1910239d5df0fff9f4eed.tar.gz | |
Merge pull request #41 from spicyjpeg/cmake
CMake fixes, Windows build instructions
Diffstat (limited to 'libpsn00b/CMakeLists.txt')
| -rw-r--r-- | libpsn00b/CMakeLists.txt | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/libpsn00b/CMakeLists.txt b/libpsn00b/CMakeLists.txt index 52914d3..083208a 100644 --- a/libpsn00b/CMakeLists.txt +++ b/libpsn00b/CMakeLists.txt @@ -41,10 +41,17 @@ foreach(_library IN LISTS PSN00BSDK_LIBRARIES) endforeach() # Extract libgcc's contents and merge them into libc after building. +# Unfortunately glob expressions won't work on Windows, so we have to manually +# enumerate the contents of libgcc and save the list to a temporary file (as it +# is too long to be passed directly on the command line). This is actually the +# most reliable way I found to do this (I tried $<TARGET_OBJECTS> to no avail). add_custom_command( TARGET c POST_BUILD + COMMAND ${CMAKE_AR} t ${PSN00BSDK_LIBGCC} $<ANGLE-R>_libgcc.txt COMMAND ${CMAKE_AR} x ${PSN00BSDK_LIBGCC} - COMMAND ${CMAKE_AR} rsuU $<TARGET_FILE:c> *.o + COMMAND ${CMAKE_AR} q $<TARGET_FILE:c> \@_libgcc.txt + COMMAND ${CMAKE_AR} s $<TARGET_FILE:c> + #COMMAND ${CMAKE_AR} rsuU $<TARGET_FILE:c> *.o COMMENT "Merging libgcc contents into SDK libc" ) |
