1+ cmake_minimum_required (VERSION 3.10 )
2+ project (PLUMED_IDE_HELPER)
3+ set (CMAKE_CXX_STANDARD 17)
4+
5+ ### comment the next line to make it float. Uncomment to make it double.
6+ add_compile_options (-DKENREF_DOUBLE )
7+
8+ # 1. Define PLUMED include paths
9+ # (These paths mimic what 'configure' found. Update paths if they differ on your system)
10+ include_directories (
11+ src
12+ # Add external paths found by configure (copy from Makefile.conf if needed)
13+ /smithlab/opt/fftw/3.3.10/include
14+ /smithlab/opt/openmpi/5.0.7_clang20.1.1_cuda12.4.1/include
15+ )
16+
17+ # 2. KEnRef include paths — point at the REPO working tree (not the installed prefix) so CLion resolves
18+ # the CURRENT KEnRef headers. `.../src` lets the frame forwarders' #include "plumedinterface/..." resolve
19+ # to the repo's src/plumedinterface/*.cpp (the real KEnRefBias impl the frame compiles).
20+ set (KENREF_REPO /home/amr/CLionProjects/KEnRef)
21+ include_directories (
22+ ${KENREF_REPO} /include_core
23+ ${KENREF_REPO} /include_plumedinterface
24+ ${KENREF_REPO} /src
25+ /smithlab/opt/eigen/5.0.1/release/include/eigen3
26+ )
27+
28+ # 3. Add source files
29+ # Recursively find all C++ files so CLion indexes them — PLUMED's own src, PLUS the KEnRef repo's
30+ # plumedinterface source (the KEnRefBias impl the fork frame forwards to) so it shows up in this project.
31+ file (GLOB_RECURSE SOURCES "src/*/*.cpp" "src/*/*.h"
32+ "${KENREF_REPO} /src/plumedinterface/*.cpp"
33+ "${KENREF_REPO} /include_plumedinterface/plumedinterface/*.h" )
34+
35+ # 4. Create a fake target
36+ add_executable (plumed_dummy ${SOURCES} )
37+
38+ add_executable (nothing donothing.cpp )
39+
40+ # 5. Define Macros used by PLUMED (Optional but helps)
41+ add_definitions (-D__PLUMED_HAS_GROMACS -D__PLUMED_HAS_MPI )
0 commit comments