Question about the compilation from cvs
I juste realized that the binaries i compiled from the cvs need the libstdc++ to work! If not, the server segfault :/
Is that normal or did i do something wrong? |
which module
|
Oops, nothing, that were other libs that were missing ;)
|
Another question :
If I compile amxx (or mmx, or amxx modules, or everything ^^) with the -O2 flag (or even -O3), does it really improve performance? And is it stable? And what does the defaut flag -O6 of the makefiles? |
The highest O flag is O3 I think, beyond that it really has no effect. I may be wrong. All it does is specificy another level of compile time optimizations.
|
Okay, for the moment, i just noticed that with the -o2 flags, the compile time is a little bit longer, but the binaries is a bit smaller, and it "works" (not heavily tested, i just checked that it launches everything without crashing xD )
And what about the -d0 flags for the small compiler? |
-d0 is highest optimization for small scripts, and contains no debugging information. while it works, be warned the compiler may take "shortcuts" that have unexpected results with more complicated operations.
also note you can turn all optimizations off with this: -d3 -C+ |
hmm
Bail: What is the best for decent optimization?
|
Which version are you guys compiling with??
I run the latest Slackware with GCC 3.2.3 and this one doesn't like some of the coding... /X PS! Original AMXmod 0.9.6j compiles fine (testing now with ahtlon-xp optimization)... |
Compiling everything with gcc 2.95.4 from a debian package, I'll try with the latest gcc 3.3.3, but i think i already tried and it doesn't works, sometimes compilation error, sometimes the binarie is not "complete" :/
And same question as magicshot : what is the best for decent optimisation? XAD: What do you change to have an athlon-xp otpimisation? EDIT: Same as XAD, the original amx 0.9.6j compile well with gcc 3.3.3, (no compilation error) but the binaries is a lot smaller (default optimisation) gcc 2.95 : 268,8 ko gcc 3.3.3 : 190,5 ko ... and ... Got a bad load with the gcc 3.3 compile ^^ The 2.95 one works fine. :? EDIT2: Apparently, I got the same binaries (in size at least) with the -O3 & -O6 flags... :? And with the -O2 flags, the binaires are a little bit smaller... :? |
Quote:
When I compile with GCC 3.2.3 I get following compile error: Code:
CModule.h: At global scope:/X PS! To AMXmod 0.9.6j to run with "athlon-xp" I added "-lstdc++" to the link options... |
It looks like GCC 3.3 (i have 3.3.1) doesn't like the __attribute(packed) thing. To compile, try changing
#ifdef __GCC__ #define PACKED something ... to #ifdef __GCC__ #define PACKED in amx.h It compiles, but i am not sure whether it affects something else. I'll try to find an another way of doing it. |
Quote:
To bad you guys started with AMXmod 0.9.6j and not my "fixed" version as I changed the original code to fix all warnings (except the two in the amx engine)... Thanks... I will test it to see if it broke something ;-) /X |
Where is your fixed version? ;]
|
Quote:
I didn't mean I expected you to have used it, only that it was bad as I think compile warnings indicates some possible issues with the code and therefore should be recoded (even if it's causing any problems). I suppose this is the same reason I "hate" people saying that plugin compile indentation warnings should be ignored as to me it indicates that the coder have created code that is error prone and easy to read wrong (also for the coder him/herself)... but hey, it's my personally opinion (and only a problem for you if I'm your boss :wink:). /X PS! It's no magic or complicated only a fix of what the warnings suggest... |
Could you send it to me? I have tried reducing a great many of the warnings but some I could not fix (such as ones about Vector casts)
|
Xad : No, used the defaut makefile of amx 0.9.6j for my "test compile" with gcc 3.3.3 (amx 0.9.7 from the CVS at AMXMOD project on sourceforge)
PM: I'll try that ;) EDIT: Doesn't work, it compiles, but the file is small (~ 190Ko ) and got a nice Code:
[META] ERROR: dll: Failed query plugin '<amxx_mm_i686.so>'; Couldn't open file '/home/niluje/HLDS_L/cstrike/addons/amxx/dlls/amxx_mm_i686.so': /home/niluje/HLDS_L/cstrike/addons/amxx/dlls/amxx_mm_i686.so: undefined symbol: __gxx_personality_v0I would also like to know how to make my compile compatible with the glibc 2.2 system (because mine is under 2.3)? I saw in the metamod makefile this line Code:
# link against older libc for compatibility |
NiLuJe: Try compiling everything with gcc 3.3;
Update: it looks like the PACKED attribute should only be removed after the names, that is, things like typedef struct { a PACKED; b PACKED; } mytype /* no PACKED */; |
PM : Okay 'ill try ;)
Metamodx : OK, works fine :) (after changing the -malign-xx flags to -faling-xx, like the warning said :) ) Amxmodx: Hu, what should i do with the packed thing? Edit by hand the amx.h to remove every packet after the names? (will try that ^^ ) : Done it and it WORKS ;) And the binarie is A LOT smaller! (also changed the -malign) csstats: Works (-malign too) fun: Works (-malign) csstrike: Works (-malign) engine: Works (-malign) binarie A LOT smaller too (/2 !) mysql: Not tested but should works too ;) EDIT: If you want to test, i uploaded all the compiles i made today : http://n1luj3.free.fr/compil_test.tar.gz (5,4mo lot of compile ^^) |
If gcc-3.3 binaries are stable for you I will distribute 686 binaries compiled by gcc-3.3 from now on
|
I dont know if they are really "stable" because i didn't test them heavily, but at least, amxx loads fine ^^
I could try them if i can compile them with compatibility with glibc 2.2 system, because my public server is under glbic 2.2 :/ But for now, i don't know how to do that, any idea? |
Quote:
Also I'm running GCC 3.2.3 with "athlon-xp" optimization on MetaMod 1.17 (+ valve updates), AMX Mod X 0.16, csstats (my reworked version based on csstats 0.9.3)... so far so good... So I would suggest you to test with both pentium4 and athlon-xp if you will release versions based on GCC 3.x.x to see if they are faster... /X |
:) I have succefully compiled metamodx linked to gcc 2.2, and it works :), but only with gcc 2.95, with gcc 3.3, i got a meta error undefined symbol :/ Is it normal?
|
:/ Got an error only with amxx_mm, when compiling with gcc-2.95 linked to libc 2.2.5 :
Code:
[META] ERROR: dll: Failed query plugin '<amxx_mm_i386.so>'; Couldn't open file '/halflife/game2877/bin/cstrike/addons/amxx/dlls/amxx_mm_i386.so': /halflife/game2877/bin/cstrike/addons/amxx/dlls/amxx_mm_i386.so: undefined symbol: __ctype_tolower_loc |
AMXx is going through rapid development right now and I'd be surprised if anything from the CVS even compiled properly. Be careful with what you use in there because it may not be stable.
|
Thats what i was wondering, so i tried from the "stable" source of the 0.16, and obtained the same result, so i guess this problem came from my side ^^
|
Make sure your makefile is correct... undefined symbols usually mean there was a linking problem. Try installing lstdc++
|
Can you give me an example of a mekfile wich works to wompile amxx with a link to glibc2.2 (and with what version of that lib?)
> Same thing with -lstdc++ :/ |
Hum, i finnally installed a debian 3.0 stable on my test box, and compiled everything from here, and it works ;)
|
| All times are GMT -4. The time now is 21:50. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.