LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE
User Name
Password
SUSE / openSUSE This Forum is for the discussion of Suse Linux.

Notices


Reply
  Search this Thread
Old 01-10-2005, 05:00 AM   #1
nkshirsagar
LQ Newbie
 
Registered: Nov 2004
Posts: 22

Rep: Reputation: 0
ifdef for suse??


Hi,

Is there any compiler directive I could use to get some code to specifically compile for suse?

like an #ifdef __SUSE__ ?? or something?

-nikhil.
 
Old 01-10-2005, 09:00 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982Reputation: 1982
nope. the name of the distro is at such a totally different level to C code it's unreal.. you really should be able to find a better solution than wanting to do that.
 
Old 01-11-2005, 12:12 AM   #3
nkshirsagar
LQ Newbie
 
Registered: Nov 2004
Posts: 22

Original Poster
Rep: Reputation: 0
hmmmm

I need it because ...

my code crashes only on suse if LANG or LC_ALL are not set ... (they're NULL) ...

for some reason, on suse, they're null by default..

i need to set them depending on whether the platform is suse.. (and not for other flavours of linux).. thats why i want some suse directive to have those statemenets compile only on suse..

any better solution than doing a strstr after fopen(etc/issue) ??


-nikhil.
 
  


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
Dual-boot WinXP / Suse 9, keeps crashing after installing Suse MagNiTek Linux - General 2 07-08-2005 01:39 PM
SuSE: Dlink Access Point: How to let SuSE 9.1 box fetch the webpages for wlan request hansschmucker Linux - Wireless Networking 3 01-06-2005 01:02 PM
Compiling programmes: How to use #ifdef? asciimonster Linux - General 1 12-13-2004 02:35 PM
help with #ifdef #undef etc tuxfood Programming 3 06-29-2004 09:12 AM
SUSE Security Announcement - Linux Kernel (SuSE-SA:2004:009) ima Linux - Security 0 04-19-2004 09:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE

All times are GMT -5. The time now is 11:18 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration