You are not logged in.

#1 2018-05-28 03:35:46

ivanmlerner
Member
From: São Paulo
Registered: 2016-03-30
Posts: 36

How to find proper dependencies for Plotagraph new package.

Hello, I recently began to study to start packaging for the AUR, and adopted a simple aur package to begin (ice-ssb).
Now I'm trying to package one from the ground up, and I found that the Plotagraph program is still not available in the aur. It is a .deb file and seems easy enough for a first try.
The thing is I ran into a problem resolving the dependencies. In the .deb file it says the dependencies are:

Depends: gconf2, gconf-service, libnotify4, libappindicator1, libxtst6, libnss3, libxss1

How do I translate the debian packages into arch packages regarding versions and stuff?

Thank you

Offline

#2 2018-05-28 08:03:57

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: How to find proper dependencies for Plotagraph new package.

pacman -Ss is your friend.

Offline

#3 2018-05-29 05:03:54

ivanmlerner
Member
From: São Paulo
Registered: 2016-03-30
Posts: 36

Re: How to find proper dependencies for Plotagraph new package.

Hello, I had tried that with little help, since for some packages it doesn't give enough information for me to check if it is the same or not.

I did manage to translate the packages, but I had to look in the debian database for the content of the packages and compare those with the output of "pacman -Ql package". Is this a reliable way of doing it?

I ended up with the following dependence list:

depends=('gconf' 'libnotify' 'libappindicator-gtk2' 'libxtst' 'nss' 'libxss')

Last edited by ivanmlerner (2018-05-29 05:04:22)

Offline

#4 2018-05-29 10:38:14

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,530
Website

Re: How to find proper dependencies for Plotagraph new package.

If you know a file that a dependency should provide, I'd use `pacman -Fs $filename` not scan through every candidate with `pacman -Ql $candidate`.  But other tools you can use include namcap on a built package which will do some checking for missing or extra dependencies, and `ldd` on any binary will tell you what libs it depends on.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#5 2018-05-31 22:17:50

ivanmlerner
Member
From: São Paulo
Registered: 2016-03-30
Posts: 36

Re: How to find proper dependencies for Plotagraph new package.

Thanks, that helps a lot. I added one extra dependency as suggested by 'namcap' (alsa-lib). But I still have a few questions regarding it's output. I'll save questions not regarding dependencies for another post.

The package provides two libraries ('libnode.so' 'libffmpeg.so') in its "/opt/$pkgname" that don't make namcap too happy. Can I safely ignore those warnings since the package already provides those, or should I install them to "/usr/lib" or should I add to the dependency list packages that supply those ('electron' supplies 'libnode.so' and 'opera' supplies 'libffmpeg.so')?

Another question is regarding the dependencies specified in the '.deb' file. The developer specified the debian equivalents of 'libnotify' and 'libappindicator-gtk2' as dependencies, but namcap says they are not needed, I'm inclined to leave them as depencies since the developer specified so, but would it be better to not include them?

'namcap' dependency related output:

plotagraph W: Referenced library 'libnode.so' is an uninstalled dependency
plotagraph W: Referenced library 'libffmpeg.so' is an uninstalled dependency
plotagraph W: Dependency included and not needed ('libnotify')
plotagraph W: Dependency included and not needed ('libappindicator-gtk2')

Last edited by ivanmlerner (2018-05-31 22:22:23)

Offline

#6 2018-05-31 22:34:45

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,530
Website

Re: How to find proper dependencies for Plotagraph new package.

Two points: 1) namcap is far from fool-proof, it can help you know what is worth a closer look, but often you still need to use your judgement on what to do, and 2) warnings are different from errors and can certainly be ignored if there is fair reason to do so as there seems to be here.  Namcap doesn't understand why those dependencies are necessary as no binary directly links to them - but you know that they are important anyways.

So use namcap as a screening tool not a diagnostic tool.  It's useful when it flags something you didn't know about and you can then look into it.

Last edited by Trilby (2018-05-31 22:35:31)


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#7 2018-06-05 18:52:02

ivanmlerner
Member
From: São Paulo
Registered: 2016-03-30
Posts: 36

Re: How to find proper dependencies for Plotagraph new package.

Thanks for the help. I have uploaded the package to the AUR.

Offline

Board footer

Powered by FluxBB