开发者

cmake parse error that repeats

I have the following line in a CMakeLists.txt file...

else
        message(FATAL_ERROR "Could not locate Lua 5.1.\n"
                "Please download from Lua website.")
endif

When I run cmake, I get the foll开发者_C百科owing error...

Parse error.  Expected "(", got newline with text "
".

Okay, I figure. That isn't valid syntax, so I'll just edit the cmake file to put it all on a line like so...

message(FATAL_ERROR "Could not locate Lua 5.1.\nPlease download from Lua website.")

Go to the directory where I ran cmake, delete all the cache stuff, re-run it, and I get the same error as before. I've even deleted that whole line and I keep getting the same error. I'm obviously missing something crucial that defines how cmake operates, but I'm not sure what.

Any help is appreciated.


The if, else, elseif, and endif all need () after them.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜