[Coco] nitros9 daily clean build script for Gene

Gene Heskett gheskett at wdtv.com
Wed Oct 22 20:42:57 EDT 2014


On Wednesday 22 October 2014 19:30:19 Tormod Volden did opine
And Gene did reply:
> On Thu, Oct 23, 2014 at 1:06 AM, Gene Heskett <gheskett at wdtv.com> wrote:
> > On Wednesday 22 October 2014 16:37:09 Tormod Volden did opine
> > 
> > And Gene did reply:
> >> I suggested this so many times, but here it is on a silver plate, so
> >> you have no escape :) Untested, so please tell if there is something
> >> wrong, or if there is any reason you cannot use this.
> >> 
> >> Tormod
> >> 
> >> 
> >> #!/bin/sh
> >> # NitrOS-9 daily clean build script
> >> # expects an existing repo in a "nitros9" directory
> >> set -e
> >> cd nitros9
> >> if ! hg incoming; then
> >> 
> >>     echo "No new changes to pull"
> >>     exit 1
> >> 
> >> fi
> >> hg pull
> >> hg update
> >> cd ..
> > 
> > ========
> > 
> >> BUILD_DIR=nitros9-$(date +%Y-%m-%d-%H-%M)
> >> hg clone nitros9 $BUILD_DIR
> >> cd $BUILD_DIR
> >> make dsk dskcopy
> > 
> > ========
> > 
> >> cd ..
> >> 
> >> #only for Gene:
> >> chown -R gene:www-data $BUILD_DIR
> > 
> > Whole script fails, no updates so it exits. doing those 4 lines by
> > hand to
> 
> "Whole script fails" - well, this is by design, if there are no
> updates it shouldn't waste anyone's time. You can comment out that
> check the first time.
> 
> > make it anyway gets me this:
> > gene at coyote:/opt/nitros9-2014-10-22-18-46$ sudo make dsk dskcopy
> 
> Nobody told you to use "sudo". This is Linux beginner fail number one,
> padding on "sudo" whenever there is an issue. If you need sudo to
> build nitros9 then your system is severely messed up. That's like
> using an administrator account on Windows to read e-mail. Hey wait...
> Just kidding :)

I don't have creation rights in /opt, and that is where the script runs.  
But the script chowns it back to me:www-data after each download/build.  
That way apache2 can also access it if you want to take a look with your 
browser.  Link in sig of course.
 
> > **************************************************
> > *                                                *
> > *              THE NITROS-9 PROJECT              *
> > *                                                *
> > **************************************************
> > make -C /lib && make -C /level1 && make -C /level2 && make -C /level3
> > && make -C /3rdparty && :
> > make[1]: Entering directory `/lib'
> > make[1]: *** No targets specified and no makefile found.  Stop.
> > make[1]: Leaving directory `/lib'
> > make: *** [all] Error 2
> 
> This is because you have set NITROS9DIR to an empty value.
No, $NITROS9DIR is set in my bashrc, and that meant it was not pointing at 
my clone+date, but to /opt/nitros9.  That has been a part of my .bashrc 
for a good decade.
> You
> shouldn't set it all. Use "unset NITROS9DIR" in your current shell, or
> start a new fresh shell.

That would inherit the assignment from my .bashrc.
> 
> > I am going to comment the lwtools branch out of my script, which
> > makes it much like yours, then try yours again, and see if I have
> > any makefiles.
> 
> Please use my script, or follow the instructions. It is impossible to
> help you if you insist on doing things your own way.

Are you saying that a fresh hg clone is not the same as a later 
hg pull;hg update?  I can do an hg pull and get nothing afterwards.  If I 
understand hg, and I'm about a first grader at it, I have assumed the 
clone to a fresh directory should give me the cleanest copy, and indeed it 
did until it ran into the blanked makefile in the level3 directory, the 
one you now have a replacement for in your inbox.
 
> > This is frustrating at best.
> 
> Do not complicate things with build scripts if you cannot get it to
> build by hand. The whole building from scratch is fairly simple. See
> http://sourceforge.net/p/nitros9/wiki/Building_NitrOS9/#obtain-and-buil
> d-nitros-9

Tormod, buildit scripts are my escape from the short term memory problems 
of being 80 years old.  When you are my age, you will depend on them 
simply because they do the same thing every time even if you have to read 
the script to refresh your own memory just to make sure you are about to 
fire off what might be the wrong one.

> Once you have this under control, you can think about making your own
> changes, using build scripts, and so on. One step at at time.

and all those 1 step at a time things were resolved and committed to a 
script in about 2001 maybe.  The script of course gets updated when I get 
the message its no longer correct.  I don't recall being told that the 
temporary lwtools branch was now frozen, and that work was now in the main 
tree.

> Regards,
> Tormod


Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>
US V Castleman, SCOTUS, Mar 2014 is grounds for Impeaching SCOTUS


More information about the Coco mailing list