Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #27663

Re: error discription and solution

Date 2014-03-03 12:44 +0000
From lipska the kat <lipskathekat@example.com>
Organization Trollbusters 3
Newsgroups comp.lang.java.programmer
Subject Re: error discription and solution
References (5 earlier) <va2juw1qwd15$.1k5tuuxq9sccs$.dlg@40tude.net> <97SdnYwVB7SC1onOnZ2dnUVZ8gednZ2d@bt.com> <dwfcxug8g4jg.1qivskyms464q.dlg@40tude.net> <ROOdnXsgfJUv7YnOnZ2dnUVZ8qCdnZ2d@bt.com> <xbKdnUA8stpD6YnOnZ2dnUVZ7tednZ2d@giganews.com>
Message-ID <wc-dnbJBEMmB5InOnZ2dnUVZ7sednZ2d@bt.com> (permalink)

Show all headers | View raw


On 03/03/14 12:26, Leif Roar Moldskred wrote:
> lipska the kat <lipskathekat@example.com> wrote:
>
>> Maven wouldn't have helped in this case would it?
>
> No; those dependencies are basically system libraries and need to be
> installed on your system and properly linked to other system libraries.
> Maven won't handle help you resolve that.

You are correct, they are system libs
The libs need to be compiled, linked and installed before the jars 
depending on them can be compiled, then, when everything is in place the 
binding jars can be compiled, these depend on the jars that depend on 
the libs. At runtime the system libraries need to be made visible via 
-Djava.library.path.

DBusConnection.getConnection(DBusConnection.SESSION);

will compile but not run until

-Djava.library.path is set to the location of the system libraries.

Once I figured this out the code compiles and runs.

Actually I really want to use the C glib bindings but the documentation 
is ... difficult so I thought I'd try and get it working in Java first.

Apparently however I'm not smart enough to do that, guess it was just 
luck then :-)

> One could argue that it might have been better if the jars in question
> were divided into a system jar, with the actual JNI code and linkage,
> and an API jar with just the API interfaces and a factory for the
> implementation. Applications that makes use of these libraries could
> then make do with dependencies only to the API jars and not have any
> dependencies on the system level.

Yes, actually I was surprised that I needed to tell Eclipse where to 
find the system libraries before the code would run, I was hoping that 
dependency was compile time only for the bindings, effectively they 
would encapsulate the platform specific stuff.

I expect it's because I'm not very smart.

> You'd still need to install the jars manually (or use your OS's
> package manager system) before you could _run_ the dependent
> application, of course,

make

> but it would make it a lot easier to build the
> application in a normal Java build pipeline, allowing you to do easily
> do Continuous Integration, generate Sonar reports and so on.

No idea what a Sonar report is, should I care?


-- 
Lipska the Kat©: Troll hunter, sandbox destroyer,
treacherous feline and farscape dreamer of Aeryn Sun
GNU/Linux user #560883 - http://www.linuxcounter.net

Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

error discription and solution Navneet Mathpal <navneetmathpal93@gmail.com> - 2014-02-20 00:59 -0800
  Re: error discription and solution Lew <lewbloch@gmail.com> - 2014-02-20 14:05 -0800
  Re: error discription and solution Roedy Green <see_website@mindprod.com.invalid> - 2014-02-21 08:56 -0800
    Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-02-21 17:53 +0000
      Re: error discription and solution Roedy Green <see_website@mindprod.com.invalid> - 2014-02-26 10:22 -0800
        Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-02-26 19:30 +0000
          Re: error discription and solution Joerg Meier <joergmmeier@arcor.de> - 2014-02-26 21:26 +0100
            Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-02-26 21:19 +0000
              Re: error discription and solution Joerg Meier <joergmmeier@arcor.de> - 2014-02-26 23:04 +0100
              Re: error discription and solution leif.roar@invalid.com (Leif Roar Moldskred) - 2014-02-26 16:53 -0600
                Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-02-27 08:34 +0000
            Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-03-03 09:27 +0000
              Re: error discription and solution Joerg Meier <joergmmeier@arcor.de> - 2014-03-03 11:56 +0100
                Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-03-03 12:08 +0000
                Re: error discription and solution leif.roar@invalid.com (Leif Roar Moldskred) - 2014-03-03 06:26 -0600
                Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-03-03 12:44 +0000
                Re: error discription and solution leif.roar@invalid.com (Leif Roar Moldskred) - 2014-03-03 06:58 -0600
                Re: error discription and solution Joerg Meier <joergmmeier@arcor.de> - 2014-03-03 17:11 +0100
                Re: error discription and solution leif.roar@invalid.com (Leif Roar Moldskred) - 2014-03-03 10:17 -0600
                Re: error discription and solution Joerg Meier <joergmmeier@arcor.de> - 2014-03-03 17:39 +0100
                Re: error discription and solution Simon Lewis <simonlewis2001@gmail.com> - 2014-03-03 20:47 +0100
                Re: error discription and solution Eric Sosman <esosman@comcast-dot-net.invalid> - 2014-03-03 17:04 -0500
                Re: error discription and solution "Chris Uppal" <chris.uppal@metagnostic.REMOVE-THIS.org> - 2014-03-06 15:25 +0000
                Future of computing [Was: Re: error discription and solution] Eric Sosman <esosman@comcast-dot-net.invalid> - 2014-03-06 12:03 -0500
                Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-03-03 17:21 +0000
                Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-03-03 17:18 +0000
                Re: error discription and solution leif.roar@invalid.com (Leif Roar Moldskred) - 2014-03-03 11:26 -0600
                Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-03-03 18:31 +0000
                Re: error discription and solution Joerg Meier <joergmmeier@arcor.de> - 2014-03-03 21:00 +0100
                Re: error discription and solution lipska the kat <lipskathekat@example.com> - 2014-03-03 20:19 +0000
                Re: error discription and solution Simon Lewis <simonlewis2001@gmail.com> - 2014-03-03 20:46 +0100
        Re: error discription and solution Jukka Lahtinen <jtfjdehf@hotmail.com.invalid> - 2014-02-26 23:39 +0200
          Re: error discription and solution Roedy Green <see_website@mindprod.com.invalid> - 2014-02-28 09:08 -0800
            Re: error discription and solution Joerg Meier <joergmmeier@arcor.de> - 2014-02-28 20:05 +0100
              Re: error discription and solution Gene Wirchenko <genew@telus.net> - 2014-02-28 15:29 -0800
  Re: error discription and solution Arne Vajhøj <arne@vajhoej.dk> - 2014-02-21 19:48 -0500

csiph-web