bitcoin/depends/packages/native_libdmg-hfsplus.mk
Carl Dong 7476b46f18 guix: Build dmg as a static binary
This relatively easy change eliminates all runtime dependencies (except
for the kernel) for dmg, which is the only native build tool that gets
put in our output tarballs.

This allows much more flexibility when constructing the codesigning
environment, and is much more robust.
2021-04-05 11:00:39 -04:00

25 lines
880 B
Makefile

package=native_libdmg-hfsplus
$(package)_version=7ac55ec64c96f7800d9818ce64c79670e7f02b67
$(package)_download_path=https://github.com/planetbeing/libdmg-hfsplus/archive
$(package)_file_name=$($(package)_version).tar.gz
$(package)_sha256_hash=56fbdc48ec110966342f0ecddd6f8f89202f4143ed2a3336e42bbf88f940850c
$(package)_build_subdir=build
$(package)_patches=remove-libcrypto-dependency.patch
define $(package)_preprocess_cmds
patch -p1 < $($(package)_patch_dir)/remove-libcrypto-dependency.patch && \
mkdir build
endef
define $(package)_config_cmds
$($(package)_cmake) -DCMAKE_C_FLAGS="$$($(1)_cflags) -Wl,--build-id=none" -DCMAKE_SKIP_RPATH="ON" -DCMAKE_EXE_LINKER_FLAGS="-static" -DCMAKE_FIND_LIBRARY_SUFFIXES=".a" ..
endef
define $(package)_build_cmds
$(MAKE) -C dmg
endef
define $(package)_stage_cmds
$(MAKE) DESTDIR=$($(package)_staging_dir) -C dmg install
endef