From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chris Marusich Subject: Re: store reference detection (was Re: JARs and reference scanning) Date: Thu, 11 May 2017 23:54:02 -0700 Message-ID: <87mvai36r9.fsf@gmail.com> References: <87a876pwaq.fsf@gmail.com> <8760hr7mwl.fsf@gmail.com> <20170426.135333.1620868924745053745.post@thomasdanckaert.be> <87fugu6jzg.fsf@gnu.org> <59022E86.1020709@crazy-compilers.com> <8760hjig4r.fsf@gnu.org> <590F179B.4060306@crazy-compilers.com> <87zieotnzr.fsf@gmail.com> <87vapbkeua.fsf@elephly.net> <87inl7n5tt.fsf@gmail.com> <87a86jy6pk.fsf@elephly.net> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48328) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d94Sr-00077f-U7 for guix-devel@gnu.org; Fri, 12 May 2017 02:54:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d94Sn-0007im-Od for guix-devel@gnu.org; Fri, 12 May 2017 02:54:13 -0400 Received: from mail-pf0-x244.google.com ([2607:f8b0:400e:c00::244]:35593) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1d94Sn-0007iW-Hj for guix-devel@gnu.org; Fri, 12 May 2017 02:54:09 -0400 Received: by mail-pf0-x244.google.com with SMTP id u26so5984147pfd.2 for ; Thu, 11 May 2017 23:54:09 -0700 (PDT) In-Reply-To: <87a86jy6pk.fsf@elephly.net> (Ricardo Wurmus's message of "Thu, 11 May 2017 13:27:03 +0200") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Ricardo Wurmus Cc: guix-devel@gnu.org --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Ricardo Wurmus writes: > Chris Marusich writes: > >>> Jar files can be told to import classes from another Jar by adding it to >>> the =E2=80=9CClass-Path=E2=80=9D field of the Jar=E2=80=99s manifest. >>> >>> Here=E2=80=99s an example: >>> https://docs.oracle.com/javase/tutorial/deployment/jar/downman.html >> >> I didn't know this! That's awesome; it might be just what we need. > [=E2=80=A6] > > Thanks for testing this! > > One limitation appears to be that this only works for applications, not > for libraries. In what way does this not work for libraries? I'm not criticizing you; I'm genuinely curious. To ask this question another way: how would a solution that "works for libraries" behave, exactly? I'm not sure what the phrase "it works for libraries" might mean, since I suspect its meaning varies depending on what one is trying to accomplish. > This could be a problem for us. We don=E2=80=99t really need this urgent= ly > for applications if we automatically generate shell wrappers (as we do > for Python executables). > I agree. > It would be interesting to know if this could be used for libraries as > well, so that the application in the end does not need to know about all > transitive dependencies, but only its first-level dependencies. I think there are at least two concrete goals here. I would phrase them as follows: 1) I can run Java applications (built with Guix). 2) I can use Java libraries (built with Guix) in an IDE to develop Java applications. We can accomplish (1) by using wrapper scripts. I suppose we could also maybe accomplish (1) by using JARs with embedded classpaths, but as long as wrapper scripts are sufficient, it isn't really necessary to do this. As for (2), I think it's probably trickier, since the exact way in which an IDE might want to be informed about the dependencies of a project may vary. I'm still not sure how I would develop Java applications using Java libraries built with Guix, without putting in a lot of manual effort to tell my IDE where the dependencies live. Surely there is a way... =2D-=20 Chris --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEy/WXVcvn5+/vGD+x3UCaFdgiRp0FAlkVXAsACgkQ3UCaFdgi Rp08zg//RR2ftny7MEF++SHLgmphs3QNN/yhkhi4lSQOXZCSluRaIU3jMRHq7ewk z829CHWz0hd1RsF/roBvHChka/D7DRzoo7wklBjcOyaubON1UL1dIZaVEtDSbrOT cWLmoigzEbzwS8uMva5uYWutU8nYZ9Tqj8RVYqppI6tRLeQSl+zR3v9X9delGl3G 0usZtign7WKdix3WAdpv7FNiIzZk475/fnU0kBr64aLXrgZRSxx3pwtSCWd7y0zh sZCcTzBrHVFkIe1CAf7caqxhh00Ui7kNO/Fj8k0ALRaqFRP6/OFHOa9oquYRuBy3 LU34Bef9RUGCrvqfs51yKF9vEzidaKdxiy0RidHVu9vu+Y2p07l61OgbvtrSW2wT gujjj3b2oX7INyeNaoZpX5TXabglBWgxPXjJKy6QSVPPO11/C61jNjNK4gYDW+2k RMMH/FczizIiXyhI+zFYTk6tuL4YXvYvk7WYjPrRLPgiuNfPrcoWWGV9RJsGiIss q5Hpi6jpWoCexFYUlMLeKWoi3/e/k8AQ124scbkbllmCDxoGbZzPm7E8NNfDjFzh GpugKlzJ9Poh2BIpem6a/R9WYjEYm9+7iJjQGaTeXQA8QVuHGM3wN0EilHobYUyo 3v1e4sw2OmdMQHA8BI7pLHjWIRBMUVNXigjztbCFC6JBQv6WO5A= =blKP -----END PGP SIGNATURE----- --=-=-=--