반응형 C++6 mac에서 Jsoncpp 설치하기 $ brew install jsoncpp 코드에는 아래와 같이 헤더파일추가 #include # compile with option -ljson 2020. 1. 23. linux C/C++ openssl 설치 후 빌드에러 libssl-dev / openssl 설치 후에 빌드시 아래 에러가 나오면 undefined reference to `OPENSSL_init_ssl' undefined reference to `OPENSSL_init_ssl' 아래 결과로 나온 경로를 빌드경로에 작성해준다 (예: SSL = -L/usr/local/lib -lssl -lcrypto ) $ pkg-config openssl --libs -L/usr/local/lib -lssl -lcrypto 2020. 1. 22. [networkprogramming] mac에서 bind코드가 잘 안될때 if (bind(server_desc_, (struct sockaddr*) &h_addr_, sizeof(h_addr_)) == -1) { 이 코드를 아래 코드로 변환해준다 if (::bind(server_desc_, (sockaddr *) &servaddr, sizeof(servaddr)) < 0) { 2020. 1. 21. linux C/C++ mysql 사용하기 $ apt-get install libmysqlclient-dev [ mysql.h 위치 찾기 ] mysql_config --cflags [ include mysql.h 방법 ] #include "/usr/include/mysql/mysql.h" (위에서 찾은 위치경로) [ 컴파일 방법 ] g++ -o 프로그램명 파일명.c -lmysqlclient 2020. 1. 21. 이전 1 2 다음 반응형