Bug 4887 - incompatible implicit declarations for the llabs() function on an x86_64 system
Status: RESOLVED FIXED
Alias: None
Product: ioquake3
Classification: Unclassified
Component: Misc
Version: unspecified
Hardware: PC All
: P3 normal
Assignee: Zachary J. Slater
QA Contact: ioquake3 bugzilla mailing list
URL:
Depends on:
Blocks:
 
Reported: 2011-01-27 02:09 EST by Zachary J. Slater
Modified: 2011-01-27 06:14:27 EST
1 user (show)

See Also:



Description Zachary J. Slater 2011-01-27 02:09:10 EST
in `man llabs`:
   
    For llabs() to be declared, it may be necessary to define _ISOC99_SOURCE or _ISOC9X_SOURCE (depending on the version of glibc) before including any standard headers.
 
ok i've defined _ISOC9X_SOURCE, and the warnings went away. however i don't know what effect this might have on other systems
 
diff --git a/code/qcommon/vm_x86_64_assembler.c b/code/qcommon/vm_x86_64_assemble
index 1771284..0f50d76 100644
--- a/code/qcommon/vm_x86_64_assembler.c
+++ b/code/qcommon/vm_x86_64_assembler.c
@@ -20,6 +20,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  0211
 ===========================================================================
 */                                                                              
 
+#define _ISOC9X_SOURCE 1 // needed for llabs on some systems
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
Comment 1 Thilo Schulz 2011-01-27 06:14:27 EST
fixed r1824