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

dirent.h inlcude error building umpire on windows #803

Open
cyrush opened this issue Jan 10, 2023 · 3 comments
Open

dirent.h inlcude error building umpire on windows #803

cyrush opened this issue Jan 10, 2023 · 3 comments

Comments

@cyrush
Copy link
Member

cyrush commented Jan 10, 2023

Describe the bug

Building Umpire 2022.10.0 with Visual Studio 19 on windows, here is my cmake config:

cmake -S ${umpire_src_dir} -B ${umpire_build_dir} \
  -DCMAKE_VERBOSE_MAKEFILE:BOOL=${enable_verbose} \
  -DCMAKE_BUILD_TYPE=Release \
  -DBUILD_SHARED_LIBS=ON \
  -Dcamp_DIR=${camp_install_dir} \
  -DENABLE_OPENMP=${enable_openmp} \
  -DENABLE_TESTS=${enable_tests} \
  -DCMAKE_INSTALL_PREFIX=${umpire_install_dir}

(enable openmp is off, and enabled_tests is off)

I see a compile error related to dirent.h:

       "C:\Users\cyrus\Documents\GitHub\ascent\scripts\build_ascent\build\umpire-2022.10.0\ALL_BUILD.vcxproj" (default target) (1) ->
       "C:\Users\cyrus\Documents\GitHub\ascent\scripts\build_ascent\build\umpire-2022.10.0\src\umpire\util\umpire_util.vcxproj" (default target) (8) ->
       (ClCompile target) ->
         C:\Users\cyrus\Documents\GitHub\ascent\scripts\build_ascent\umpire-2022.10.0\src\umpire\util\io.cpp(26,10): fatal error C1083: Cannot open include file: 'dirent.h': No such file or direc
       tory [C:\Users\cyrus\Documents\GitHub\ascent\scripts\build_ascent\build\umpire-2022.10.0\src\umpire\util\umpire_util.vcxproj]
@davidbeckingsale
Copy link
Member

davidbeckingsale commented Jan 10, 2023

Hey @cyrush on Windows we only support std::filesystem for IO. Can you build with c++17 and -DUMPIRE_ENABLE_FILESYSTEM=On?

You can see the CMake line we are using for testing here: https://github.com/LLNL/Umpire/blob/develop/azure-pipelines.yml#L18

@kab163
Copy link
Contributor

kab163 commented Jan 29, 2024

@cyrush - is this still an issue? Was there a fix?

@cyrush
Copy link
Member Author

cyrush commented Jan 29, 2024

@kab163

-DUMPIRE_ENABLE_FILESYSTEM=On and C++17 did the trick.

Here are the extra params I pass to configure on windows:

https://github.com/Alpine-DAV/ascent/blob/6d1ca3f8d27e9b640be93453c6453f76f545ae7d/scripts/build_ascent/build_ascent.sh#L518

Since I think these are requirements, it would be good if Umpire made the choices in its build system and could error on configure if they aren't available.

Regardless, I have a working path. Hope this helps!

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

No branches or pull requests

3 participants