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

hw11,这次还行 #10

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

Conversation

knowledgaction
Copy link

  • cmake_minimum_required具有指定cmake_policy的功能,不指定 cmake_minimum_required的话会报错, CMP0048相关的错误,可能是不能用现代CMake。
  • 为了适应legacy,LANGUAGES设为CXX C,子可以看到父的变量。
    -set(CMAKE_CXX_STANDARD 17), 设置c++标准。
  • file(GLOB_RECURSE main_sources CONFIGURE_DEPENDS src/*.cpp ) 在src目录下搜集.cpp文件。
  • ${PROJECT_VERSION}表示项目版本。
  • exe与dll生成在不同目录,设置下mylib库的属性,指定它的位置。
  • 最后一个设为PUBLIC,只有PUBLIC才能看到include的路径。(这块不太确定,哈哈~~)

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

Successfully merging this pull request may close these issues.

1 participant