mirror of
https://github.com/dolthub/dolt.git
synced 2026-05-04 03:11:52 -05:00
amend Dockerfile to embed interpreters from diff build stages
# Conflicts: # go/cmd/dolt/doltversion/version.go # go/go.mod # go/go.sum
This commit is contained in:
@@ -1,17 +0,0 @@
|
||||
cmake_minimum_required(VERSION 3.10)
|
||||
|
||||
project(DoltCxxConnectorTest
|
||||
VERSION 0.1
|
||||
DESCRIPTION "A smoke test for mysql-connector-c++ connecting to Dolt"
|
||||
LANGUAGES CXX)
|
||||
|
||||
add_executable(test_mysql_connector_cxx mysql-connector-cpp-test.cpp)
|
||||
set_property(TARGET test_mysql_connector_cxx PROPERTY CXX_STANDARD 11)
|
||||
|
||||
if(WITH_JDBC)
|
||||
add_subdirectory(third_party/mysql-connector-cpp EXCLUDE_FROM_ALL)
|
||||
target_link_libraries(test_mysql_connector_cxx connector-jdbc)
|
||||
else()
|
||||
find_library(LIBMYSQLCPPCONN "mysqlcppconn")
|
||||
target_link_libraries(test_mysql_connector_cxx "${LIBMYSQLCPPCONN}")
|
||||
endif()
|
||||
@@ -1,14 +1,14 @@
|
||||
MYSQL_CONCPP_DIR = /usr/local/Cellar/mysql-connector-c++/8.0.21
|
||||
CPPFLAGS = -I $(MYSQL_CONCPP_DIR)/include -L $(MYSQL_CONCPP_DIR)/lib64
|
||||
LDLIBS = -lmysqlcppconn8
|
||||
CXX = clang++ -stdlib=libc++
|
||||
CXXFLAGS = -std=c++11
|
||||
CXX = g++
|
||||
CXXFLAGS = -I/usr/include/cppconn -std=c++11 -Wall -O2
|
||||
LDFLAGS = -lmysqlcppconn
|
||||
TARGET = /build/bin/cpp-mysql-connector-test
|
||||
SRCS = mysql-connector-cpp-test.cpp
|
||||
|
||||
all: mysql-connector-cpp-test
|
||||
all: $(TARGET)
|
||||
|
||||
mysql-connector-cpp-test: mysql-connector-cpp-test.cpp
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) -o $@ $^ $(LDLIBS)
|
||||
$(TARGET): $(SRCS)
|
||||
@mkdir -p /build/bin
|
||||
$(CXX) $(CXXFLAGS) -o $@ $^ $(LDFLAGS)
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -f mysql-connector-cpp-test
|
||||
rm -f $(TARGET)
|
||||
|
||||
@@ -46,6 +46,11 @@ std::string queries[QUERIES_SIZE] =
|
||||
int is_update[QUERIES_SIZE] = {1,0,0,1,0,0,0,0,0,1,0,0,0,0};
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
if (argc < 4) {
|
||||
std::cerr << "Usage: " << argv[0] << " <user> <port> <database>" << std::endl;
|
||||
return 1;
|
||||
}
|
||||
|
||||
std::string user = argv[1];
|
||||
std::string port = argv[2];
|
||||
std::string db = argv[3];
|
||||
|
||||
Reference in New Issue
Block a user