Error installing SSMTP

I can't install the ssmtp port:

Code:
cd /usr/ports/mail/ssmtp/ && make install replace clean

this gives error:

Code:
Couldn't fetch it - please try to retrieve this...

So I tried:

Code:
make distclean

and got the same error.

Then I tried:

1.
Code:
rm -f distinfo
2.
Code:
make makesum

and got the same error.

I downloaded the distfile from the Debian site:

Code:
fetch http://ftp.de.debian.org/debian/pool/main/s/ssmtp/ssmtp_2.64.orig.tar.bz2

and after extracting to a dir and:

1.
Code:
./configure
2.
Code:
make
3.
Code:
make install replace clean

I get this result with error at the end:

Code:
/usr/bin/install -c -d -m 755 /usr/local/sbin
/usr/bin/install -c -s -m 755 ssmtp /usr/local/sbin/ssmtp
/usr/bin/install -c -d -m 755 /usr/local/man/man8
/usr/bin/install -c -m 644 ./ssmtp.8 /usr/local/man/man8/ssmtp.8
/usr/bin/install -c -d -m 755 /usr/local/etc/ssmtp
/usr/bin/install -c -m 644 ./revaliases /usr/local/etc/ssmtp/revaliases
./generate_config /usr/local/etc/ssmtp/ssmtp.conf
hostname: illegal option -- -
usage: hostname [-fs] [name-of-host]
*** Error code 1

Stop in /usr/ports/mail/ssmtp/temp/ssmtp-2.64.

ssmtp.conf isn't generated but all other dir's/files before it are.

Does this imply the port can't be fetched because it has been removed as it has a hostname related error in its configure file?

More importantly - what are my options to install ssmtp?

My goal is to replace sendmail on a web server with ssmtp, which will forward mail to a mail server that has been successfully built using the PurpleHat guide here:

Code:
http://www.purplehat.org/?page_id=4

While I'm here, as I'm a noob with email servers - if anyone has setup forwarding mail to a mail server like in the link (Dovecot, Postfix, ... using SSL,TLS) - your advice would be appreciated.
 
Copy the file you downloaded to /usr/ports/distfiles/ and see if it's the file the port wants.
 
  • Thanks
Reactions: nx
Thanks, I forgot to mention that the first thing I did was fetch the file from the debian site to the distfiles dir, but in my haste I didn't notice the version difference.

The debian site file is ssmtp_2.64, but the port version failing to be fetched is ssmtp_2.61, which http://www.freshports.org/mail/ssmtp/ shows was released between 2004 and '09.

Should I try to install an older version like 2.62.3, and if so will I have to use portdowngrade to do this?

I'm trying to install ssmtp on a freebsd 9 server I setup 3 days ago, and I have updated ports in the last 2 days.
 
nx said:
Thanks, I forgot to mention that the first thing I did was fetch the file from the debian site to the distfiles dir, but in my haste I didn't notice the version difference.

The debian site file is ssmtp_2.64, but the port version failing to be fetched is ssmtp_2.61, which http://www.freshports.org/mail/ssmtp/ shows was released between 2004 and '09.

Should I try to install an older version like 2.62.3, and if so will I have to use portdowngrade to do this?

I'm trying to install ssmtp on a freebsd 9 server I setup 3 days ago, and I have updated ports in the last 2 days.
Which version do you want to install?
If it is the latest (2.64) then you already have the distfile in place; you may still need to upgrade your port to the latest version as well (considering ports-mgmt/portsnap is already installed):
# cd /usr/ports
# portsnap fetch extract mail/ssmtp
# cd mail/ssmtp
# make install clean

If you want an older version (e.g. 2.61) - what I would not recommend - you need to use ports-mgmt/portdowngrade. In this case you need to download the distfile for that version as well.
 
  • Thanks
Reactions: nx
Thanks...

and OMG my bad... I forgot I'm installing ssmtp on my 8.2 box not the 9, the latter which I've been working on for the last 3 days.

No surprise the 8.2 is looking for an older version of ssmtp.

Thanks all!

(Time to sleep .)
 
All versions of FreeBSD use the same ports tree. It just means your 8.2 box has an old ports tree that needs updating.
 
Yeah... the 8.2 has been shelved for a while! :r

I think it's going to be quicker to clone the 9 and install ssmtp on that rather than wait for 16k+ patches etc to be downloaded before the ports tree is updated.

Unless there's a quicker way to update the ports tree?
 
First time is going to take a little while. If you regularly run portsnap(8) it won't have to do that many changes.
 
Back
Top