Universal tinderbox


Tinderbox's main purpose would be as a developer tool to assist in FreeBSD port maintainers in getting various software packages available to FreeBSD users, but can it be used for more than that - yes. It is based on the scripts used by pointyhat to constantly compile ports to test for errors as well as create packages that are available to download through the various mirror sites. Which means it also gives you the ability to compile your own packages repository. If you want to make it do other things you would need to get into the scripts and adjust it to suit. Basically it is a set of scripts that sets up a clean system environment then compiles ports within it. That is a series of preset commands with some runtime options. There is no reason it can't be adjusted to run any automated task that you want to test within multiple clean systems.

So why would you want to build your own packages repository? Maybe you want your packages built with extra options turned on. Maybe you want to compile your ports with -O3 or CPUTYPE=corei7 to get a bit more performance. Or you support a range of servers and desktops that are not all the same OS versions and company policy prevents binary downloads from external sources being installed on your systems. Or you just want to build your own ports but want to know everything builds successfully before changing anything on your base system.

That last one comes in handy if you want to compile everything with clang. While effort is being made to move away from gcc and have everything built with clang, we aren't there yet. When you build your own ports in your base system various dependencies are built and installed before the port that needs them. This leads to newer libraries installed that may not work well with older versions of packages that use them and this mixed bag gets left that way when one port breaks. So it can be useful to know that everything compiles that is needed before anything in the base system gets changed. If you are using zfs then you could also use snapshots to rollback after a bad upgrade, but that's another story.

If you make changes to your ports tree to fix build issues then share the fixes with others by submitting a problem report. Chances are others would like to use the same fixes you made.

But tinderbox also lets you build against system versions that you don't have installed. How does that help you? Maybe you have an old 7.4 machine that you want to upgrade, you can build all the ports you want for that machine against FreeBSD 9.0 so they are all ready before you upgrade. It is often recommended that you recompile your ports after major system version updates. But then what if your upgrade goes bad and you want to go back to your old system? With tinderbox you could also build your ports against an older version and downgrade with confidence. While no-one would recommend you do that, it can give you peace of mind knowing that you have a way to fall back when changes don't work the way you want. If you want the option to fallback you may want to build both package versions before you upgrade.

In previous posts I have talked about setting up builds with a variety of system versions and configuring the environment options for each so I won't repeat that here. If you are wanting to build your own ports then you may want to expand the environment settings a bit. While you don't get the flexibility that you have with the /etc/make.conf you can add most of the options you would normally use there. The main limitation is you don't get conditional sections so anything you setup will be applied to every port you build. I previously showed you how to set the cputype used and you should be able to figure out how to add your own CFLAGS to the environment settings.

The recent options changes within the ports infrastructure (referred to as optionsng) does provide a way to set options for every port - tinderbox limitations prevent you using that within the environment settings for every port, but you can set some global options or turn on a few important options if that is all you want to do. Options set in the environment file will be applied to each port build, whether you choose to build with non-default options or not. If you want to configure options for a lot of ports then use the standard option config dialogs to set them up. My compileport script from the previous post allows you to use the -O option to use non-default options for each port.

So what are some options that you may want to add to your environment?

export PAPERSIZE=a4 export QT4_OPTIONS="CUPS QGTKSTYLE" export WITHOUT_JAVA=true export OPTIONS_SET="PGSQL SQLITE" export OPTIONS_UNSET="MYSQL JAVA" export PERL_VERSION=5.16.0

Well PAPERSIZE seems obvious. QT4_OPTIONS shows that any values with a space needs to be quoted, without the quotes only the first item is recognized. Within the environment file you can't use variable+=addvalue to set your variables gradually - you only get variable=value. The OPTIONS_SET and OPTIONS_UNSET provide a way to globally turn on or off common options. While a lot of options are unique to each port there is some consistency with naming that may also be expanded over time, with optionsng already adding some common ones like THREADS and DOCS to replace the NOPORTDOCS option that was previously available. To set an option only for a specific port use <uniquename>_SET. To get the ports uniquename use make -V UNIQUENAME eg -

cd /usr/ports/devel/py-gdata make -V UNIQUENAME py27-gdata cd /usr/ports/x11-toolkits/py-gtk2 make -V UNIQUENAME py-gtk2

While there is some consistency you can't always guess the ports uniquename from the portname. You may also want to look in /var/db/ports/<portname>/options for installed ports to see what values you have already used and what is available.

By default tinderbox isn't setup to store the port options you configure. You need to do that manually. To make it work you need to create a directory called options at the top of the tinderbox directory and inside that create a directory for each buildname you want options saved. As standard in unix the directory can be a link to another so you can use your existing options. To compile the ports with non-default options you need to build the ports with the -O option (or -o option to clear existing options and then set options)

So now all there is to do is create a build environment for your ports and start building. If you've been following along and have the base jails setup then -

cd /usr/local/tinderbox mkdir options cd options ln -s /var/db/ports 9-mypackages cd ../scripts ./tc createBuild -b 9-mypackages-amd64-clang -j 9.0-amd64 -p FreeBSD setenv OPTPORTLIST `pkg_info -aoq` ./compileport -O -B 9-mypackages -A amd64 -C clang

And if you are setting up your own packages to distribute through your network of FreeBSD machines you have a couple of options. To use them with the standard pkg_add you can either set PKG_PATH or PACKAGESITE to point to your packages. See man pkg_add for more details. If you use portmaster then you can set LOCAL_PACKAGEDIR to point to /usr/local/tinderbox/packages/9-mypackages-amd64-clang (or a common network mount) as well as PM_PACKAGES=first and PM_PACKAGES_LOCAL=pmp_local. Other package management tools should offer similar config options.


880 comments

fifa 17 mobile free points's picture

It's perfect time to make some plans for the future and it's time to be happy.
I have read this post and if I could I wish
to suggest you some interesting things or advice.
Perhaps you can write next articles referring to this article.
I wish to read more things about it!

credit rating ranges's picture

Very good article! We will be linking to
this particularly great post on our website. Keep up the good writing.

http://www.zebogamesmobile.com's picture

Hi there, this weekend is good designed for me, as this moment i am reading this enormous informative
article here at my home.

http://wiki.studrespublika.com/index.php?title=Seo_software_'s picture

Excellent web site. A lot of useful information here.
I am sending it to several buddies ans also sharing in delicious.
And obviously, thanks to your sweat!

Rosita's picture

Today, I went to the beachfront with my kids. I found
a sea shell and gave it to my 4 year old daughter and said "You can hear the ocean if you put this to your ear." She put the shell to her ear and screamed.
There was a hermit crab inside and it pinched her ear.
She never wants to go back! LoL I know this is completely off topic but
I had to tell someone!

Betting UK's picture

I'm impressed, I have to admit. Rarely do I come across a blog that's both educative
and interesting, and let me tell you, you have hit the nail on the head.
The problem is something that not enough men and
women are speaking intelligently about. I'm very
happy I found this in my search for something concerning this.

Curvy Bust Review's picture

Thanks for ones marvelous posting! I quite enjoyed reading it, you are a great author.I will be
sure to bookmark your blog and will often come back later on. I want to encourage you to definitely
continue your great work, have a nice morning!

The Boy Next Door online schauen's picture

Great items from you, man. I've take into accout your stuff preevious to and
you are simply extremely excellent. I really like what you've bought here, really
like what youu are stating and the way bby which
you are saying it. You are making it entertaining and you still take cre of to stay
it sensible. I can't wait to read ffar more from you.
That is really a wonderful website.

οικοδομικα υλικα θεσσαλονικη's picture

I loved as much as you will receive carried out right here.

The sketch is attractive, your authored material stylish. nonetheless, you command get got an impatience
over that you wish be delivering the following. unwell unquestionably come
further formerly again as exactly the same nearly very often inside case you
shield this increase.

http://www.Flashbored.Com/profile/1936806/Wzvmaricela.html's picture

The average age of participants was 64. 3 years,
and there were 1, 312 men with a history of cancer included in the
trial.

Trap Lift's picture

Heeft u dienovereenkomstig wat betreffende de stoellift.

garcinia pure's picture

Highly energetic article, I loved that a lot. Will there be a part 2?

hoodies for guys's picture

I really like your blog.. very nice colors & theme.
Did you create this website yourself or did you hire someone
to do it for you? Plz reply as I'm looking to create my own blog and would like to find out where u got
this from. appreciate it

Firoz Patel's picture

Hi there, I discovered your web site by means of Google
even as searching for a comparable matter, your web site
got here up, it appears good. I have bookmarked it in my google bookmarks.

Hello there, simply became aware of your blog thru Google, and found that it is truly informative.
I am goinmg to be careful for brussels. I will appreciate in case
you proceed this in future. Numerous other people can be benefited outt of your writing.
Cheers!

Shanel's picture

This paragraph offers clear idea for the new users of blogging, that
truly how to do blogging.

my webpage; kia soul reviews (Shanel)

Torrentz's picture

When Twiztid starts feeling the financial pinch, he or she cut
his publicist. Your IP address is often a dead give
away to your online identity. When the movies are
available for the internet, several lots of people will get
full access by paying membership fees.

Joe Olujic's picture

I know this if off topic but I'm looking into starting my own weblog and was curious what all is required to get setup?
I'm assuming having a blog like yours would
cost a pretty penny? I'm not very web savvy so I'm not 100% sure.
Any suggestions or advice would be greatly appreciated.

Cheers

Reefs2Go's picture

I seriously love your blog.. Great colors & theme. Did you make
this website yourself? Please reply back as I'm wanting to create my own personal blog and want to find out where you got this from or what the theme is named.
Many thanks!

Das blaue Zimmer Stream Online Schauen stream's picture

Awesome article.

labellotasoft.co.uk's picture

Heeft u tevens wat over de lifttrap.

demolition squad slot's picture

Another strategy is to limit yourself to only two suits for numbered cards to give yourself greater mobility in your game.
Research shows that those who have first degree relatives who have addiction problems with gambling are more like or prone to be addicted as
well. Winning a fortune on a one-dollar slot machine is a
pretty awesome notion, however slim the odds.

Firoz Patel's picture

This is my first time pay a visit at here and i am genuinely pleassant to rea everthing at alne place.

Jeff Halevy's picture

This article will help the internet visitors for setting up new webpage or even a weblog
from start to end.

ankara matematik dersi's picture

excellent submit, very informative. I wonder why the other specialists of this sector don't realize this.
You must continue your writing. I am confident, you've a huge readers'
base already!

rug rehab's picture

Hi there every one, here every one is sharing such know-how, therefore it's good to read this web site, and I used to pay a visit this webpage all the time.

traplift kopen's picture

Waarom schrijf jij tot nu toe niets over trap lifen.

Sophia's picture

Useful information. Fortunate me I found your web site unintentionally, and I am surprised
why this accident did not took place in advance! I bookmarked it.

fast &amp; furious 7 francais's picture

Hey there! I'm att work surfing around your blog from mmy new iphone!
Just wanted to say I love reading your bpog and look forward to
all your posts! Keep up the fantastic work!

IPL LIVE STREAMING's picture

I visited many websites except the audio feature for audio
songs current at this site is truly wonderful.

internet marketing minneapolis's picture

When someone writes an article he/she keeps the thought
of a user in his/her brain that how a user can be aware of it.
Therefore that's why this paragraph is perfect. Thanks!

testosterone boost reviews's picture

I am curious to find out what blog platform you have been working
with? I'm experiencing some minor security issues with my latest
website and I would like to find something more safe. Do you have any recommendations?

mark dubowitz's picture

Hello there! Would you mind if I share your blog with my facebook group?
There's a lot of folks that I think would
really enjoy your content. Please let me know.

Many thanks

Fisher Investments's picture

This is very interesting, You are a very skilled blogger.
I have joined your rss feed and look forward to seeking more of your magnificent post.
Also, I have shared your web site in my social networks!

Hijab Tutorial Complete's picture

Contrary to popular belief, it is very uncommon for a bone
spur in the heel to be the actual source of pain, although they
are commonly found with plantar fasciitis. There are a group of diseases
that involve the immune system attacking tissue in joints and the tissue
that connects to bone. Check out our list
to learn of the up and coming young Muslim women that offer sewing how-tos, baby's firsts, Quran tips,
hip hop inspiration and much more -- they really are doing something
different.

Karate Brighton's picture

Cool blog! Is your theme custom made or did you download it from somewhere?
A design like yours with a few simple adjustements would
really make my blog jump out. Please let me know where you got your design. With
thanks

Harris's picture

Fastidious answer back in return of this query with
real arguments and describing all on the topic of that.

ali-express.by's picture

Hello There. I found your blog using msn. This is a really well written article.
I will be sure to bookmark it and return to read more of your useful
information. Thanks for the post. I'll definitely comeback.

Ketone Slim XT's picture

It's remarkable in support of me to have a website, which is helpful in support of my knowledge.
thanks admin

Jeff Halevy's picture

We're a gaggle of volunteers and opening a brand new scheme
in our community. Your web site provided us with valuable information to work on. You
have performed a formidable task and our whole neighborhood might be thankful
to you.

clash of clans hack activation code.txt's picture

Tout ce que vous devez faire est de connecter votre appareil a l'ordinateur et cliquez sur le bouton hack !

Joe Olujic's picture

Fantastic web site. A lot of useful info here.
I'm sending it to some friends ans also sharing in delicious.
And obviously, thanks to your sweat!

adopteunmec gratuit's picture

Some brands are made of one or two main ingredients,
whilst others are composed of even five to six herbs.
It speeds up the heart and increases our adrenaline levels.
What's more, you can submit articles to us around the clock.

agen bola tangkas's picture

s Haiti Relief Bounty Tournament will match all bounty money won and donate the total relief efforts to
Haiti up to $50,000 and also contribute all tournament fees collected.
In fact, a great many goal-based writings are geared towards improving businesses at the bottom line in terms of increased efficiency,
increased productivity, etc. Learn to be aware of your
intuition, and you will get better over time.

post83660's picture

Hey just wanted to give you a quick heads up.
The text in your article seem to be running off the scrwen in Firefox.
I'm not sure if this is a formatting issue or something to do
with internet browser compatibility but I figured I'd post to let you know.
The design look gdeat though! Hope you get the problem solved soon. Kudos

site's picture

I'd like to thank you for the efforts you have put in writing
this blog. I'm hoping to view the same high-grade content
from you later on as well. In fact, your creative writing abilities
has encouraged me to get my own, personal site now
;)

clash of clans hack tool's picture

Greetings! Very helpful advice in this particular article!

It's the little changes that make the largest changes.

Many thanks for sharing!

trap lift's picture

Hebt u ook wat aangaande de lifttrap.

Nur eine Stunde Ruhe online schauen's picture

Hello there, I found your site by means of Google whilst looking for a similar subject,
your site got here up, it looks great. I have bookmarked it in my google
bookmarks.
Hi there, simply became alert to your blog thru Google, and found that it's
truly informative. I'm going to watch out for brussels.
I'll be grateful should you proceed this in future. Many people will likely be benefited from your writing.
Cheers!

Reefs2Go's picture

My programmer is trying to persuade me to move to .net from
PHP. I have always disliked the idea because of the expenses.
But he's tryiong none the less. I've been using WordPress on various websites for about a year and am
anxious about switching to another platform. I have heard great
things about blogengine.net. Is there a way I can import all my
wordpress posts into it? Any kind of help would be really appreciated!

make money online fast paypal's picture

How To Make Money Online Guaranteed Udemy Course
100% Free

Video Link: http://tinyurl.com/odxl2c6

Pages

Add new comment