Path: csiph.com!weretis.net!feeder7.news.weretis.net!news.mixmin.net!aioe.org!bofh.it!news.nic.it!robomod From: Emmanuel Bourg Newsgroups: linux.debian.maint.java Subject: Re: To build a java package with maven Date: Sun, 21 Jun 2020 11:00:01 +0200 Message-ID: References: X-Original-To: Mechtilde Stehmann , Debian Java X-Mailbox-Line: From debian-java-request@lists.debian.org Sun Jun 21 08:55:30 2020 Old-Return-Path: X-Amavis-Spam-Status: No, score=-11.981 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, LDO_WHITELIST=-5, MURPHY_DRUGS_REL8=0.02, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H2=-0.001] autolearn=ham autolearn_force=no X-Policyd-Weight: using cached result; rate: -5.5 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit X-Mailing-List: archive/latest/22298 List-ID: List-URL: List-Archive: https://lists.debian.org/msgid-search/60f68501-cf44-6399-a405-55496a71c798@apache.org Approved: robomod@news.nic.it Lines: 28 Organization: linux.* mail to news gateway Sender: robomod@news.nic.it X-Original-Date: Sun, 21 Jun 2020 10:55:13 +0200 X-Original-Message-ID: <60f68501-cf44-6399-a405-55496a71c798@apache.org> X-Original-References: <57d76a1c-d960-6974-cea4-efd510ab4620@debian.org> <4ddad89b-ef09-e860-e3ba-8b2bf9d39540@debian.org> Xref: csiph.com linux.debian.maint.java:11717 Le 21/06/2020 à 08:01, Mechtilde Stehmann a écrit : > do I understand it in a right way? > > I patch the entry for the dependency part from javax.validation to > jakarta.vvalidation etc > > then I use in maven.rules > s/javax.validation/jakarta.validation/ > s/validation-api/jakarta.validation-api/ * s/.*/debian/ * * > > So the import line import javax.validation.ConstraintViolation; > etc. should work. No it won't, because the classes in the jakarta artifact are in the jakarta.* package, not javax.*, so you would have to patch the Java files to change the import statements. The easiest solution is to depend on libgeronimo-validation-1.1-spec-java and use this substitution rule: s/javax.validation/org.apache.geronimo.specs/ s/validation-api/geronimo-validation_1.1_spec/ * s/.*/debian/ * * That's what the eclipselink package does for example: https://sources.debian.org/src/eclipselink/2.6.6-1/debian/maven.rules/?hl=2#L2 Emmanuel Bourg