mirror of
https://github.com/mkxp-z/mkxp-z.git
synced 2025-08-26 08:43:44 +02:00
Statically link libzip and zlib
This commit is contained in:
parent
921fe8954f
commit
fce135cd38
4 changed files with 22 additions and 2 deletions
2
.github/workflows/autobuild.yml
vendored
2
.github/workflows/autobuild.yml
vendored
|
@ -352,7 +352,7 @@ jobs:
|
||||||
- name: Install apt dependencies
|
- name: Install apt dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt update
|
sudo apt update
|
||||||
sudo apt install git curl build-essential automake libtool meson libzip-dev -y
|
sudo apt install git curl build-essential automake libtool meson cmake zlib1g-dev -y
|
||||||
|
|
||||||
- name: Build phase 2
|
- name: Build phase 2
|
||||||
run: |
|
run: |
|
||||||
|
|
17
meson.build
17
meson.build
|
@ -33,10 +33,25 @@ global_args += '-DHAVE_NANOSLEEP'
|
||||||
|
|
||||||
if get_option('retro') == true
|
if get_option('retro') == true
|
||||||
retro_phase1 = get_option('retro_phase1_path')
|
retro_phase1 = get_option('retro_phase1_path')
|
||||||
|
cmake = import('cmake')
|
||||||
|
libzip_options = cmake.subproject_options()
|
||||||
|
libzip_options.add_cmake_defines({'CMAKE_POSITION_INDEPENDENT_CODE': true})
|
||||||
|
libzip_options.add_cmake_defines({'BUILD_SHARED_LIBS': false})
|
||||||
|
libzip_options.add_cmake_defines({'LIBZIP_DO_INSTALL': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_COMMONCRYPTO': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_GNUTLS': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_MBEDTLS': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_OPENSSL': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_WINDOWS_CRYPTO': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_FDOPEN': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_BZIP2': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_LZMA': false})
|
||||||
|
libzip_options.add_cmake_defines({'ENABLE_ZSTD': false})
|
||||||
library(
|
library(
|
||||||
'retro-' + meson.project_name(),
|
'retro-' + meson.project_name(),
|
||||||
dependencies: [
|
dependencies: [
|
||||||
compilers['cpp'].find_library('zip', required: true),
|
compilers['cpp'].find_library('z', required: true, static: true),
|
||||||
|
cmake.subproject('libzip', options: libzip_options).dependency('zip'),
|
||||||
],
|
],
|
||||||
c_args: [
|
c_args: [
|
||||||
'-fno-optimize-sibling-calls',
|
'-fno-optimize-sibling-calls',
|
||||||
|
|
1
subprojects/.gitignore
vendored
Normal file
1
subprojects/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
||||||
|
/libzip
|
4
subprojects/libzip.wrap
Normal file
4
subprojects/libzip.wrap
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
[wrap-git]
|
||||||
|
url = https://github.com/nih-at/libzip
|
||||||
|
revision = v1.11.2
|
||||||
|
depth = 1
|
Loading…
Add table
Reference in a new issue