Gentoo Archives: gentoo-hardened

From: Shinkan <shinkan@×××××.com>
To: gentoo-hardened@l.g.o
Subject: Re: [gentoo-hardened] Hardened Targets
Date: Tue, 01 Dec 2009 16:32:23
Message-Id: 166af1cf0912010831h44d04029j852d0b596d4d45be@mail.gmail.com
In Reply to: Re: [gentoo-hardened] Hardened Targets by Ed W
1 2009/12/1 Ed W <lists@××××××××××.com>
2
3 >
4 > So look at the TinyGentoo instructions:
5 > http://en.gentoo-wiki.com/wiki/TinyGentoo and this gives you the basic
6 > principles
7 >
8
9 Yeah, I'm more fond of things like this.
10 I don't need uclibc, or embedded things ... I just use a dedicated host as
11 my "build" chroot.
12 I based my thoughts on http://www.gentoo.org/proj/en/base/embedded/handbook/
13 The problem now is that I want some targets to run with "previous version"
14 libc, where previous comes for "anterior to my host libc/gcc".
15 So I think you have to compile with correct "previous version" gcc.
16 So I deduced I have to build a special env with old gcc + old libc to build
17 my old libc based target.
18 Is that the case ?
19 Or can I just emerge --root=/mytarget --configdir=/mytargetconfig
20 glibc-oldversion with my current host, and target will run correctly based
21 on glibc-oldversion ?
22
23
24 >
25 > I use a kind of similar process to build my builds. I use a chroot as the
26 > build system (basically just a roughly right stage4 build), then I chroot
27 > into that and build packages for everything that I need, then I install all
28 > the packages into some build directory and that becomes the new
29 > installation. This means that the destination doesn't need portage or gcc,
30 > etc (it's a very small and bare installation). You can also build packages
31 > to distribute with qpkg, etc.
32 >
33
34 I'm quite near that instead that I want to directly emerge in my target
35 build instead of building packages then unpacking them to my target.
36 Why is the chroot useful ? Why don't you just emerge onto your target with
37 you host ?
38
39
40 > I personally build mine the other way and install only the stuff I need
41 >
42
43 That's I want to do to. I would prefer not unmerging things.
44 I prefer asking myself "what should I add to nothing to have a bare minimal
45 working system" instead of "what sould I remove from a full build-capable
46 stage4 without breaking things".
47
48
49 >
50 > What I *expect* catalyst to do is to build a stage1-4 build environment,
51 > then use that stage4 build environment to build another stage1-4
52 > distribution where each stage builds incrementally?
53 >
54
55 Catalyst build stages from 1 to 4 starting with a chrooted stage3 which
56 serves as a build platform.
57 But as soon as you talk about "stage" in Gentoo, you comes with portage, gcc
58 and many build stuff I don't want in my target.
59 Catalyst use a "when stage4 is built, unmerge and remove a big list of
60 things like gcc" logic, which I don't want.
61 At least, that's what I figured out.
62
63 Anyway, thanks for the tips that was quite useful.
64
65
66 --
67 Pierre.
68 "Sometimes when I'm talking, my words can't keep up with my thoughts. I
69 wonder why we think faster than we speak. Probably so we can think twice." -
70 Bill Watterson

Replies

Subject Author
Re: [gentoo-hardened] Hardened Targets Ed W <lists@××××××××××.com>