windows: Use ZLIB_DIR for zlib dependency lookup
This commit is contained in:
parent
8ceea9ce08
commit
95fdd19a44
|
@ -20,20 +20,24 @@ exit /B %errorlevel%
|
|||
if not defined OPENSSL_DIR set all_set=0
|
||||
if not defined REGEX_INCLUDE_DIR set all_set=0
|
||||
if not defined REGEX_DIR set all_set=0
|
||||
if not defined ZLIB_DIR set all_set=0
|
||||
|
||||
if %all_set%==1 (
|
||||
@echo - Using OpenSSL: %OPENSSL_DIR%
|
||||
@echo - Using Regex Include Directory: %REGEX_INCLUDE_DIR%
|
||||
@echo - Using Regex Lib Directory: %REGEX_DIR%
|
||||
@echo - Using zlib: %ZLIB_DIR%
|
||||
) else (
|
||||
@echo At least one of the following variables were not set:
|
||||
@echo - OPENSSL_DIR: %OPENSSL_DIR%
|
||||
@echo - REGEX_INCLUDE_DIR: %REGEX_INCLUDE_DIR%
|
||||
@echo - REGEX_DIR: %REGEX_DIR%
|
||||
@echo - ZLIB_DIR: %ZLIB_DIR%
|
||||
@echo Please define them using by creating a "env.bat" file containing:
|
||||
@echo @set OPENSSL_DIR=^<your OpenSSL directory^>
|
||||
@echo @set REGEX_INCLUDE_DIR=^<your pcre/include directory^>
|
||||
@echo @set REGEX_DIR=^<your pcre/lib directory^>
|
||||
@echo @set ZLIB_DIR=^<your zlib directory^>
|
||||
exit /B 1
|
||||
)
|
||||
set all_set=
|
||||
|
@ -121,6 +125,7 @@ exit /B 0
|
|||
-Dopenssl_dir=%OPENSSL_DIR%^
|
||||
-Dregex_include_dir=%REGEX_INCLUDE_DIR%^
|
||||
-Dregex_dir=%REGEX_DIR%^
|
||||
-Dzlib_dir=%ZLIB_DIR%^
|
||||
-Dcrypto=openssl^
|
||||
-Dnls=false^
|
||||
-Dsystemd=false^
|
||||
|
|
|
@ -213,19 +213,34 @@ if sys_linux and config_h.has('HAVE_LISTXATTR') and config_h.has('HAVE_SETXATTR'
|
|||
endif
|
||||
|
||||
regexp = []
|
||||
zlib = []
|
||||
if sys_windows == true
|
||||
# PCRE
|
||||
inc_arg = '-I' + get_option('regex_include_dir')
|
||||
if cc.has_header('regex.h', args: inc_arg) == false
|
||||
error('regex can not be found')
|
||||
error('regex.h cannot be found')
|
||||
endif
|
||||
regexp = cc.find_library('pcre',
|
||||
dirs : [get_option('regex_dir')],
|
||||
required: true)
|
||||
if regexp.found() == false
|
||||
error('regex can not be found')
|
||||
error('regex library cannot be found')
|
||||
endif
|
||||
|
||||
# zlib
|
||||
zlib_dir = get_option('zlib_dir')
|
||||
zlib_include_dir = zlib_dir + '/include'
|
||||
if cc.has_header('zlib.h', args: '-I' + zlib_include_dir) == false
|
||||
error('zlib.h cannot be found')
|
||||
endif
|
||||
zlib = cc.find_library('zlib',
|
||||
dirs: [zlib_dir + '/lib'],
|
||||
required: true)
|
||||
if not zlib.found()
|
||||
error('zlib library can not be found')
|
||||
endif
|
||||
else
|
||||
zlib = dependency('zlib')
|
||||
if cc.has_header_symbol('fnmatch.h', 'fnmatch') == false
|
||||
error('fnmatch can not be found')
|
||||
endif
|
||||
|
|
|
@ -127,7 +127,13 @@ option('regex_include_dir',
|
|||
option('regex_dir',
|
||||
type : 'string',
|
||||
value : '',
|
||||
description : 'Which SSL Crypto library used in efl'
|
||||
description : 'Which is the /lib directory for PCRE'
|
||||
)
|
||||
|
||||
option('zlib_dir',
|
||||
type : 'string',
|
||||
value : '',
|
||||
description : 'Which is the /lib directory for zlib'
|
||||
)
|
||||
|
||||
option('glib',
|
||||
|
|
|
@ -11,7 +11,7 @@ subdir('common')
|
|||
|
||||
common = static_library('evas_loader_common',
|
||||
generic_src,
|
||||
include_directories : config_dir,
|
||||
include_directories : [config_dir, zlib_include_dir],
|
||||
dependencies: [generic_deps, rt],
|
||||
)
|
||||
|
||||
|
|
|
@ -4,5 +4,5 @@ generic_src = files([
|
|||
'pixelfuncs.c'
|
||||
])
|
||||
|
||||
generic_deps = [eina, dependency('zlib')]
|
||||
generic_deps = [eina, zlib]
|
||||
generic_support = ['xcf.gz']
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
emile_deps = [jpeg, crypto, dependency('zlib', required: false)]
|
||||
emile_deps = [jpeg, crypto, zlib]
|
||||
emile_pub_deps = [eina, efl]
|
||||
|
||||
emile_headers = [
|
||||
|
|
Loading…
Reference in New Issue