Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Gentoo With Musl [I have no idea what I'm doing]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
unheatedgarage
n00b
n00b


Joined: 19 Sep 2016
Posts: 21

PostPosted: Mon Dec 11, 2017 4:28 am    Post subject: Gentoo With Musl [I have no idea what I'm doing] Reply with quote

Greetings to all. I hope this message finds you in good places—with good people.

I had hoped to start this as a “how-to” for Gentoo musl, but I’m stuck. With your good graces, maybe we can work this into some sort of self-help. If it pleases everyone, I’ll update this later with my methodology with all the ins-and-outs, but for now, here’s the TL;DR:

I’m chrooted into my environment, I can build an XFCE desktop and all its goodies, but for the life of me, I cannot boot.

Try as I might, I can't get an initramfs. Genkernel gives me this:


Code:
* Gentoo Linux Genkernel; Version 68
* Running with options: --install initramfs

* Using genkernel.conf from /etc/genkernel.conf
* Sourcing arch-specific config.sh from /usr/share/genkernel/arch/x86_64/config.sh ..
* Sourcing arch-specific modules_load from /usr/share/genkernel/arch/x86_64/modules_load ..

* Linux Kernel 4.12.12-gentoo for x86_64...
* .. with config file /etc/kernels/kernel-config-x86_64-4.12.12-gentoo
* mount: /boot mounted successfully!
* busybox: >> Applying patches...
*           - 1.18.1-openvt.diff
*           - busybox-1.20.1-strict-atime.patch
*           - busybox-1.20.2-glibc-sys-resource.patch
*           - busybox-1.7.4-signal-hack.patch
* busybox: >> Configuring...
* busybox: >> Compiling...
* ERROR: Failed to compile the "all" target...
*
* -- Grepping log... --
*
*  SHIPPED scripts/kconfig/zconf.tab.c
*  SHIPPED scripts/kconfig/lex.zconf.c
*  SHIPPED scripts/kconfig/zconf.hash.c
*  HOSTCC  scripts/kconfig/zconf.tab.o
*In file included from scripts/kconfig/zconf.tab.c:152:0:
*scripts/kconfig/zconf.hash.c:155:43: warning: ‘kconf_id_strings_contents’ is static but used in inline function ‘kconf_id_lookup’ which is not static
* #define kconf_id_strings ((const char *) &kconf_id_strings_contents)
*                                           ^
*scripts/kconfig/zconf.hash.c:222:44: note: in expansion of macro ‘kconf_id_strings’
*               register const char *s = o + kconf_id_strings;
*                                            ^~~~~~~~~~~~~~~~
*scripts/kconfig/zconf.hash.c:215:26: warning: ‘kconf_id_hash’ is static but used in inline function ‘kconf_id_lookup’ which is not static
*       register int key = kconf_id_hash (str, len);
*                          ^~~~~~~~~~~~~
*scripts/kconfig/zconf.hash.c:171:26: warning: ‘wordlist’ is static but declared in inline function ‘kconf_id_lookup’ which is not static
*   static struct kconf_id wordlist[] =
*                          ^~~~~~~~
*  HOSTLD  scripts/kconfig/conf
*scripts/kconfig/conf -o Config.in
*#
*.config:45:warning: trying to assign nonexistent symbol PID_FILE_PATH
*.config:100:warning: trying to assign nonexistent symbol SHA3_SMALL
*.config:268:warning: trying to assign nonexistent symbol SHA3SUM
*.config:621:warning: trying to assign nonexistent symbol FEATURE_VOLUMEID_EXFAT
*.config:625:warning: trying to assign nonexistent symbol FEATURE_VOLUMEID_NILFS
*.config:633:warning: trying to assign nonexistent symbol FEATURE_VOLUMEID_SQUASHFS
*.config:1027:warning: trying to assign nonexistent symbol FEATURE_KMSG_SYSLOG
*--
*Additional LDLIBS (EXTRA_LDLIBS) []
*
* Debugging Options
*
*Build BusyBox with extra Debugging symbols (DEBUG) [N/y/?] n
*Abort compilation on any warning (WERROR) [N/y/?] n



And etc, etc.

I’ve tried compiling the kernel manually and that gives no errors. Going through the the whole grub-mkconfig thingie works fine. System recognizes and tries to boot into it, but always with the kernel panic:

Code:
unable to mount root fs block [0.0]


Or something along those lines.

This is all new to me. Honestly, there’s always been someone else who’s asked the same question I’ve had, and so I’ve been able to humm along quietly in the background. But here with musl experimental, I’m really struggling.

Here’s my make.conf

Code:
# These settings were set by the catalyst build script that automatically
# built this stage.
# Please consult /usr/share/portage/config/make.conf.example for a more
# detailed example.
CFLAGS="-march=native -O2 -pipe -fomit-frame-pointer"
CXXFLAGS="${CFLAGS}"
# WARNING: Changing your CHOST is not something that should be done lightly.
# Please consult http://www.gentoo.org/doc/en/change-chost.xml before changing.
CHOST="x86_64-gentoo-linux-musl"
# These are the USE flags that were used in addition to what is provided by the
# profile used for building.
MAKEOPTS="-j3"
VIDEO_CARDS="intel i965"
USE="libressl mmx sse sse2"
PORTDIR="/usr/portage"
DISTDIR="${PORTDIR}/distfiles"
PKGDIR="${PORTDIR}/packages"
CPU_FLAGS_X86="aes avx mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3"
FEATURES="buildpkg"
CURL_SSL="libressl"
ACCEPT_KEYWORDS="~amd64"


I’ve researched the snot out of this—been working on this on-and-off for about a week—have learned a lot, but obviously I’m too dense to see what the problem is. I can’t help but feel it’s right in front of me.

Yes, I installed the experimental musl stage3. Absolutely I got layman going and got the musl overlay happening.

In all my other installs, I’ve never bothered with multiple partitions—just one big fat ext4 and then genkernel (or a quickie kernel tweak) took care of it. This whole bootstrap issue is (obviously) new.

[IHAVENOIDEAWHATI’MDOING]

Found a bug report here: https://github.com/orsonteodoro/muslx32/issues/4 but I’m not sure if it’s even relevant anymore.

I’ve subscribed to the gentoo-musl mailing list and scoured their history, but for the most part it’s devs talking to devs. They’ve already got a working system and (seriously) know what they're talking about.

So I’m flustered. My feathers are rustled.

I’ll calm my tits eventually, but for now I’m crawling before you with alms bowl in hand—humbly begging for a few shekels of help.

Is there any way I can boot into this puppy!?

[edit] I'm in this for the long haul; would really enjoy and appreciate anyone walking me through this. I'm not a fly-by-night kitten!
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 39297
Location: 56N 3W

PostPosted: Mon Dec 11, 2017 11:32 am    Post subject: Reply with quote

unheatedgarage,

Configure your kernel so you don't need an initrd.

You need to set a few things =y in the kernel but thats it.

These few things are
the options to read your partition tables
support for SCSI disks
support for your HDD controller, at least, the one that has your root filesystem attached.
support for your root filesystem.

Everything else can be modules.

Build and install your kernel and modules in the normal way.
You might even be able to use genkernel -menuconfig to help.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
helecho
Apprentice
Apprentice


Joined: 26 Dec 2016
Posts: 238

PostPosted: Tue Dec 12, 2017 7:20 am    Post subject: Reply with quote

In my opinion, your choice implies the following acquired:

  1. have the fundamentals of programming
  2. know the development environment
  3. have a good knowledge of the C language (advanced level)

It seems to me that the third element is essential to perceive significant elements. Feel free to ask questions!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum