Skip to content

Commit d9c9b87

Browse files
committed
Merge branch 'master' of https://github.com/dnybz/cppbase
2 parents bc77c4e + 1756ec8 commit d9c9b87

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/CMakeLists.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -588,9 +588,11 @@ link_directories(${PROJECT_BINARY_DIR}/bin)
588588

589589
if (WIN32)
590590
target_link_libraries(base Netapi32 PowrProf Setupapi Version Dbghelp Ws2_32 Shlwapi)
591-
else (WIN32)
591+
elseif (LINUX)
592592
target_link_libraries(base dl pthread)
593-
endif(WIN32)
593+
elseif (BSD)
594+
target_link_libraries(base dl pthread execinfo)
595+
endif()
594596

595597
if (MSVC)
596598
add_custom_command(TARGET ${PROJECT_NAME} POST_BUILD

src/examples/process_info.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
int main(int argc, char** argv) {
99

10+
#if defined(OS_WIN) || defined(OS_LINUX)
1011
int process_id = 0;
1112
if (argc >= 2) {
1213
process_id = std::stoi(std::string(argv[1]));
@@ -44,5 +45,6 @@ int main(int argc, char** argv) {
4445

4546
}
4647

48+
#endif
4749
return 0;
4850
}

0 commit comments

Comments
 (0)