diff options
author | mwilliammyers <mwilliammyers@gmail.com> | 2016-07-12 20:29:04 -0600 |
---|---|---|
committer | mwilliammyers <mwilliammyers@gmail.com> | 2016-07-20 17:24:21 -0600 |
commit | 578ddea418efe744862e0f5d22aaa65e521e9f9f (patch) | |
tree | 04859c00f4fdb39165070ed75ab282ff49b30382 /var | |
parent | cf0f5756f55a0bb3390975950a7f12b18833262d (diff) | |
download | spack-578ddea418efe744862e0f5d22aaa65e521e9f9f.tar.gz spack-578ddea418efe744862e0f5d22aaa65e521e9f9f.tar.bz2 spack-578ddea418efe744862e0f5d22aaa65e521e9f9f.tar.xz spack-578ddea418efe744862e0f5d22aaa65e521e9f9f.zip |
opencv : Fix pep8 style issues
Diffstat (limited to 'var')
-rw-r--r-- | var/spack/repos/builtin/packages/opencv/package.py | 49 |
1 files changed, 30 insertions, 19 deletions
diff --git a/var/spack/repos/builtin/packages/opencv/package.py b/var/spack/repos/builtin/packages/opencv/package.py index 3d887f0775..301ac46c0e 100644 --- a/var/spack/repos/builtin/packages/opencv/package.py +++ b/var/spack/repos/builtin/packages/opencv/package.py @@ -26,22 +26,28 @@ from spack import * class Opencv(Package): + """OpenCV is released under a BSD license and hence it's free for both + academic and commercial use. It has C++, C, Python and Java interfaces and + supports Windows, Linux, Mac OS, iOS and Android. OpenCV was designed for + computational efficiency and with a strong focus on real-time applications. + Written in optimized C/C++, the library can take advantage of multi-core + processing. Enabled with OpenCL, it can take advantage of the hardware + acceleration of the underlying heterogeneous compute platform. Adopted all + around the world, OpenCV has more than 47 thousand people of user community + and estimated number of downloads exceeding 9 million. Usage ranges from + interactive art, to mines inspection, stitching maps on the web or through + advanced robotics. """ - OpenCV is released under a BSD license and hence it's free for both academic and commercial use. It has C++, C, - Python and Java interfaces and supports Windows, Linux, Mac OS, iOS and Android. OpenCV was designed for - computational efficiency and with a strong focus on real-time applications. Written in optimized C/C++, the library - can take advantage of multi-core processing. Enabled with OpenCL, it can take advantage of the hardware - acceleration of the underlying heterogeneous compute platform. Adopted all around the world, OpenCV has more than - 47 thousand people of user community and estimated number of downloads exceeding 9 million. Usage ranges from - interactive art, to mines inspection, stitching maps on the web or through advanced robotics. - """ + homepage = 'http://opencv.org/' url = 'https://github.com/Itseez/opencv/archive/3.1.0.tar.gz' version('3.1.0', '70e1dd07f0aa06606f1bc0e3fa15abd3') - variant('shared', default=True, description='Enables the build of shared libraries') - variant('debug', default=False, description='Builds a debug version of the libraries') + variant('shared', default=True, + description='Enables the build of shared libraries') + variant('debug', default=False, + description='Builds a debug version of the libraries') variant('eigen', default=True, description='Activates support for eigen') variant('ipp', default=True, description='Activates support for IPP') @@ -66,24 +72,29 @@ class Opencv(Package): cmake_options = [] cmake_options.extend(std_cmake_args) - cmake_options.extend(['-DCMAKE_BUILD_TYPE:STRING=%s' % ('Debug' if '+debug' in spec else 'Release'), - '-DBUILD_SHARED_LIBS:BOOL=%s' % ('ON' if '+shared' in spec else 'OFF'), - '-DENABLE_PRECOMPILED_HEADERS:BOOL=OFF', - '-DWITH_IPP:BOOL=%s' % ('ON' if '+ipp' in spec else 'OFF'), - '-DWITH_CUDA:BOOL=%s' % ('ON' if '+cuda' in spec else 'OFF')]) + cmake_options.extend( + ['-DCMAKE_BUILD_TYPE:STRING=%s' % ( + 'Debug' if '+debug' in spec else 'Release'), + '-DBUILD_SHARED_LIBS:BOOL=%s' % ( + 'ON' if '+shared' in spec else 'OFF'), + '-DENABLE_PRECOMPILED_HEADERS:BOOL=OFF', + '-DWITH_IPP:BOOL=%s' % ( + 'ON' if '+ipp' in spec else 'OFF'), + '-DWITH_CUDA:BOOL=%s' % ( + 'ON' if '+cuda' in spec else 'OFF')]) python_prefix = spec['python'].prefix python_lib = python_prefix.lib if spec.satisfies('^python@3:'): python = join_path(python_prefix.bin, 'python3') cmake_options.extend(['-DBUILD_opencv_python3=ON', - '-DPYTHON_EXECUTABLE={0}'.format(python), - '-DPYTHON_LIBRARIES={0}'.format(python_lib)]) + '-DPYTHON_EXECUTABLE=%s' % (python), + '-DPYTHON_LIBRARIES=%s' % (python_lib)]) elif spec.satisfies('^python@2:3'): python = join_path(python_prefix.bin, 'python2') cmake_options.extend(['-DBUILD_opencv_python2=ON', - '-DPYTHON_EXECUTABLE={0}'.format(python), - '-DPYTHON_LIBRARIES={0}'.format(python_lib)]) + '-DPYTHON_EXECUTABLE=%s' % (python), + '-DPYTHON_LIBRARIES=%s' % (python_lib)]) with working_dir('spack_build', create=True): cmake('..', *cmake_options) |