Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Handling exceptions in nodejs addon

Received: by 10.224.220.12 with SMTP id hw12mr15964341qab.8.1349824657701;
        Tue, 09 Oct 2012 16:17:37 -0700 (PDT)
X-BeenThere: nodejs@googlegroups.com
Received: by 10.224.146.194 with SMTP id i2ls2403qav.6.gmail; Tue, 09 Oct 2012
 16:17:21 -0700 (PDT)
Received: by 10.224.70.131 with SMTP id d3mr15948496qaj.0.1349824641949;
        Tue, 09 Oct 2012 16:17:21 -0700 (PDT)
Received: by 10.224.28.72 with SMTP id l8msqac;
        Tue, 9 Oct 2012 12:16:38 -0700 (PDT)
Received: by 10.236.173.202 with SMTP id v50mr2288749yhl.19.1349810198629;
        Tue, 09 Oct 2012 12:16:38 -0700 (PDT)
Date: Tue, 9 Oct 2012 12:16:37 -0700 (PDT)
From: Sergey Volvovski <svolvo2...@gmail.com>
To: nodejs@googlegroups.com
Message-Id: <5c9bc2d2-4bee-4703-ab4c-a8e5f78d0656@googlegroups.com>
Subject: Handling exceptions in nodejs addon
MIME-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_727_1894401.1349810197649"

------=_Part_727_1894401.1349810197649
Content-Type: multipart/alternative; 
	boundary="----=_Part_728_29603176.1349810197649"

------=_Part_728_29603176.1349810197649
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

I just started using nodejs and currently I'm working on addon that is=20
supposed to use the other library. Those library is using internally=20
boost::asio. When I'm trying to compile my addon code I receive the=20
following output:

In file included from=20
/usr/local/boost_1_51_0/boost/asio/detail/impl/throw_error.ipp:21:0,
                 from=20
/usr/local/boost_1_51_0/boost/asio/detail/throw_error.hpp:52,
                 from=20
/usr/local/boost_1_51_0/boost/asio/detail/impl/posix_mutex.ipp:23,
                 from=20
/usr/local/boost_1_51_0/boost/asio/detail/posix_mutex.hpp:73,
                 from=20
/usr/local/boost_1_51_0/boost/asio/detail/mutex.hpp:25,
                 from=20
/usr/local/boost_1_51_0/boost/asio/detail/service_registry.hpp:20,
                 from=20
/usr/local/boost_1_51_0/boost/asio/impl/io_service.hpp:19,
                 from /usr/local/boost_1_51_0/boost/asio/io_service.hpp:767=
,
                 from=20
/usr/local/boost_1_51_0/boost/asio/basic_io_object.hpp:19,
                 from=20
/usr/local/boost_1_51_0/boost/asio/basic_socket.hpp:19,
                 from=20
/usr/local/boost_1_51_0/boost/asio/basic_datagram_socket.hpp:20,
                 ............

/usr/local/boost_1_51_0/boost/system/system_error.hpp: In member function=
=20
=E2=80=98virtual const char* boost::system::system_error::what()=20
const=E2=80=99:/usr/local/boost_1_51_0/boost/system/system_error.hpp:70:16:=
 error:=20
exception handling disabled, use -fexceptions to enable

However adding -fexceptions to cflags section of my binding.gyp does not=20
have any effect, I still have the same output.
Is there any work-around for this problem?

Any kind of help is appreciated.

Thanks,
Sergey




------=_Part_728_29603176.1349810197649
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: quoted-printable

I just started using nodejs and currently I'm working on addon that is supp=
osed to use the other library. Those library is using internally boost::asi=
o. When I'm trying to compile my addon code I receive the following output:=
<div><br></div><div><div>In file included from /usr/local/boost_1_51_0/boos=
t/asio/detail/impl/throw_error.ipp:21:0,</div><div>&nbsp; &nbsp; &nbsp; &nb=
sp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;from /usr/local/boost_1_51_0/boost/as=
io/detail/throw_error.hpp:52,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; =
&nbsp; &nbsp; &nbsp; &nbsp;from /usr/local/boost_1_51_0/boost/asio/detail/i=
mpl/posix_mutex.ipp:23,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;=
 &nbsp; &nbsp; &nbsp;from /usr/local/boost_1_51_0/boost/asio/detail/posix_m=
utex.hpp:73,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nb=
sp; &nbsp;from /usr/local/boost_1_51_0/boost/asio/detail/mutex.hpp:25,</div=
><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;from /u=
sr/local/boost_1_51_0/boost/asio/detail/service_registry.hpp:20,</div><div>=
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;from /usr/loc=
al/boost_1_51_0/boost/asio/impl/io_service.hpp:19,</div><div>&nbsp; &nbsp; =
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;from /usr/local/boost_1_51_=
0/boost/asio/io_service.hpp:767,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbs=
p; &nbsp; &nbsp; &nbsp; &nbsp;from /usr/local/boost_1_51_0/boost/asio/basic=
_io_object.hpp:19,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbs=
p; &nbsp; &nbsp;from /usr/local/boost_1_51_0/boost/asio/basic_socket.hpp:19=
,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;f=
rom /usr/local/boost_1_51_0/boost/asio/basic_datagram_socket.hpp:20,</div><=
div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;.........=
...</div><div><br></div><div>/usr/local/boost_1_51_0/boost/system/system_er=
ror.hpp: In member function =E2=80=98virtual const char* boost::system::sys=
tem_error::what() const=E2=80=99:/usr/local/boost_1_51_0/boost/system/syste=
m_error.hpp:70:16: error: exception handling disabled, use -fexceptions to =
enable</div></div><div><br></div><div>However adding&nbsp;-fexceptions to c=
flags section of my binding.gyp does not have any effect, I still have the =
same output.</div><div>Is there any work-around for this problem?</div><div=
><br></div><div>Any kind of help is appreciated.</div><div><br></div><div>T=
hanks,</div><div>Sergey</div><div><br></div><div><br></div><div><br></div>
------=_Part_728_29603176.1349810197649--

------=_Part_727_1894401.1349810197649--