Skip to content

Unable to test the build of stdlib library using CMake #348

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

Closed
aman-godara opened this issue Mar 18, 2021 · 6 comments
Closed

Unable to test the build of stdlib library using CMake #348

aman-godara opened this issue Mar 18, 2021 · 6 comments

Comments

@aman-godara
Copy link
Member

aman-godara commented Mar 18, 2021

I was working in the directory D:/GSoC/Fortran Codes and used the command cmake -B build -G Ninja to get this message.

-- Detecting Fortran compiler ABI info
-- Detecting Fortran compiler ABI info - done
-- Check for working Fortran compiler: C:/MinGW/bin/gfortran.exe - skipped
-- Checking whether C:/MinGW/bin/gfortran.exe supports Fortran 90
-- Checking whether C:/MinGW/bin/gfortran.exe supports Fortran 90 - yes
-- Performing Test f18errorstop
-- Performing Test f18errorstop - Success
-- Performing Test f03rank
-- Performing Test f03rank - Success
-- Performing Test f03real128
-- Performing Test f03real128 - Success
-- Configuring done
-- Generating done
-- Build files have been written to: D:/GSoC/Fortran Codes/build

Then I ran the command cmake --build build --target test and got a very long error.
This is how the end of the error looks like:

Errors while running CTest
FAILED: CMakeFiles/test.util
cmd.exe /C "cd /D "D:\GSoC\Fortran Codes\build" && C:\Users\<myusername>\AppData\Roaming\Python\Python37\site-packages\cmake\data\bin\ctest.exe --force-new-ctest-process "
ninja: build stopped: subcommand failed.

I was working on a different version of the stdlib (after successfully pulling #346 to my local machine using Git) while I was following the instructions given in README.md file of stdlib. I was following the instructions from top to bottom one by one until I got this error.

I am using gfortran compiler GNU Fortran (MinGW.org GCC Build-2) 9.2.0 and platform architecture is
image
with Windows 10 as the operating system.
CMake version cmake version 3.18.4
Ninja version 1.10.0.git.kitware.jobserver-1
fypp version 3.0, python version Python 3.7.7

Can anyone please help me with it? Thank you.

@aman-godara
Copy link
Member Author

aman-godara commented Mar 25, 2021

Hey! Can anyone help me with this? I tried using gfortran GNU Fortran (Rev9, Built by MSYS2 project) 10.2.0 but the problem persisted. The README.md file of stdlib says that people were able to successfully build stdlib with MSYS version 10 of GCC Fortran but for me it failed. I will be grateful if anyone can help me with it. Thank you.

@LKedward
Copy link
Member

Hi @aman-godara, did you run cmake --build build first, before running cmake --build build --target test?

@aman-godara
Copy link
Member Author

aman-godara commented Mar 25, 2021

Hi @aman-godara, did you run cmake --build build first, before running cmake --build build --target test?

I ran this command cmake -B build -G Ninja.

@LKedward
Copy link
Member

You are perhaps missing a step, there are three separate commands to run:

cmake -B build -G Ninja

cmake --build build

cmake --build build --target test

@LKedward
Copy link
Member

I ran the command asked by you on a freshly cloned stdlib repository but I got errors. Can you please once check if current repository is successfully building on your local machine?

Yes I just ran these on the latest stdlib version. What errors are you getting now?

@aman-godara
Copy link
Member Author

aman-godara commented Mar 25, 2021

I ran the command asked by you on a freshly cloned stdlib repository but I got errors. Can you please once check if current repository is successfully building on your local machine?

Yes I just ran these on the latest stdlib version. What errors are you getting now?

It worked somehow this time. Thank you!! Probably I was doing something wrong.

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