Skip to content

Commit

Permalink
Automatic snapshot commit from tribits at 357f5f6
Browse files Browse the repository at this point in the history
Origin repo remote tracking branch: 'github/master'
Origin repo remote repo URL: 'github = git@github.com:TriBITSPub/TriBITS.git'

At commit:

commit 7a46273df1cee2dbab0857ef90ab867dcb090acd
Author:  Roscoe A. Bartlett <rabartl@sandia.gov>
Date:    Wed Oct 10 09:23:57 2018 -0600
Summary: Remove some conditional code based on CMake versions less than 3.10.0 (trilinos#1761)
  • Loading branch information
bartlettroscoe authored and tjfulle committed Dec 6, 2018
1 parent 3e3d290 commit 71f3bae
Show file tree
Hide file tree
Showing 27 changed files with 1,358 additions and 112 deletions.
49 changes: 28 additions & 21 deletions cmake/tribits/ReleaseNotes.txt
Original file line number Diff line number Diff line change
@@ -1,28 +1,34 @@
----------------------------------------
Release Notes for TriBITS
----------------------------------------

2108/10/10:

(*) MAJOR: TriBITS Core: Changed minimum CMake version from 2.8.11 to 3.10.0.

2017/09/25:

(*) MINOR: Added cache and enve vars CTEST_SUBMIT_RETRY_COUNT and
CTEST_SUBMIT_RETRY_DELAY to allow the number of ctest_submit() submit
attemtps to retry and how how log to pause between retries. Before, these
were hard-coded to 25 and 120 respectively, which means that something
like a MySQL insertion error could consume as much as 50 minutes befor
moving on! The new defalts are set at 5 retries with a 3 sec delay (which
appear to be the CTest defaults).
(*) MINOR: TriBITS CTest Driver: Added cache and enve vars
CTEST_SUBMIT_RETRY_COUNT and CTEST_SUBMIT_RETRY_DELAY to allow the number
of ctest_submit() submit attemtps to retry and how how log to pause
between retries. Before, these were hard-coded to 25 and 120
respectively, which means that something like a MySQL insertion error
could consume as much as 50 minutes befor moving on! The new defalts are
set at 5 retries with a 3 sec delay (which appear to be the CTest
defaults).

2017/09/30:

(*) MINOR: Added TEST_<IDX> COPY_FILES_TO_TEST_DIR block for
(*) MINOR: TriBITS Core: Added TEST_<IDX> COPY_FILES_TO_TEST_DIR block for
TRIBITS_ADD_ADVANCED_TEST(). This was added in such a way so to avoid
clashing with existing usages of the script (since the new arguments
SOURCE_DIR and DEST_DIR are only parsed if COPY_FILES_TO_TEST_DIR is
listed in the TEST_<IDX> block.

2017/09/05:

(*) MINOR: Unparsed and otherwise ignored arguments are now flagged (see
developers guide documentation for
(*) MINOR: TriBITS Core: Unparsed and otherwise ignored arguments are now
flagged (see developers guide documentation for
${PROJECT_NAME}_CHECK_FOR_UNPARSED_ARGUMENTS). The default value is
'WARNING' which results in simply printing a warning but allow configure
to complete. This allows one to see the warnings but for the project to
Expand All @@ -31,8 +37,8 @@ Release Notes for TriBITS

2017/06/24:

(*) MINOR: Add new all-at-once more for CTest -S driver scripts using
TRIBITS_CTEST_DRIVER() by setting the variable
(*) MINOR: TriBITS CTest Driver: Add new all-at-once more for CTest -S driver
scripts using TRIBITS_CTEST_DRIVER() by setting the variable
${PROJECT_NAME}_CTEST_DO_ALL_AT_ONCE=TRUE. This works with older versions
of CMake/CTest and CDash but, by default, will just return a single glob
of results, not breaking results out package-by-package. Therefore, this
Expand All @@ -50,27 +56,27 @@ Release Notes for TriBITS

2017/05/25:

(*) MINOR: PARSE_ARGUMENTS() has been deprecated and replaced by
(*) MINOR: TriBITS Core: PARSE_ARGUMENTS() has been deprecated and replaced by
CMAKE_PARSE_ARGUMENTS() everywhere in TriBITS. Any call to
PARSE_ARGUMENTS() will warn users and tell them to use
CMAKE_PARSE_ARGUMENTS() instead.

2017/05/17:

(*) MAJOR: TriBITS now unconditionally sets
(*) MAJOR: TriBITS Core: TriBITS now unconditionally sets
${PROJECT_NAME}_ENABLE_Fortran_DEFAULT to ON. Projects will now need to
put in special logic to set to OFF or ON for certain platforms.

2017/01/11:

(*) MINOR: TriBITS now correctly sets the default value for
(*) MINOR: TriBITS Core: TriBITS now correctly sets the default value for
DART_TESTING_TIMEOUT to 1500 seconds and will scale it by
<Project>_SCALE_TEST_TIMEOUT even if DART_TESTING_TIMEOUT is not
explicitly set.

2016/12/07:

(*) MAJOR: The long deprecated variable
(*) MAJOR: TriBITS Core: The long deprecated variable
${PROJECT_NAME}_ENABLE_SECONDARY_STABLE_CODE has been removed. Upgrading
existing TriBITS projects just requires a simple string replacement of
_ENABLE_SECONDARY_STABLE_CODE with _ENABLE_SECONDARY_TESTED_CODE in all
Expand All @@ -80,11 +86,12 @@ Release Notes for TriBITS

2016/11/02:

(*) MAJOR: gitdist now accepts --dist-repos and --dist-not-repos arguments and
requires that the base repo '.' be explicitly listed in the
.gitdist[.default] files and in --dist-repos. The arguments
--dist-extra-repos, --dist-not-extra-repos and --dist-not-base-repo are
not longer supported. See gitdist --help for more details.
(*) MAJOR: TriBITS Python Utils: gitdist now accepts --dist-repos and
--dist-not-repos arguments and requires that the base repo '.' be
explicitly listed in the .gitdist[.default] files and in --dist-repos.
The arguments --dist-extra-repos, --dist-not-extra-repos and
--dist-not-base-repo are not longer supported. See gitdist --help for
more details.

(*) MINOR: TriBITS projects now install with full RPATH set by default (see
"Setting install RPATH" in build reference guide).
Expand Down
2 changes: 1 addition & 1 deletion cmake/tribits/ci_support/CheckinTest.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ def getReposStats(inOptions, tribitsGitRepos):
repoStatTableDirName = getRepoStatTableDirName(inOptions, gitRepo.repoDir)
repoStatTable.insertRepoStat(repoStatTableDirName, gitRepo.gitRepoStats, repoIdx)
repoIdx += 1
print(gitdist.createAsciiTable(repoStatTable.getTableData()))
print(gitdist.createTable(repoStatTable.getTableData()))
return hasChangesToPush
# NOTE: Above, we could just call 'gitdist dist-repo-status' but by
# printing the table here with the actualy gitRepoStat data, we ensure
Expand Down
2 changes: 1 addition & 1 deletion cmake/tribits/ci_support/clone_extra_repos.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ def getExtraReposTable(extraRepoDictList):
]
#print("extraReposTableDictList =", extraReposTableDictList)

extraReposTable = gitdist.createAsciiTable(extraReposTableDictList)
extraReposTable = gitdist.createTable(extraReposTableDictList)

# Return the table
return extraReposTable
Expand Down
14 changes: 6 additions & 8 deletions cmake/tribits/core/package_arch/TribitsAddAdvancedTest.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -780,7 +780,7 @@ INCLUDE(PrintVar)
# ``${PROJECT_NAME}_TRIBITS_DIR`` (pointing to the TriBITS location). For example,
# a valid project can be a simple as::
#
# CMAKE_MINIMUM_REQUIRED(VERSION 2.8.11)
# CMAKE_MINIMUM_REQUIRED(VERSION 3.10.0)
# SET(PROJECT_NAME TAATDriver)
# PROJECT(${PROJECT_NAME} NONE)
# SET(${PROJECT_NAME}_TRACE_ADD_TEST TRUE)
Expand Down Expand Up @@ -818,13 +818,11 @@ FUNCTION(TRIBITS_ADD_ADVANCED_TEST TEST_NAME_IN)
SET(TEST_NAME ${TEST_NAME_IN})
ENDIF()

IF (NOT CMAKE_VERSION VERSION_LESS "3.1.0.0")
# Avoid quoted strings lookup variables
CMAKE_POLICY(SET CMP0054 NEW)
# NOTE: For some reason, setting this policy at the top level with TriBITS
# in TribitsCMakePolices.cmake does not affect this function. Therefore,
# I have to set it again here.
ENDIF()
# Avoid quoted strings lookup variables
CMAKE_POLICY(SET CMP0054 NEW)
# NOTE: For some reason, setting this policy at the top level with TriBITS
# in TribitsCMakePolices.cmake does not affect this function. Therefore, I
# have to set it again here.

#
# A) Parse the overall arguments and figure out how many tests
Expand Down
11 changes: 4 additions & 7 deletions cmake/tribits/core/package_arch/TribitsAddExecutable.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -639,15 +639,12 @@ FUNCTION(TRIBITS_ADD_EXECUTABLE EXE_NAME)

TARGET_LINK_LIBRARIES(${EXE_BINARY_NAME} ${LINK_LIBS})

IF ("${CMAKE_VERSION}" VERSION_GREATER "2.8.4")
ASSERT_DEFINED(${PROJECT_NAME}_LINK_SEARCH_START_STATIC)
IF (${PROJECT_NAME}_LINK_SEARCH_START_STATIC)
#MESSAGE("${EXE_BINARY_NAME}: Adding property LINK_SEARCH_START_STATIC")
SET_PROPERTY(TARGET ${EXE_BINARY_NAME} PROPERTY LINK_SEARCH_START_STATIC 1)
ENDIF()
ASSERT_DEFINED(${PROJECT_NAME}_LINK_SEARCH_START_STATIC)
IF (${PROJECT_NAME}_LINK_SEARCH_START_STATIC)
#MESSAGE("${EXE_BINARY_NAME}: Adding property LINK_SEARCH_START_STATIC")
SET_PROPERTY(TARGET ${EXE_BINARY_NAME} PROPERTY LINK_SEARCH_START_STATIC 1)
ENDIF()


IF(PARSE_DIRECTORY)
SET_TARGET_PROPERTIES( ${EXE_BINARY_NAME} PROPERTIES
RUNTIME_OUTPUT_DIRECTORY ${PARSE_DIRECTORY} )
Expand Down
14 changes: 2 additions & 12 deletions cmake/tribits/core/package_arch/TribitsConstants.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

# Define the TriBITS minimum required CMake version

SET(TRIBITS_CMAKE_MINIMUM_REQUIRED 2.8.11)
SET(TRIBITS_CMAKE_MINIMUM_REQUIRED 3.10.0)

MACRO(TRIBITS_ASESRT_MINIMUM_CMAKE_VERSION)

Expand All @@ -48,21 +48,11 @@ MACRO(TRIBITS_ASESRT_MINIMUM_CMAKE_VERSION)
" ${TRIBITS_CMAKE_MINIMUM_REQUIRED} or higher!")
ENDIF()

IF(NOT CMAKE_VERSION VERSION_LESS 3.3)
CMAKE_POLICY(VERSION 3.3)
ELSE()
CMAKE_POLICY(VERSION ${CMAKE_VERSION})
ENDIF()

ENDMACRO()

# Misc constants

IF (NOT CMAKE_VERSION VERSION_LESS 3.10)
SET(${PROJECT_NAME}_CTEST_USE_NEW_AAO_FEATURES TRUE)
ELSE()
SET(${PROJECT_NAME}_CTEST_USE_NEW_AAO_FEATURES FALSE)
ENDIF()
SET(${PROJECT_NAME}_CTEST_USE_NEW_AAO_FEATURES TRUE)

# File names for TriBITS system

Expand Down
4 changes: 1 addition & 3 deletions cmake/tribits/core/package_arch/TribitsGeneralMacros.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,7 @@ FUNCTION( TRIBITS_APPEND_INCLUDE_AND_LINK_DIRS TPL_OR_PACKAGE PREFIX
" '${PREFIX}' '${LIST}' '${EXTRA_DEP_LIBS_INOUT}'")
ENDIF()
SET(EXTRA_DEP_LIBS_INOUT_TMP ${${EXTRA_DEP_LIBS_INOUT}})
IF (NOT CMAKE_VERSION VERSION_LESS "3.1.0.0")
CMAKE_POLICY(SET CMP0054 NEW)
ENDIF()
CMAKE_POLICY(SET CMP0054 NEW)
IF (
"${TPL_OR_PACKAGE}" STREQUAL "TPL"
AND
Expand Down
15 changes: 5 additions & 10 deletions cmake/tribits/core/package_arch/TribitsGlobalMacros.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -305,17 +305,12 @@ MACRO(TRIBITS_DEFINE_GLOBAL_OPTIONS_AND_DEFINE_EXTRA_REPOS)
"Build with OpenMP support." OFF)

IF (CMAKE_GENERATOR STREQUAL "Ninja")
IF (NOT CMAKE_VERSION VERSION_LESS "3.7.0")
IF("${${PROJECT_NAME}_WRITE_NINJA_MAKEFILES_DEFAULT}" STREQUAL "")
SET(${PROJECT_NAME}_WRITE_NINJA_MAKEFILES_DEFAULT ON)
ENDIF()
SET(${PROJECT_NAME}_WRITE_NINJA_MAKEFILES
${${PROJECT_NAME}_WRITE_NINJA_MAKEFILES_DEFAULT} CACHE BOOL
"Generate dummy makefiles to call ninja in every bulid subdirectory (requires CMake 3.7.0 or newer)." )
ELSE()
MESSAGE("-- NOTE: CMAKE_VERSION=${CMAKE_VERSION} < 3.7.0: Can not generate"
" dummy makefiles for Ninja generator!")
IF("${${PROJECT_NAME}_WRITE_NINJA_MAKEFILES_DEFAULT}" STREQUAL "")
SET(${PROJECT_NAME}_WRITE_NINJA_MAKEFILES_DEFAULT ON)
ENDIF()
SET(${PROJECT_NAME}_WRITE_NINJA_MAKEFILES
${${PROJECT_NAME}_WRITE_NINJA_MAKEFILES_DEFAULT} CACHE BOOL
"Generate dummy makefiles to call ninja in every bulid subdirectory (requires CMake 3.7.0 or newer)." )
ENDIF()
IF ("${${PROJECT_NAME}_WRITE_NINJA_MAKEFILES}" STREQUAL "")
SET(${PROJECT_NAME}_WRITE_NINJA_MAKEFILES OFF)
Expand Down
2 changes: 1 addition & 1 deletion cmake/tribits/ctest_driver/TribitsCTestDriverCore.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ MESSAGE("*******************************")
MESSAGE("")


CMAKE_MINIMUM_REQUIRED(VERSION 2.8.11 FATAL_ERROR)
CMAKE_MINIMUM_REQUIRED(VERSION 3.10.0 FATAL_ERROR)

#
# Get the basic variables that define the project and the build
Expand Down
37 changes: 37 additions & 0 deletions cmake/tribits/doc/build_ref/TribitsBuildReferenceBody.rst
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,7 @@ See the following use cases:
* `Determine the list of packages that can be enabled`_
* `Print package dependencies`_
* `Enable a set of packages`_
* `Enable or disable tests for specific packages`_
* `Enable to test all effects of changing a given package(s)`_
* `Enable all packages with tests and examples`_
* `Disable a package and all its dependencies`_
Expand Down Expand Up @@ -412,6 +413,42 @@ statement in an input ```*.cmake`` options files. However, setting
``-DXXX_ENABLE_YYY=TRUE`` and ``-DXXX_ENABLE_YYY=FALSE`` is allowed and will
be interpreted correctly..


Enable or disable tests for specific packages
+++++++++++++++++++++++++++++++++++++++++++++

The enable tests for explicitly enabled packages, configure with::

-D <Project>_ENABLE_<TRIBITS_PACKAGE_1>=ON \
-D <Project>_ENABLE_<TRIBITS_PACKAGE_2>=ON \
-D <Project>_ENABLE_TESTS=ON \

This wil result in the enable of the test suites for any package that
explicitly enabled with ``-D <Project>_ENABLE_<TRIBITS_PACKAGE>=ON``. Note
that his will **not** result in the enable of the test suites for any packages
that may only be implicitly enabled in order to build the explicitly enabled
packages.

If one wants to enable a package along with the enable of other packages, but
not the test suite for that package, then when can disable the tests for that
package by configuring with::

-D <Project>_ENABLE_<TRIBITS_PACKAGE_1>=ON \
-D <Project>_ENABLE_<TRIBITS_PACKAGE_2>=ON \
-D <Project>_ENABLE_<TRIBITS_PACKAGE_3>=ON \
-D <Project>_ENABLE_TESTS=ON \
-D <TRIBITS_PACKAGE_2>_ENABLE_TESTS=OFF \

The above will enable the package test suites for ``<TRIBITS_PACKGE_1>`` and
``<TRIBITS_PACKGE_3>`` but **not** for ``<TRIBITS_PACKAGE_2>`` (or any other
packages that might get implicitly enabled). One might use this if one wants
to build and install package ``<TRIBITS_PACKAGE_2>`` but does not want to
build and run the test suite for that package.

These and other options give the user complete control of what packages get
enabled or disabled and what package test suites are enabled or disabled.


Enable to test all effects of changing a given package(s)
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Expand Down
4 changes: 2 additions & 2 deletions cmake/tribits/doc/build_ref/create-project-build-ref.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@
clp.add_option(
"--min-cmake-version", dest="minCMakeVersion", type="string",
help="Minimum version of CMake needed for given project" \
" [Default '2.8.11']",
default="2.8.11" )
" [Default '3.10.0']",
default="3.10.0" )

GenerateDocUtilsOutput.addCmndLineOptions(clp)

Expand Down
6 changes: 3 additions & 3 deletions cmake/tribits/doc/developers_guide/TribitsDevelopersGuide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -779,7 +779,7 @@ the variable ``TRIBITS_CMAKE_MINIMUM_REQUIRED`` (the current minimum version
of CMake required by TriBITS is given at in `Getting set up to use CMake`_) .
For example, the ``VERA/CMakeLists.txt`` file lists as its first line::

SET(VERA_TRIBITS_CMAKE_MINIMUM_REQUIRED 2.8.11)
SET(VERA_TRIBITS_CMAKE_MINIMUM_REQUIRED 3.10.0)
CMAKE_MINIMUM_REQUIRED(VERSION ${VERA_TRIBITS_CMAKE_MINIMUM_REQUIRED}
FATAL_ERROR)

Expand Down Expand Up @@ -4553,7 +4553,7 @@ Test Test Category ``BASIC`` (`Test Test Category BASIC`_)

Typically a TriBITS project will define a "standard development environment"
which is comprised of a standard compiler (e.g. GCC 4.6.1), TPL versions
(e.g. OpenMPI 1.4.2, Boost 4.9, etc.), and other tools (e.g. cmake 2.8.11, git
(e.g. OpenMPI 1.4.2, Boost 4.9, etc.), and other tools (e.g. cmake 3.10.0, git
1.8.2, etc.). This standard development environment is expected to be used to
test changes to the project's code before any push. By using a standard
development environment, if the code builds and all the tests pass for the
Expand Down Expand Up @@ -9047,7 +9047,7 @@ Below is a snapshot of the output from ``install_devtools.py --help``.

.. Common references to raw CMake commands:
.. _CONFIGURE_FILE(): http://www.cmake.org/cmake/help/v2.8.11/cmake.html#command:configure_file
.. _CONFIGURE_FILE(): https://cmake.org/cmake/help/v3.10/command/configure_file.html

.. Other references
Expand Down
5 changes: 0 additions & 5 deletions cmake/tribits/doc/tribits_tutorial/.gitignore

This file was deleted.

8 changes: 8 additions & 0 deletions cmake/tribits/doc/tutorial/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
*.pdf
*.html
*.tex
*.log
.log
/*.aux
/*.log
/*.pdf
3 changes: 3 additions & 0 deletions cmake/tribits/doc/tutorial/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# TriBITS Tutorials

NOTE: These are still in development and may not build on your machine.
21 changes: 21 additions & 0 deletions cmake/tribits/doc/tutorial/generate-tutorial.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/bin/bash

function make_doc {
if [ -z ${1+x} ]; then
echo "no file specified to make_doc"
return 1
elif [ ! -f src/$1.rst ]; then
echo "File not found! $1.rst"
else
echo "Generating HTML and PDF files for ${1} ..."
cp src/$1.rst .
rst2html $1.rst $1.html
rst2latex $1.rst $1.tex
latex -output-format=pdf $1.tex
fi
}

make_doc TribitsTutorial_ConvertAProject
make_doc TribitsTutorial_Dependencies
make_doc TribitsTutorial_HelloWorld
make_doc TribitsTutorial_ProjectStructure
Loading

0 comments on commit 71f3bae

Please sign in to comment.