Page 1 of 1

Compiling Problems

Posted: Thu Apr 01, 2010 2:35 pm
by Azati Prime
I'm trying to compile this program and I'm running into a problem.
http://pdfcrack.sourceforge.net/

I downloaded the source and extracted it to /opt/ and ran sudo make. This worked fine but when I type pdfcrack in terminal I get an error message that
The program 'pdfcrack' is currently not installed. You can install it by typing.....
The program runs just fine if I open the source folder and type ./pdfcrack. How can I get the program to run from anywhere?

Re: Compiling Problems

Posted: Thu Apr 01, 2010 3:11 pm
by RedWagon
I think you forgot

Code: Select all

sudo make install
When compiling from source you usually follow these commands:

Code: Select all

./configure
make
sudo make install

Re: Compiling Problems

Posted: Thu Apr 01, 2010 3:38 pm
by Azati Prime
There doesn't appear to be a configure or make install script in this program.

Re: Compiling Problems

Posted: Thu Apr 01, 2010 3:49 pm
by RedWagon
Wait a sec... pdfcrack is in the repos. You don't have to compile from source, just run

Code: Select all

sudo apt-get install pdfcrack

Re: Compiling Problems

Posted: Thu Apr 01, 2010 3:55 pm
by RedWagon
I downloaded pdfcrack and messed around with it. You're right, it doesn't need a ./config and doesn't have make install setup. Since it's such a small program I guess they just left it up to us to install manually. Using a package manager is always the preferred way to install a program, but if you want to use the source anyways, (you're only one command away from being done) run this:

Code: Select all

sudo ln -s /opt/pdfcrack-0.11/pdfcrack /usr/local/bin/
This will make a symbolic link from the pdfcrack in /opt/pdfcrack-0.11/ to /usr/local/bin/ which will allow it to be run anywhere.

Re: Compiling Problems

Posted: Thu Apr 01, 2010 8:42 pm
by Azati Prime
So it is. Thanks! At least I got practice for compiling future programs.