Determining what's in a port

Michael Dickens michaelld at macports.org
Tue Oct 30 10:37:25 UTC 2018


2 ways that I can think of:

1) "activate" the specific port version & have port print "contents". As you note, this doesn't work unless the port & version is active. This way might break other ports temporarily due to binary incompatibility, but port does not generally verify binary compatibility on activate, so this should work OK. when you're done, activate the desired version.

2) generally located in "$PREFIX/var/macports/software/$PORT/" will be compressed tarballs of the activated files for any given PORT. Use "tar jtvf $FILENAME" to get contents, where FILENAME will be something like "$PORT-$VERSION+$VARIANTS.$OS.$ARCH.tbz2". For example for a recent "ffmpeg": "ffmpeg-4.0.2_1+gpl2.darwin_16.x86_64.tbz2".

Hope this is useful. - MLD

On Mon, Oct 29, 2018, at 11:00 PM, Michael wrote:
> Is there a way to determine what's in an in-active port?
> Attempting to ask "contents" does not work.
> 
> Here's what does *not* work:
> 
> bash-3.2# port installed x264
> The following ports are currently installed:
>   x264 @20160119_0
>   x264 @20161201_0 (active)
>   x264 @20170522_0
>   x264 @20171225_0
> bash-3.2# port contents x264
> Port x264 contains:
>   /opt/local/bin/x264
>   /opt/local/include/x264.h
>   /opt/local/include/x264_config.h
>   /opt/local/lib/libx264.148.dylib
>   /opt/local/lib/libx264.a
>   /opt/local/lib/libx264.dylib
>   /opt/local/lib/pkgconfig/x264.pc
> bash-3.2# ffmpeg
> dyld: Library not loaded: /opt/local/lib/libx264.152.dylib
>   Referenced from: /opt/local/bin/ffmpeg
>   Reason: image not found
> Trace/BPT trap: 5
> bash-3.2# port contents x264 @20170522_0
> Port x264 contains:
>   /opt/local/bin/x264
>   /opt/local/include/x264.h
>   /opt/local/include/x264_config.h
>   /opt/local/lib/libx264.148.dylib
>   /opt/local/lib/libx264.a
>   /opt/local/lib/libx264.dylib
>   /opt/local/lib/pkgconfig/x264.pc
> bash-3.2# port contents x264 @20171225_0
> Port x264 contains:
>   /opt/local/bin/x264
>   /opt/local/include/x264.h
>   /opt/local/include/x264_config.h
>   /opt/local/lib/libx264.148.dylib
>   /opt/local/lib/libx264.a
>   /opt/local/lib/libx264.dylib
>   /opt/local/lib/pkgconfig/x264.pc
> bash-3.2# 
> 


More information about the macports-users mailing list