Skip to content

Commit 1e8eedf

Browse files
committed
FreeBSD has no "libresolv"
If a 64-bit build, only set CONCPP_LIB_DIR to "lib64" if it exists updated the jdbc submodule
1 parent 6b6631c commit 1e8eedf

File tree

3 files changed

+13
-11
lines changed

3 files changed

+13
-11
lines changed

cdk/foundation/CMakeLists.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
1+
# Copyright (c) 2015, 2020, Oracle and/or its affiliates. All rights reserved.
22
#
33
# This program is free software; you can redistribute it and/or modify
44
# it under the terms of the GNU General Public License, version 2.0, as
@@ -94,9 +94,9 @@ target_link_libraries(cdk_foundation
9494
)
9595

9696
IF(WIN32)
97-
target_link_libraries(cdk_foundation PRIVATE Dnsapi)
98-
ELSE()
99-
target_link_libraries(cdk_foundation PRIVATE resolv)
97+
target_link_libraries(cdk_foundation PRIVATE Dnsapi)
98+
ELSEIF(NOT FREEBSD)
99+
target_link_libraries(cdk_foundation PRIVATE resolv)
100100
ENDIF()
101101

102102
IF(WIN32)

testapp/CMakeLists.txt

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
1+
# Copyright (c) 2015, 2020, Oracle and/or its affiliates. All rights reserved.
22
#
33
# This program is free software; you can redistribute it and/or modify
44
# it under the terms of the GNU General Public License, version 2.0, as
@@ -85,7 +85,7 @@ if(WITH_CONCPP)
8585
set(CONCPP_INCLUDE_DIR "${WITH_CONCPP}/include")
8686
endif()
8787
if(NOT CONCPP_LIB_DIR)
88-
if(IS64BIT)
88+
if(IS64BIT AND EXISTS "${WITH_CONCPP}/lib64")
8989
set(CONCPP_LIB_DIR "${WITH_CONCPP}/lib64")
9090
else()
9191
set(CONCPP_LIB_DIR "${WITH_CONCPP}/lib")
@@ -300,10 +300,12 @@ if(NOT WIN32)
300300
)
301301
endif()
302302

303-
# Connector needs to Link with libresolv
304-
set_property(TARGET MySQL::conncpp
305-
APPEND PROPERTY INTERFACE_LINK_LIBRARIES resolv
306-
)
303+
if(NOT FREEBSD)
304+
# Connector needs to Link with libresolv
305+
set_property(TARGET MySQL::conncpp
306+
APPEND PROPERTY INTERFACE_LINK_LIBRARIES resolv
307+
)
308+
endif()
307309

308310
else()
309311
# Connector needs to Link with Dnsapi

0 commit comments

Comments
 (0)