Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Other Things Gentoo
  • Search

migration from glibc to musl

Still need help with Gentoo, and your question doesn't fit in the above forums? Here is your last bastion of hope.
Post Reply
Advanced search
28 posts
  • 1
  • 2
  • Next
Author
Message
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

migration from glibc to musl

  • Quote

Post by DaggyStyle » Fri Oct 31, 2014 7:57 pm

Greetings,

I'm thinking of migrating from glibc to musl, has anyone done it? are there any pitfalls I should know of
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
Ant P.
Watchman
Watchman
Posts: 6920
Joined: Sat Apr 18, 2009 7:18 pm
Contact:
Contact Ant P.
Website

  • Quote

Post by Ant P. » Fri Oct 31, 2014 8:29 pm

Haven't done it myself, but I'm also interested.

There's install instructions here, looks a bit fiddly but I may give it a try in a VM later.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Fri Oct 31, 2014 9:43 pm

thanks for the link but I don't think going hardened is something I need.
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
Ant P.
Watchman
Watchman
Posts: 6920
Joined: Sat Apr 18, 2009 7:18 pm
Contact:
Contact Ant P.
Website

  • Quote

Post by Ant P. » Fri Oct 31, 2014 10:58 pm

Yeah, doesn't seem perfect to me either, but it looks like the only "supported" option at the moment. I haven't seen anything else other than a crossdev target and that seems a lot more work.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 01, 2014 6:47 am

Ant P. wrote:Yeah, doesn't seem perfect to me either, but it looks like the only "supported" option at the moment. I haven't seen anything else other than a crossdev target and that seems a lot more work.
I know of a user using a different distro which switched to musl completely.

maybe I'll create a vm and start fixing this (off work project), I did it at work for some programs that we needed to work with.
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
heiwa
n00b
n00b
Posts: 70
Joined: Wed Oct 24, 2012 7:25 pm

  • Quote

Post by heiwa » Sat Nov 01, 2014 7:51 am

To have a non-hardened toolchain, start out with the *-vanilla stage3.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 01, 2014 11:05 am

heiwa wrote:To have a non-hardened toolchain, start out with the *-vanilla stage3.
I know of no other than vanilla stage3 (normal one) unless I'm mistaken.

anyway what is needed to even start this is a static gcc as the first stage will be to convert gcc to musl from glibc (as one cannot install musl when glibc is installed, portage blocks it)
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
heiwa
n00b
n00b
Posts: 70
Joined: Wed Oct 24, 2012 7:25 pm

  • Quote

Post by heiwa » Sat Nov 01, 2014 4:11 pm

There is no easy way for switching the libc. You need to reinstall starting from one of the musl stage3s.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 01, 2014 4:46 pm

heiwa wrote:There is no easy way for switching the libc. You need to reinstall starting from one of the musl stage3s.

afaik, there is no such one... I think that stage1 is the only way to do that
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
heiwa
n00b
n00b
Posts: 70
Joined: Wed Oct 24, 2012 7:25 pm

  • Quote

Post by heiwa » Sat Nov 01, 2014 5:25 pm

Have you looked at the link in the first reply in this thread?
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 01, 2014 5:27 pm

yes, just noticed that.

http://distfiles.gentoo.org/experimenta ... 21.tar.bz2
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
N8Fear
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 140
Joined: Mon Apr 15, 2013 9:24 pm
Location: Berlin (Germany)

  • Quote

Post by N8Fear » Sat Nov 01, 2014 9:07 pm

musl is really cool, but you will definitely encounter breakage (especially on ~arch) and it will require quite a bit of manual labour to get everything running. If you're fine with that: go for it, but expect a more 2003ish Gentoo experience not the "pampered" one you'll have on glibc right now.
Other than that I think that there is no real migration option (except reinstall from a musl stage 3 or bootstrap the system from scratch).

If you're really interested you could take a look at https://github.com/N8Fear/musl-overlay where I did some work to get "my system" working on musl (there's still some stuff missing for me, like clang/llvm and firefox/chromium).
Top
badc0d3d
n00b
n00b
User avatar
Posts: 6
Joined: Sun Oct 27, 2013 4:41 pm

  • Quote

Post by badc0d3d » Sun Nov 02, 2014 7:32 pm

I recently found out alpine linux that is running on musl wih grsec/pax and for the time I've used it, acts pretty stable.
You might consider trying it, it was built using portage, but it has its own package manager.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Mon Nov 03, 2014 7:48 am

I want my gentoo :)
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
Ian
l33t
l33t
Posts: 834
Joined: Mon Oct 28, 2002 10:15 pm
Location: Somerville, MA

  • Quote

Post by Ian » Mon Nov 03, 2014 1:17 pm

Curious if anyone has thoughts on using MUSL for ARM, specifically a BeagleBone Black? I might try it just because, though I'm not sure if it's actually worthwhile or not.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Mon Nov 03, 2014 2:20 pm

Ian wrote:Curious if anyone has thoughts on using MUSL for ARM, specifically a BeagleBone Black? I might try it just because, though I'm not sure if it's actually worthwhile or not.
that might be a good question for the guys at crosstool-ng, the guy which was in charge of adding it to crosstool-ng was using arm in the first place I think.
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
Ian
l33t
l33t
Posts: 834
Joined: Mon Oct 28, 2002 10:15 pm
Location: Somerville, MA

  • Quote

Post by Ian » Tue Nov 04, 2014 2:13 am

DaggyStyle wrote:that might be a good question for the guys at crosstool-ng, the guy which was in charge of adding it to crosstool-ng was using arm in the first place I think.
I might look into this more. Turns out I'm going to be working all weekend, so this might turn into a longer term project then I was hoping for. Oh well, like I said, if it's a "just because" project it's not like it was going to be on a real timeline anyways.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 08, 2014 4:53 pm

after talking with the main dev of the hardend musl branch, he told me that the branch is not hardened only, it just stored there.
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
steveL
Watchman
Watchman
Posts: 5153
Joined: Wed Sep 13, 2006 1:18 pm
Location: The Peanut Gallery

  • Quote

Post by steveL » Sat Nov 08, 2014 9:51 pm

Go for it, DaggyStyle; I'd like to follow how you get on. #gentoo-embedded is full of people who'll help (blueness is in there, too.)
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Fri Nov 14, 2014 6:17 am

steveL wrote:Go for it, DaggyStyle; I'd like to follow how you get on. #gentoo-embedded is full of people who'll help (blueness is in there, too.)

Code: Select all

(chroot) livecd tmp # gcc-config -l
 [1] x86_64-gentoo-linux-musl-4.8.3 *
(chroot) livecd tmp # emerge -s eudev
Searching...    
[ Results for search key : eudev ]
[ Applications found : 1 ]

*  sys-fs/eudev
      Latest version available: 1.10-r2
      Latest version installed: 1.10-r2
      Size of files: 1,735 kB
      Homepage:      https://github.com/gentoo/eudev
      Description:   Linux dynamic and persistent device naming support (aka userspace devfs)
      License:       LGPL-2.1 MIT GPL-2

(chroot) livecd tmp # emerge -s systemd
Searching...    
[ Results for search key : systemd ]
[ Applications found : 6 ]

*  kde-misc/kcmsystemd [ Masked ]
      Latest version available: 0.7.0
      Latest version installed: [ Not Installed ]
      Size of files: 50 kB
      Homepage:      https://github.com/rthomsen/kcmsystemd
      Description:   KDE control module for systemd
      License:       GPL-3

*  sys-apps/gentoo-systemd-integration
      Latest version available: 4
      Latest version installed: [ Not Installed ]
      Size of files: 51 kB
      Homepage:      https://bitbucket.org/mgorny/gentoo-systemd-integration
      Description:   systemd integration files for Gentoo
      License:       BSD

*  sys-apps/systemd [ Masked ]
      Latest version available: 9999
      Latest version installed: [ Not Installed ]
      Size of files: 0 kB
      Homepage:      http://www.freedesktop.org/wiki/Software/systemd
      Description:   System and service manager for Linux
      License:       GPL-2 LGPL-2.1 MIT public-domain

*  sys-apps/systemd-sysv-utils [ Masked ]
      Latest version available: 217
      Latest version installed: [ Not Installed ]
      Size of files: 3,607 kB
      Homepage:      http://www.freedesktop.org/wiki/Software/systemd
      Description:   sysvinit compatibility symlinks and manpages
      License:       GPL-2

*  sys-apps/systemd-ui [ Masked ]
      Latest version available: 9999
      Latest version installed: [ Not Installed ]
      Size of files: 0 kB
      Homepage:      http://www.freedesktop.org/wiki/Software/systemd
      Description:   System and service manager for Linux
      License:       GPL-2

*  sys-devel/systemd-m4 [ Masked ]
      Latest version available: 9999
      Latest version installed: [ Not Installed ]
      Size of files: 0 kB
      Homepage:      https://bitbucket.org/mgorny/systemd-m4/
      Description:   autoconf macros for packages using systemd
      License:       BSD

(chroot) livecd tmp # 
;)
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
steveL
Watchman
Watchman
Posts: 5153
Joined: Wed Sep 13, 2006 1:18 pm
Location: The Peanut Gallery

  • Quote

Post by steveL » Fri Nov 14, 2014 1:22 pm

w00t! ;-)

Any tricky packages etc, please let us know in this thread as well, man.
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 15, 2014 5:30 am

steveL wrote:w00t! ;-)

Any tricky packages etc, please let us know in this thread as well, man.
well I've only started looking at this, I wasn't able to complete the install due to not been able to compile the following pkgs:
  • cronie
  • dhcpcd
  • portage-utils
  • grub2
so far I've provided upstream patches for cronie and portage-utils, dhcpcd is next and I'm waiting for clarifications on grub2.

according to the head maintainer of this branch gnome is kinda working on it, kde isn't so much, the rest of the WM works ok (xfce is best supported)
as I'm using kde in default I think I'll try focusing on it.
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
steveL
Watchman
Watchman
Posts: 5153
Joined: Wed Sep 13, 2006 1:18 pm
Location: The Peanut Gallery

  • Quote

Post by steveL » Sat Nov 15, 2014 6:21 am

DaggyStyle wrote:I wasn't able to complete the install due to not been able to compile the following pkgs:
  • cronie
  • dhcpcd
  • portage-utils
  • grub2
so far I've provided upstream patches for cronie and portage-utils, dhcpcd is next and I'm waiting for clarifications on grub2.
Excellent; you got links for those?
according to the head maintainer of this branch gnome is kinda working on it, kde isn't so much, the rest of the WM works ok (xfce is best supported)
as I'm using kde in default I think I'll try focusing on it.
Nice one, I'm a kde-user too, always have on Linux. Would be interesting to get -semantic-craptop and [topic=970574]creaker's patchsets[/topic] going, also his [topic=972762]Qt-mounter[/topic] for Michel's [topic=938680]nubkit-free desktop[/topic]. Speaking of whom, fvwm-crystal might be a good lightweight intermediate target (and you'd get an excellent userbase.)

Though I had to switch [topic=945868]to mutt from KMail[/topic] after I turned off semantic-craptop, which was very hard after 15 years happily using KMail, I'm really glad I did now. It's so light and quick in combination with yakuake, and my desktop now runs as slick as 3.5.x used to. I was ready to jack KDE in before I finally got it slimmed-down; 4.9 and "Attach as tab to.." finally made it feel like an improvement (though mainly that was because of the taskbar idiocy no longer being an issue, it's a classic example of multiprocessing and doing things simply, leading to a very nice setup.)
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 15, 2014 9:47 am

steveL wrote:
DaggyStyle wrote:I wasn't able to complete the install due to not been able to compile the following pkgs:
  • cronie
  • dhcpcd
  • portage-utils
  • grub2
so far I've provided upstream patches for cronie and portage-utils, dhcpcd is next and I'm waiting for clarifications on grub2.
Excellent; you got links for those?
these patches weren't accepted yet by hardend-devs so no links yet.
steveL wrote:
according to the head maintainer of this branch gnome is kinda working on it, kde isn't so much, the rest of the WM works ok (xfce is best supported)
as I'm using kde in default I think I'll try focusing on it.
Nice one, I'm a kde-user too, always have on Linux. Would be interesting to get -semantic-craptop and [topic=970574]creaker's patchsets[/topic] going, also his [topic=972762]Qt-mounter[/topic] for Michel's [topic=938680]nubkit-free desktop[/topic]. Speaking of whom, fvwm-crystal might be a good lightweight intermediate target (and you'd get an excellent userbase.)

Though I had to switch [topic=945868]to mutt from KMail[/topic] after I turned off semantic-craptop, which was very hard after 15 years happily using KMail, I'm really glad I did now. It's so light and quick in combination with yakuake, and my desktop now runs as slick as 3.5.x used to. I was ready to jack KDE in before I finally got it slimmed-down; 4.9 and "Attach as tab to.." finally made it feel like an improvement (though mainly that was because of the taskbar idiocy no longer being an issue, it's a classic example of multiprocessing and doing things simply, leading to a very nice setup.)
I think that the main goal should be have kde work on musl before going into adventures.

but I was thinking of focusing on kf5 instead of kde4 as I don't want to work on something that might be deprecated halfway
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
DaggyStyle
Watchman
Watchman
User avatar
Posts: 5969
Joined: Wed Mar 22, 2006 6:57 am

  • Quote

Post by DaggyStyle » Sat Nov 15, 2014 5:33 pm

howto can be found at http://forums.gentoo.org/viewtopic-p-76 ... ml#7651260
Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein
Top
Post Reply

28 posts
  • 1
  • 2
  • Next

Return to “Other Things Gentoo”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic