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

C++ cmakelist怎么写 #148

Closed
ycr-sjtu opened this issue Jun 20, 2023 · 1 comment
Closed

C++ cmakelist怎么写 #148

ycr-sjtu opened this issue Jun 20, 2023 · 1 comment

Comments

@ycr-sjtu
Copy link

请问,如果用cmake编译oss程序的时候,cmakelist怎么写?

@ycr-sjtu
Copy link
Author

【已解决】
cmake_minimum_required(VERSION 3.5)
project(YourProjectName VERSION 1.0)

set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_FLAGS "-fno-rtti")

add_executable(test.bin test.cpp)
target_link_libraries(test.bin PRIVATE alibabacloud-oss-cpp-sdk curl crypto pthread)

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

1 participant