[LLVMdev] Linux-x86 Compatability

Vikram S. Adve vadve at cs.uiuc.edu
Fri Sep 13 11:06:01 PDT 2002


Is the #include <endian.h> necessary for Linux or is that a leftover
artifact from before?  I'm trying to get this code to compile on MacOS
(which is based on BSD), and stdint.h exists there, but not endian.h.

--Vikram

----------------------------------------------------------------------
 VIKRAM S. ADVE
 Assistant Professor                         E-MAIL: vadve at cs.uiuc.edu
 Department of Computer Science                 PHONE:  (217) 244-2016
 Univ. of Illinois at Urbana-Champaign          FAX:    (217) 244-6869
 1304 W. Springfield Ave.                http://www.cs.uiuc.edu/~vadve
 Urbana IL 61801.
----------------------------------------------------------------------


> -----Original Message-----
> From: llvmdev-admin at cs.uiuc.edu [mailto:llvmdev-admin at cs.uiuc.edu]On
> Behalf Of Chris Lattner
> Sent: Friday, September 13, 2002 10:41 AM
> To: Casey Carter
> Cc: LLVMdev List
> Subject: Re: [LLVMdev] Linux-x86 Compatability
>
>
> > >Interesting.  INT64_MAX is supposed to be provided by
> > >include/Support/DataTypes.h.  Do you know of a reliable preprocessor
> > >symbol that can be used to determine whether we're on a linux box, or
>
> > Well, there is always __linux__, but that doesn't necessarily imply that
> > we are on a Linux box with stdint.h.
>
> Ok, I'll switch to that from the placeholder "LINUX".
>
> > >(better yet) whether the system has a valid <stdint.h>?
>
> > Nope.  Autoconf is definitely the way to go here (even though converting
> > is a pain).
>
> Agreed.  We plan to autoconfiscate LLVM eventually, but it won't get
> started for quite some time.  In the meantime, the #ifdef __linux__ hack
> should be sufficient.
>
> Thanks for the help,
>
> -Chris
>
> http://llvm.cs.uiuc.edu/
> http://www.nondot.org/~sabre/Projects/
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://mail.cs.uiuc.edu/mailman/listinfo/llvmdev
>




More information about the llvm-dev mailing list