From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23532 invoked by alias); 20 Oct 2014 13:50:58 -0000 Mailing-List: contact java-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: java-patches-owner@gcc.gnu.org Received: (qmail 23522 invoked by uid 89); 20 Oct 2014 13:50:57 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.1 required=5.0 tests=BAYES_00,SPF_NEUTRAL,TVD_RCVD_IP autolearn=no version=3.3.2 X-HELO: mail.dimjasevic.net Received: from 19.246.102.46.static.intovps.com (HELO mail.dimjasevic.net) (46.102.246.19) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 20 Oct 2014 13:50:52 +0000 Received: from [10.0.0.31] (c-24-6-217-84.hsd1.ca.comcast.net [24.6.217.84]) by mail.dimjasevic.net (Postfix) with ESMTPSA id 7E17313416BA; Mon, 20 Oct 2014 15:50:41 +0200 (CEST) Message-ID: <1413813034.4798.20.camel@neelix> Subject: Re: Compiling Scala-generated bytecode From: Marko =?UTF-8?Q?Dimja=C5=A1evi=C4=87?= To: Andrew Haley Cc: java-patches@gcc.gnu.org Date: Mon, 20 Oct 2014 13:50:00 -0000 In-Reply-To: <5444C1F9.7060306@redhat.com> References: <1413785951.4798.12.camel@neelix> <5444C1F9.7060306@redhat.com> Content-Type: multipart/signed; micalg="pgp-sha1"; protocol="application/pgp-signature"; boundary="=-jftzhLbqFSUmYt2tIVVB" Mime-Version: 1.0 X-SW-Source: 2014-q4/txt/msg00024.txt.bz2 --=-jftzhLbqFSUmYt2tIVVB Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Content-length: 1856 On Mon, 2014-10-20 at 09:04 +0100, Andrew Haley wrote: > You have to link with the Scala library, either directly or indirectly. > You will want to compile the library to a shared object. That's what I thought. > Before explaining any more, do you have experience with shared > libraries in C and C++? Just a tiny bit. As far as my understanding goes, I'd first create a shared library with something like this: gcj -fPIC /usr/share/java/scala-library.jar -shared -o scala-library.so and then when compiling a Scala program, I'd say: gcj --classpath=3D.:/usr/share/java/scala-library.jar HelloWorld*.class scala-library.so But I haven't managed to create the shared library. When I attempt to run the first command, I get something like: scala/collection/immutable/StringLike.scala: In class 'scala.collection.immutable.StringLike$class': scala/collection/immutable/StringLike.scala: In method 'scala.collection.immutable.StringLike $class.replaceAllLiterally(scala.collection.immutable.StringLike,java.lang.= String,java.lang.String)': In file included from scala/collection/immutable/StringLike.scala:28:0, from scala/collection/immutable/StringLike.scala:190, from scala/collection/immutable/StringLike.scala:142, ... from scala/AnyVal.scala:7, from :3: scala/collection/immutable/StringLike.scala:174:0: error: class 'java.util.regex.Pattern' has no method named 'quote' matching signature '(Ljava/lang/String;)Ljava/lang/String;' In file included from scala/collection/immutable/StringLike.scala:28:0, from scala/collection/immutable/StringLike.scala:190, from scala/collection/immutable/StringLike.scala:142, ... Can you please tell me how to get the shared library? --=20 Regards, Marko http://dimjasevic.net/marko --=-jftzhLbqFSUmYt2tIVVB Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit Content-length: 836 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAABAgAGBQJURRMqAAoJEGjtezy5N0tHolwP+wVtVVWksHz2KuPRte5Auxsw VNLFuh19/LE9uvjw6OTW7LINtCd0ainhncRHSBfc1heWn0xKGwatCOYdOyx/8/BW ZdYbNiP2jdZeskYO3lKHDoaoWablFrHdY+jnkdToh0Iilj352oX3+Ict5qLnuEw9 17D5pBDztToK6A8lHRUYnaOM264hgnm64LLN+L4WO0Hs6wi/q0gO/pR0ROllOj0D vJFfd1EuDz5u6R9L5KDBR1foxl0QIJm0gOHLw/C7MVqy3ekVuhJYwDp/9D33R24w dNEW8yOU4/n1AjyhYJMVmGfuo3hYcJUJcEXWgRTyK3EU9RVHBzkYAYRd0ZoGizgb S7tBiTm/bE6ILNFFU1zrNdFwCkYuZ7dzVuh9j2fMYRcTxwPeV7tUYkjiDhZWJxCN 2/WUil1ZS4v1pD2Ul7CzsrsKRJtT23hjBaX8pB0o+7EeW8x0RYzL05+l6Ng+wvil aSyjqI9kWxkVxOmDwe0OsKTusFGMb19nEpSfb1VFKfbzu8cRmhUHUhT3J59Jkf1W 6hBe1oGd/C7TTew5OL+T1WFbD/mQen/2Fz5vtOGJBitkRC5vL6cMEFt8QCLHujGQ EThoWAe4jkhjwlwDR7A5mhQ7LsbOuoB7rghJOZUZCVQJUjLi2hiUHn2ZwNBBJy3D wodA6AUdIx2YzjgDScuF =SIWz -----END PGP SIGNATURE----- --=-jftzhLbqFSUmYt2tIVVB--