Defacer35 21 Posted March 6, 2021 Share Posted March 6, 2021 (edited) Hello devs, after a C++20 released i want to upgrade my compiler support 17 to 20 but i have little trouble with libsql ; Best Regards. Edited August 18, 2022 by Metin2 Dev Core X - External 2 Internal Link to comment Share on other sites More sharing options...
Defacer35 21 Posted March 7, 2021 Author Share Posted March 7, 2021 Bump. @Mali61 Any idea my friend ? 1 Link to comment Share on other sites More sharing options...
Defacer35 21 Posted March 8, 2021 Author Share Posted March 8, 2021 Bump. Link to comment Share on other sites More sharing options...
Defacer35 21 Posted March 14, 2021 Author Share Posted March 14, 2021 Still not solved. Link to comment Share on other sites More sharing options...
Developer Ikarus_ 2414 Posted March 15, 2021 Developer Share Posted March 15, 2021 post the makefile libsql 1 My youtube channel on which you can see my works here Link to comment Share on other sites More sharing options...
Defacer35 21 Posted March 16, 2021 Author Share Posted March 16, 2021 4 hours ago, Ikarus_ said: post the makefile libsql CXX = g++10 BIN = ../libsql.a CFLAGS = -I/usr/local/include/mysql -Wall -O2 -ggdb3 -g3 -std=gnu++20 -pipe -mtune=i386 -fstack-protector -static CPP = AsyncSQL.cpp Semaphore.cpp Statement.cpp Tellwait.cpp all: $(BIN) clean: rm -f *.o rm -f $(BIN) %.o: %.cpp @echo -e "\033[0;32m[LibSQL]\033[0m \033[0;33mDerleniyor;\033[0m" $* @$(CXX) $(CFLAGS) -c $^ -o $@ $(BIN): $(CPP:%.cpp=%.o) @ar cru $(BIN) $^ @ranlib $(BIN) chmod 700 $(BIN) Link to comment Share on other sites More sharing options...
Developer Solution Ikarus_ 2414 Posted March 16, 2021 Developer Solution Share Posted March 16, 2021 (edited) It looks like it is getting "false" as an int somehow. I ve no idea why it is happening only to you. A dirty solution may be define a spaceship operator with bool and int at the beginning of AsyncSQL.h (before the includes). Since i can't reproduce the error i m not able to check if my propose is valid (and i neither tried to compile the code tbh). inline constexpr auto operator<=>(const bool x, const int y) { return x <=> bool(y); } to be honest i don't like it, i hate it, and i ve many doubts that it will work. Another ugly way would be to use bool(false) instead of false where is getting the error.... but i don't really like to modify std files.. A test that i think i may try to suggest you use to move the standard files included in AsyncSQL.h to the beginning of the file (move them above the other includes, i ve seen your files in stackoverflow question you made) EDIT: I ve found the cause of the error, it is a macro in libthrecore/stdafx.h and following my suggestion of move up the standard headers and move down the user defined headers you will solve your error. here the macro is destroying the standard code: #ifndef false #define false 0 #define true (!false) #endif Edited March 16, 2021 by Ikarus_ 1 My youtube channel on which you can see my works here Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now