PaulCombal / SamRewritten

Steam Achievement Manager For Linux. Rewritten in C++.
GNU General Public License v3.0
334 stars 32 forks source link

No such file or directory after "make" #119

Closed cocosunriseidk closed 2 years ago

cocosunriseidk commented 2 years ago

Hello I have cloned the repository to my PC, and when I try to execute make in /SamRewritten-master, I get this error. OS: Linux vps-efdc6074 4.9.0-16-amd64 #1 SMP Debian 4.9.272-2 (2021-07-19) x86_64 GNU/Linux

make: pkg-config: Command not found
make: pkg-config: Command not found
g++ -c -o obj/src/controller/MySteam.o src/controller/MySteam.cpp -std=c++17  -Wall
In file included from src/controller/MySteam.h:4:0,
                 from src/controller/MySteam.cpp:1:
src/controller/../types/StatValue.h:4:15: fatal error: any: No such file or directory
 #include <any>
               ^
compilation terminated.
Makefile:48: recipe for target 'obj/src/controller/MySteam.o' failed
make: *** [obj/src/controller/MySteam.o] Error 1

Before that I installed $ sudo apt install libgtkmm-3.0-dev libcurl4-gnutls-dev libyajl-dev The system has just been installed

PaulCombal commented 2 years ago

Hi, sorry you're having troubles. What is your g++ --version? Can you do sudo apt install pkg-config and try again? That is weird because as far as I know this command is shipped out of the box with most distros. Also, are you compiling on a headless server?

cocosunriseidk commented 2 years ago

g++:

g++ (Debian 6.3.0-18+deb9u1) 6.3.0 20170516
Copyright (C) 2016 Free Software Foundation, Inc.

sudo apt install pkg-config didn't change anything Yes, it's a headless server

PaulCombal commented 2 years ago

It looks like your GCC version is too old.

Looking back on an old issue I opened while working on this project, I mentionned some C++17 features weren't available with g++ version 6, but work with g++ version 8 and up.

The pkg-config command is required for building. It appears that you are using an ancient Debian version for which I do not have a lot of knowledge. I cannot give you precise instructions but having this command is a requirement.

If you don't mind me asking, why would you use such a setup? Are you testing coverage or CI?

cocosunriseidk commented 2 years ago

OK, I'll try another version, thanks. I'm just testing if I can use Steam and SAM on a headless server (unsuccessful).

UPD: I can say for sure that this error does not exist on Debian 11.

PaulCombal commented 2 years ago

I think you could use the command-line options in a headless server, if there's also a way to run Steam headlessly. Great to see you found a solution! Is your issue considered solved?

cocosunriseidk commented 2 years ago

Yes, the problem is solved. Also everything is fine on Fedora 34

PaulCombal commented 2 years ago

Thank you, if you need anything else, let me know!