summaryrefslogtreecommitdiff
path: root/ext/DynaLoader
Commit message (Collapse)AuthorAgeFilesLines
* DynaLoader: On Android, define DLOPEN_WONT_DO_RELATIVE_PATHSBrian Fraser2014-02-051-0/+11
| | | | | | | | | | | | | | Android's linker will actually do relative paths just fine; the problem is that it won't search from the current directory, only on /vendor/lib, /system/lib, and whatever is in LD_LIBRARY_PATH. While the core handles that just fine, bits of CPAN rather rightfully expect this to work: use lib 'foo' # puts foo/ in @INC use My::Module::In::Foo; # calls dlopen() with foo/My/Module/... # which will likely fail So we take this route instead.
* DynaLoader: On android, dl_load_flags should always be 0x00Brian Fraser2014-02-031-2/+8
| | | | | | | | | | The linker ignores all the flags and works as if under RTLD_LOCAL, so don't give users the headache of seeing warnings ala "Can't make loaded symbols global on this platform while loading %s" when using a module that subclasses DynaLoader and defines dl_load_flags to anything else.
* ext/DynaLoader/t/DynaLoader.t: Skip the dl_findfile test when cross-compilingBrian Fraser2014-01-222-1/+3
|
* DynaLoader: Pure-perl mod2fname shouldn't use %Config at runtimeBrian Fraser2014-01-181-3/+3
| | | | | | | | | | | This is somewhat obscure. Previously, mod2fname would've tried accessing $Config{dlext} each time it was called. The reason this can be problematic is that mod2fname can be called during global destruction, after %Config is freed but before its magic is. This was causing Devel::GlobalDestruction's tests to fail on builds with -Dd_libname_unique. This commit grabs the data we need when DynaLoader.pm is being built in DynaLoader_pm.PL, so it no longer need to depend on %Config.
* fix some linuxisms and RETVAL warnings from xsubppAlan Hourihane2014-01-161-16/+15
| | | | | Original patch by Alan, modified by Tony Cook to remove unused return types.
* [perl #89502] support for dld on Atari FreeMINTTony Cook2014-01-161-0/+221
|
* DynaLoader: Introduce d_libname_uniqueBrian Fraser2014-01-032-3/+58
| | | | | | | | | | | | Android's linker has some unusual behavior, in that it only uses the basename of a library in its cache. That means that, as far as dlopen() is concerned, the libraries for Hash::Util and List::Util, both of which are called Util.so, are the same. This commit teaches DynaLoader about d_libname_unique. When defined, it signals DynaLoader define a mod2fname sub that renames the .so files to something "unique" -- so for example, Hash/Util/Util.so becomes Hash/Util/PL_Hash__Util.so.
* bump DynaLoader version after previous commitsDavid Mitchell2013-11-261-1/+1
|
* dl_hpux.xs: fix PREINIT boundaryDavid Mitchell2013-11-261-1/+1
| | | | | my previous commit moved some var declarations from CODE: to PREINIT:; but I was slightly overzealous and moved a non-declaration line too.
* Dynaloader: use PREINIT to avoid compiler errorsDavid Mitchell2013-11-262-2/+4
| | | | | | | | | | | A recent change to the typmap definitions makes a var declaration generate code. Move this declaration from CODE: to PREINIT: to avoid a 'Mixed declarations' compiler error. This was spotted in dl_hpux.xs by bulk88, which I've blindly fixed. From visual inspection there were also declarations in dl_vms.xs that needed moving (although in that case it dosen't trigger the typemap code emission).
* Dynaloader: fix build issueDavid Mitchell2013-11-149-9/+18
| | | | | My commit from yesterday, 860b3d937d9b004a7de4b684765ab75006c71f00, inadvertently included c99-ish mixed declarations and code.
* DynaLoader: silence some compiler warningsDavid Mitchell2013-11-1310-1/+10
|
* Remove support for GNU DLD in DynaLoader.Nicholas Clark2013-09-052-212/+3
| | | | | GNU DLD was a library that provided dynamic linking on a.out based systems. The last release was in 1996, and it has been superseded by dlopen.
* Skip dynaloader test on Bitrig like we do for OpenBSDChris 'BinGOs' Williams2013-08-221-1/+1
|
* Skip tests for dl_unload_file() when built with -DPERL_GLOBAL_STRUCT_PRIVATENicholas Clark2013-08-211-0/+4
| | | | | | | | | Building with -DPERL_GLOBAL_STRUCT_PRIVATE uses alternative implementations of Perl_my_cxt_init() and Perl_my_cxt_index() which store the pointer to the extension name. For a dynamically loaded shared object this is a pointer to memory which will be released if that shared object is unloaded, meaning that any *other* module which calls Perl_my_cxt_index() will likely attempt a read of unmapped memory.
* Whitespace changes to DynaLoader.t, as part of adding a TODO: block.Nicholas Clark2013-08-211-9/+9
|
* Document that DynaLoader::dl_unload_file() is not called at exit by default.Nicholas Clark2013-08-211-3/+4
| | | | | | | | | | | | | DynaLoader::dl_unload_file() is only called automatically to unload all loaded shared objects if the perl interpreter was built with the C macro DL_UNLOAD_ALL_AT_EXIT defined. The documentation has been incorrectly stating that it is always called since dl_unload_file() was added in v5.6.0 When dl_unload_file() was first added by commit abb9e9dca5a5f121 (March 1st, 2000), it was always called at exit, if available. It was made conditional on DL_UNLOAD_ALL_AT_EXIT being defined by commit 23d2500b2b45b1be (March 20th, 2000), but the documentation was never updated to reflect this. v5.6.0 was release on March 22nd, 2000.
* Add $dl_dlext to DynaLoader's interface summary now that it's documentedSteve Hay2013-08-171-0/+1
|
* Document $DynaLoader::dl_dlext, per sisyphus++.James E Keenan2013-07-291-1/+14
| | | | | | With one modification suggested by Andy Dougherty; version bump to 1.19. For: RT #119031
* change DynaLoader.t to know VOS has no libc libraryPaul Green2013-06-031-1/+1
|
* Remove the BeOS port.Nicholas Clark2012-12-141-133/+0
| | | | | | | | | BeOS was an operating system for personal computers developed by Be Inc, initially for their BeBox hardware. The OS Haiku was written as an open source replacement/continuation for BeOS, and its perl port is current and actively maintained. The BeOS port has not been updated since 2004.
* Stop DynaLoader.t from unload File::GlobFather Chrysostomos2012-12-101-2/+8
| | | | | | | | | | File::Glob now sets PL_opfreehook. That means that if we unload it we will leave PL_opfreehook pointing to an invalid address, resulting in a crash when ops are freed. I didn’t catch this because the tests are skipped on darwin. They don’t actually need to be, at least under recent versions, so I modi- fied the skip code.
* Remove "register" declarationsKarl Williamson2012-11-242-10/+10
| | | | | | | This finishes the removal of register declarations started by eb578fdb5569b91c28466a4d1939e381ff6ceaf4. It neglected the ones in function parameter declarations, and didn't include things in dist, ext, and lib, which this does include
* Use correct type to avoid a cast added by fe1c5936a5Steve Hay2012-10-311-2/+2
| | | | (Suggested by Tony Cook.)
* Bump DynaLoader's $VERSION after commit fe1c5936a5Steve Hay2012-10-311-1/+1
|
* consting in perl.c:S_Internals_V and Win32 DynaLoaderDaniel Dragan2012-10-311-3/+3
| | | | | | | These assorted static allocated variables were in RW memory in the perl image. Move them to RO memory so they are sharable between different Perl processes by the OS. The lack of consting in Win32 Dynaloader traces to commit 0a753a76406 . S_Internals_V traces to commit 4a5df386486 .
* Remove the MPE/iX port.Nicholas Clark2012-09-211-146/+0
| | | | | MPE/iX was a business-oriented minicomputer operating system made by Hewlett-Packard. Support from HP terminated at the end of 2010.
* Remove the VM/ESA port.Nicholas Clark2012-08-311-196/+0
| | | | | VM/ESA was a mainframe OS. IBM ended service on it in June 2003. It was superseded by Z/VM.
* Silence ParseXS warning about abusing the CODE sectionSteffen Mueller2012-08-318-71/+90
| | | | | | | See RT #114198. DynaLoader was warning about somewhat dubious use of RETVAL with a CODE section but without an OUTPUT section. This fixes that problem, but I have obviously not been able to test on all affected operating systems.
* Update DynaLoader's VERSION after commit 7d08496d81c138d9.Nicholas Clark2012-06-181-1/+1
|
* Cast exception handler in dl_vms.xs.Craig A. Berry2012-05-281-1/+1
| | | | C++ needs an explicit type on the handler.
* Increase $DynaLoader'VERSION from 1.13 to 1.14,Father Chrysostomos2011-10-061-1/+1
| | | | in view of 2e3468793982.
* Export DynaLoader symbols from libperl againReini Urban2011-09-301-0/+1
| | | | | | With 5.15.2 and the new xubpp, DynaLoader symbols were XS_INTERNAL, before they were effectively XS_EXTERNAL. This broke B::C and possibly other embedded apps which link to DynaLoader functions.
* Add PERL_NO_GET_CONTEXT to dl_dlopen.xsNicholas Clark2011-03-191-0/+2
| | | | | | For threaded builds on platforms using dlopen() for dynamic loading, this should reduce object size, and slightly reduce CPU usage when loading extensions.
* Remove the couple of references to AutoLoader that remained inDavid Leadbeater2011-03-131-6/+2
| | | | DynaLoader after 0a0b6c96e6.
* Dispatch dl_expandspec at build time, not run time.Craig A. Berry2011-02-181-7/+5
| | | | | | | | | | Before 0a0b6c96e6042658aa123b3990724be593a2bb63, dl_expandspec was an autoloaded function that would never be called if an XS version was already loaded. Without autoloading in DynaLoader anymore, the pure Perl version gets loaded first, which causes trouble if the XS version is what's expected. It looks as though VMS is the only platform that has an XS version, so just avoid declaring the Perl version there.
* DynaLoader.t: AUTOLOAD TODO tests passingDavid Mitchell2011-02-181-6/+3
| | | | | Now that AUTOLOAD has been removed from DynaLoader, some TODO tests are passing, so unmark them as TODO.
* Increase DynaLoader’s versionFather Chrysostomos2011-02-171-1/+1
|
* [perl #84358] Removing AutoLoader from DynaLoaderLeon Timmermans2011-02-171-16/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | DynaLoader currently uses Autoloader. This was an optimization going back to perl 5.000 in 1994. However, this implementation detail leaks in a rather troublesome way. DynaLoader is used by subclassing it. Because of this, when you call some undefined method on an instance of any class that derives from DynaLoader (directly or indirectly) you do not get this error message: Can't locate object method "undefined_method" via package "Foo" But this rather cryptic error: Can't locate auto/Foo/undefined_m.al in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.0 /usr/local/share/perl/5.10.0 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl .) This is totally incomprehensible for anyone who isn't familiar with what's going on. It was rather a premature optimization anyway if you ask me, on my machine it's just 66 non-empty lines of code that are being autoloaded. Therefore, I think AutoLoader should be removed from DynaLoader.
* Fix typos (spelling errors) in ext/*.Peter J. Acklam) (via RT2011-01-073-3/+3
| | | | | | | | | # New Ticket Created by (Peter J. Acklam) # Please include the string: [perl #81882] # in the subject line of all future correspondence about this issue. # <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=81882 > Signed-off-by: Abigail <abigail@abigail.be>
* Update K&R-style function declarations in dl_vms.xs.Craig A. Berry2011-01-061-6/+2
|
* Don't install Cygwin code into other platformsJan Dubois2011-01-031-1/+3
| | | | | | DynaLoader already has its own preprocessor to filter out code that is only relevant on other platforms, so use it for the change from commit cc7e77fd
* CYG14 Dynaloader without USEIMPORTLIB, and search cyg prefixReini Urban2011-01-042-0/+10
| | | | | | | | | | | | | | | | | part1: Support the standard cyg dll prefix, which is e.g. needed for FFI's. Ctypes and C::DynaLib use DynaLoader to find dlls. part2: With -DUSEIMPORTLIB DynaLoader symbols link against the prefixed symbol names for the .dll.a importlib, but we need to link against the symbols directly. We don't link Dynaloader against libperl.dll.a. Otherwise: $ g++-4 -o cygperl5_13_4.dll --shared perlsrc.o cygwin.o DynaLoader.o -ldl -lcrypt Creating library file: libperl.dll.a DynaLoader.o: In function `XS_DynaLoader_dl_undef_symbols': ext/DynaLoader/DynaLoader.c:346: undefined reference to `__imp__PL_stack_sp' ext/DynaLoader/DynaLoader.c:346: undefined reference to `__imp__PL_markstack_ptr' ext/DynaLoader/DynaLoader.c:346: undefined reference to `__imp__PL_stack_base'
* bump version of many modulesZefram2010-12-191-1/+1
| | | | | Core-only modules that have changed from v5.13.7, and dual-life modules that have changed from v5.13.7 and didn't show up in earlier passes.
* Remove "dead" RCS $Id$ tags from files that we own.Nicholas Clark2010-12-161-1/+0
| | | | | All files have been modified more recently than their tag, rendering information in the tag redundant.
* Increase DynaLoader’s versionFather Chrysostomos2010-11-011-1/+1
|
* Avoid buffer overflow in dl_win32.cJan Dubois2010-11-011-0/+4
| | | | | This fixes the DynaLoader related part of bug 78710 http://rt.perl.org/rt3//Public/Bug/Display.html?id=78710
* Improve DynaLoader::bootstrap documentation.Nicholas Clark2010-10-071-1/+8
| | | | | Document that all arguments are passed on to the module's bootstrap function, and the behaviour of the bootstrap function in modules built by xsubpp.
* Remove MacOS classic support from DynaLoader.Nicholas Clark2010-06-232-210/+3
| | | | | ExtUtils::MakeMaker removed MacOS support in 6.25, merged to blead in December 2004, so this code is vestigial, and a small maintenance penalty.
* With Win32 now building DynaLoader in ext, it is now built withSteve Hay2009-09-281-1/+1
| | | | | | -noprototypes (as was always the case on *nix), so no need to explicitly disable prototype checking in DynaLoader.t any more, i.e. we can revert a2c4b2d6db383103b96e4733616b17d0a3bb0bd9