Tinderbox extra scripts

Continuing on from my previous two ramblings let's have a look at two scripts I use with my tinderbox setup. It may not be the best place but I decided to keep these within the tinderbox/scripts folder.

The first script is gencompilerenvfiles which I have expanded a little since my previous post.

#!/bin/sh cd /usr/local/tinderbox/scripts/etc/env rm build.* ## set CC options ############################################### for BNAME in `../../tc listBuilds | grep clang` do cat > build.$BNAME <<CCOPTIONS export CC=clang export CXX=clang++ export CPP=clang-cpp export NO_WERROR= export WERROR= CCOPTIONS done for BNAME in `../../tc listBuilds | grep gcc` do cat > build.$BNAME <<CCOPTIONS export CC=gcc export CXX=g++ export CPP=cpp export NO_WERROR= export WERROR= CCOPTIONS done ## set the ARCH ############################################### for BNAME in `../../tc listBuilds | grep i386` do cat >> build.$BNAME <<CCOPTIONS export ARCH=i386 CCOPTIONS done for BNAME in `../../tc listBuilds | grep amd64` do cat >> build.$BNAME <<CCOPTIONS export ARCH=amd64 CCOPTIONS done ## optionally set the CPUTYPE - fixes some build issues ############################################### if [ "$1" = "cpu" ] then for BNAME in `../../tc listBuilds | grep i386` do cat >> build.$BNAME <<CCOPTIONS export CPUTYPE=pentium2 CCOPTIONS done for BNAME in `../../tc listBuilds | grep amd64` do cat >> build.$BNAME <<CCOPTIONS export CPUTYPE=nocona CCOPTIONS done fi

So the changes since my previous post are fairly small and obvious - first I added NO_WERROR and WERROR which allows some ports to finish building that only generate warnings. Some ports are setup to treat warnings as errors causing the build to stop. While it can make sense with some ports, others it isn't of concern and only gets annoying that the builds stop and you take 10 minutes to figure out that it's all because of a simple warning.

The next change is the addition of ARCH - when building for the same arch as the base system this is of no concern but some ports have a problem building on an amd64 system when the compiler is generating x86 code. The ARCH definition overcomes that issue.

The other change is the conditional addition of CPUTYPE. This is added by calling the script with an argument of cpu. I found a couple of ports that have trouble compiling when targeting the minimum cpu features. While the cpu types used can be adjusted I chose pentium2 as the minimum 32bit as i686 is a common base but sometimes the lack of mmx causes problems, pentium2 is the next one up that has mmx support, pentium4 or prescott are other good choices if you know the minimum cpu your builds need to run on or if you need sse. For amd64 I chose nocona as the first Intel 64bit cpu, not sure that core2 would be any advantage but this can be changed to corei7 to include sse4.2 support. Other options for amd cpu's can be used if you want to test against amd specific features.

The other script I showed previously I called testbuilds.sh. I have expanded this script quite a bit and now call it compileport - while it is now a lot longer than the previous example it's not really more complex. The extra length is from many case and if statements than any real complexity. You can download it below if you want to use it or just read through it.

For the most part you should be able to figure it out based on the comments and help (-h) included within the script. To compile a port we want to know 4 things - sysversion arch compiler and port, sysversion arch and compiler default to current i386/amd64 and gcc/clang and can be left out if you wish to use that combination. That leaves us with specifying the port, giving a minimum of compileport -P <category/portname> to compile against 10-CURRENT.

A few bonus options for sysversion are for preset searches - all current stable and release should be obvious, with releng being a moving target based on system releases. Currently this is set to 9.0 8.3 and 7.4 - being the highest minor release of each major version. Over time this should be updated to include newer releases and drop the less than current releases. So when 9.1 goes beta or RC1 it would be added to the list and after release we can remove 9.0.

If you want to setup default values you can do that through environment variables, which can also be setup in your shell rc files like any other variable. So if you always compile for 9-STABLE you can set OPTBASEVERS to 9-STABLE and it will be used without you having to specify -B 9-STABLE every time. This is where the upper/lower case options come into play. If you have the OPTBASEVERS set to 9-STABLE then compileport -b 8-STABLE will build the port for both 9-STABLE and 8-STABLE but if you use compileport -B 8-STABLE then it will ignore the environment settings and just compile for 8-STABLE. The real advantage to environment settings comes when you want to compile a list of ports. This may be a preset list of all the ports you maintain or you can do something like -

setenv OPTPORTLIST `pkg_info -aoq` compileport -B all

will compile every port you have installed on your system with every tinderbox build you have setup - or -

setenv OPTPORTLIST `pkg_version -vL= | awk '{print $1}' | xargs pkg_info -oq` compileport -B 9-STABLE

will compile every port that needs updating against the 9-STABLE builds you have setup. This leads into what I plan to talk about in my next post - using tinderbox to build your own packages.

gencompilerenvfiles.bz2451 bytes
compileport.bz22.53 KB


Cheri's picture

Moldy odors are a signal of a big problem which will be resolved.
This is why acting fast and getting water out with the carpet and cleaning everything up
properly is the best option in restoring its condition and quality.
If the river damage within your basement comes from a minor spill, then you can certainly
likely care for it on your own.

p13351's picture

Hi there! Quick question that's completely off topic. Do you know how
to make your site mobile friendly? My website looks weird when browsing from
my iphone. I'm trying to find a theme or plugin that might be able to correct this problem.
If you have any recommendations, please share.
Appreciate it!

nba live mobile hack's picture

Way cool! Some very valid points! I appreciate you penning this write-up plus the
rest of the site is really good.

Bonita's picture

I absolutely love your blog and find nearly all of your post's to be just what
I'm looking for. Does one offer guest writers to write content
for you? I wouldn't mind producing a post or elaborating on a few of the subjects you write related to here.Again, awesome weblog!

memek mulus tante's picture

Pretty nice post. I just stumbled upon your weblog and wished to say that I've really enjoyed surfing around
your blog posts. In any case I'll be subscribing to your feed and I hope you write again very

セルライト エステ's picture

matusazi|rinpamatusazi|Zhi Ya matusazisitadakedehanakanaka|Si uyouni|sumuzunisurimuni|Xi ku|sutukirinatutekurenaiZu |Xia Ban Shen |Jiao mawarinigatukarisiteiru|Can Nian niSi tuteiru|Bei sikuSi tuteiruChang He hamotiron,souiuZhong deTe niZu Shou Zhou Bian |Xia Ban Shen |Tai momonomukuminadodeNao ndeiruFang desuto,Shi siniYi Du |Yi Hui Shi Ti Yan |Ti Yan |Jing Yan sitemoraitaitoSi useruraito esutegaSi iFu kabimasu|arimasu|osusumedesu. Yi Wai niSi wareru|Zhi ranai|Kan Wei isiteiruFang moDuo i|Shao nakunai|takusanirutoSi imasuga,esute|esutesaron|Shou Shen esutetoha,Yuan Lai natiyuraru|Wu Li nonai|Zi Ran nakeakaraCheng riLi tuteite,Ti |Shen Ti |bodeinoNei Ce deXin Chen Dai Xie |tanoba|Xi Bao noSheng mareBian wariwoLiang kusite|Gai Shan |Zheng eteWu Ti noYi Ge wobesuto|Zui Gao naZhuang Tai |Zui Liang niJin dukeyou|Jin duketeiku|Zheng eteikutoiuYi Ge wokonasu,Wu Ti |Shen Ti |bodeiniokeruMei Rong Ji Shu ninarimasu. Ji Ji De Xiu Xi |riratukusu|rirakuzesiyonmoJu imasu. konoseruraitonoZheng Ti toha|ha|desuga,Zeng ki|Ji mawasii|Ku "siiPi Xia Zhi Fang ,aruiha|mataha|mosikuhaPi Xia Zhi Fang Jian woLiu reruXi Bao Jian Ye deari,soreranoyounaYao Su |sorera|koreragaKuai toHua si|Bian Hua si|natute,Ji "sikumo|Kun tutakotoni|Bei sikumosoregaJi noBiao Mian nimo|he|madeJin ndeXing tute|Dong iteiki|Jin Xing siteiki,soretowakarudekobokositaZhuang Tai woChu Lai Shang garaseteimasu|ninarimasu|heBian Hua siteikimasu.

お金借りる's picture

Pin Fan niterebideyatuteiru,Shui mogasonoCun Zai woZhi ruXiao Fei Zhe Jin Rong noJin Rong Ge She hahotondogasupidoShen Cha woyatuteite,Zui Duan deShou kerareruJi Ri Rong Zi niDui Ying surukotomoKe Neng desu. Shen Cha nikakaruShi Jian moZao itokorodatoZui moSu kute30Fen kuraidesu. Wu Li Xi sabisunoTe Dian ha,onoononoXiao Fei Zhe Jin Rong Hui She deBian watutekurunode,netutowoumakuHuo Yong siteiroironasaitowoBi Jiao siteQue Ren siteikukotode,Zi Fen niXiang iteiruBian Li natokorowoTan sukotogadekirutoSi imasu.

Tweets from Luke Weil's picture

Today, I went to the beach front with my children. 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 entirely off topic but I had to tell someone!

losing weight technique's picture

Hmm it looks like your site ate my first comment (it was super long) so I guess I'll just sum
it up what I submitted and say, I'm thoroughly enjoying
your blog. I as well am an aspiring blog writer
but I'm still new to the whole thing. Do you have any tips and
hints for rookie blog writers? I'd genuinely appreciate it.

haemorrhoiden symptome's picture

Look at these various activities you do and make adjustments to their frequency
for effective hemorrhoid treatment. This is great for some temporary
relief, but unfortunately you are practically guaranteed to flare
up again. Hemorrhoids Saviour is a holistic system designed
to treat hemorrhoids, and claims that it contains information that can be
a hemorrhoids cure.

Wohnung mieten's picture

Hi to all, how is thee whole thing, I think every one is getting more from this web page, annd
your views are pleasant in favor of new users.

purpose of methadone maintenance programs's picture

Your telephone call is routed to the nearest situation center in the national network purpose of methadone maintenance programs
greater than 150 crisis facilities.

best survival gear of 2016's picture

Headaches can begin as soon as 24 hours after missing sleep.

By eliminating distracting elements from a room, you will be able to study for longer
periods of time, and will retain the information much better.

If we don't adapt in a healthy manner, we will get left behind or stay stuck in an unhealthy rut.

basketball gear list's picture

This site was... how do you say it? Relevant!! Finally I've found something that helpoed me.
Appreciate it!

Here is my web page ... basketball gear list

Mariano's picture

Very nice post. I just stumbled upon your blog and wished to say that I've truly
enjoyed browsing your blog posts. In any case I'll be subscribing to your feed and I hope
you write again soon!

labs.ww.isaev.infoww.isaev.info's picture

This is the perfect website for everyone who hopes
to understand this topic. You know a whole lot its lmost tough
to argue with youu (not that I actually would want to...HaHa).
Youu definitely put a new spin on a topic that has besen written about for many years.
Wonderful stuff, just excellent!

Review my web page :: computers usa online (labs.ww.isaev.infoww.isaev.info)

Saul's picture

Each year, Google transforms its search formula around
500-600 times.2015 has actually already been a rollercoaster for online marketers that are attempting to monitor
Google ... as well as we could anticipate far more yet ahead.

my blog ... dallas seo - Saul -

online casino Malaysia's picture

Hey there fantastic blog! Does running a blog such as this take a great deal of work?
I have very little understanding of programming but I had been hoping to start my own blog in the near future.
Anyhow, should you have any ideas or techniques for new blog
owners please share. I know this is off subject however I just needed to ask.
Thank you!

global-discourse.com's picture

Your style is very unique in comparison to other people I've read stuff from.
Many thanks for posting when you've got the opportunity,
Guess I'll just book mark this site.

basketball shoes for men clearance's picture

Have you ever considered about including a little bit more than just your articles?
I mean, what you say is important and everything.
But imagine if you added some great photos or video clips to give your posts more, "pop"!

Your content is excellen but with images annd videos, this blog could certainly be one of the very best in its field.
Wonderful blog!

My web blog: basketball shoes for men clearance

testing's picture

Very nice article, exactly what I needed.

basketball shoes with Good arch support's picture

I all the time used to read article in news papers but now as I am a user oof net thus from
now I am using net for articles, thanks to web.

My weblog basketball shoes with Good arch support

Adele's picture

Once the river adjusted you will have to handle the carpets or another flooring.
After it can be determined which possessions and structures can be salvaged, the permanently damaged
materials is going to be hauled away, along with the drying
process can begin. Cracks, tears, and rot within your roofing material are
evident signs that water damage has occurred.

Cabo San Lucas Private Yacht Rentals's picture

always i used to read smaller posts which as well clear their motive, and
that is also happening with this post which I am reading
at this time.

letoltes's picture

Hi my loved one! I wish to say that this post is amazing, great written and come
with almost all vital infos. I would like to see
more posts like this .

one of a kind experience synonym's picture

Have a great Wednesday!

zlokalizowanie osoby's picture

This excellent website really has all the info I
wanted concerning this subject and didn't know who
to ask.

basketball clothing flyer's picture

It's amazing to pay a quick visit this web page annd reading the views of all mates about this paragraph, while
I am also eaber of getting knowledge.

Here is my websitfe :: basketball clothing flyer

perfumes's picture

Heya i'm for the primary time here. I came across this board
and I to find It really helpful & it helped me
out much. I hope to provide something again and help others such as you aided me.

basketball gear youth's picture

Greatt blog! Is your thme custom made or diid 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

Cheeck out my wenpage basketball gear youth

barbara wine's picture

Heya! I'm at work browsing your blog from my new apple iphone!
Just wanted to say I love reading your blog and look forward
to all your posts! Keep up the excellent work!

Also visit my blog post :: barbara wine

basketball clothing websites's picture

This post is invaluable. How can I find out more?

Alsso visit myy webpage :: basketball clothing websites

forum sexting's picture

If you are going for best contents like me, only go to see
this web site all the time since it gives quality contents, thanks

shop computer online usa's picture

My developer is trying to persuade me to move to .net
frim PHP. I have always disoiked the idea because of the costs.
But he's tryiong none the less. I've ben using Movable-type on several websites for about
a year aand am worried abot switching tto another platform.

I have heard geat things about blogengine.net. Is there a way I
can transfer all my wordpress content into it?

Any help would bbe greatly appreciated!

My blog post ... shop computer online usa

casino online malaysia's picture

Hi! I could have sworn I've visited your blog before but after browsing through a few of the articles
I realized it's new to me. Nonetheless, I'm certainly pleased I
stumbled upon it and I'll be bookmarking it and checking back frequently!

dien dan rao vat tong hop's picture

Hey! Do you know if they make any plugins to help with Search Engine Optimization?

I'm trying to get my blog to rank for some targeted keywords but I'm not seeing very good success.
If you know of any please share. Cheers!

buy gaming computer usa's picture

Hello there, just became alert to your blogg through Google, and found that it is truly informative.

I'm going to watch out for brussels. I'll be grateful if you
continue this in future.Numerous people will
be benefited from your writing. Cheers!

Feel free too visit my bpog posxt :: buy gaming computer usa

Bandar Bola Terpercaya danTerbaik's picture

Pretty nice post. I just stumbled upon your weblog and wished to say that I've really enjoyed surfing around
your blog posts. In any case I will be subscribing to your rss feed and I
hope you write again soon!

bet365 games's picture

I was curious if you ever thought of changing the page layout of your website?

Its very well written; I love what youve got to say.
But maybe you could a little more in the way of content so people could connect with it better.
Youve got an awful lot of text for only having 1 or two images.
Maybe you could space it out better?

Augusto de Arruda Botelho's picture

Its like you read my mind! You seem to know a lot about this,
like you wrote the book in it or something. I think that you can do with some pics to drive the message home a little bit, but other than that, this is great blog.
A great read. I'll definitely be back.

Clash Royale Hack No Survey's picture

Great article.

fetish's picture

Horny beginner fashions at home with live intercourse webcams.

Ian Leaf Tax Fraud's picture

When I initially left a comment I seem to
have clicked on the -Notify me when new comments are added- checkbox and from now on each time a comment is added
I recieve 4 emails with the exact same comment.
Perhapss there is an easy method you can remove me from that service?

shop computer online usa's picture

I blog often and I really appreciate your information. The article has really
peaked my interest. I'm going to book mqrk your blog andd keep checking for
new details about once a week. I opted in for your RSS feed
as well.

Here is my homepage shop computer online usa

Gary Huffman's picture

First off I want to say terrific blog! I had a quick question that I'd like
to ask if you do not mind. I was interested to know how you center yourself and
clear your thoughts prior to writing. I have had a difficult time clearing my
thoughts in getting my ideas out. I truly do enjoy writing but it just seems like the first 10 to 15 minutes are generally lost simply
just trying to figure out how to begin. Any ideas or hints?


Joesph's picture

Heya i am for the first time here. I came across this board and I find It really useful & it helped
me out a lot. I hope to give something back and help others like you helped me.

too much vitamin c's picture

whoah this weblog is magnificent i really like studying your posts.
Stay up the good work! You understand, a lot of individuals are looking around
for this info, you could aid them greatly.

facebook.com's picture

That is a very good tip especially to those fresh to the blogosphere.
Simple but very precise information... Many thanks for sharing
this one. A must read post!

link's picture

hey there and thank you for your information - I've definitely picked up something new from right here.
I did however expertise several technical issues using this site,
as I experienced to reload the website a lot of times previous to I could get it to load correctly.
I had been wondering if your web host is OK? Not that I'm complaining,
but slow loading instances times will very frequently affect your placement in google and could damage your high quality score if advertising and marketing with Adwords.
Anyway I am adding this RSS to my e-mail and could look out for much more of your respective exciting content.

Make sure you update this again very soon.

My website: link

Jodi's picture

Today, while I wаs аt work, mү cousin stole mу iphone and tested tо seee if іt can survive a forty fooit drop, just soo ѕһе cаn Ƅе ɑ youtube sensation. Μү iPad iѕ noա broken and ѕһᥱ һas 83 views.
Ӏ knoow thіs іѕ totally ߋff topic but Ι ɦad tο share іt ѡith ѕomeone!

Ꭺlso visit mү ρage :: atkins diet plan (Jodi)


Add new comment