Created attachment 284747 [details] ebuild 2.2.0 v1 Hello, I'm the main developer of LaTeXila, an Integrated LaTeX Environment for GNOME, written in Vala. I attach the ebuild for the 2.2.0 version. This ebuild depends on ITS Tool, which is packaged in the GNOME overlay: http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=tree;f=dev-util/itstool;h=44d4d95a4793476300c503bae08d5dc2cb440deb;hb=HEAD I think the best category is "app-editors", since Kile is also there. But Texmaker is in "app-office". Best regards, Sébastien
Created attachment 284749 [details] The metadata
Some notes: "-rf" is useless in the line (in src_prepare()): rm -rf src/C/*.c It's possible to compile LaTeXila directly from the C code generated, but I think it's better to compile from Vala files. Another thing, in the pkg_postinst() function, there is a message to inform the user that Latexmk or Rubber is useful with LaTeXila. I hesitated to create two more USE flags: "latexmk" and "rubber", with dependencies to the corresponding packages. But there is no compilation options to specify if latexmk or rubber should be activated. If latexmk is installed afterwards, or if it is unmerged, it doesn't change anything for latexila. That's why I finally choose the log message.
Created attachment 286767 [details, diff] ebuild 2.2.1 With this new minor version, latexila calls "valac-0.12" directly for the compilation, instead of "valac". So there is no need to set an environment variable, or use eselect-vala and the vala eclass from the vala overlay. But ITS Tool is still missing.
Created attachment 291255 [details] ebuild 2.2.2 Update for the 2.2.2 bugs-fixes release. And dev-util/itstool is now in Portage. Can someone review my ebuild?
Ebuild review: > I think the best category is "app-editors", since Kile is also there. But > Texmaker is in "app-office". For some reason, TeX editors are scattered all over the portage tree :) There is kile in app-editors, lyx in app-office, and kbibtex in app-text. But sure, app-editors sounds reasonable. > inherit gnome.org gnome2-utils cmake-utils fdo-mime Why not simply "inherit cmake-utils gnome2"? That way you will not need to write pkg_preinst, pkg_postinst, and pkg_postm boilerplate, and will not need to update it if additional boilerplate becomes necessary in the future. > local lang=$(basename ${po_file} .po) > > if ! has ${lang} ${LINGUAS}; then > rm ${po_file} > fi If the user has LINGUAS="zh", then zh_CN.po will be deleted, and the user will not get the Chinese translation that he expects. > # Build from Vala sources > rm src/C/*.c All other vala-based packages in portage that ship pre-generated C code will build from C by default (unless USE=vala). Is there a technical reason why you always want to build from vala? > Another thing, in the pkg_postinst() function, there is a message to inform the > user that Latexmk or Rubber is useful with LaTeXila. I hesitated to create two > more USE flags: "latexmk" and "rubber", with dependencies to the corresponding > packages. But there is no compilation options to specify if latexmk or rubber > should be activated. If latexmk is installed afterwards, or if it is unmerged, > it doesn't change anything for latexila. That's why I finally choose the log > message. This is a matter of taste. IMHO, adding a default-enabled USE flag at least for latexmk (which I assume is the default latex build tool that latexila uses) would be a bit more user-friendly, especially since latexmk is a very light package.
Created attachment 295327 [details] New ebuild version > Why not simply "inherit cmake-utils gnome2"? It's indeed simpler. I didn't use the gnome2 eclass because latexila doesn't use the autotools but cmake. But for the functions pkg_preinst, pkg_postinst, and pkg_postrm, it's almost identical. > If the user has LINGUAS="zh", then zh_CN.po will be deleted Fixed. > All other vala-based packages in portage that ship pre-generated C code will > build from C by default (unless USE=vala). Is there a technical reason why you > always want to build from vala? Fedora for example prefer to build from Vala sources, because they don't like already generated stuff. But since it's OK to build from the C code, I've simplified the ebuild. > IMHO, adding a default-enabled USE flag at least for > latexmk (which I assume is the default latex build tool that latexila uses) > would be a bit more user-friendly I prefer like that too. Done.
Created attachment 295329 [details] The metadata Add the two new USE flags descriptions: latexmk and rubber.
(In reply to comment #6) > > If the user has LINGUAS="zh", then zh_CN.po will be deleted > > Fixed. Wait, I think it's not completely fixed. If the LINGUAS contains zh_CN, but not zh, then zh_CN.po will be deleted.
Created attachment 295503 [details] ebuild 2.2.2 v3 Fix the remove of useless *.po. The LINGUAS variable is simplified to keep only the two first letters for each language. Idem for the *.po. It's not a perfect solution, but the code is quite simple, and it's better to keep a little too much than removing useful PO files. Anyway, thanks for your review, Alexandre.
(In reply to comment #5) > If the user has LINGUAS="zh", then zh_CN.po will be deleted, and the user will > not get the Chinese translation that he expects. I was wrong about this, and I apologize for misleading you. Intltool uses exact language name matches, e.g. LINGUAS="zh" should only match zh, not zh_CN (check /usr/share/intltool/Makefile.in.in if you are interested), so that's the behavior that we want to duplicate. Also, an unset LINGUAS means that all translations need to be installed. Ebuild committed with the following changes: * tested on ~amd64 and ~x86; * CMAKE_IN_SOURCE_BUILD="yes" (needed for gnome2.eclass compatibility); * GCONF_DEBUG="no" (to avoid spurious debug USE flag); * added a few missing dependencies (e.g. libX11, pango, gdk-pixbuf); * change LINGUAS handling to match intltool behavior; * do not install INSTALL file (Gentoo end users do not need it); * stylistic fixes. >*latexila-2.2.2 (17 Dec 2011) > > 17 Dec 2011; Alexandre Rostovtsev <tetromino@gentoo.org> > +latexila-2.2.2.ebuild, +metadata.xml: > New ebuild for a LaTeX IDE for bug #380779, thanks to Sébastien Wilmet.
Thank you!
*** Bug 348603 has been marked as a duplicate of this bug. ***