[PC-BSD Pbi-dev] PBI building simplifying
A.Yerenkow
yerenkow at uct.ua
Thu Dec 24 15:25:50 PST 2009
Hello all.
Long time ago I once started this topic - How to simplify PBI building.
I suggest then use packages, and now I see how it's going to be.
1.
/pbi-build would have a new directory, "cached-packages"
/pbisandbox scripts would have a LOCALBASE set to something like this:
/usr/veryveryveryveryverylongprobably256symbolslonglocalbase
for example, we are building Firefox.
we creating locabase like this:
/Programs/Firefox
and linking to this directory
/usr/veryveryveryveryverylongprobably256symbolslonglocalbase (so this
isn't real dir, it's symlink to /Programs/Firefox)
2. all required soft installed via packages from "cached-packages".
Localbase of these packages of course is our long one.
If such package not exists, we are iterating by dependencies deeper,
checking the same.
If there is no dependencies, build package for long Localbase, copy
package to /pbi-build/cached-packages.
After one run, we'll have all needed ports as packages.
Of course, there have to be a black-list, a list where ports have to be
built against real localbase, such as /Programs/Firefox -- ports which
are not respecting LOCALBASE, and/or have somewhere hardcoded usage of
localbase resources. But we anyway install's them to long localbase, to
satisfy dependencies for now.
3. After target port installed OK - Iterate by blacklisted ports,
deinstall packages from
/usr/veryveryveryveryverylongprobably256symbolslonglocalbase and install
it via ports to /Programs/Firefox
4. after all installed to
/usr/veryveryveryveryverylongprobably256symbolslonglocalbase, which is
really /Programs/Firefox, do this:
- find all executable files
- chrpath it's RPATH to /Programs/Firefox
About chrpath: http://www.freshports.org/devel/chrpath/
5. How to make a black-list ports:
make package for
/usr/veryveryveryveryverylongprobably256symbolslonglocalbase, install it,
change in all elfs RPATH, after this: if somewhere there exists elf
file, which contains
/usr/veryveryveryveryverylongprobably256symbolslonglocalbase -
blacklist it. probably even not elf file, text one, or other if contains
long localbase - better blacklist it.
This will significantly make PBI builds easier; almost all PBIs installs
xorg, perl, etc. - some of this ports can be chrpath'ed, and all time
required to build PBI will be reduced.
Maybe not significantly, but I think this is worth thing.
Comments?
More information about the Pbi-dev
mailing list