To install mysql server on Debian
apt-get install mariadb-server
To start, run;
service mysql start
I also found mysql_config not to be found on Debian 10
likely due to the development stuff not being installed as I could also not find /usr/include/mysql
so, installing and resolving is as follows;
sudo apt-get install libmariadb-dev-compat
also worthwhile maybe;
alp-get install libmysqlcppconn-dev
apt-get install libmysql++
I discovered this while trying to use something similar to the following;
execute_process(COMMAND mysql_config --cflags
OUTPUT_VARIABLE MYSQL_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
execute_process(COMMAND mysql_config --libs
OUTPUT_VARIABLE MYSQL_LIBS OUTPUT_STRIP_TRAILING_WHITESPACE)
target_compile_options(checkStamping PUBLIC ${MYSQL_CFLAGS})
target_link_libraries(checkStamping ${MYSQL_LIBS})
similar to;
gcc -o mysql_test $(mysql_config --cflags) $(mysql_config --libs) mysql_test.c
(see here for mysql_config flags)
No comments:
Post a Comment
Note: only a member of this blog may post a comment.