OPNsense Forum

Archive => 20.1 Legacy Series => Topic started by: AmirmohammadShk on April 03, 2021, 06:57:44 am

Title: Opnsense Build From Source
Post by: AmirmohammadShk on April 03, 2021, 06:57:44 am
Hi
i Try to Build opnsense from source this way:
on FreeBSD 12:
in /usr/:
 - clone core src tools plugins ports
 - apply my changes to core
 - apply my configs to tools/config/20.7/ports.conf and tools/config/20.7/build.conf
 - build and create iso using make dvd
and generate iso
but on every build take long time to create iso
and Most of the time is taken for ports

Most of my changes are for core
and dont need to build ports every time

on pfsense case i use poudriere for build ports and store all txz in poudriere .

how to use poudriere in opnsense build???
or is there a stable way without poudriere?????
Title: Re: Opnsense Build From Source
Post by: mimugmail on April 03, 2021, 01:07:53 pm
Its only the first time it takes that long. Should be around 6-8 hours.
Title: Re: Opnsense Build From Source
Post by: Patrick M. Hausen on April 03, 2021, 02:16:55 pm
This is the curse of not using standard FreeBSD packages. So you would need to create your own ports tree in poudriere (from OPNsense) and somehow create a HardenedBSD jail in poudriere. Sorry, never tried that, yet.
Title: Re: Opnsense Build From Source
Post by: AmirmohammadShk on April 05, 2021, 02:04:19 pm
Its only the first time it takes that long. Should be around 6-8 hours.



hi mimugmail
thanks for your replay
yes first time takes long . in my case takes 5H.
but on any change the rebuil progress start from first and take 5H again.
Title: Re: Opnsense Build From Source
Post by: franco on April 05, 2021, 03:06:36 pm
FreeBSD does not compile OpenSSL from ports into their packages for obvious reasons. But this makes updating OpenSSL harder than it should. We've always followed that pattern and except for the 1.1.1k breakage that was a good choice.


Cheers,
Franco
Title: Re: Opnsense Build From Source
Post by: franco on April 05, 2021, 03:11:52 pm
PS: Individual stories on why we had to diverge further from ports can be found below.

https://github.com/opnsense/tools/blob/6e84a332829a69ac4006c7c96415f57817a070dd/config/21.1/make.conf#L53-L101