You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by jo...@nokia.com on 2008/01/15 13:09:09 UTC
Symbian support in APR
Hi,
A few years ago at Nokia Research Center we ported Apache
httpd to the Symbian/S60 platform (the OS that is used in
Nokia's smartphones) and in the spring of 2006 we open
sourced the results under the name Raccoon
(http://sourceforge.net/projects/raccoon).
Last summer MWS - a consumer oriented mobile web server
based upon Raccoon - was launched (http://mymobilesite.net).
>From the beginning our intention was to get the Symbian port
integrated into the mainstream Apache distribution and now I'd
like to take some concrete steps in that direction.
I asked on the Apache development list on how to proceed and
was suggested that having Symbian support added to APR would
be the first step.
So, now I'm asking the same question here. How should I proceed
in order to have our Symbian APR port included in the APR
mainstream distribution? Our Apache port is based on version
2.2.4, so the APR version is 1.2.8.
I'd be happy to provide a description on what kind of
modifications have been done where.
Best regards,
Johan Wikman
RE: Symbian support in APR
Posted by jo...@nokia.com.
> wrowe@rowe-clan.net wrote:
>...
>I expected something similar although APU_EXPORT_DATA() might
>make more sense for the first macro (consider line lengths!)
Yes, I fully agree that the macro is a bit long (to put it mildly).
However, they come in pairs; one for declaring the data and another
one for defining it. For defining I use APU_DEFINE_EXPORTED_DATA,
which is nicely symmetrical with the macro for declaring the data.
But I'd be happy to use shorter alternatives.
>...
>Here's the issue;
>
> http://apr.apache.org/versioning.html
>
>We need to introduce these new macros with the next minor
>(1.3) bump, although we do -not- have to wait for 2.0 since
>(as you pointed out) there will be no ABI breakage on existing
>platforms.
Yes, having sent the previous posting, I looked around and found
that link, and realized that this change surely will need a change
in the minor number.
Ok, so what's the best way to proceed?
Johan
Re: No connection could be made because the target machine actively refused it.
Posted by Lucian Adrian Grijincu <lu...@gmail.com>.
On Jan 16, 2008 7:52 PM, Learning apr <le...@hotmail.co.uk> wrote:
>
> Hello,
>
> I use function apr_socket_connect(_self->shared_socket, _self->intf_addr) to
> make a TCP connection.
>
> But I got the error message: No connection could be made because the target
> machine actively refused it.
>
Are you sure that someone is listening on the IP:PORT you're connecting to?
try a "telnet IP port" and see if you can connect to the machine.
--
Lucian
Re: No connection could be made because the target machine actively refused it.
Posted by Colm MacCarthaigh <co...@allcosts.net>.
On Thu, Jan 17, 2008 at 12:52:48AM +0800, Learning apr wrote:
> But I got the error message: No connection could be made because the target machine actively refused it.
>
> What caused this error.
Erm, the target machine actively refused the connection :-) The above
error message is what clib on Windows gives you when it instead of
getting a SYN|ACK it gets a FIN or a RST or similar, it means that
nothing is listening or what a firewall is denying that connection.
--
Colm MacCárthaigh Public Key: colm+pgp@stdlib.net
No connection could be made because the target machine actively
refused it.
Posted by Learning apr <le...@hotmail.co.uk>.
Hello,
I use function apr_socket_connect(_self->shared_socket, _self->intf_addr) to make a TCP connection.
But I got the error message: No connection could be made because the target machine actively refused it.
What caused this error.
Thanks!
_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
Re: Symbian support in APR
Posted by "William A. Rowe, Jr." <wr...@rowe-clan.net>.
johan.wikman@nokia.com wrote:
>> wrowe@rowe-clan.net wrote:
>> ...
>> I'd enthusiastically support a richer macro to express a
>> data-by-call dereference, but that's not possible until APR
>> 1.3 at earliest due to the versioning rules. Since 1.3 is in
>> development, that's the best version to target for such a change.
>
> Ah, but this change would not need to cause binary or even
> source incomptibilities for other OS versions.
Which doesn't matter...
> Now, in the case of all other operating systems, we could
> simply have
>
> #define APU_DECLARE_EXPORTED_DATA(type, name)\
> APU_DECLARE_DATA extern type name
I expected something similar although APU_EXPORT_DATA() might make
more sense for the first macro (consider line lengths!)
> If that also would cause a change in the minor number, then
> I would be perfectly happy with
Here's the issue;
http://apr.apache.org/versioning.html
We need to introduce these new macros with the next minor (1.3) bump,
although we do -not- have to wait for 2.0 since (as you pointed out)
there will be no ABI breakage on existing platforms.
Bill
RE: Symbian support in APR
Posted by jo...@nokia.com.
>wrowe@rowe-clan.net wrote:
>...
>I'd enthusiastically support a richer macro to express a
>data-by-call dereference, but that's not possible until APR
>1.3 at earliest due to the versioning rules. Since 1.3 is in
>development, that's the best version to target for such a change.
Ah, but this change would not need to cause binary or even
source incomptibilities for other OS versions.
This example is now from APU, to be a little less convoluted
since here data and not data arrays are exported.
In apr_hooks.h there is the line
APU_DECLARE_DATA extern apr_pool_t *apr_hook_global_pool;
which in the Symbian version now looks like
APU_DECLARE_EXPORTED_DATA(apr_pool_t *, apr_hook_global_pool);
When APU_DECLARE_EXPORT is defined, that is, when the apu
library is being built, it expands into
APU_DECLARE_DATA extern apr_pool_t *apr_hook_global_pool;
In other words, components built into the apu library sees that
variable directly.
When APU_DECLARE_EXPORT is not defined, it expands into
APU_DECLARE(apr_pool_t*) _apr_hook_global_pool(void);
in which case the define
#define apr_hook_global_pool (*_apr_hook_global_pool())
also becomes visible. That is, components not built into
apu uses that variable indirectly via a function call. But
on the source code level there is no difference.
Now, in the case of all other operating systems, we could
simply have
#define APU_DECLARE_EXPORTED_DATA(type, name)\
APU_DECLARE_DATA extern type name
If that also would cause a change in the minor number, then
I would be perfectly happy with
#if defined(__SYMBIAN32__)
APU_DECLARE_EXPORTED_DATA(apr_pool_t *, apr_hook_global_pool);
#else
APU_DECLARE_DATA extern apr_pool_t *apr_hook_global_pool;
#endif
which would cause no changes for other Oss and thus could be
introduced as a patch?
My assumption is that there is less overhead for httpd to take
an APR version into use where only the patch number and not the
minor number has changed. And I'd really like to be able to
start working for the Symbian httpd modifications to be accepted.
Br,
Johan
Re: Symbian support in APR
Posted by "William A. Rowe, Jr." <wr...@rowe-clan.net>.
johan.wikman@nokia.com wrote:
>
> The problem is that on Symbian you cannot export data from
> a DLL, but any exported data must be turned into a
> automatically dereferenced function call when the "exported"
> data is used from another module than the one where the data
> resides.
>
> APR_DECLARE_DATA is not expressive enough for that.
Understood. However it's not possible for us to change the structure
of APR 1.2.
I'd enthusiastically support a richer macro to express a data-by-call
dereference, but that's not possible until APR 1.3 at earliest due
to the versioning rules. Since 1.3 is in development, that's the best
version to target for such a change.
RE: Symbian support in APR
Posted by jo...@nokia.com.
>Are the mods available as patches anywhere?
http://opensource.nokia.com/files/httpd-2.2.4_srclib_apr.patch_.txt
Note that there are some changes there now that, should
the patch be applied, will cause other than Symbian builds
to fail. However, they are easily fixed.
The problem is that on Symbian you cannot export data from
a DLL, but any exported data must be turned into a
automatically dereferenced function call when the "exported"
data is used from another module than the one where the data
resides.
APR_DECLARE_DATA is not expressive enough for that.
Johan
Re: Symbian support in APR
Posted by Graham Leggett <mi...@sharp.fm>.
On Tue, January 15, 2008 2:09 pm, johan.wikman@nokia.com wrote:
> So, now I'm asking the same question here. How should I proceed
> in order to have our Symbian APR port included in the APR
> mainstream distribution? Our Apache port is based on version
> 2.2.4, so the APR version is 1.2.8.
>
> I'd be happy to provide a description on what kind of
> modifications have been done where.
Are the mods available as patches anywhere?
Regards,
Graham
--