Opencv fix (#5040)
* Added a package for the MDAnalysis toolkit. * Changed cmake_options to args to be consistent with the rest of the file and fix a cmake error about undefined errors. Additionally, added guards for both png and zlib to not include their cmake options when those variants are not specified.
This commit is contained in:
parent
0137f17306
commit
28b0421eb1
@ -128,27 +128,29 @@ def cmake_args(self):
|
||||
]
|
||||
|
||||
# Media I/O
|
||||
zlib = spec['zlib']
|
||||
args.extend([
|
||||
'-DZLIB_LIBRARY_{0}:FILEPATH={1}'.format((
|
||||
'DEBUG' if '+debug' in spec else 'RELEASE'),
|
||||
join_path(zlib.prefix.lib,
|
||||
'libz.{0}'.format(dso_suffix))),
|
||||
'-DZLIB_INCLUDE_DIR:PATH={0}'.format(zlib.prefix.include)
|
||||
])
|
||||
if '+zlib' in spec:
|
||||
zlib = spec['zlib']
|
||||
args.extend([
|
||||
'-DZLIB_LIBRARY_{0}:FILEPATH={1}'.format((
|
||||
'DEBUG' if '+debug' in spec else 'RELEASE'),
|
||||
join_path(zlib.prefix.lib,
|
||||
'libz.{0}'.format(dso_suffix))),
|
||||
'-DZLIB_INCLUDE_DIR:PATH={0}'.format(zlib.prefix.include)
|
||||
])
|
||||
|
||||
libpng = spec['libpng']
|
||||
args.extend([
|
||||
'-DPNG_LIBRARY_{0}:FILEPATH={1}'.format((
|
||||
'DEBUG' if '+debug' in spec else 'RELEASE'),
|
||||
join_path(libpng.prefix.lib,
|
||||
'libpng.{0}'.format(dso_suffix))),
|
||||
'-DPNG_INCLUDE_DIR:PATH={0}'.format(libpng.prefix.include)
|
||||
])
|
||||
if '+png' in spec:
|
||||
libpng = spec['libpng']
|
||||
args.extend([
|
||||
'-DPNG_LIBRARY_{0}:FILEPATH={1}'.format((
|
||||
'DEBUG' if '+debug' in spec else 'RELEASE'),
|
||||
join_path(libpng.prefix.lib,
|
||||
'libpng.{0}'.format(dso_suffix))),
|
||||
'-DPNG_INCLUDE_DIR:PATH={0}'.format(libpng.prefix.include)
|
||||
])
|
||||
|
||||
if '+jpeg' in spec:
|
||||
libjpeg = spec['libjpeg-turbo']
|
||||
cmake_options.extend([
|
||||
args.extend([
|
||||
'-DBUILD_JPEG:BOOL=OFF',
|
||||
'-DJPEG_LIBRARY:FILEPATH={0}'.format(
|
||||
join_path(libjpeg.prefix.lib,
|
||||
@ -158,7 +160,7 @@ def cmake_args(self):
|
||||
|
||||
if '+tiff' in spec:
|
||||
libtiff = spec['libtiff']
|
||||
cmake_options.extend([
|
||||
args.extend([
|
||||
'-DTIFF_LIBRARY_{0}:FILEPATH={1}'.format((
|
||||
'DEBUG' if '+debug' in spec else 'RELEASE'),
|
||||
join_path(libtiff.prefix.lib,
|
||||
@ -168,7 +170,7 @@ def cmake_args(self):
|
||||
|
||||
if '+jasper' in spec:
|
||||
jasper = spec['jasper']
|
||||
cmake_options.extend([
|
||||
args.extend([
|
||||
'-DJASPER_LIBRARY_{0}:FILEPATH={1}'.format((
|
||||
'DEBUG' if '+debug' in spec else 'RELEASE'),
|
||||
join_path(jasper.prefix.lib,
|
||||
|
Loading…
Reference in New Issue
Block a user