File tree Expand file tree Collapse file tree 3 files changed +20
-7
lines changed Expand file tree Collapse file tree 3 files changed +20
-7
lines changed Original file line number Diff line number Diff line change @@ -236,9 +236,11 @@ file(WRITE "${INFO}" "Connector/C++ build information.\n\n")
236
236
set (INFO_PREFIX "jdbc-" )
237
237
238
238
merge_libraries (connector-jdbc jdbc )
239
+ target_link_libraries (connector-jdbc PUBLIC Boost::boost )
239
240
240
241
if (MAINTAINER_MODE )
241
242
merge_libraries (connector-jdbc-static STATIC jdbc )
243
+ target_link_libraries (connector-jdbc-static PUBLIC Boost::boost )
242
244
endif ()
243
245
244
246
@@ -306,6 +308,13 @@ INSTALL(FILES ${MYSQLCPPCONN_SPECIFIC_INSTALL_HEADERS}
306
308
COMPONENT JDBCDev
307
309
)
308
310
311
+ # Note: Copy to build location so that test code can use headers without
312
+ # installing them first.
313
+
314
+ file (COPY ${MYSQLCPPCONN_SPECIFIC_INSTALL_HEADERS}
315
+ DESTINATION "${CMAKE_BINARY_DIR} /include/jdbc"
316
+ )
317
+
309
318
if (TARGET connector-jdbc-static )
310
319
311
320
set_property (TARGET connector-jdbc-static PROPERTY OUTPUT_NAME ${LIB_NAME_STATIC} )
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ CONFIGURE_FILE(version_info.h.cmake version_info.h @ONLY)
65
65
66
66
SET (MYSQLCPPCONN_INSTALL_HEADERS
67
67
build_config.h
68
- ${CMAKE_CURRENT_BINARY_DIR} /config.h
68
+ " ${CMAKE_CURRENT_BINARY_DIR} /config.h"
69
69
connection.h
70
70
datatype.h
71
71
driver.h
@@ -78,11 +78,18 @@ SET(MYSQLCPPCONN_INSTALL_HEADERS
78
78
statement.h
79
79
sqlstring.h
80
80
warning.h
81
- ${CMAKE_CURRENT_BINARY_DIR} /version_info.h
81
+ " ${CMAKE_CURRENT_BINARY_DIR} /version_info.h"
82
82
variant.h )
83
83
84
84
INSTALL (
85
85
FILES ${MYSQLCPPCONN_INSTALL_HEADERS}
86
- DESTINATION ${INSTALL_INCLUDE_DIR} /cppconn
86
+ DESTINATION " ${INSTALL_INCLUDE_DIR} /cppconn"
87
87
COMPONENT JDBCDev
88
88
)
89
+
90
+ # Note: Copy to build location so that test code can use headers without
91
+ # installing them first.
92
+
93
+ file (COPY ${MYSQLCPPCONN_INSTALL_HEADERS}
94
+ DESTINATION "${CMAKE_BINARY_DIR} /include/jdbc/cppconn"
95
+ )
Original file line number Diff line number Diff line change 48
48
49
49
#include < boost/scoped_ptr.hpp>
50
50
51
- #include < jdbc/mysql_connection.h>
52
- #include < jdbc/mysql_driver.h>
53
- #include < jdbc/cppconn/resultset.h>
54
- #include < jdbc/cppconn/statement.h>
51
+ #include < mysql/jdbc.h>
55
52
56
53
#define DEFAULT_URI " tcp://127.0.0.1"
57
54
#define EXAMPLE_USER " root"
You can’t perform that action at this time.
0 commit comments