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

Add cmake support. #457

Merged
merged 3 commits into from Jun 4, 2015
Merged

Add cmake support. #457

merged 3 commits into from Jun 4, 2015

Conversation

xfxyjwf
Copy link
Contributor

@xfxyjwf xfxyjwf commented Jun 3, 2015

Add cmake support primarily for Visual Studio users. These scripts can also be used to build protobuf on Linux, MinGW, Cygwin as well.

This PR also includes a shell script used to copy file lists from src/Makefile.am to cmake files so we don't need to do that manually.

@pherl to review

@snikulov snikulov mentioned this pull request Jun 3, 2015
> cd path/to/protobuf/cmake
> mkdir build
> cd build
> cmake -G "Visual Studio 9 2008" ..
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like text after '..' becomes grey for some reason. Please double check if it is some special mark down syntax.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. Fixed the formatting of this file.

@liujisi
Copy link
Contributor

liujisi commented Jun 4, 2015

Should we delete the current msvc proj files? Or should we generated them in releases and do not include them in git?

@paleozogt
Copy link

I vote for leaving them out of git. The generated project files can be thought of in the same way as binaries-- they're compiled artifacts generated from the source.

@jtattermusch
Copy link
Contributor

I think commiting the generated projects makes sense. It's easier for users to start when they already have their vsprojects ready once they clone - non everyone has cmake installed.

if we commit the vsproject files, we need to make sure they are always up to date (there should be a presubmit check that verifies that regenerating the projects using cmake yields no diff).

@xfxyjwf xfxyjwf force-pushed the cmake branch 3 times, most recently from 1216d45 to cd0f7ec Compare June 4, 2015 18:24
Change-Id: I121cb70bfdc4894c297ab1a36f1db47736c0652b
@xfxyjwf
Copy link
Contributor Author

xfxyjwf commented Jun 4, 2015

Vsproject files generated by cmake actually depend on cmake. When you build the solution, it will run cmake to check whether any dependencies have changed and regenerate vsproject files if necessary. The last time I checked, they have no plan to update cmake to generate *clean" vsproject files that can work alone without cmake. So users would have to install cmake anyway regardless of whether we check-in the generated files. Given this, checking in these files provides little value and we probably shouldn't do that.

@liujisi
Copy link
Contributor

liujisi commented Jun 4, 2015

LGTM

xfxyjwf added a commit that referenced this pull request Jun 4, 2015
@xfxyjwf xfxyjwf merged commit 42f109d into protocolbuffers:master Jun 4, 2015
@xfxyjwf xfxyjwf deleted the cmake branch June 6, 2015 00:36
bithium pushed a commit to bithium/protobuf that referenced this pull request Sep 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants