Installation for Windows

53 views
Skip to first unread message

Paolo Tesini

unread,
Sep 1, 2025, 11:31:22 AMSep 1
to deal.II User Group
Hi all,

I built the program on Windows using CMake with Ninja instead of GNU Make:

cmake -G Ninja -DCMAKE_INSTALL_PREFIX=...

Configuration completed with only one warning: 
"No cmake_minimum_required command is present. A line of code such as cmake_minimum_required(VERSION 3.29) should be added at the top of the file."

It seems to have worked, but I’m not sure if that warning affects this step.

Furthermore, normally the followong instructions say to run:

make --jobs=4 install
make test

Could you please tell me how I should adapt these commands when using Ninja, and whether I need to add any additional instructions?

Best regards
paolo


blais...@gmail.com

unread,
Sep 2, 2025, 4:37:12 AMSep 2
to deal.II User Group
The warning you are referring to concerns the cmake version declaration. In the present case, it would appear that the cmake version you are using is a lot more recent than what deal.II requires. Newer cmake version tend to require you to have very high version number of cmake_minimum_required() for compatibility reason I suppose. In all cases, if your cmake configuration ran, everything should be fine.


regarding:
 make --jobs=4 install

If you configured deal.II with ninja instead of make, then you would use the following command:
ninja -j4 install
ninja test

Whether you use ninja or make to compile deal.II won't have any significant consequences on the outcome (although ninja is faster).

Cheers
Bruno

Paolo Tesini

unread,
Sep 2, 2025, 10:18:50 AMSep 2
to dea...@googlegroups.com
Thanks for your help so far.

Inside my build folder (which contains now the generated files: base (folder), CMakeFiles (folder), build.ninja, cmake_install, CMakeCache), when I run:

ninja -j4 install

I get the error: ninja: error: unknown target 'install'

Do you know why this happens, and how I should proceed?

Thank you very much
Best regards,
paolo

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dealii+un...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/dealii/14871cdb-84ea-4acd-901b-8899f6cb6ee5n%40googlegroups.com.

Matthias Maier

unread,
Sep 2, 2025, 10:41:50 AMSep 2
to dea...@googlegroups.com
You very likely did not configure with the correct base directory. You
will need to make sure that you configure with the source directory
containing LICENSE.md/README.md/SUPPORT.md and not another directory.

That way the warning goes away and you will have an install target.

MM
>> <https://groups.google.com/d/msgid/dealii/14871cdb-84ea-4acd-901b-8899f6cb6ee5n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>

Paolo Tesini

unread,
Sep 2, 2025, 2:21:36 PMSep 2
to dea...@googlegroups.com
Thank you very much. Let me clarify my situation a bit better:

When I decompress the archive, it creates the folder dealii-9.7.0.
Inside this folder there are several subfolders (including \include\deal.II) and various files such as LICENSE.md, README.md, and SUPPORT.md.

However, those files (LICENSE.md, README.md, SUPPORT.md) are only in the top-level dealii-9.7.0 directory, not inside \include\deal.II.

My question is:
Where exactly should I create the build directory from which to run "cmake -G Ninja -DCMAKE_INSTALL_PREFIX=C:\Users\bin\deal.II ../deal.II" and how should I adjust ../deal.II, considering that the deal.II directory itself does not contain the LICENSE.md, README.md, and SUPPORT.md files?

Thanks again for your help
paolo

Daniel Arndt

unread,
Sep 2, 2025, 2:33:26 PMSep 2
to dea...@googlegroups.com
Paolo,

it doesn't matter where you create the. build directory (as long as
it's a subdirectory) but you need to point CMake to the uppermost
directory that has a CMakeLists.txt file (which should be the same as
the one containing LICENSE.md, README.md, and SUPPORT.md .

Best,
Daniel
> To view this discussion visit https://groups.google.com/d/msgid/dealii/CAPGdp0oQ3fTF_bNTvRgJwaBH2Ni-AkQpu3XvXOiO1SXOO6P07Q%40mail.gmail.com.
Message has been deleted

Paolo Tesini

unread,
Sep 4, 2025, 5:03:49 AMSep 4
to dea...@googlegroups.com
Thanks again. I pointed CMake to the uppermost directory that contains the CMakeLists.txt file along with LICENSE.md, README.md, and SUPPORT.md. Now the configuration seems to start correctly:

-- Performing Test DEAL_II_HAVE_FLAG_Werror
-- Performing Test DEAL_II_HAVE_FLAG_Werror - Success
-- Performing Test DEAL_II_HAVE_FLAG_pedantic
-- Performing Test DEAL_II_HAVE_FLAG_pedantic - Success
-- Performing Test DEAL_II_HAVE_FLAG_Wall
...

  But then I get, for example:
...
-- Performing Test DEAL_II_HAVE_AVX512 - Failed
-- Performing Test DEAL_II_HAVE_ALTIVEC - Failed
...

And finally: 

-- Looking for C++ include sys/resource.h - not found
-- Looking for C++ include unistd.h - found
-- Looking for gethostname - not found
-- Looking for getpid - found
CMake Error at cmake/checks/check_02_system_features.cmake:85 (message):

  Cygwin and forks such as MinGW and MinGW-64 are unsupported due to multiple
  unresolved miscompilation issues.

Call Stack (most recent call first):
  cmake/macros/macro_verbose_include.cmake:18 (include)
  CMakeLists.txt:129 (verbose_include)

-- Configuring incomplete, errors occurred!

Any advice on how to solve this issue?    

thank you very much
paolo

Matthias Maier

unread,
Sep 4, 2025, 3:09:06 PMSep 4
to dea...@googlegroups.com
Long story short: We lack the manpower and motivation to support cygwin
and mingw. You can simply remove this check from
cmake/checks/check_02_system_features.cmake in line 85 and try your luck
but I doubt that this will work.

As an alternative, what about using WSL (Windows Subsystem for
Linux). WSL-2 has excellent support for running entire Linux
distributions on top of windows; the Ubuntu and Debian variant can be
installed with one click from the Microsoft store and they come with
all crucial dependencies already packaged. For Ubuntu in particular you
simply add the PPA for the latest release and then

$ apt install libdeal.ii-dev

Afterwards you can simply check out the current development version and
compile by hand if you want to have the latest version.

Best,
Matthias
>> https://groups.google.com/d/msgid/dealii/CAOYDWbJZEb3rmtyJqW9vaemtoLfUM%2BMDzqfAmcbiT96DKa-uVA%40mail.gmail.com
>> .
>>
Reply all
Reply to author
Forward
Message has been deleted
0 new messages