Skip to content

An assortment of CMake fixes and cleanups - #8

Open
ligfx wants to merge 10 commits into
DFHack:masterfrom
ligfx:cmake_fixes
Open

An assortment of CMake fixes and cleanups#8
ligfx wants to merge 10 commits into
DFHack:masterfrom
ligfx:cmake_fixes

Conversation

@ligfx

Copy link
Copy Markdown

No description provided.

Compilers like Clang are becoming available on Windows. If there's a
requirement on something provided by only MINGW and MSVC, it should be
specified directly.
ligfxand others added 8 commits October 30, 2017 11:19
- The CLSOCKET_SHARED logic is done for free by the standard CMake
option BUILD_SHARED_LIBS.
- The CLSOCKET_DEP_ONLY logic can be achieved by passing the
EXCLUDE_FROM_ALL option to add_subdirectory when adding clsocket.
Global names beginning with an underscore are reserved, and each system
already defines relevant macros:
- All Linux and BSD targets (except Apple) define __unix__
- All Apple targets define __APPLE__
- All Windows targets define _WIN32
For more information, see
http://nadeausoftware.com/articles/2012/01/c_c_tip_how_use_compiler_predefined_macros_detect_operating_system
Makes it easier to use inside of another project by correctly propagating
usage requirements.
It's set automatically based on file extension.
It was inconsistent, standardize on the KitWare preferred style.
@ligfx

Copy link
Copy Markdown
Author

I think the CI failure is fixed by #11, and isn't related to these changes.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@ligfx@myk002