Skip to content
Snippets Groups Projects
Commit 81c1404b authored by Mayeul d'Avezac's avatar Mayeul d'Avezac Committed by Todd Gamblin
Browse files

Adds catch, cppunit, spdlog, tinyxml(1 and 2), google benchmark (#2627)

* Adds catch, cppunit, spdlog, tinyxml(1 and 2), google benchmark

Tinyxml comes in two flavors, 1 and 2. Each comes in several
versions... So they cannot be easily united into a single package.

* Use CMakePackage and friends, add copyright

Also eleminate debug/release variants, since it no longuer fits in the
CMakePackage format.

* Remove unnecessary url

* spdlog now has tagged releases

* Remove unnecessary url argument

* Fewer quotes in cmake args, because magic

* Incorrect base class for tinyxml
parent baaa613e
No related branches found
No related tags found
No related merge requests found
##############################################################################
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-647188
#
# For details, see https://github.com/llnl/spack
# Please also see the LICENSE file for our notice and the LGPL.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License (as
# published by the Free Software Foundation) version 2.1, February 1999.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and
# conditions of the GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from spack import *
class Catch(Package):
"""Catch tests"""
homepage = "https://github.com/philsquared/Catch"
url = "https://github.com/philsquared/Catch/archive/v1.3.0.tar.gz"
version('1.3.0', 'e13694aaff72817d02af8ed27d077cd261b6e857')
def install(self, spec, prefix):
mkdirp(prefix.include)
install(join_path('single_include', 'catch.hpp'), prefix.include)
# fakes out spack so it installs a module file
mkdirp(join_path(prefix, 'bin'))
##############################################################################
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-647188
#
# For details, see https://github.com/llnl/spack
# Please also see the LICENSE file for our notice and the LGPL.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License (as
# published by the Free Software Foundation) version 2.1, February 1999.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and
# conditions of the GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from spack import *
class Cppunit(AutotoolsPackage):
"""Obsolete Unit testing framework for C++"""
homepage = "https://wiki.freedesktop.org/www/Software/cppunit/"
url = "http://dev-www.libreoffice.org/src/cppunit-1.13.2.tar.gz"
version('1.13.2', '0eaf8bb1dcf4d16b12bec30d0732370390d35e6f')
##############################################################################
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-647188
#
# For details, see https://github.com/llnl/spack
# Please also see the LICENSE file for our notice and the LGPL.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License (as
# published by the Free Software Foundation) version 2.1, February 1999.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and
# conditions of the GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from spack import *
class Gbenchmark(CMakePackage):
"""A microbenchmark support library"""
homepage = "https://github.com/google/benchmark"
url = "https://github.com/google/benchmark/archive/v1.0.0.tar.gz"
version('1.1.0', '8c539bbe2a212618fa87b6c38fba087100b6e4ae')
version('1.0.0', '4f778985dce02d2e63262e6f388a24b595254a93')
def build_type(self):
return "Release"
def patch(self):
filter_file(
r'add_cxx_compiler_flag..fstrict.aliasing.',
r'##### add_cxx_compiler_flag(-fstrict-aliasing)',
'CMakeLists.txt'
)
filter_file(
r'add_cxx_compiler_flag..Werror',
r'##### add_cxx_compiler_flag(-Werror',
'CMakeLists.txt'
)
def cmake_args(self, spec, prefix):
if self.compiler.name == 'intel':
return [
"-DCMAKE_CXX_FLAGS=-no-ansi-alias -fno-strict-aliasing",
"-DCMAKE_C_FLAGS=-no-ansi-alias -fno-strict-aliasing",
"-DBENCHMARK_ENABLE_TESTING=OFF"
]
return []
##############################################################################
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-647188
#
# For details, see https://github.com/llnl/spack
# Please also see the LICENSE file for our notice and the LGPL.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License (as
# published by the Free Software Foundation) version 2.1, February 1999.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and
# conditions of the GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from spack import *
class Spdlog(CMakePackage):
"""Very fast, header only, C++ logging library"""
homepage = "https://github.com/gabime/spdlog"
url = "https://github.com/gabime/spdlog/archive/v0.9.0.tar.gz"
version('0.11.0', '08232203f18a6f9ff47e083cc7a141a050805d3b')
version('0.10.0', '57b471ef97a23cc29c38b62e00e89a411a87ea7f')
version('0.9.0', 'dda741ef8e12d57d91f778d85e95a27d84a82ac4')
cmake_minimum_required(VERSION 2.6)
project(TinyXml)
OPTION(TIXML_USE_STL "Use STL with TIXML" ON)
if(TIXML_USE_STL)
add_definitions(-DTIXML_USE_STL)
endif(TIXML_USE_STL)
add_library(
tinyxml
tinyxml.cpp
tinystr.cpp
tinyxmlerror.cpp
tinyxmlparser.cpp
)
INSTALL( FILES tinyxml.h tinystr.h DESTINATION include )
INSTALL( TARGETS tinyxml ARCHIVE DESTINATION lib )
##############################################################################
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-647188
#
# For details, see https://github.com/llnl/spack
# Please also see the LICENSE file for our notice and the LGPL.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License (as
# published by the Free Software Foundation) version 2.1, February 1999.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and
# conditions of the GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from spack import *
import os.path
class Tinyxml(CMakePackage):
"""Simple, small, efficient, C++ XML parser"""
homepage = "http://grinninglizard.com/tinyxml/"
url = "https://sourceforge.net/projects/tinyxml/files/tinyxml/2.6.2/tinyxml_2_6_2.tar.gz"
version('2.6.2', 'cba3f50dd657cb1434674a03b21394df9913d764')
def patch(self):
copyfile(join_path(os.path.dirname(__file__),
"CMakeLists.txt"), "CMakeLists.txt")
##############################################################################
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-647188
#
# For details, see https://github.com/llnl/spack
# Please also see the LICENSE file for our notice and the LGPL.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License (as
# published by the Free Software Foundation) version 2.1, February 1999.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and
# conditions of the GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from spack import *
class Tinyxml2(CMakePackage):
"""Simple, small, efficient, C++ XML parser"""
homepage = "http://grinninglizard.com/tinyxml2/"
url = "https://github.com/leethomason/tinyxml2/archive/3.0.0.tar.gz"
version('4.0.1', '08570d385788f6b02f50f5fd9df32a9d4f8482cc')
version('4.0.0', '7a6f0858d75f360922f3ca272f7067e8cdf00489')
version('3.0.0', '07acaae49f7dd3dab790da4fe72d0c7ef0d116d1')
version('2.2.0', '7869aa08241ce16f93ba3732c1cde155b1f2b6a0')
version('2.1.0', '70ef3221bdc190fd8fc50cdd4a6ef440f44b74dc')
version('2.0.2', 'c78a4de58540e2a35f4775fd3e577299ebd15117')
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment