Allow Statically Linking in Go (#2067)

* unset -L and -rpath from CGO_LDFLAGS

Signed-off-by: Pedro Tôrres <t0rr3sp3dr0@gmail.com>

* allow go statically linking

Signed-off-by: Pedro Tôrres <t0rr3sp3dr0@gmail.com>

* fix setup.py

---------

Signed-off-by: Pedro Tôrres <t0rr3sp3dr0@gmail.com>
Co-authored-by: mio <mio@lazym.io>
This commit is contained in:
Pedro Tôrres
2024-12-20 19:02:28 -08:00
committed by GitHub
parent 7737e7b436
commit 2899088844
7 changed files with 33 additions and 76 deletions

View File

@@ -1515,6 +1515,7 @@ if(UNICORN_INSTALL AND NOT MSVC)
)
endif()
install(FILES $<TARGET_FILE:unicorn_archive> DESTINATION ${CMAKE_INSTALL_LIBDIR})
install(FILES $<TARGET_FILE_DIR:unicorn_archive>/$<TARGET_PROPERTY:unicorn_archive,SYMLINK_NAME> DESTINATION ${CMAKE_INSTALL_LIBDIR})
install(FILES ${UNICORN_HEADERS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/unicorn)
if (ATOMIC_LINKAGE_FIX)
set(ATOMIC_LINK_PKG_CONFIG " -latomic")