[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: jarwrapper dependency



On Mon, Jul 15, 2013 at 1:57 PM, Eugene Zhukov <jevgeni.zh@gmail.com> wrote:
> On Mon, Jul 15, 2013 at 12:58 PM, Matthew Johnson <mjj29@debian.org> wrote:
>> On Mon Jul 15 10:15, Eugene Zhukov wrote:
>>> > Does this work:
>>> >
>>> > $ /usr/share/java/epubcheck.jar
>>> Yes, it does. Like I said
>>> java -jar /usr/share/java/epubcheck.jar
>>> works just fine.
>>
>> No, I meant calling it directly (see below)
>>
>>> > when you say "it's displayed in red", do you mean the target of the link, or the link itself. My bash shows a good link to a jar to be cyan for the link and red for the jar, but a bad link red for both.
>>> In my case it is cyan for the link and red for the jar too. However if
>>> I install a working package from Sid then it is cyan for the link and
>>> green for the jar.
>>> >
>>> > is /usr/share/java/epubcheck.jar executable? That's the best explanation I have for this behaviour.
>>> It is executable only via java -jar. If I just run
>>> /usr/share/java/epubcheck.jar it's "Permission denied". However with
>>> older epubcheck package from Sid the jar in /usr/share/java is
>>> displayed in green!
>>> That's the whole reason for the problem. How to grant execute
>>> permission to jar when it is installed to /usr/share/java? It has to
>>> be green in order for the link to work.
>>
>> Yes, it must have execute permissions, which I think I mentioned some time ago. Try "chmod +x /usr/share/java/epubcheck.jar", does everything work now?
>>
>> You must set it during package build to be executable. You can do this by hand, or by calling jh_exec after creating all the symlinks et al.
>
> Many thanks, Matt! I finally solved it by adding the following to d/rules
> install/epubcheck::
>         chmod +x debian/epubcheck/usr/share/java/epubcheck.jar
>
> Not sure how to use jh_exec or dh overrides here, since the package is
> debianized with maven-debian-helper.
>
> Eugene

Btw, how to get rid of Lintian warning now?
W: epubcheck: executable-not-elf-or-script usr/share/java/epubcheck.jar


Reply to: