usage of openssl command in ports

Matthew Seaman matthew at FreeBSD.org
Wed Oct 5 06:37:43 UTC 2016


On 05/10/2016 03:04, Koichiro IWAO wrote:
> Hi,
> 
> I have a question about usage of openssl command in ports.
> 
> If a port uses openssl command for example in pkg-install, how can I
> determine which openssl to use?
> I think if ssl=base, /usr/bin/openssl should be used.  If ssl=openssl,
> ${PREFIX}/bin/openssl should be used.
> And other ssl ports.

Correct.  You can also specify ssl=libressl

> Is there something like ${OPENSSL_CMD} or do I have to do manually like
> this?
> 
> .if ${SSL_DEFAULT} == base
> OPENSSL_CMD= /usr/bin/openssl
> .endif
> 
> .if ${SSL_DEFAULT} == openssl
> OPENSSL_CMD= ${PREFIX}/bin/openssl
> .endif
> 
> .if ${SSL_DEFAULT} == libressl
> OPENSSL_CMD= "i don't know"
> .endif

No -- all of the openssl-like ports install an openssl binary.  If your
port has:

USES=	ssl

Then you can just use:

${OPENSSLBASE}/bin/openssl

to run the appropriate binary.  You'ld have to use the SUB_LIST and
SUB_FILES mechanism to get the resulting value substituted into
pkg-install.in

	Cheers,

	Matthew




-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 931 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20161005/5b6ed263/attachment.sig>


More information about the freebsd-ports mailing list