The Thinly Sliced Developments

If you're coding on or porting to IRIX, this is the forum for discussion.
Post Reply
mrthinlysliced
Posts: 41
Joined: Mon May 14, 2018 9:21 am
Location: Colchester. UK

The Thinly Sliced Developments

Post by mrthinlysliced » Tue May 22, 2018 10:27 am

So I've only really started on the journey of trying to get vaguely modern tools up and running.

Originally wanted to get latest autoconf/automake/libtool which wasn't having any of it. So then I started down the rabbit hole of coreutils. Which brought me to needing a recent perl.

After much faffing, I have a latest single threaded perl:

Code: Select all

[dan@leafy t]$ ./perl --version

This is perl 5, version 26, subversion 2 (v5.26.2) built for IP30-irix

Copyright 1987-2018, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl".  If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.
And running tests shows lots of spam of course ........
then at the bottom....

Code: Select all

../lib/vars.t ...................................................... ok     
../lib/vars_carp.t ................................................. ok   
../lib/vmsish.t .................................................... ok     
../lib/warnings.t .................................................. ok       
All tests successful.
Files=2562, Tests=1154433, 7984 wallclock secs (1490.65 usr 73.01 sys + 6647.84 cusr 578.03 csys = 8789.53 CPU)
Result: PASS
It's not properly packaged in a dist of course, and I'm guessing there is probably issues when I turn on threading/shared libraries, but this is a start :-)

TruHobbyist
Posts: 25
Joined: Tue May 15, 2018 12:04 am

Re: The Thinly Sliced Developments

Post by TruHobbyist » Tue May 22, 2018 6:14 pm

Congrats !

User avatar
dexter1
Posts: 66
Joined: Thu May 24, 2018 9:30 am
Location: Zoetermeer, The Netherlands

Re: The Thinly Sliced Developments

Post by dexter1 » Thu May 24, 2018 10:14 am

I have ported Perl 5.24 in a threaded and non-threaded version as a Nekoware package. Have a look at ftp://ftp.irix.cc/pub/nekoware/dual-mip ... .0.tardist

It doesn't have any dependencies BTW, and you can have a look at how the IRIX inst package looks like and how i've built it. Maybe you can roll-your-own package.

We still require modern tools to run on IRIX machines so i'd welcome any attempts on getting this done. My current projects deals with porting python 2.7.15. Remember to keep checking those unittests!

mrthinlysliced
Posts: 41
Joined: Mon May 14, 2018 9:21 am
Location: Colchester. UK

Re: The Thinly Sliced Developments

Post by mrthinlysliced » Thu May 24, 2018 12:04 pm

OOoooo nice dexter, I'll take a peek at that this weekend and crib what I can.

mrthinlysliced
Posts: 41
Joined: Mon May 14, 2018 9:21 am
Location: Colchester. UK

Re: The Thinly Sliced Developments

Post by mrthinlysliced » Thu Jun 07, 2018 4:03 pm

Sooo, I started looking into making a perl package, and then I started looking into pumping up the optimisation level on some of the tools I was using to build perl, and now it's all broken :-0

Surprise.

It kind of impressed on me the need to go down the road of "create something that builds a deterministic bootstrap environment".

You can find my current efforts (currently unfinished, don't run it, honest) here:

https://github.com/danielhams/didbs

The goal of it is to basically get a bunch of things installed into some bootstrap root (without swpkg) to allow deterministic builds of other things like perl.

I've got as far as it doing a deterministic configure of tar (building is next) - but that's about it so far. I've still not decided what tools I should rely on for "bootstrapping". I might go as far as coding some ugly raw HTTP client in perl to bootstrap far enough up that curl or some other wget style thing works. File signatures seem painful too. "sum" isn't reliable between irix/linux.

It's still missing a dependency engine and proper handling of custom cflags and other stuff too I'd like to add. It doesn't yet detect what it has built either, there is a plan there, but this is all a hobby, so we see where it takes me :-)

User avatar
dexter1
Posts: 66
Joined: Thu May 24, 2018 9:30 am
Location: Zoetermeer, The Netherlands

Re: The Thinly Sliced Developments

Post by dexter1 » Thu Jun 07, 2018 6:33 pm

Careful with the increase of optimization levels of program-suite build. It can create obscure errors which are hard to detect.

File signatures i did with md5sum, which seem to be portable between different unix flavors.

Automated build systems for IRIX have been done before, see Tom Christensen's work at https://jupiterrise.com/tgcware/
He made the build tools available on github: https://github.com/tgc/buildpkg/blob/ma ... aging.irix
Also check out long-standing developer Rainer Canavan's beta directory in nekoware, where he made neko_<package>.txt into a runnable shell script for automatic building and installing of software.

Your approach of building in perl sounds good, but i don't think it will be that easy since it depends on the source code quality and configure ecosystem.
You probably need a recipe for each package and possibly it will also be version dependent. Any ideas on how to handle that?

mrthinlysliced
Posts: 41
Joined: Mon May 14, 2018 9:21 am
Location: Colchester. UK

Re: The Thinly Sliced Developments

Post by mrthinlysliced » Fri Jun 08, 2018 2:51 am

Yeah I was using sha256sum up until now for signatures, I'm just trying to avoid relying on other non out of the box built binaries (i.e. is coreutils available on mips3, for example). Might even go as far as including C source and a first run compile of critical tools like that.

Whilst I am intending to turn this into an automated builder - it's an automated builder for bootstrapped tooling - not for building end game Irix packages. For now :-)

To try and keep it flexible I'm intending each package to able to specify how they like to be built via a helper configure and helper build script. I even used the word recipe in there too.

Ideal goal: being able to run something like "bootstrap.pl --prefix=/path/to/bootstraproot --verifiedpackages" which will install the bits that have been marked as passing all the related package checks.
You probably need a recipe for each package and possibly it will also be version dependent. Any ideas on how to handle that?
I've got a per-package file like this for the moment (not set in stone, but gives a vague idea of where I'd like to go):

Code: Select all

packageSource=http://ftp.gnu.org/gnu/tar/tar-1.30.tar.gz
packageFile=tar-1.30.tar.gz
packageChecksum=e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
packageExtraction=gunziptarhelper.sh
packageDir=tar-1.30
packagePatch=tar.fix_ex_clashes.patch
expectedToolList=
dependenciesList=
envModifs=
configureRecipe=
buildRecipe=tar.buildit
passesChecksIndicator=0

mrthinlysliced
Posts: 41
Joined: Mon May 14, 2018 9:21 am
Location: Colchester. UK

Re: The Thinly Sliced Developments

Post by mrthinlysliced » Tue Jul 31, 2018 1:15 pm

Here's a first release of my little development bootstrapping tool "didbs". Needs mips4, fair chunk of ram, 2Gb of disk ish.

You can find quick destructions here:

https://github.com/danielhams/didbs/blo ... /README.md

It builds the following tools:

Code: Select all

autoconf-2.69
automake-1.16.1
bash-3.2.57
bzip2-1.0.6
coreutils-8.29
diffutils-3.6
emacs-23.3
findutils-4.6.0
gawk-3.1.8
gettext-0.19.8.1
git-2.17.0
gmp-6.1.2
gnutls-3.1.5
grep-3.1
gzip-1.9
jpeg-9c
less-530
libXpm-3.5.12
libarchive-3.3.2
libiconv-1.15
libpng-1.6.34
libtool-2.4.6
m4-1.4.18
make-3.82
mpfr-4.0.1
ncurses-6.1
nettle-3.4
openssl-1.1.0h
perl-5.22.4
pkg-config-0.29.2
readline-7.0
sed-4.5
tar-1.30
tiff-4.0.9
unzip60
vim81
wget-1.19.5
xli-2005-02-27
xosview-1.20
xz-5.2.4
zlib-1.2.11
It _doesn't_ build tardists (for better or for worse, that's where it is).

If you don't want to git clone from github I've attached a snapshot from today:
didbs-0.0.1a.tar.gz

User avatar
gijoe77
Posts: 196
Joined: Fri Jun 22, 2018 9:17 pm

Re: The Thinly Sliced Developments

Post by gijoe77 » Tue Jul 31, 2018 2:37 pm

very nice! I'll give this a try once I free up some time from my current building projects

User avatar
Raion-Fox
Founder
Posts: 194
Joined: Fri Nov 17, 2017 12:23 am
Location: Virginia
Contact:

Re: The Thinly Sliced Developments

Post by Raion-Fox » Mon Aug 06, 2018 5:17 pm

Very nice. I like this.
I'm the manager

Besides irix.cc, I run these sites:

projectkitsune.com

kazuo.io

Post Reply