Please check out these resources.
https://cmake.org/cmake/help/latest/module/FindPkgConfig.html
https://gitlab.com/petsc/petsc/-/merge_requests/2367
Yann Jobic writes:
> Hi all,
>
> I solved my problem, but i don't know if it's the right way to do it.
> Libs.private is used in case of static
Hi all,
I solved my problem, but i don't know if it's the right way to do it.
Libs.private is used in case of static linking. So I added:
execute_process ( COMMAND pkg-config PETSc --libs --static
OUTPUT_VARIABLE STATIC_LIBS)
string(STRIP ${STATIC_LIBS} STATIC_LIBS)
message("Libs static : "
Hi all,
I'm trying to create a correct CMakeLists.txt in order to compile a
petsc program.
I can compile my code, but i cannot link it.
I have this link command :
/local/lib/openmpi/gcc8/4.0.3/bin/mpicc -g -rdynamic
CMakeFiles/Test1.dir/src/dvm_dg1D_qff_2dV.c.o