diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 2000-03-03 16:21:34 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 2000-03-03 16:21:34 +0000 |
commit | 403d6f8e894056e673725f16d00d471c48c44dd2 (patch) | |
tree | dd61fe365d6609a453e2d29568b78c3bb7da7649 /os2 | |
parent | a4cf958aac2453eded53a4701d1bec205cf252eb (diff) | |
download | perl-403d6f8e894056e673725f16d00d471c48c44dd2.tar.gz |
OS/2 patches for dlclose() support (from Yitzchak Scott-Thoennes
<sthoenna@efn.org>)
p4raw-id: //depot/perl@5488
Diffstat (limited to 'os2')
-rw-r--r-- | os2/diff.configure | 23 | ||||
-rw-r--r-- | os2/dl_os2.c | 10 | ||||
-rw-r--r-- | os2/dlfcn.h | 1 | ||||
-rw-r--r-- | os2/os2.sym | 1 |
4 files changed, 19 insertions, 16 deletions
diff --git a/os2/diff.configure b/os2/diff.configure index c8f3b5899b..59a8a5331c 100644 --- a/os2/diff.configure +++ b/os2/diff.configure @@ -1,18 +1,18 @@ ---- Configure-pre Sun Jul 25 19:18:02 1999 -+++ Configure Wed Jul 28 17:50:14 1999 -@@ -1528,6 +1528,11 @@ if test X"$trnl" = X; then +--- Configure.orig Tue Feb 29 19:07:00 2000 ++++ Configure Thu Mar 2 10:10:24 2000 +@@ -1605,6 +1605,11 @@ esac fi if test X"$trnl" = X; then -+ case "`echo foo|tr '\r' x 2>/dev/null`" in -+ foox) trnl='\r' ;; ++ case "`echo foo|tr '\r\n' xy 2>/dev/null`" in ++ fooxy) trnl='\n\r' ;; + esac +fi +if test X"$trnl" = X; then cat <<EOM >&2 $me: Fatal Error: cannot figure out how to translate newlines with 'tr'. -@@ -1844,7 +1849,7 @@ for file in $loclist; do +@@ -1921,7 +1926,7 @@ *) echo "I don't know where '$file' is, and my life depends on it." >&4 echo "Go find a public domain implementation or fix your PATH setting!" >&4 @@ -21,16 +21,7 @@ ;; esac done -@@ -3688,7 +3693,7 @@ int main() { - exit(0); - } - EOM --if $cc -o gccvers gccvers.c; then -+if $cc -o gccvers gccvers.c $ldflags; then - gccversion=`./gccvers` - case "$gccversion" in - '') echo "You are not using GNU cc." ;; -@@ -4892,7 +4897,7 @@ case "$libc" in +@@ -5719,7 +5724,7 @@ esac ;; esac diff --git a/os2/dl_os2.c b/os2/dl_os2.c index 4a9688cb59..aab48dd672 100644 --- a/os2/dl_os2.c +++ b/os2/dl_os2.c @@ -87,3 +87,13 @@ dlerror(void) return buf; } +int +dlclose(void *handle) +{ + ULONG rc; + + if ((rc = DosFreeModule((HMODULE)handle)) == 0) return 0; + + retcode = rc; + return 2; +} diff --git a/os2/dlfcn.h b/os2/dlfcn.h index c96f97f82d..c2feee6000 100644 --- a/os2/dlfcn.h +++ b/os2/dlfcn.h @@ -1,3 +1,4 @@ void *dlopen(char *path, int mode); void *dlsym(void *handle, char *symbol); char *dlerror(void); +int dlclose(void *handle); diff --git a/os2/os2.sym b/os2/os2.sym index 7724e566c1..685568623a 100644 --- a/os2/os2.sym +++ b/os2/os2.sym @@ -5,6 +5,7 @@ OS2_Perl_data dlopen dlsym dlerror +dlclose my_tmpfile my_tmpnam my_flock |