Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
for wf in build-macos.yml build-windows.yml test.yml; do
key=$(echo "${wf%.*}" | tr '-' '_')
run_id=$(gh run list --repo "${{ github.repository }}" --workflow "$wf" \
--branch main --status success --json databaseId,headSha \
--branch main --status success --limit 200 --json databaseId,headSha \
--jq ".[] | select(.headSha == \"${{ github.sha }}\") | .databaseId" | head -n1)
if [ -z "$run_id" ]; then
echo "::error::No successful $wf run on main for commit ${{ github.sha }}. Push to main and wait for it to build before tagging."
Expand Down Expand Up @@ -113,6 +113,11 @@ jobs:
mkdir -p ../release-assets
zip -r ../release-assets/coverage_monero_cpp_html.zip coverage_monero_cpp_html

# to check a download against what the workflow published: sha256sum -c SHA256SUMS
- name: Checksum the assets
working-directory: release-assets
run: sha256sum -- *.deb *.whl *.zip > SHA256SUMS

- name: Create draft release
env:
GH_TOKEN: ${{ github.token }}
Expand All @@ -122,4 +127,4 @@ jobs:
--draft \
--title "${{ github.ref_name }}" \
--generate-notes \
release-assets/*.deb release-assets/*.whl release-assets/*.zip
release-assets/*.deb release-assets/*.whl release-assets/*.zip release-assets/SHA256SUMS
10 changes: 10 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -351,4 +351,14 @@ set(MONERO_PYTHON_LINK_LIBS

target_link_libraries(monero PRIVATE ${MONERO_PYTHON_LINK_LIBS})

# A python module has to export PyInit_monero and nothing else. Left to itself the linker also exports every
# symbol of the static libraries it takes in, those of monero-project and monero-cpp: about 27000 on linux, from
# 7000 to 11000 on macOS and 1100 on windows. They make the module bigger and can clash with the symbols that
# another extension of the same process brings, a boost or a protobuf for one.
if(APPLE)
target_link_options(monero PRIVATE -Wl,-dead_strip -Wl,-exported_symbol,_PyInit_monero)
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
target_link_options(monero PRIVATE -Wl,--exclude-libs,ALL -Wl,--gc-sections)
endif()

install(TARGETS monero DESTINATION .)
Loading