Home
Help
Search
Login
Register
OPNsense Forum
»
English Forums
»
Development and Code Review
(Moderator:
fabian
) »
[SOLVED] Building other tools
« previous
next »
Print
Pages: [
1
]
Author
Topic: [SOLVED] Building other tools (Read 24466 times)
reep
Jr. Member
Posts: 68
Karma: 8
[SOLVED] Building other tools
«
on:
May 17, 2015, 05:40:40 pm »
Can someone give me some tips on building other tools from the git repo ?
I am used to using mc for navigating around a file system and editing odd files.
I can see it is in the git
https://github.com/opnsense/ports/tree/master/misc/mc
but it doesn't seem there is a built package so wondered how one goes about building it from the source ?
Any help appreciated.
B. Rgds
John
«
Last Edit: May 18, 2015, 08:32:00 am by franco
»
Logged
franco
Administrator
Hero Member
Posts: 17668
Karma: 1611
Re: Building other tools
«
Reply #1 on:
May 17, 2015, 08:19:38 pm »
Hi John,
load the ports tree into your opnsense (assuming git is already on there):
# cd /usr && git clone
https://github.com/opnsense/ports
And then try a FreeBSD-style build, maybe it works out of the box:
# cd ports/misc/mc && make install
Cheers,
Franco
Logged
reep
Jr. Member
Posts: 68
Karma: 8
Re: Building other tools
«
Reply #2 on:
May 17, 2015, 11:00:49 pm »
That did it thanks Franco ! Guessed a few config options (disable X display and enable Ncurses text mode) and away it went.
Only thing I thought was would it not be normal to download the source tree to /usr/src rather than usr ?
It's a great utility and would be nice to see it prebuilt so it could be installed with pkg :-)
I think I managed to create a package for it by doing
cd /root
pkg create mc
I then get mc-4.8.14_1.txz
I guess I can then save this someplace and install with :
pkg add [-f] <pkg.txz>
Thanks for the help.
B. Rgds
John
Logged
franco
Administrator
Hero Member
Posts: 17668
Karma: 1611
Re: Building other tools
«
Reply #3 on:
May 18, 2015, 08:31:46 am »
John, I can add mc to the mirror if you like. I'll check the options, thanks for mentioning it wants to pull some X foo. Normally we use the following make.conf, you can move it to /etc/make.conf:
https://github.com/opnsense/tools/blob/master/config/OPNsense/make.conf
We handle these requests as they pop up, because we want the mirror to be lean (right now around 130MB) and building 200 ports is a lot less stressful than well over 20000 each time we do a release.
Once the next version is out, you can install using the proper way (you may have to deinstall the other one or it will upgrade by itself next time there is a new version):
# pkg install mc
/usr/src is reserved for the source tree, which is not the ports tree under /usr/ports -- src is for the FreeBSD base system, ports are for third party tools only.
You are welcome.
Franco
Logged
franco
Administrator
Hero Member
Posts: 17668
Karma: 1611
Re: [SOLVED] Building other tools
«
Reply #4 on:
May 18, 2015, 08:49:42 am »
I have added the "mc-light" package which seems more appropriate, will be available with 15.1.11 this week as an optional install. Thanks for mentioning this.
https://github.com/opnsense/tools/commit/bc13f1e4992ab4fb6cb73f907cb63ab9072a6f16
Logged
reep
Jr. Member
Posts: 68
Karma: 8
Re: [SOLVED] Building other tools
«
Reply #5 on:
May 18, 2015, 10:59:44 pm »
Cool - it's a great lightweight tool and I am lost without it !
Editor is handy too if you aren't a vi/vim hero :-) You can use it usually with 'mcedit my.file'
Logged
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
English Forums
»
Development and Code Review
(Moderator:
fabian
) »
[SOLVED] Building other tools