Locating dependencies for Apache server

c00kie

Active Member


Messages: 178

With an up-to-date ports tree running on FreeBSD 10.2-RELEASE

cd /usr/ports/www/apache24/ && make install clean
Code:
===>  apache24-2.4.18 depends on executable: autoconf-2.69 - not found
===>  autoconf-2.69 depends on executable: gm4 - not found
===>  autoconf-2.69 depends on executable: gm4 - not found
*** Error code 1

Stop.
make[2]: stopped in /usr/ports/devel/autoconf
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/www/apache24
*** Error code 1

Stop.
make: stopped in /usr/ports/www/apache24
Oh dear, Apache won't install.

Working backwards - I tried cd /usr/ports/devel/autoconf && make install clean but am thwarted with:
Code:
===>  autoconf-2.69 depends on executable: gm4 - not found
===>  autoconf-2.69 depends on executable: gm4 - not found
*** Error code 1

Stop.
make: stopped in /usr/ports/devel/autoconf
OK, where does gm4 hang out? Anyways, pkg() should be smart enough to find these guys, no?

Thanks in advance.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 7,875
Messages: 31,140

Anyways, pkg() should be smart enough to find these guys, no?
Yes, but pkg(8) has nothing to do with this. A port checks for the existence of a specific executable or library to see if its dependencies are installed.
 
OP
OP
c00kie

c00kie

Active Member


Messages: 178

Yes, but pkg(8) has nothing to do with this. A port checks for the existence of a specific executable or library to see if its dependencies are installed.
Hang on, am I getting closer following:

http://www.freshports.org/www/apache24/

and installing:

Code:
[LIST=1]
[*]libcrypto.so.8 : security/openssl
[*]autoconf-2.69 : devel/autoconf
[*]autoheader-2.69 : devel/autoconf
[*]autoreconf-2.69 : devel/autoconf
[*]aclocal-1.15 : devel/automake
[*]automake-1.15 : devel/automake
[*]libtoolize : devel/libtool
[/LIST]

prior to Apache?
 

tobik@

Daemon
Developer

Reaction score: 1,382
Messages: 1,909

OK, where does gm4 hang out?
It's in devel/m4. But something odd is going on here. It should be build and installed automatically if it is not there.

You can list all dependencies of a port with make all-depends-list.
 
OP
OP
c00kie

c00kie

Active Member


Messages: 178

Anything in your /etc/make.conf ?
Erm...it seems this is undefined:

ls -l /etc/
Code:
...
-rw-r--r--  1 root  wheel  566 Aug 12 11:27 mac.conf
drwxr-xr-x  3 root  wheel  512 Aug 17 09:58 mail
-rw-r--r--  1 root  wheel  106 Aug 12 11:27 mail.rc
-rw-------  1 root  wheel  1838 Nov 22 04:17 master.passwd
-rw-r--r--  1 root  wheel  937 Aug 17 09:58 motd
drwxr-xr-x  2 root  wheel  512 Aug 12 11:27 mtree
...
 
OP
OP
c00kie

c00kie

Active Member


Messages: 178

But something odd is going on here.
It sure is.

I go in search of my dependencies:

cd /usr/ports/devel/m4/ && make install clean
# cd /usr/ports/misc/help2man/ && make install clean

Code:
 autoconf-2.69 depends on executable: autoconf-wrapper - not found
cd /usr/ports/devel/autoconf-wrapper/ && make install clean


Code:
cd /usr/ports/www/apache24/ && make install clean
===>  apache24-2.4.18 depends on executable: autoconf-2.69 - found
===>  apache24-2.4.18 depends on executable: autoheader-2.69 - found
===>  apache24-2.4.18 depends on executable: autoreconf-2.69 - found
===>  apache24-2.4.18 depends on executable: aclocal-1.15 - found
===>  apache24-2.4.18 depends on executable: automake-1.15 - found
===>  apache24-2.4.18 depends on executable: libtoolize - found
===>  apache24-2.4.18 depends on shared library: libexpat.so - found (/usr/local/lib/libexpat.so)
===>  apache24-2.4.18 depends on shared library: libapr-1.so - not found
===>  apr-1.5.2.1.5.4 depends on shared library: libexpat.so - found (/usr/local/lib/libexpat.so)
===>  apr-1.5.2.1.5.4 depends on shared library: libgdbm.so - not found
===>  apr-1.5.2.1.5.4 depends on shared library: libgdbm.so - not found
*** Error code 1

Stop.
make[3]: stopped in /usr/ports/devel/apr1
*** Error code 1

Stop.
make[2]: stopped in /usr/ports/devel/apr1
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/www/apache24
*** Error code 1

Stop.
make: stopped in /usr/ports/www/apache24

OK. What now? (Wipe the disk) It shouldn't be this tricky. Really?
 
Last edited by a moderator:

kpa

Beastie's Twin

Reaction score: 1,810
Messages: 6,318

I remember the autoconf ports being quite broken if you somehow manage to leave behind files from the previous installs, the ports fail then to recognize the need to install their dependencies properly. Try installing devel/m4, devel/autoconf and devel/autoconf-wrapper from packages:

# pkg install devel/autoconf devel/autoconf-wrapper devel/m4

If that fails with some error use pkg install -f instead.
 
OP
OP
c00kie

c00kie

Active Member


Messages: 178

leave behind files from the previous installs, the ports fail then to recognize the need to install their dependencies properly.
Are you, or do you know of a command which can clean-up broken or fragmented partially installed ports?
 
OP
OP
c00kie

c00kie

Active Member


Messages: 178

Are you, or do you know of a command which can clean-up broken or fragmented partially installed ports?
I just tried: pkg autoremove and
cd /usr/ports/www/apache24/ && make clean
 
Last edited by a moderator:

kpa

Beastie's Twin

Reaction score: 1,810
Messages: 6,318

Are you, or do you know of a command which can clean-up broken or fragmented partially installed ports?
I have occasionally used something like, finds files and symbolic links that are not part of an installed package:

# find /usr/local\( -type f -or -type l \) -exec pkg which {} \; | grep "not found in the database"

You'll have to then inspect the output and decide if a file is a leftover, something under /usr/local/bin is very likely a leftover, /usr/local/etc is a different story because that's where your own configuration files go.
 

kpa

Beastie's Twin

Reaction score: 1,810
Messages: 6,318

You could try out the newest addition to the package builder tool family, ports-mgmt/synth. It avoids a lot of the problems like these with leftover files when building ports over a live system. I've had good success with it so far.
 

DutchDaemon

Administrator
Staff member
Administrator
Moderator
Developer

Reaction score: 2,826
Messages: 11,313

Make sure your ports tree is up to date as well.
 

marian_cerny

New Member

Reaction score: 7
Messages: 14

I ... re-extracted the ports tree, update and re-install Apache and, voila...works.
I had the same problem and re-extracting the ports tree using portsnap extract did help. Before I did portsnap fetch update.
 
Top