Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SEACAS: Remove the usage of deprecated TriBITS macros and update TriBITS snapshot (TriBITSPub/TriBITS#429) #361

Merged

Conversation

bartlettroscoe
Copy link
Contributor

This matches a similar commits from PR trilinos/Trilinos#11380 and updates to the same version of TriBITS.

See the individual commit messages for details.

NOTE: This also removes a bunch of generated *.pyc files that got added to the repo by accident. I added *.pyc to the the .gitignore file to avoid this in the future.

…TriBITS#429)

The deprecated TriBITS macro include_directories() now issues a CMake
Deprecation warning.  The fix is to use tribits_include_directories() instead
and use raw CMake include_directories() where that is the behavior you want.

This matches a similar commit from PR trilinos/Trilinos#11380

I was not able to use git format-patch and git am to apply the patch from the
Trilinos branch due to no current clean snapshot so I had to run the tool
TriBITS/refactoring/replace_include_directories_r.sh from scratch.
Origin repo remote tracking branch: 'github/master'
Origin repo remote repo URL: 'github = [email protected]:TriBITSPub/TriBITS.git'
Git describe: Vera4.0-RC1-start-1418-g3879de00

At commit:

commit c2f52215a2bf6d1004c5422164f0019952fcc1f2
Author:  Roscoe A. Bartlett <[email protected]>
Date:    Tue Dec 20 11:15:04 2022 -0700
Summary: Add RUN_SERIAL to tribits_add_executable_and_test() (sandialabs#554)

MANUAL NOTE: This commit deleted a bunch of *.pyc files that got accidentally
added to the git repo.  I don't think you ever want to commit these files.  I
will add to the .gitignore file so these will not be added in the future.
…riBITSPub/TriBITS#429)

A refactoring in TriBITS related to tribits_include_directories() (see
TriBITSPub/TriBITS#553) required renaming set_and_inc_dirs() to
tribits_set_and_inc_dirs() and deprecating the former.  The deprecated TriBITS
macro set_and_inc_dirs() now issues a CMake Deprecation warning.

This matches a similar commit from PR trilinos/Trilinos#11380

I was not able to use git format-patch and git am to apply the patch from the
Trilinos branch due to no current clean snapshot so I had to run the tool
TriBITS/refactoring/replace_set_and_inc_dirs_r.sh from scratch.
@bartlettroscoe
Copy link
Contributor Author

FYI: It looks like the snapshot of TriBITS wiped out changes to several of the find modules that have local modifications in this repo. To account for this, I will put back all of these files to what was in the SEACAS 'master' branch.

…#429)

The last snapshot of TriBITS 'master' into cmake/tribits/ wiped out a bunch of
local changes to these files.  Therefore, this commit put all of those back
again.
@bartlettroscoe
Copy link
Contributor Author

FYI: One new thing that updated TriBITS does now is to validate the names of dependent packages in the Dependencies.cmake files. It was just ignoring them. But with this update, we see that SEACAS does not configure as shown here showing:

Processing Project, Repository, and Package dependency files and building internal dependencies graph ...

CMake Error at cmake/tribits/core/package_arch/TribitsReadDepsFilesCreateDepsGraph.cmake:723 (message):
  Error, the package 'PaToH' is listed as a dependency of the package
  'Zoltan' but the package 'PaToH' is either not defined or is listed later
  in the package order.  This may also be an attempt to create a circular
  dependency between the packages 'PaToH' and 'Zoltan' (which is not
  allowed).  Check the spelling of 'PaToH' or see how it is listed in a call
  to tribits_repository_define_packages() in relation to 'Zoltan'.  To
  ignore/disable the undefined package 'PaToH', set the cache variable
-- Configuring incomplete, errors occurred!
See also "D:/a/seacas/seacas/build/CMakeFiles/CMakeOutput.log".
  Seacas_ASSERT_DEFINED_DEPENDENCIES=IGNORE.
Call Stack (most recent call first):
  cmake/tribits/core/package_arch/TribitsReadDepsFilesCreateDepsGraph.cmake:576 (tribits_abort_on_missing_package)
  cmake/tribits/core/package_arch/TribitsReadDepsFilesCreateDepsGraph.cmake:[52](https://github.com/sandialabs/seacas/actions/runs/3751177176/jobs/6371840666#step:4:53)7 (tribits_set_dep_packages__handle_undefined_pkg)
  cmake/tribits/core/package_arch/TribitsReadDepsFilesCreateDepsGraph.cmake:463 (tribits_set_dep_packages)
  cmake/tribits/core/package_arch/TribitsReadDepsFilesCreateDepsGraph.cmake:308 (tribits_process_package_dependencies_lists)
  cmake/tribits/core/package_arch/TribitsReadDepsFilesCreateDepsGraph.cmake:185 (tribits_read_toplevel_package_deps_files_add_to_graph)
  cmake/tribits/core/package_arch/TribitsReadDepsFilesCreateDepsGraph.cmake:85 (tribits_read_all_package_deps_files_create_deps_graph)
  cmake/tribits/core/package_arch/TribitsReadAllProjectDepsFilesCreateDepsGraph.cmake:79 (tribits_read_deps_files_create_deps_graph)
  cmake/tribits/core/package_arch/TribitsProjectImpl.cmake:1[54](https://github.com/sandialabs/seacas/actions/runs/3751177176/jobs/6371840666#step:4:55) (tribits_read_all_project_deps_files_create_deps_graph)
  cmake/tribits/core/package_arch/TribitsProject.cmake:92 (tribits_project_impl)
  CMakeLists.txt:46 (TRIBITS_PROJECT)

It is getting listed in:

SET(LIB_OPTIONAL_DEP_TPLS MPI METIS ParMETIS PaToH Scotch Zlib CCOLAMD OVIS)

in the file:

  • seacas/packages/zoltan/cmake/Dependencies.cmake

Well, that TPL is not defined in the file TPLsList.cmake.

I will add a commit to remove the listing of PaToH and see what happens.

@bartlettroscoe bartlettroscoe force-pushed the tribits-429-remove-deprecated branch from 3ea1a57 to ccd3308 Compare December 21, 2022 17:01
@bartlettroscoe
Copy link
Contributor Author

Well, just removing the missing TPLs from the zoltan/cmake/Depenencies.cmake file did not work because, as shown here, now the Zoltan configuring is issuing the errors:

CMake Error at cmake/tribits/core/utils/AssertDefined.cmake:79 (message):
  Error, the variable Zoltan_ENABLE_PaToH is not defined!
Call Stack (most recent call first):
  packages/zoltan/src/CMakeLists.txt:13 (ASSERT_DEFINED)


CMake Error at cmake/tribits/core/utils/AssertDefined.cmake:79 (message):
  Error, the variable Zoltan_ENABLE_Scotch is not defined!
Call Stack (most recent call first):
  packages/zoltan/src/CMakeLists.txt:16 (ASSERT_DEFINED)


CMake Error at cmake/tribits/core/utils/AssertDefined.cmake:79 (message):
  Error, the variable Zoltan_ENABLE_OVIS is not defined!
Call Stack (most recent call first):
  packages/zoltan/src/CMakeLists.txt:19 (ASSERT_DEFINED)

I think a better way to address this is to list the TPLs PaToH, Scotch, and OVIS in the TPLsList.cmake file but give them FindTPL<tplName>.cmake files that error out if they are ever enabled.

@bartlettroscoe
Copy link
Contributor Author

NOTE: as shown here, a bunch of deprecation warnings are also being issued for the Zoltan snapshot in the seacas repo. I will address those with new commits that do the replacements.

It would be good if I could find a way to build the stand-alone seacas CMake project on a SNL machine with the SEMS modules. Then I would work all of these issues our without taking up time on GitHub Actions.

…b/TriBITS#63)

The updated version of TriBITS requires that all TPLs listed in a package's
Dependencies.cmake file be defined.  For some reason, the TPLs PaToH, Scotch,
CCOLAMD, and OVIS listed in zoltan/cmake/Dependencies.cmake are not defined in
the base TriBITS repo file seacas/TPLsList.cmake.  Old TriBITS would just
ignore these undefined TPLs but new TriBITS will error out by default.

We have defined the FindTPL<tplName>.cmake files to error out if these TPLs
are ever enabled (and these files are processesd).
…TriBITS#429)

The deprecated TriBITS macro include_directories() now issues a CMake
Deprecation warning.  The fix is to use tribits_include_directories() instead
and use raw CMake include_directories() where that is the behavior you want.
@bartlettroscoe bartlettroscoe force-pushed the tribits-429-remove-deprecated branch from ccd3308 to 6e504a8 Compare December 21, 2022 22:09
…SPub/TriBITS#429)

Let's not generate any deprecated warnings from the deprecated TriBITS
include_directories() function.  Let's just not define it.
@bartlettroscoe
Copy link
Contributor Author

@gsjaardema, this has finally passed all of the GitHub Action checks so I think this is ready to merge.

@gsjaardema gsjaardema merged commit bb9ba5b into sandialabs:master Dec 22, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Dec 22, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants