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

build cmake windows 10 #521

Closed
holzpfanne opened this issue Dec 30, 2019 · 1 comment
Closed

build cmake windows 10 #521

holzpfanne opened this issue Dec 30, 2019 · 1 comment

Comments

@holzpfanne
Copy link

holzpfanne commented Dec 30, 2019

I am trying to build json-c on windows 10 with cmake
after I execute cmake ../ at the end I get:

-- Performing Test HAS_GNU_WARNING_LONG - Failed
-- Performing Test HAVE_ATOMIC_BUILTINS
-- Performing Test HAVE_ATOMIC_BUILTINS - Failed
-- Performing Test HAVE___THREAD
-- Performing Test HAVE___THREAD - Failed
-- Written C:/Users/****/source/repos/json-c/build/config.h
-- Written C:/Users/****/source/repos/json-c/build/json_config.h
-- Configuring done
-- Generating done
-- Build files have been written to: C:/Users/****/source/repos/json-c/build

And no makefile is then created
I am following those instructions
Am I doing something wrong?
Any help is appreciated
thanks in advance

@hawicz
Copy link
Member

hawicz commented Dec 31, 2019

The cmake build on windows doesn't create makefiles, it creates Visual Studio project files instead. You can build from the command line using something similar to what https://github.com/json-c/json-c/blob/master/appveyor.yml does (i.e. cmake --build . --target install), but you'll need to do that from a command prompt that is set up to run the VS tools (e.g. cl.exe) properly (e.g. "Developer Command Prompt for VS2015").
Once you have a command prompt with the right environment, you should also be able to run msbuild.exe directly, instead of having cmake do it for you.
Or, you can open the project files using the VS gui.

@hawicz hawicz closed this as completed Dec 31, 2019
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

2 participants