[AD] Irix & allegro-3.9.40 |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
I've compiled allegro-3.9.40 for Irix, and ran into the following new
(and old) warnings and errors. I've attached patches for 3 of them. I
used diff -u originalfile newfile to create them, if this is not ok
let me know and I'll redo the diffs. Please check before you would
commit..
I've tested these patches on Irix and linux.
---1---
In file included from include/allegro/fmaths.h:38,
from include/allegro.h:61,
from ./src/allegro.c:23:
include/allegro/inline/fmaths.inl:123: conflicting types for `floorf'
/usr/include/math.h:333: previous declaration of `floorf'
This is one I've seen before: Stephan Roh made a patch for Irix
math.h, in include/allegro/platform/alucfg.h .
I solved it by adding '#undef ffloor' to the list of Irix macro's that
are undefined. Very strange: apparently the Irix compiler mangles
ffloor and floorf. If I #undef'ed floorf, the problem remained.
attached: alucfg.diff
---2---
param.h (included from pthread.h) defines MIN and MAX for Irix, and
conflicts with include/allegro/base.h as follows:
/usr/include/sys/param.h:370: warning: `MIN' redefined
include/allegro/base.h:58: warning: this is the location of the
/usr/include/sys/param.h:371: warning: `MAX' redefined
include/allegro/base.h:59: warning: this is the location of the
Since it's only a warning and there are only so many ways to define
MAX and MIN, I've left it like this. It could probably be solved by
including pthread before allegro.h, but in usystem.c this is not so
trivial. Could also be solved by including <pthreads.h> in base.h for
Irix only.
---3---
old (3.9.39 had it too):
some of the test programs (akaitest and afinfo, in any case) use pow,
and cause an unresolved external when linking. (missing math library)
I solved this by adding -lm to LINK_LIBALLEG in the makefile. I am not
certain if this is the right way to solve it, but if it is, attached is a
patch where \$(LIBS) is added to LINK_LIBALLEG for the shared library
build. The static build already had this. \$(LIBS) contains more than
just -lm (in my case) so perhaps it's better to just add -lm in
configure.in, I'm not sure. It may also be possible to let configure
detect it but I don't know how.
attached: configure.in.diff
---4---
old (3.9.39 had it too):
ld32: WARNING 1: Unknown option: export-dynamic (ignored).
ld32: WARNING 84: /usr/lib32/libdl.so is not used for resolving any
symbol.
It seems this is still in. I discussed and testet it with Peter Wang:
it seems the Irix linker doesn't handel the exporting of symbols for
the modules. (At least, we couldn't find how. Stephan Roh, do you
perhaps know how to fix this? Do you get this warning as well?)
Peter, you said we should just disable modules, right? Should I
write a patch for the Irix documentation that configure should be run
with , or should this be fixed in
configure or makefile for Irix?
---5---
on Irix machine:
make clean -> command line too long.
This is strange, because I use rm (GNU fileutils) 4.0, so I didn't
expect it. Using linux it does work.
I 'fixed' this by splitting up CLEAN_FILES (makefile.lst) into two
parts (OBJ_CLEAN_FILES and OTHER_CLEAN_FILES) and removing those
separately (makefile.in). Since the other make *clean targets are all
depending on make clean, this should cause no further problems.
attached: makefile.in.diff, makefile.lst.diff
>-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-<
Hein Zelle hein@xxxxxxxxxx
http://www.icce.rug.nl/~hein
>-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-<
--- configure.in Thu Nov 15 14:22:31 2001
+++ ../../allegro-3.9.40/configure.in Tue Nov 20 20:46:00 2001
@@ -221,7 +221,7 @@
allegro_static_libraries=yes
else
LIBALLEG="lib/unix/lib${LIB_TO_LINK}-\$(shared_version).so lib/unix/lib${LIB_TO_LINK}_unsharable.a"
- LINK_LIBALLEG="-Llib/unix -l${LIB_TO_LINK}-\$(shared_version) -l${LIB_TO_LINK}_unsharable"
+ LINK_LIBALLEG="-Llib/unix -l${LIB_TO_LINK}-\$(shared_version) -l${LIB_TO_LINK}_unsharable \$(LIBS)"
LINK_WITH_STATIC_LIBS=no
allegro_shared_libraries=yes
fi
--- include/allegro/platform/alucfg.h Tue Nov 6 18:09:26 2001
+++ ../../allegro-3.9.40/include/allegro/platform/alucfg.h Tue Nov 20 15:59:42 2001
@@ -51,6 +51,7 @@
# undef fsqrt
# undef fhypot
# undef fceil
+# undef ffloor
#endif
#undef ALLEGRO_INCLUDE_MATH_H
@@ -81,4 +82,3 @@
#endif
#endif /* ifndef ALUCFG_H */
-
--- makefile.in Fri Nov 16 00:11:22 2001
+++ ../../allegro-3.9.40/makefile.in Tue Nov 20 21:15:56 2001
@@ -275,7 +275,8 @@
touch suid
clean:
- rm -f $(CLEAN_FILES)
+ rm -f $(OBJ_CLEAN_FILES)
+ rm -f $(OTHER_CLEAN_FILES)
distclean: clean
rm -f $(DISTCLEAN_FILES)
--- makefile.lst Fri Nov 16 00:11:22 2001
+++ ../../allegro-3.9.40/makefile.lst Tue Nov 20 21:15:37 2001
@@ -486,10 +486,12 @@
docs/makedoc.c \
src/i386/asmdef.c
-CLEAN_FILES = \
+OBJ_CLEAN_FILES = \
+ obj/*/*.o obj/*/*/*.o obj/*/*/*/*.o obj/*/*.obj obj/*/*/*.obj
+
+OTHER_CLEAN_FILES = \
docs/*.texi docs/*.txi docs/*.tex docs/*.info docs/*.inf docs/*.3 \
docs/*.txt \
- obj/*/*.o obj/*/*/*.o obj/*/*/*/*.o obj/*/*.obj obj/*/*/*.obj \
obj/*/*.h obj/*/*.s obj/*/*.exe obj/*/*/*.lst obj/*/*/*.asm \
obj/*/*/*.res obj/*/asmdef src/i386/asmdef \
lib/*/*.a lib/unix/*.so* lib/unix/sta* \