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

Tidying up CMake files #118

Merged
merged 22 commits into from
Jul 6, 2018
Merged

Tidying up CMake files #118

merged 22 commits into from
Jul 6, 2018

Conversation

jhale
Copy link
Member

@jhale jhale commented Jul 3, 2018

No description provided.

@jhale jhale changed the title Tidying up Cm Tidying up CMake files Jul 3, 2018
@jhale
Copy link
Member Author

jhale commented Jul 3, 2018

This is now ready to merge. MPI and PETSc are now required dependencies. This should make the build logic and the main code easier to read (no HAS_MPI or HAS_PETSC, I could remove these in another pull request?). I also removed some obsolete workarounds for e.g. old Intel compilers.

Regarding Python, I've wrapped some existing Python interpreter calls inside if(PYTHONINTERP_FOUND) guards, but the logic in FindUFC.cmake still requires python3 and FFC. I think it would be nice if it were possible to build dolfinx without Python3 (+FFC) at all, by passing the location of ufc.h by manually passing -DUFC_INCLUDE_DIR. This would make it easier to build on clusters, and then simply push up the FFC generated .h files before compiling. Thoughts?

Copy link
Contributor

@chrisrichardson chrisrichardson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@@ -34,13 +34,11 @@ if (NOT DOLFIN_USE_FILE_INCLUDED)
find_package(Boost 1.48 QUIET REQUIRED COMPONENTS
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should bump the required version to the minimum required for the Python bindings, which I think is 1.55.

@garth-wells
Copy link
Member

UFC detection without Python sounds good (although we want to keep the Python detection for convenience). Maybe check UFC_DIR first, and fall-back to detection via the Python interpreter.

@blechta blechta self-requested a review July 4, 2018 07:27
Copy link
Member

@blechta blechta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We also have docs which have to be updated https://fenicsproject.org/docs/dolfinx/dev/python/installation.html 😉

@@ -119,6 +116,11 @@ foreach (OPTIONAL_PACKAGE ${OPTIONAL_PACKAGES})
add_feature_info(${OPTION_NAME} ${OPTION_NAME} "Compile with support for ${OPTIONAL_PACKAGE}.")
endforeach()

# Required packages
# TODO: Remove #ifdef in code?
option("DOLFIN_ENABLE_PETSC" "Compile with support for PETSc." ON)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is PETSc required?

jhale added 2 commits July 6, 2018 09:30
I couldn't get Boost_VERSION to work (it outputs e.g. 105600 rather than 1.56).
@jhale jhale merged commit 896e36c into master Jul 6, 2018
@jhale jhale deleted the jhale/cmake-changes branch July 6, 2018 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants