static linked python from the ports tree - possible ?

Micah micahjon at
Fri Aug 11 21:55:48 UTC 2006

Ensel Sharon wrote:
> For a variety of reasons (long, hard to explain) I need a static python
> binary - with no external libraries.
> I know how to do this from source.  However, I would like to install from
> the ports tree - what line can I run inside of /usr/ports/lang/python to
> get a totally static, standalone python binary ?
> Thanks.

So, how do you do it from source? Perhaps you can apply changes to 
lang/python/Makefile to do the same steps (and then submit a PR with the 
changes so others can benefit).  Checkout

Alternately, doing a make install really does the following: make fetch, 
make extract, make patch, make configure, make build, then make install. 
You could manually run each make step and apply any needed changes in 
between steps, but that would make upgrading hard.


More information about the freebsd-questions mailing list