Add LIEF-backed exports command and integrate LIEF into build, CI, and packaging - #5
Add LIEF-backed exports command and integrate LIEF into build, CI, and packaging#5YSaxon wants to merge 3 commits into
exports command and integrate LIEF into build, CI, and packaging#5Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8859c43d50
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| sed -i 's|^compiler\.libcxx\s*=.*|compiler.libcxx=c++_shared|' "$PROFILE_PATH" | ||
| else | ||
| printf '\ncompiler.libcxx=c++_shared\n' >> "$PROFILE_PATH" |
There was a problem hiding this comment.
Stop forcing Android builds to use c++_shared
Setting compiler.libcxx to c++_shared makes the Android cliffi/test binaries depend on libc++_shared.so, but the Android test flow only pushes cliffi, libcliffi_test.so, and cliffi_unit_tests to /data/local/tmp (see prepare_and_test_via_adb.sh), so emulator runs can fail at process startup with a missing runtime library. This regression is specific to Android jobs in the dockcross workflow and can break those builds/tests even before any test logic runs.
Useful? React with 👍 / 👎.
Motivation
exportsworks on distributed builds and installs.Description
src/export_symbols.cppandsrc/export_symbols.hthat implementlist_exported_symbols_with_lief()with a no-op fallback if LIEF is not available.parseListExports()and anexports <library>branch insrc/main.cand documented the command inREADME.mdwith an example usage line.CMakeLists.txtto enable C++ language, include the new source file, make LIEF optional viapkg_search_moduleandfind_package, exposeCLIFFI_HAS_LIEFcompile definition, and propagate includes/links into the test and executable targets.liefto Homebrew formulacliffi.rb, addedlief/0.16.2toconanfile.txt, addedliefinstallation to.github/workflows/dockcross.ymland.github/workflows/mac.yml, and added Android libc++ handling inprofile_script.sh.Testing
cmake -B build -DCMAKE_BUILD_TYPE=Releaseandcmake --build buildto ensure the project compiles with the new source and C++ enabled.cliffi_unit_teststarget and executed viactest --output-on-failurein CI configurations to validate behavior (unit test target built and run as part of CIcteststep).ctest --output-on-failureon macOS builds (configured in the workflows), and the configured CTest runs completed successfully in those CI jobs.Codex Task