Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

additional steps to compile on ubuntu bionic #6

Closed
mailinglists35 opened this issue Dec 30, 2019 · 1 comment
Closed

additional steps to compile on ubuntu bionic #6

mailinglists35 opened this issue Dec 30, 2019 · 1 comment

Comments

@mailinglists35
Copy link

apt install libarchive-dev gcc-8
export CXX="g++-8" CC="gcc-8"
make

without these, you get:

In file included from src/unlocker.cpp:35:
include/archiveutils.h:6:10: fatal error: archive.h: No such file or directory
    6 | #include <archive.h>
      |          ^~~~~~~~~~~
compilation terminated.
<builtin>: recipe for target 'src/unlocker.o' failed
make: *** [src/unlocker.o] Error 1

and

g++ -Wall -std=c++17 -Iinclude   -c -o src/unlocker.o src/unlocker.cpp
src/unlocker.cpp:25:10: fatal error: filesystem: No such file or directory
 #include <filesystem>
          ^~~~~~~~~~~~
compilation terminated.
<builtin>: recipe for target 'src/unlocker.o' failed
make: *** [src/unlocker.o] Error 1
@paolo-projects
Copy link
Owner

the dependencies and compilation instructions are explained in the readme, namely here

The program needs the following libraries:

  • libcurl
  • zlib
  • libarchive

and here

Linux: Use the embedded Makefile. Get needed libraries (or compile them and install) first, then run make

Note regarding default g++ version on Ubuntu: by default, Ubuntu ships with g++ v7, which doesn't support natively c++17 features. To compile the program you have to install at least g++-8, set CXX variable when running make and add stdc++fs library dependence (make CXX=g++-8 LIBS=-lstdc++fs)

Alternatively, you can install g++-9 and avoid adding the library dependency.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants