Gentoo Archives: gentoo-user

From: waltdnes@××××××××.org
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Anybody got a Gentoo system working under uclibc?
Date: Wed, 27 Apr 2016 21:31:48
Message-Id: 20160427213140.GA2563@waltdnes.org
In Reply to: Re: [gentoo-user] Anybody got a Gentoo system working under uclibc? by Corbin
1 On Wed, Apr 27, 2016 at 12:25:41PM -0500, Corbin wrote
2 >
3 > On 04/27/2016 09:12 AM, waltdnes@××××××××.org wrote:
4 > > I'm testing uclibc in a 32-bit QEMU Gentoo VM. I want to eventually
5 > > install on my ancient 32-bit-only netbook. I'm running into problems.
6 > > See https://forums.gentoo.org/viewtopic-p-7912494.html
7 > >
8 > > To summarize...
9 > > * static IP works for eth0, but dhcpcd fails, which is bad news for a
10 > > laptop or netbook
11 > > * when building x-rg-server, the builds for xf86-input-keyboard and
12 > > xf86-video-intel fail to compile
13 > > * www-client/w3m fails to build, so I can't even get decent textmode
14 > > web browsing
15 > >
16 >
17 > You already found my test load :)
18 > Glad it helped someone.
19 >
20 > Did you have/add "evdev" in "make.conf" for INPUT_DEVICES?
21 > "evdev" is built-into-the-kernel or a kernel module. The newer input
22 > function, augmenting/replacing the AT keyboard and /dev/psaux.
23 > ( Seems "evdev" is almost replacing the functions of "xf86-input"
24 > libraries for Xorg.)
25
26 No. Do I have to set something in the kernel? Will the keyboard work
27 with evdev and without xf86-input-keyboard? My netbook uses framebuffer
28 video driver, so I might try using that in the uclibc VM.
29
30 > What CPU flags did you set/unset for the build?
31 >
32 > My reason for asking ... a lot of software has an unmarked dependency on
33 > "sse/sse2". If the info on the Atom CPU I found was correct ... it
34 > doesn't have sse/sse2 instruction sets.
35
36 My Atom netbook has them, according to /proc/cpuinfo
37
38 flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge
39 mca cmov pat clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx
40 constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor ds_cpl
41 vmx est tm2 ssse3 xtpr pdcm movbe lahf_lm dtherm tpr_shadow vnmi
42 flexpriority
43
44 Note also the "movbe" flag. *I CANNOT TEST RUN MY NETBOOK-OPTIMIZED
45 CODE I BUILD IN THE QEMU VM*. QEMU claims to emulate "Atom" CPUs.
46 There are over 100 different atoms in the periodic table known to
47 physicists, and Intel is just as bad, with all their "Atom" variants.
48 QEMU's "Atom" emulation does not support the "movbe" flag. So I simply
49 run with the host CPU in a 32-bit VM, and set "-march=native". When
50 building for the netbook, I build with "-march=bonnell". Important
51 distinction...
52
53 different "-march" values != crossdev
54
55 As long as the "CHOST" variable is identical, you can build for
56 different "-march" variants, even those that won't run in the build
57 environment.
58
59 > Useful Info : https://wiki.gentoo.org/wiki/Safe_CFLAGS
60
61 See also http://gentoo-en.vfose.ru/wiki/Safe_Cflags#-march.3Dnative
62
63 gcc -march=native -E -v - </dev/null 2>&1 | grep cc1
64
65 Ignore all the fancy flags. Both of those pages come up with output
66 that shows "-march=bonnell" on my Atom
67 https://en.wikipedia.org/wiki/Bonnell_%28microarchitecture%29
68
69 I have a standard glibc 32-bit VM which I use for Gentoo distcc for
70 the Atom, as well as manually building Pale Moon web browser. I use the
71 following settings for both...
72
73 CFLAGS="-O2 -march=bonnell -mfpmath=sse -pipe -fomit-frame-pointer \
74 -fno-unwind-tables -fno-asynchronous-unwind-tables"
75
76 CCFLAGS="${CFLAGS}"
77
78 "-march=bonnell" implies all the other flags, so no need to enter them
79 into the CFLAGS variable.
80
81 Thanks for that initial post. I had almost given up on even a minimal
82 install, before I found it.
83
84 --
85 Walter Dnes <waltdnes@××××××××.org>
86 I don't run "desktop environments"; I run useful applications

Replies

Subject Author
Re: [gentoo-user] Anybody got a Gentoo system working under uclibc? Corbin <corbinbird@×××××××.net>