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

Adjust MSVC detection/support in CMakeLists.txt #1842

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

Spudz76
Copy link
Contributor

@Spudz76 Spudz76 commented Sep 19, 2018

  • Add vim modeline to end of file to help ensure correct indents (no tabs, 4 spaces)
  • Patch whitespace where indent did not match above rules
  • When MSVC, protect -std=c++11 from being added to CUDA_NVCC_FLAGS (avoid warnings during compile)
  • Add /LTCG to global linker flags (avoid "restarting linker" warning during link of openssl/hwloc deps)
  • Add also /INCREMENTAL:NO /OPT:REF to shared linker flags for smaller EXE (unused references removal)
  • Add /Ox /GL /EHsc to compiler flags to generate output compatible with above new linker flags

@Spudz76
Copy link
Contributor Author

Spudz76 commented Sep 19, 2018

I have been using these patches on my own "daily driver" rigs for over 6 months, pretty sure they work nice. Mostly makes a handful of the pointless build warnings go away, does not appear to cause any problems.

Spudz76 added a commit to Spudz76/xmr-stak that referenced this pull request Sep 19, 2018
@psychocrypt
Copy link
Collaborator

psychocrypt commented Sep 24, 2018

Could you please remove the white space changes in this PR. Please do never mix formatting of a full file with any improvements.
If you add a separate PR where all white spaces changes are in I can check it without doing any test. Also there is no need to mentioned white space changes in the change log but changing linker flags are important.

@Spudz76
Copy link
Contributor Author

Spudz76 commented Sep 24, 2018

refactored

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants