What is the reason for error in CMake?

megamence

I am running the following script to change the name by which I call my GROMACS command from gmx to gmx_196g. The script employs CMake:

cd gromacs-2019.6/build_stage3/
suffix=196g

install_path=/home/my_username/software/gmx_2019/.local

OPTFLAGS="-Ofast -mtune=broadwell"
cmake3 .. -DCMAKE_BUILD_TYPE=Release \
        -DCMAKE_C_COMPILER=icc -DCMAKE_C_FLAGS_RELEASE="$OPTFLAGS" \
        -DCMAKE_CXX_COMPILER=icpc -DCMAKE_CXX_FLAGS_RELEASE="$OPTFLAGS" \
        -DGMX_MPI=ON -DGMX_OPENMP=ON \ -DGMX_GPU=CUDA -DGMX_CUDA_TARGET_SM=60 \
        -DGMX_SIMD=AVX2_256 -DGMX_DOUBLE=OFF \ -DGMX_FFT_LIBRARY=mkl \
        -DGMX_DEFAULT_SUFFIX=OFF -DGMX_BINARY_SUFFIX=_${suffix} -DGMX_LIBS_SUFFIX=_${suffix} \
        -DCMAKE_INSTALL_PREFIX=${install_path}

make -j 8 make install

cd ../../

However, I am receiving this error:

CMake Error: The source directory "/home/my_username/software/gmx_2019/gromacs-2019.6/build_stage3/ -DGMX_FFT_LIBRARY=mkl" does not exist.
Specify --help for usage, or press the help button on the CMake GUI.
make: *** No rule to make target 'make'.  Stop.

Why is the error highlighting -DGMX_FFT_LIBRARY=mkl and my source directory? I am confused as to why this is happening... Any advice you have would be appreciated!

steeldriver

The backslash characters in this context are meant to be line continuation characters, escaping the literal newlines.

When you place a backslash in the middle of a line, it is escaping the following character, so for example in

    -DGMX_MPI=ON -DGMX_OPENMP=ON \ -DGMX_GPU=CUDA -DGMX_CUDA_TARGET_SM=60 \

the \ -DGMX_GPU=CUDA is read as a single token starting with a literal space. Because it doesn't begin with a dash, cmake is interpreting it as a source directory instead of an option.

Either remove such superfluous backslashes

    -DGMX_MPI=ON -DGMX_OPENMP=ON -DGMX_GPU=CUDA -DGMX_CUDA_TARGET_SM=60 \

or use them as intended i.e. as line-continuations

    -DGMX_MPI=ON -DGMX_OPENMP=ON \ 
    -DGMX_GPU=CUDA -DGMX_CUDA_TARGET_SM=60 \

making sure that there are no trailing characters after the \

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

What is the reason of error on git push?

What is the reason for the error A is not a subtype of B

What is the reason for Hibernate Error, SQLGrammarException

What is the reason of overlapping instances error?

what is the reason for this error. (Prisma)

Superblock error, but no clue what's the reason

What is the reason for "Use of unassigned local variable" error?

What is the reason of below error in vespa.ai?

What is the reason for the error "RESOURCE_EXHAUSTED"?

What is the reason for error message "(" was unexpected at this time?

What exactly the reason of Import Error here?

what is the reason of this error in using git bash

What is the reason of error using ycinterextra R package?

What is the reason I got the unit test error?

What is the reason for error message "N was unexpected at this time"?

What the reason of TS error and how to fix it?

what is the reason for this logstash error("error"=>{"type"=>"illegal_argument_exception", "reason"=>"mapper)

What is CMake telling me (error on Windows)?

Redux-toolkit - What could be the reason for a type-error in an extraReducer?

What's the reason and possible solution of this weird error in the configuration of IntelliJ and Tomcat?

What is a reason of getting error: "Unknown property '' on class MyBean"?

What is the reason for this usage error using sockaddr_in() in Perl?

What is the reason for the error message "System cannot find the path specified"?

What's the reason behind "structure has extra field" error

What is the reason for Kubernetes error "a line break is expected" when updating ConfigMap?

What's the reason for NPM Error on firebase deploy --only functions

What is the reason for not spread (es 6 spread operator) javascript Error object

Difference between using @FindBy and By; what could be thre reason for this error?

What is the reason for getting an error when I use eval() with prompt()?

TOP Ranking

  1. 1

    Failed to listen on localhost:8000 (reason: Cannot assign requested address)

  2. 2

    Loopback Error: connect ECONNREFUSED 127.0.0.1:3306 (MAMP)

  3. 3

    How to import an asset in swift using Bundle.main.path() in a react-native native module

  4. 4

    pump.io port in URL

  5. 5

    Compiler error CS0246 (type or namespace not found) on using Ninject in ASP.NET vNext

  6. 6

    BigQuery - concatenate ignoring NULL

  7. 7

    ngClass error (Can't bind ngClass since it isn't a known property of div) in Angular 11.0.3

  8. 8

    ggplotly no applicable method for 'plotly_build' applied to an object of class "NULL" if statements

  9. 9

    Spring Boot JPA PostgreSQL Web App - Internal Authentication Error

  10. 10

    How to remove the extra space from right in a webview?

  11. 11

    java.lang.NullPointerException: Cannot read the array length because "<local3>" is null

  12. 12

    Jquery different data trapped from direct mousedown event and simulation via $(this).trigger('mousedown');

  13. 13

    flutter: dropdown item programmatically unselect problem

  14. 14

    How to use merge windows unallocated space into Ubuntu using GParted?

  15. 15

    Change dd-mm-yyyy date format of dataframe date column to yyyy-mm-dd

  16. 16

    Nuget add packages gives access denied errors

  17. 17

    Svchost high CPU from Microsoft.BingWeather app errors

  18. 18

    Can't pre-populate phone number and message body in SMS link on iPhones when SMS app is not running in the background

  19. 19

    12.04.3--- Dconf Editor won't show com>canonical>unity option

  20. 20

    Any way to remove trailing whitespace *FOR EDITED* lines in Eclipse [for Java]?

  21. 21

    maven-jaxb2-plugin cannot generate classes due to two declarations cause a collision in ObjectFactory class

HotTag

Archive