Page 1 of 1

Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 6:40 am
by plevexier
Hi all,

I'm having an issue compiling the meaty skeleton on one of my machine, mint 17.3 (make 3.81), while I can on a laptop with mint 18 (make 4.1).

The commands clean.sh and build.sh return:

>Makefile:23: arch//make.config: No such file or directory
>make: *** No rule to make target `arch//make.config'. Stop.

(it's missing the i386 in the path arch//make.config.)

When I run:
>./target-triplet-to-arch.sh i686-elf

which the makefile in kernel seems to do, I get:

>i386

Which should be then used to compile the module kernel but no luck...

Any help appreciated.

Re: Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 9:26 am
by Octacone
If you target arch is 686 then you should compile it with 686 not 386.

Re: Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 9:48 am
by sortie
Hi, I'm the author of Meaty Skeleton.

I recently upgraded the Meaty Skeleton example. It now requires GNU make 4.0 to get the “FOO != bar” syntax. This is essentially equivalent to “FOO := $(shell bar)”, but works on BSD make as well and has a better chance of being standardized. You can do the reverse transformation if you want to support older GNU make.

Note that your distro Mint 17.3 ships GNU make 3.81, which is from 2006. GNU make 4.0 is from 2013 and while older GNU makes are still in the wild, it's increasingly becoming reasonable to just depend on GNU make from 2013. It seems reasonable to blame your distro here, unfortunately. Mint 17.3 is based on the Ubuntu 14.04 long term support and it ships a lot of outdated software. You probably want to upgrade to Mint 18 (based on Ubuntu 16.04 LTS, which has modern GNU make), or to manually compile the latest GNU make 4.2 release from https://ftp.gnu.org/gnu/make/.

It's regretful that common distributions still ship ancient GNU make releases. I'll add a item on my todo list to properly document that GNU make 4.0 is a prerequisite.

Thanks for trying out meaty skeleton and good luck with osdev

Re: Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 10:07 am
by plevexier
sortie wrote:Hi, I'm the author of Meaty Skeleton.

I recently upgraded the Meaty Skeleton example. It now requires GNU make 4.0 to get the “FOO != bar” syntax. This is essentially equivalent to “FOO := $(shell bar)”, but works on BSD make as well and has a better chance of being standardized. You can do the reverse transformation if you want to support older GNU make.

Note that your distro Mint 17.3 ships GNU make 3.81, which is from 2006. GNU make 4.0 is from 2013 and while older GNU makes are still in the wild, it's increasingly becoming reasonable to just depend on GNU make from 2013. It seems reasonable to blame your distro here, unfortunately. Mint 17.3 is based on the Ubuntu 14.04 long term support and it ships a lot of outdated software. You probably want to upgrade to Mint 18 (based on Ubuntu 16.04 LTS, which has modern GNU make), or to manually compile the latest GNU make 4.2 release from https://ftp.gnu.org/gnu/make/.

It's regretful that common distributions still ship ancient GNU make releases. I'll add a item on my todo list to properly document that GNU make 4.0 is a prerequisite.

Thanks for trying out meaty skeleton and good luck with osdev
You absolutely right, I need to upgrade mint asap. For now, I just upgraded make, and now it compiles perfectly!

Thanks a lot, and good job with meaty skeleton, it's a very good starting point for me, the structure, the libc etc.

Re: Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 10:52 am
by sortie
Sounds good. I can relate, this laptop still runs 17.3, though I did get around to upgrading my desktop to 18 (which is nicely newer, but subtle stuff was changed and there's new and different bugs, and it felt less like home, but I've gotten more used now). I'm glad to hear meaty skeleton is doing a good job showing how to potentially structure an OS.

Re: Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 12:43 pm
by crunch
Sortie, that's a really nice tutorial. I think it should go on the front page of the wiki.
I appreciate that you included stuff on making a hosted libc - I'm just getting around to doing that myself.

You guys should switch to Arch. Bleeding edge software and all that 8)

Re: Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 12:49 pm
by sham1
crunch wrote:Sortie, that's a really nice tutorial. I think it should go on the front page of the wiki.
I appreciate that you included stuff on making a hosted libc - I'm just getting around to doing that myself.

You guys should switch to Arch. Bleeding edge software and all that 8)
Gentoo is where it's at. But this is kinda off-topic.

Re: Compilation issue with meaty skeleton

Posted: Wed Sep 21, 2016 2:29 pm
by sortie
Obviously you should all osdev from my OS. Hehe. Isn't that the absolute self-hosting ideal? Not only preferring to develop on your own system, but people prefer to develop their own too. :P
crunch wrote:Sortie, that's a really nice tutorial. I think it should go on the front page of the wiki.
Thanks, I went ahead and did that.
crunch wrote:I appreciate that you included stuff on making a hosted libc - I'm just getting around to doing that myself.
Yeah, I need to do an in-depth libc tutorial. Meaty Skeleton only covers the organization and some crucial concepts like the sysroot, but those are pretty useful and goes a long way.