Linux, GCC, Program developers ...

Submitted by Anonymous
on August 6, 2004 - 2:55pm

Hi, I'm not an expert user, this days I try to install gentoo on my laptop, and is was something (I don't know really how to explain it) but bootstraping the system, it was a very dificult for me.
The situation is:
gcc compiler knows how to optimize programs
we have a lot of scripts and programs that tell us wath are the flags that we can activate or not, to compile to our architecture, and developers can tell us what are the flags that we cant use to optimize software, ok.

Now why nobody, i think, makes or develop something to merge all. An script that automatically activate the flags on our makefiles, and a file thas say what soft flags program support.

Anybody knows something about? I have a lot of interest to learn about this.

And learn the language too (sorry for my poor poor english)

Thanks everybody

Gentoo is messy, and doesn't

Ano Nymous
on
August 6, 2004 - 6:07pm

Gentoo is messy, and doesn't make things easier or less complicate (horrible complicated init system, badly used use-flags, terribly inefficient portage, etc). Just compile some from source yourself, doing the ./configure && make thing.

To see all available compile time options, do ./configure -help. Gentoo uses use-flags to choose some of those options.

The nice thing is that you can set the needed environment variables, they're listed with the -help option. So just export CFLAG/CXXFLAGS to whatever you want, and any package with a sane build system will compile perfectly with your compile flags. The application specific options will be appended by the Makefile, the platform specific options are set by the autobuild system. Everything should just work.

Keep in mind that which options are good and which won't work is mainly a compiler version specific issue.

There are a lot of compile flags, but luckily they are grouped together. If you want good optimization, use -O2. If you like to gamble and want a few % more (or less) performance, use -O3. Personally I used with Gentoo "march=i586 -O2 -s --fomit-frame-pointer". Almost all other options you see a lot people using are already included with -O2 or the specific cputype with march.

fomit-frame-pointer is a bad,

Anonymous
on
August 7, 2004 - 6:56am

fomit-frame-pointer is a bad, bad idea, at least on i386. It precludes you from any sort of debugging, and with some programs causes unpredictable behavior.

Re: fomit-frame-pointer is a bad,

Anonymous
on
August 9, 2004 - 2:03am

BS. -fomit-frame-pointer is Just Fine if you are not interested in debugging. For to-be-GCC-3.5 and for SuSE GCC-3.3 (the hammer-branch), -fomit-frame-pointer even is the default, and you still can debug your stuff because you have variable tracking. I'm not sure which GCC is used by Gentoo, but if it is 3.3-hammer-branch, you can safely use -fomit-frame-pointer.

If I want to debug I'll recom

Ano Nymous
on
August 9, 2004 - 8:20am

If I want to debug I'll recompile with -g...

Re: Gentoo is messy, and doesn't...

Anonymous
on
August 10, 2004 - 4:59am

Hmmm... Distro war...

< flame >
I suppose you're an LFS type? Do you also believe in reading your mail with tcpdump?
< /flame >

Please share your insights with the regard to the horribleness and messyness.

Sure. The messiness: Just

Ano Nymous
on
August 11, 2004 - 6:42am

Sure.

The messiness: Just do a `ls /etc /usr`. Perhaps you're used to it, but all those links for "backward" compatibility are just plain ugly, not to mention that they let a lot programs dump their content wherever they like (those should be either configured to do that in the appropriate place, or patched). It can be so much cleaner.

Mind that I said "horrible complicated init system". It's ok if it just works and if you just make simple init scripts the Gentoo way, but it was totally broken after I updated some programs (instead of the whole system). I needed to manually fix it, and then it's no fun anymore. It also somehow can't handle parallel init scripts, at least not my custom made one (bash script with & at the end at the right place).

Last time I run portage it took 15 minutes just updating the package list. Syncing thousands of files of which most you simply don't use is plain stupid IMHO. At the very least it's very inefficient... (Though it seems that that's the case with all package managers). The least thing portage could do is use compression when syncing. If it already does then the problem is worse than I thought.

If you want to learn the basic build systems (autobuild, makefiles, etc.) then using Gentoo isn't very helpful. In that context I said that simply doing ./configure && make yourself with the right environment flags comes very close to what the original poster wanted.

I don't know that many distros, so I'm not saying that Gentoo is worse than average though.

If you think my complaints about Gentoo aren't valid, great, that means it's good enough for you. Personally I think Gentoo's good points come from hard working people, and not because of their good system.

BTW, this isn't a distrowar, except if you start comparing Gentoo with other distros, which I don't and won't do. If some other distro is worse than that's no excuse for Gentoo.

There are easier ways...

Hydroxides
on
August 8, 2004 - 9:58pm

I probably haven't fully understood what it was you wanted but I have a few suggestions.

Gentoo isn't the easiest distro to install to begin with. You might like to try Mandrake for example. If you definately prefer Gentoo then why not try installing from a Stage 3 GRP? This is much easier than bootstrapping and you can always recompile the provided packages to your own preferences. If you still *really* want to do a bootstrap install and you are having difficulties, post / search for your problems on the Gentoo forums at http://forums.gentoo.org/ where you can find support in a variety of different languages.

From what I think you are trying to get at with the point about makefiles; to get the portage system to automatically recognise flags in makefiles would require some form of intelligence. Emerge would have to be able to assign some form of semantics to each flag.

The ebuild system avoids the need for any such processing. One human operator produces an ebuild, contributes it to portage, and millions of gentoo users can benefit from the automation it provides. The problem arises when there isn't an ebuild for the software you want to install. In these cases, if you want it badly enough, you should write your own ebuild and contribute it, thereby giving a little back to the community.

hi

Anonymous
on
August 11, 2004 - 9:51pm

i also not about gcc. can u help me on this topics.
thanks.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.