2014-07-23 01:31:30 -04:00
|
|
|
package=miniupnpc
|
2023-02-02 11:29:07 -03:00
|
|
|
$(package)_version=2.2.7
|
2024-05-22 03:54:41 -04:00
|
|
|
$(package)_download_path=http://miniupnp.free.fr/files/
|
2014-07-23 01:31:30 -04:00
|
|
|
$(package)_file_name=$(package)-$($(package)_version).tar.gz
|
2023-02-02 11:29:07 -03:00
|
|
|
$(package)_sha256_hash=b0c3a27056840fd0ec9328a5a9bac3dc5e0ec6d2e8733349cf577b0aa1e70ac1
|
2024-04-30 01:28:59 -04:00
|
|
|
$(package)_patches=dont_leak_info.patch cmake_get_src_addr.patch fix_windows_snprintf.patch
|
2023-04-19 16:49:04 -04:00
|
|
|
$(package)_build_subdir=build
|
2014-07-23 01:31:30 -04:00
|
|
|
|
|
|
|
define $(package)_set_vars
|
2023-04-19 16:49:04 -04:00
|
|
|
$(package)_config_opts = -DUPNPC_BUILD_SAMPLE=OFF -DUPNPC_BUILD_SHARED=OFF
|
|
|
|
$(package)_config_opts += -DUPNPC_BUILD_STATIC=ON -DUPNPC_BUILD_TESTS=OFF
|
|
|
|
$(package)_config_opts_mingw32 += -DMINIUPNPC_TARGET_WINDOWS_VERSION=0x0601
|
2014-07-23 01:31:30 -04:00
|
|
|
endef
|
|
|
|
|
|
|
|
define $(package)_preprocess_cmds
|
2022-08-31 07:23:38 -04:00
|
|
|
patch -p1 < $($(package)_patch_dir)/dont_leak_info.patch && \
|
2024-04-30 01:28:59 -04:00
|
|
|
patch -p1 < $($(package)_patch_dir)/cmake_get_src_addr.patch && \
|
|
|
|
patch -p1 < $($(package)_patch_dir)/fix_windows_snprintf.patch
|
2014-07-23 01:31:30 -04:00
|
|
|
endef
|
|
|
|
|
2023-04-19 16:49:04 -04:00
|
|
|
define $(package)_config_cmds
|
|
|
|
$($(package)_cmake) -S .. -B .
|
|
|
|
endef
|
|
|
|
|
2014-07-23 01:31:30 -04:00
|
|
|
define $(package)_build_cmds
|
2023-04-19 16:49:04 -04:00
|
|
|
$(MAKE)
|
2014-07-23 01:31:30 -04:00
|
|
|
endef
|
|
|
|
|
|
|
|
define $(package)_stage_cmds
|
2023-04-19 16:49:04 -04:00
|
|
|
cmake --install . --prefix $($(package)_staging_prefix_dir)
|
2014-07-23 01:31:30 -04:00
|
|
|
endef
|
2024-07-25 07:01:22 -04:00
|
|
|
|
|
|
|
define $(package)_postprocess_cmds
|
|
|
|
rm -rf bin && \
|
|
|
|
rm -rf share
|
|
|
|
endef
|