The attached patch fixes qtruby (part of kdebindings) so that it can
be used out of the box.  Currently, when building kdebindings, .0.0
are added to the ruby .so extensions.  Ruby assumes that .so
extensions don't have numeric extensions, so it can't load the files
until the appropriate files are renamed to remove .0.0.  This patch
removes the .0.0 extensions before building the package so that qtruby
works out of the box.

Tested on i386.  Please test and commit.

Jeremy
Index: Makefile
===================================================================
RCS file: /cvs/ports/x11/kde/bindings3/Makefile,v
retrieving revision 1.44
diff -u -r1.44 Makefile
--- Makefile    28 Jul 2007 14:08:08 -0000      1.44
+++ Makefile    7 Aug 2007 16:40:06 -0000
@@ -4,11 +4,11 @@
 BROKEN=                        "gcc spins on x_20.cpp"
 .endif
 
-COMMENT=               "K Desktop Environment, extra language support"
+COMMENT=               K Desktop Environment, extra language support
 CATEGORIES=            x11 x11/kde devel
 VERSION=               3.5.7
 DISTNAME=              kdebindings-${VERSION}
-PKGNAME=               ${DISTNAME}p0
+PKGNAME=               ${DISTNAME}p1
 MODKDE_VERSION=                3.5.7
 SHARED_LIBS += kjsembed             2.0      # .1.0
 SHARED_LIBS += smokeqt              4.0      # .3.2
@@ -39,5 +39,11 @@
 
 GNU_ARCH=${MACHINE_ARCH:S/amd64/x86_64/}
 SUBST_VARS=GNU_ARCH OSREV
+
+post-install:
+       (cd ${PREFIX}/lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV} && \
+        mv korundum.so.0.0 korundum.so && \
+        mv qtruby.so.0.0 qtruby.so && \
+        mv qui.so.0.0 qui.so)
 
 .include <bsd.port.mk>
Index: pkg/PLIST
===================================================================
RCS file: /cvs/ports/x11/kde/bindings3/pkg/PLIST,v
retrieving revision 1.14
diff -u -r1.14 PLIST
--- pkg/PLIST   1 Apr 2006 10:49:19 -0000       1.14
+++ pkg/PLIST   7 Aug 2007 16:40:06 -0000
@@ -70,11 +70,11 @@
 lib/ruby/site_ruby/1.8/Qt.rb
 lib/ruby/site_ruby/1.8/Qt/qtruby.rb
 lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/korundum.la
-lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/korundum.so.0.0
+lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/korundum.so
 lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/qtruby.la
-lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/qtruby.so.0.0
+lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/qtruby.so
 lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/qui.la
-lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/qui.so.0.0
+lib/ruby/site_ruby/1.8/${GNU_ARCH}-openbsd${OSREV}/qui.so
 @man man/man1/kjscmd.1
 share/applications/kde/kjscmd.desktop
 share/applnk/

Reply via email to