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

CMake: No Fortran #1108

Merged
merged 1 commit into from
Jun 19, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
echo "deb https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
sudo apt-get update
sudo apt-get install -y intel-oneapi-dpcpp-compiler intel-oneapi-mkl gfortran
sudo apt-get install -y intel-oneapi-dpcpp-compiler intel-oneapi-mkl
set +e
source /opt/intel/inteloneapi/setvars.sh
set -e
Expand Down
6 changes: 2 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ include(CTest)
# builds AMReX from source (default) or finds an existing install
include(${WarpX_SOURCE_DIR}/cmake/dependencies/AMReX.cmake)
# suppress warnings in AMReX headers (use -isystem instead of -I)
#make_third_party_includes_system(AMReX::amrex AMReX)
make_third_party_includes_system(AMReX::amrex AMReX)

# PICSAR
# builds PICSAR from source
Expand Down Expand Up @@ -149,9 +149,7 @@ set_target_properties(WarpX PROPERTIES
)

# link dependencies
# FIXME use AMReX::thirdparty::AMReX as soon as
# missing _deps/fetchedamrex-build/mod_files is solved
target_link_libraries(WarpX PUBLIC AMReX::amrex)
target_link_libraries(WarpX PUBLIC WarpX::thirdparty::AMReX)

if(WarpX_ASCENT)
# work-around until ascent's CMake Config scripts are properly placed
Expand Down
1 change: 0 additions & 1 deletion Regression/WarpX-GPU-tests.ini
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ sourceTree = C_Src
suiteName = WarpX-GPU

COMP = g++
FCOMP = gfortran
add_to_c_make_command = TEST=TRUE USE_ASSERTION=TRUE WarpxBinDir=

purge_output = 1
Expand Down
1 change: 0 additions & 1 deletion Regression/WarpX-tests.ini
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ sourceTree = C_Src
suiteName = WarpX

COMP = g++
FCOMP = gfortran
add_to_c_make_command = TEST=TRUE USE_ASSERTION=TRUE WarpxBinDir=

purge_output = 1
Expand Down
2 changes: 1 addition & 1 deletion cmake/WarpXFunctions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ endmacro()
#
function(make_third_party_includes_system imported_target propagated_name)
add_library(WarpX::thirdparty::${propagated_name} INTERFACE IMPORTED)
target_link_libraries(WarpX::thirdparty::${propagated_name} INTERFACE AMReX::amrex)
target_link_libraries(WarpX::thirdparty::${propagated_name} INTERFACE ${imported_target})
get_target_property(ALL_INCLUDES ${imported_target} INCLUDE_DIRECTORIES)
set_target_properties(WarpX::thirdparty::${propagated_name} PROPERTIES INTERFACE_INCLUDE_DIRECTORIES "")
target_include_directories(WarpX::thirdparty::${propagated_name} SYSTEM INTERFACE ${ALL_INCLUDES})
Expand Down
5 changes: 2 additions & 3 deletions cmake/dependencies/AMReX.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,8 @@ macro(find_amrex)
set(ENABLE_DP_PARTICLES OFF CACHE INTERNAL "")
endif()

enable_language(Fortran)
set(ENABLE_FORTRAN ON CACHE INTERNAL "")
set(ENABLE_FORTRAN_INTERFACES ON CACHE INTERNAL "")
set(ENABLE_FORTRAN OFF CACHE INTERNAL "")
set(ENABLE_FORTRAN_INTERFACES OFF CACHE INTERNAL "")
set(ENABLE_TUTORIALS OFF CACHE INTERNAL "")
set(ENABLE_PARTICLES ON CACHE INTERNAL "")
set(ENABLE_TINY_PROFILE ON CACHE INTERNAL "")
Expand Down