Contribute a package to AUR?

How much work for, a non-tech, is involved in contributing a package to AUR?

This afternoon I have installed EpiData (3 packages) on my Manjaro Mate machine. Everything is running fine. :grinning:

I used debtap on the debs, with help from posts on this forum. Thank you.

I downloaded the latest debs from the EpiData download page.

I would like to contribute the resulting packages to AUR. But before contacting the EpiData developers and offering to do this, I have a question and a request:
The question: How much work, for a non-tech person like me, is involved in contributing and maintaining a package on AUR?

The request to the experts on this forum:

Could you please correct my INSTALL (all three had a similar error on line 22. And if I am going to contribute this I would like the error fixed. But I don’t know how to do it myself.)

Here is the error message, the INSTALL and the PKGBUILD:

error:

/tmp/alpm_q3ZGbA/.INSTALL: line 22: syntax error near unexpected token ;;' /tmp/alpm_q3ZGbA/.INSTALL: line 22: removemenu;;’

.INSTALL (line 22 is the first “removemenu;;” line

post_install() {

gtk-update-icon-cache -q -t -f usr/share/icons/hicolor

update-desktop-database -q
}

post_upgrade() {
post_install
}

pre_remove() {

{
xdg-desktop-menu uninstall --mode system epidata-epidata.directory epidata-epidataentryclient.desktop
}

  removemenu;;
  removemenu;;
deconfigure) ;;

}

post_remove() {
gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
update-desktop-database -q
}

The PKGBUILD - dependencies were the same for all 3 packages (apart from the optdepend which referenced other packages in the epidata suite)

pkgname = epidataanalysis
pkgver = 3.0.0.1-1
pkgdesc = EpiData Statistical Analysis Tool. EpiData Analysis is a tool for creating statistical analysis.
url =
builddate = 1621142085
packager = Bruce1844
arch = x86_64
size = 9924737
license = GNU
depend = atk
depend = cairo
depend = desktop-file-utils
depend = gdk-pixbuf2
depend = glib2
depend = glibc
depend = gtk2>=2.6
depend = hicolor-icon-theme
depend = libx11
depend = pango
optdepend = epidataentryclient>=1.3

Thank you all for contributing to my favourite distribution, Manjaro.

Not a coder at all myself, but I think if there is a closing brace, there has to be an opening one as well?

1 Like

https://wiki.archlinux.org/title/AUR_submission_guidelines#Publishing_new_package_content

Mmm thanks mangiaro. Will have to look into that.

Hello Bruce, that .install file is not necessary as pacman is already doing that operations with pre-existing pacman hooks (instead in .deb they are written and performed for every single package)

Most of the values are invalid. See the templates in /usr/share/pacman/.

Also see:

1 Like

As much as you’re willing to learn how to write a PKGBUILD and how to use git. PKGBUILD is just a bash script, with predefined expected variables and functions for you to write, while git is a (distributed) version control system where AUR is built on top of.

Let’s indent your install file in a better way:

post_install() {
  gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
  update-desktop-database -q
}

post_upgrade() {
  post_install
}

pre_remove() {
  { // too many braces, remove
    xdg-desktop-menu uninstall --mode system epidata-epidata.directory epidata-epidataentryclient.desktop
  } // too many braces, remove

  removemenu;;    // what is this?
  removemenu;;    // and this ?
  deconfigure) ;; // even worse, this. it looks like a part of case statement, but wrongly copied
}

post_remove() {
  gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
  update-desktop-database -q
}

so indeed the file has some syntax errors (a reference to bash case statement is here), I cannot really say what to do as I don’t know what ACTUALLY needs to be done on pre_remove.

I write all my PKGBUILDs by hand, I suggest you do as well, if you’re serious about contributing to AUR. Contributing doesn’t mean you just publish once and goodbye. If you’re the publisher, you are also the maintainer, expect complains from users when they found out your package is out of date, for example. If you can’t take that burden, I suggest don’t try, and ask someone who are willing to do it instead of you. Don’t look at me, I already maintain 15 packages myself and often skip versions due to lack of free time to update.

2 Likes

If you want you can add me as co-maintainer, but I can’t guarantee I will have time as I already have my stacke of pkgbuilds

AUR is for Arch packages not for debs. :rofl:

@bhh Clearly you’re missing several the points about this thread, (and also this)

Thanks Lolix, I installed with an empty .INSTALL, and yes, everything is working just fine and no error messages!

I appreciate your offer. If I come up with a PKGBUILD could you check it out as a co-maintainer :grinning:.
I just downloaded the tgz from EpiData download page. I’ll have to see what I can do with it. But won’t be for a few days.

Thanks for your input leledumbo, after looking at the work needed, it doesn’t seem too complex with all the pointers I already have on this thread. It isn’t a very complex package from what I can see. They also don’t seem to release often. If this is my only package… I might try it out. I’ve use git previously, just need to brush up on technique. I’m not so good on bash, but there’s always the manual/google :grinning:

Thanks Yochanan, very helpful! I think I could do this. :grinning:

@Bruce1844 my offer was diretcted to @leledumbo

Anyway I made the pkgbuilds for the 3 edpidata programs

Thank you Lolix, I appreciate the pkgbuilds. When I finish building this EpiData project, I will seriously look at packaging the programs for AUR. You have given me an excellent starting point.

Thank you to all who replied on this thread. I’m impressed with the Manjaro community. And yes, the question is answered: It takes quite a bit of work to contribute packages to AUR but it isn’t overwhelming and very worthwhile.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.