diff options
author | tv <tv@pkgsrc.org> | 1999-05-06 20:07:21 +0000 |
---|---|---|
committer | tv <tv@pkgsrc.org> | 1999-05-06 20:07:21 +0000 |
commit | 6ffc0333dac9095cdb8b0303acfe10fba612a42d (patch) | |
tree | 0ce11f00e4abcf3c54cd00aad9edef5ead4b10cf /devel/ptl2 | |
parent | a168b58f8e72d241166aaba7e9b5a2b27129f6b1 (diff) | |
download | pkgsrc-6ffc0333dac9095cdb8b0303acfe10fba612a42d.tar.gz |
Use proper ELF build (with -soname); also add c++rt0 for a.out and
crt{begin,end}S for ELF so that a constructor does not have to be attached
to every resultant .o file (_pthread_init() becomes a constructor in the
library itself). Add ptlg++ as analogue of ptlgcc.
The pkgname is renamed ptl-990315 (drop -current-) so this version is not
considered compatible in binary form.
Diffstat (limited to 'devel/ptl2')
-rw-r--r-- | devel/ptl2/Makefile | 6 | ||||
-rw-r--r-- | devel/ptl2/patches/patch-ab | 18 | ||||
-rw-r--r-- | devel/ptl2/patches/patch-ac | 39 | ||||
-rw-r--r-- | devel/ptl2/patches/patch-ae | 17 | ||||
-rw-r--r-- | devel/ptl2/pkg/PLIST | 4 |
5 files changed, 71 insertions, 13 deletions
diff --git a/devel/ptl2/Makefile b/devel/ptl2/Makefile index c5b45fa1297..388a15b2d83 100644 --- a/devel/ptl2/Makefile +++ b/devel/ptl2/Makefile @@ -1,7 +1,7 @@ -# $NetBSD: Makefile,v 1.5 1999/05/02 12:04:11 tron Exp $ +# $NetBSD: Makefile,v 1.6 1999/05/06 20:07:21 tv Exp $ DISTNAME= PTL2-current-990325 -PKGNAME= ptl2-current-990325 +PKGNAME= ptl2-990325 CATEGORIES= devel MASTER_SITES= ftp://ftp.media.osaka-cu.ac.jp/pub/PTL/PTL2/PTL2-current-990325/ @@ -10,6 +10,8 @@ HOMEPAGE= http://www.media.osaka-cu.ac.jp/~k-abe/PTL/ BUILD_DEPENDS= ${LOCALBASE}/bin/perl:../../lang/perl5 +CONFLICTS= ptl-current-* + USE_GMAKE= YES PLIST_SRC= ${WRKDIR}/PLIST diff --git a/devel/ptl2/patches/patch-ab b/devel/ptl2/patches/patch-ab index d254ccf057a..62f81bbd65e 100644 --- a/devel/ptl2/patches/patch-ab +++ b/devel/ptl2/patches/patch-ab @@ -1,17 +1,17 @@ -$NetBSD: patch-ab,v 1.1 1999/05/01 10:24:40 tron Exp $ +$NetBSD: patch-ab,v 1.2 1999/05/06 20:07:21 tv Exp $ ---- include/sys/pthread-init.h.orig Wed Apr 28 14:30:28 1999 -+++ include/sys/pthread-init.h Wed Apr 28 20:49:27 1999 -@@ -15,9 +15,9 @@ +--- include/sys/pthread-init.h.orig Tue Feb 9 09:59:50 1999 ++++ include/sys/pthread-init.h Thu May 6 11:37:10 1999 +@@ -14,11 +14,7 @@ + /* * Initialize the PTL */ - # ifdef __GNUC__ +-# ifdef __GNUC__ -static void _pthread_inithook() __attribute__((constructor)); -extern void _pthread_init(); -static void _pthread_inithook() { _pthread_init(); } -+static void _pthread_inithook(void) __attribute__((constructor)); -+extern void _pthread_init(void); -+static void _pthread_inithook(void) { _pthread_init(); } - # else +-# else ++# ifndef __GNUC__ # define main __pthread_main # endif /*!__GNUC__*/ + #endif /*!PTL_INTERNAL*/ diff --git a/devel/ptl2/patches/patch-ac b/devel/ptl2/patches/patch-ac new file mode 100644 index 00000000000..f6009888e4a --- /dev/null +++ b/devel/ptl2/patches/patch-ac @@ -0,0 +1,39 @@ +$NetBSD: patch-ac,v 1.3 1999/05/06 20:07:22 tv Exp $ + +--- Util/Makefile.in.orig Thu Mar 25 07:51:18 1999 ++++ Util/Makefile.in Thu May 6 11:32:11 1999 +@@ -264,10 +264,14 @@ + + .SUFFIXES: .po + ++LIBSTUFF=$(LIBRARY_OBJS_PIC) libc_r/*.po net_r/*.po $(altsysdir)/*.po + $(SHARED_LIBRARY) : $(LIBRARY_OBJS_PIC) libc_r net_r + @echo "Loading $@ ... " +- $(MKSHLIBCMD) -o $@ $(LIBRARY_OBJS_PIC) libc_r/*.po net_r/*.po $(altsysdir)/*.po +- -ln -s $@ $@.$(SLIBVER) ++ @if [ -f /usr/lib/crtbeginS.o ]; then \ ++ $(MKSHLIBCMD) -o $@.$(SLIBVER) -soname libPTL.so.1 /usr/lib/crtbeginS.o $(LIBSTUFF) /usr/lib/crtendS.o; \ ++ else \ ++ $(MKSHLIBCMD) -o $@.$(SLIBVER) /usr/lib/c++rt0.o $(LIBSTUFF); \ ++ fi + @echo done + + .c.po: +@@ -432,14 +436,10 @@ + @$(utildir)/banner "copying $(MERGED_LIBRARY) to $(dest_libdir)" + $(INSTALL_DATA) $(MERGED_LIBRARY) $(dest_libdir) + $(RANLIB) $(dest_libdir)/$(MERGED_LIBRARY) +- if [ -f $(SHARED_LIBRARY) ]; then \ +- $(INSTALL_DATA) $(SHARED_LIBRARY) $(dest_libdir) ;\ +- (cd $(dest_libdir); \ +- rm -f $(SHARED_LIBRARY).$(SLIBVER) ; \ +- ln -s $(SHARED_LIBRARY) $(SHARED_LIBRARY).$(SLIBVER) ) ; \ +- fi ++ $(INSTALL_DATA) $(SHARED_LIBRARY).$(SLIBVER) $(dest_libdir) + $(INSTALL_DATA) specs $(dest_specsdir) +- $(INSTALL_PROGRAM) ptlgcc $(dest_bindir) ++ sed -e 's,gcc ,g\+\+ ,' ptlgcc >ptlg++ ++ $(INSTALL_PROGRAM) ptlgcc ptlg++ $(dest_bindir) + + clean : libaltsys-clean + -rm -rf *.o *.po core config.h libc_r net_r \ diff --git a/devel/ptl2/patches/patch-ae b/devel/ptl2/patches/patch-ae new file mode 100644 index 00000000000..c07e0d2a07c --- /dev/null +++ b/devel/ptl2/patches/patch-ae @@ -0,0 +1,17 @@ +$NetBSD: patch-ae,v 1.1 1999/05/06 20:07:22 tv Exp $ + +--- src/proto.h.orig Thu May 6 11:37:33 1999 ++++ src/proto.h Thu May 6 11:38:14 1999 +@@ -100,7 +100,11 @@ + extern void _pthread_psigmask_clear_sigmask_if_need __PTL_NOARGS; + extern void _pthread_psigmask_clear_sigmask_on_csw __PTL_NOARGS; + /* pthread.c */ +-extern void _pthread_init __PTL_NOARGS; ++extern void _pthread_init __PTL_NOARGS ++#ifdef __GNUC__ ++__attribute__((constructor)) ++#endif ++; + extern void _pthread_destroy __PTL_P((_pthread_tcb *thread_ptr)); + extern int _pthread_setscheduler __PTL_P((_pthread_tcb *thread_ptr, int policy, const struct sched_param *param)); + /* queue.c */ diff --git a/devel/ptl2/pkg/PLIST b/devel/ptl2/pkg/PLIST index 2b735b86512..b38f63ce2f9 100644 --- a/devel/ptl2/pkg/PLIST +++ b/devel/ptl2/pkg/PLIST @@ -1,5 +1,5 @@ -@comment $NetBSD: PLIST,v 1.2 1999/03/30 00:59:24 msaitoh Exp $ +@comment $NetBSD: PLIST,v 1.3 1999/05/06 20:07:22 tv Exp $ bin/ptlgcc +bin/ptlg++ lib/libPTL.a -lib/libPTL.so lib/libPTL.so.1.1 |