Perl language binding cleanup for 64bit systems

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Perl language binding cleanup for 64bit systems

Gerhard Sittig-2
I recently was informed that building the Perl binding for the Dazuko
library results in size mismatch warnings (pointers vs integers) on
64bit systems.  Here is a quick patch to cleanup how C pointers are
passed to Perl scripts and back.

An even better method would be to make use of "blessed pointers",
which would add automatic type verification on behalf of perlxs(1).
But since I consider the current implementation inappropriate anyway
(it "leaks" the library's internals into the Perl application), that
quick hack should do for now and a much improved version should
materialize RSN.  I have plans to cleanly encapsulate internals and to
adjust the API so that applications cannot "forget" to return access
events.  This should bring the Perl binding up to where the Python,
Ruby and Lua bindings currently are.


Please notice that some systems may insist in that all object files
which are used to build the IO.so shared library shall be built with
the -fPIC option.  So it may be necessary to run the follwing steps:

  $ tar xzf dazuko-<version>.tar.gz
  $ cd dazuko-<version>
  $ ./configure [ options ]
  $ vi library/Makefile
  maybe add "CFLAGS += -fPIC"
  $ make -C library
  $ cd example_perl
  $ perl Makefile.PL
  $ make
  # make test
  # make install
  # perl Example.pl `pwd`


virtually yours                                     Gerhard Sittig
pgp fingerprint AF29 3CD2 A531 F5A8 5F42  CB9A 1B7F 59F8 BA7A 9EE5
--
    If you don't understand or are scared by any of the above,
            ask your parents or an adult to help you.

_______________________________________________
Dazuko-devel mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/dazuko-devel

patch-dazuko-perl-pointer.diff (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Perl language binding cleanup for 64bit systems

John Ogness-2
Gerhard Sittig wrote:
> Here is a quick patch to cleanup how C pointers are
> passed to Perl scripts and back.

Sorry, I should have included this patch (and -fPIC) in the upcoming
2.3.4 release. It will be included in 2.3.4-pre3.

John Ogness

--
Dazuko Maintainer


_______________________________________________
Dazuko-devel mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/dazuko-devel