Re: __FreeBSD__ not available and unsigned long type
dear Chetan, Chetan Shukla wrote: I have two doubts working further ion FreeBSD. In my machine (8.0-RELEASE) I am not getting the macro __FreeBSD__. As a workaround I have to conditionally define it in makefile. Could someone define what is missing in this case. For this one, I do not have any clue. Moreover when I have to use unsigned long and signed long the only Options that I have are to write unsigned long and signed long Nothing more specific like uint64_t?Or are there any special header files that need to be included. The type uint64_t is indeed defined by the header stdint.h (mnemonic: standard integer types). This seems to suit the requirements of C99. Try `man stdint' at the command line. Best regards, Michael ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: __FreeBSD__ not available and unsigned long type
On 10/13/10 13:47, Chetan Shukla wrote: Hi I have two doubts working further ion FreeBSD. In my machine (8.0-RELEASE) I am not getting the macro __FreeBSD__. As a workaround I have to conditionally define it in makefile. Could someone define what is missing in this case. It's compiled into gcc. Specifically /usr/src/contrib/gcc/config/freebsd-spec.h, which contains the line builtin_define_with_int_value (__FreeBSD__, FBSD_MAJOR); Moreover when I have to use unsigned long and signed long the only Options that I have are to write unsigned long and signed long Nothing more specific like uint64_t?Or are there any special header files that need to be included. #include stdint.h Looking forward for guidance, -- Although the wombat is real and the dragon is not, few know what a wombat looks like, but everyone knows what a dragon looks like. -- Avram Davidson, _Adventures in Unhistory_ ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: __FreeBSD__ not available and unsigned long type
On Oct 13, 2010, at 5:47 AM, Chetan Shukla wrote: In my machine (8.0-RELEASE) I am not getting the macro __FreeBSD__. As a workaround I have to conditionally define it in makefile. What does: touch foo.h; cpp -dM foo.h | grep FreeBSD ...return? Regards, -- -Chuck ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
RE: __FreeBSD__ not available and unsigned long type
Hi, I tried this and got following output: cerebrus# touch foo.h; cpp -dM foo.h | grep FreeBSD #define __FreeBSD_cc_version 81 #define __VERSION__ 4.2.1 20070719 [FreeBSD] #define __FreeBSD__ 8 It means __FreeBSD__ is defined but how then to use it? Regards, Chetan -Original Message- From: Chuck Swiger [mailto:cswi...@mac.com] Sent: Wednesday, October 13, 2010 11:08 PM To: Chetan Shukla Cc: freebsd-questions@freebsd.org Subject: Re: __FreeBSD__ not available and unsigned long type On Oct 13, 2010, at 5:47 AM, Chetan Shukla wrote: In my machine (8.0-RELEASE) I am not getting the macro __FreeBSD__. As a workaround I have to conditionally define it in makefile. What does: touch foo.h; cpp -dM foo.h | grep FreeBSD ...return? Regards, -- -Chuck DISCLAIMER: This message is proprietary to Aricent and is intended solely for the use of the individual to whom it is addressed. It may contain privileged or confidential information and should not be circulated or used for any purpose other than for what it is intended. If you have received this message in error, please notify the originator immediately. If you are not the intended recipient, you are notified that you are strictly prohibited from using, copying, altering, or disclosing the contents of this message. Aricent accepts no responsibility for loss or damage arising from the use of the information transmitted by this email including damage from virus. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org