LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices

Reply
 
Search this Thread
Old 09-24-2004, 10:01 PM   #1
black hole sun
Member
 
Registered: Jul 2004
Distribution: Slackware Current
Posts: 127

Rep: Reputation: 15
Where to change CFLAGS in Fedora Core 2?


I'm building a Linux From Scratch system using FC2 as the host. Thus I want some CFLAGS to optimize LFS.

Where do I set CFLAGS? There is no /etc/make.conf as in Gentoo, so I'm sort of lost.
 
Old 09-25-2004, 02:38 AM   #2
CroMagnon
Member
 
Registered: Sep 2004
Location: New Zealand
Distribution: Debian
Posts: 900

Rep: Reputation: 33
I'm surprise the LFS instructions don't cover this (haven't read them lately), but I liked to create a script in my home directory called "lfs" that took care of all the setup I needed (running the chroot command, setting variables and so on). All you need to do is add the command 'export CFLAGS=blablabla' to a script like that, or to your ~/.bashrc if you don't mind it always being set (if you're about to switch to your LFS system, this might be the case).
Good luck!
 
Old 09-26-2004, 11:42 AM   #3
black hole sun
Member
 
Registered: Jul 2004
Distribution: Slackware Current
Posts: 127

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by CroMagnon
I'm surprise the LFS instructions don't cover this (haven't read them lately), but I liked to create a script in my home directory called "lfs" that took care of all the setup I needed (running the chroot command, setting variables and so on). All you need to do is add the command 'export CFLAGS=blablabla' to a script like that, or to your ~/.bashrc if you don't mind it always being set (if you're about to switch to your LFS system, this might be the case).
Good luck!
Thanks. I managed to finish up my LFS system, using the temporary export command.

About the ~/.bashrc, I don't have this file. I have tried to create it and enter in:

export CFLAGS="-O2 -march=pentium4 -fomit-frame-pointer"

But when I echo $CLFAGS I get no result I want these settings to be permanent, I don't want to manually export CFLAGS every time I open up a shell...


EDIT: never mind. I just added the export commands to /etc/profile Thanks for your help!

Last edited by black hole sun; 09-26-2004 at 11:48 AM.
 
Old 09-26-2004, 05:17 PM   #4
CroMagnon
Member
 
Registered: Sep 2004
Location: New Zealand
Distribution: Debian
Posts: 900

Rep: Reputation: 33
If you're running X, you might need to log off and back on before items in .bashrc show up (or it's possible that it's not even being read due to the way you log in, or how your system is configured). ~/.bash_profile might be another option, but if you're happy with it in /etc/profile (i.e: all users) then that's fine too
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
question on optimizing fedora 2 CFLAGS to speed up programs opioid Linux - Software 1 11-21-2004 09:58 AM
Change boot image in Fedora Core 2 how?? virussx Fedora 1 10-23-2004 03:00 AM
How can i change file associations under fedora core 2? Braveheart1980 Linux - Software 13 08-01-2004 12:12 PM
change color depth in fedora core 2 paperdiesel Linux - Software 1 07-06-2004 10:42 AM
Can't change resolution in Fedora Core 1 thaitea Fedora 1 04-16-2004 04:44 PM


All times are GMT -5. The time now is 10:38 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration