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

Rename example dir balance_seeds to balance #231

Merged
merged 1 commit into from
Aug 30, 2023

Conversation

cburstedde
Copy link
Owner

Rename example balance_seeds to balance

The example directory balance_seeds contains a specific balance test. To add further balance tests in the future, it will be more fitting to rename the directory plainly to balance.

@cburstedde
Copy link
Owner Author

Asking @mkirilin: does CMake build all example exactly as the autotools do it?

@mkirilin
Copy link
Collaborator

@cburstedde
CMake doesn't build examples. Neither during p4est build nor by manual build call for the examples. At the latter case it stops configuring with the error:

-- Could NOT find SC (missing: SC_DIR)
CMake Error at /opt/software/easybuild/software/CMake/3.23.1-GCCcore-11.3.0/share/cmake-3.23/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find SC (missing: SC_LIBRARY SC_INCLUDE_DIR SC_mpi_ok)
Call Stack (most recent call first):
  /opt/software/easybuild/software/CMake/3.23.1-GCCcore-11.3.0/share/cmake-3.23/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
  /home/kirilin/p4est_workspace/p4est/cmake/FindSC.cmake:66 (find_package_handle_standard_args)
  CMakeLists.txt:26 (find_package)

@cburstedde
Copy link
Owner Author

@cburstedde CMake doesn't build examples. Neither during p4est build nor by manual build call for the examples. o

Thanks for checking. Likely some of our CMake updates did not update the part about the examples and is now incompatible to the core. Do you see any way to repair this?

@pkestene
Copy link
Contributor

@mkirilin

Just FYI.
currently, the way cmake has been setup in example folder, examples are treated as a separated cmake project; so when you build p4est, examples are not built. One has to build p4est examples separated taking care of providing build information about where p4est libs where installed.

here is what I do to build both p4est and p4est examples with cmake:

# 1. build p4est
cd $(P4EST_SRC)
mkdir -p _build/cmake
cd _build/cmake
cmake ../..
make; make install
# you should have a folder "local" where both p4est and libsc were just installed
# 2. now build p4est examples using p4est install in "local"
mkdir examples
cd examples
cmake -DCMAKE_PREFIX_PATH=`pwd`/../local ../../../example
make

For me building the p4est example works fine; it just a bit "convoluted" because examples are in separated cmake project. It should be documented somewhere.

@cburstedde
Copy link
Owner Author

cburstedde commented Aug 25, 2023 via email

@pkestene
Copy link
Contributor

Should'nt be hard. I'll look it.

@cburstedde
Copy link
Owner Author

I'll merge this now to continue with the proper directory structure.

@cburstedde cburstedde merged commit 5170b82 into develop Aug 30, 2023
36 checks passed
@cburstedde cburstedde deleted the feature-rename-example branch August 30, 2023 09:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants