-fno-exceptions and throw
I have a problem writing module for linux version of hl server.
If I build with -fno-exceptions I get this error: acc/include/AccSupport.h:47: error: exception handling disabled, use -fexceptions to enable If I build with -fexceptions module is not loading in server (I doesn't spoted any message about why it is not loaded, but it is absent in meta list output) AccSupport.h is include from foreign library. This library seem using exceptions. Can I somehow solve this? PS Under Windows (for windows version of hlds) this module compiles and works. |
Re: -fno-exceptions and throw
The likely cause of it not loading with exceptions enabled is because the version of libstdc++ the binary is compiled against does not match the version on the machine, or libstdc++ may not even be on the machine.
|
Re: -fno-exceptions and throw
Quote:
Look at this thread: http://forums.alliedmods.net/showthread.php?t=16859 -fno-exceptions mentioned there. May be AMXX doesn't allow modules with enabled exceptions? Can I somehow mix exceptions enabled code with wrapping it with non exception code? I use this Makefile: Code:
#(C)2004-2005 AMX Mod X Development Team Looked and found libstdc++.so.6.0.8 in /usr/bin. I am using debian 2.6.18-6 if this make sence. |
Re: -fno-exceptions and throw
Update:
I tried to build cstrike module (it served me as example in the past). And has a luck. But this lead me to mistake. I used "meta list" to spot if module is loaded. Cstrike was shown in list. Then I found that nvault module has -fexceptions option for build in 1.8.0 version. Tried to compile and load it. And meta list doesn't show it is loaded. Some digging in Internet and I found that I was wrong. So I have to use "amxx modules". Here is the output: Code:
meta list |
Re: -fno-exceptions and throw
Finally found were I was wrong: not linked with libstdc++.
In nvault Makefile found link to libstdc++. Added this link to my test project with -fexceptions and get it loaded: Code:
meta list |
All times are GMT -4. The time now is 05:10. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.