You are not logged in.
Reset branch 'makepkg'
==> Starting pkgver()...
==> Updated version: antimony-git 20150619-1
==> Removing existing $pkgdir/ directory...
==> Starting build()...
sed: can't read qt/shared.pri: No such file or directory
==> ERROR: A failure occurred in build().
Aborting...
Something changed upstream AFAI understand.
Also when it used to build it didn't create a desktop entry. (Starts fine through command line though)
And at last has anyone tried it on wayland. I get a transparent background on the object window instead of the expected black background.
Last edited by 89c51 (2016-08-03 12:24:55)
Offline
Post this on https://aur.archlinux.org/packages/antimony-git/
Have you tried https://aur.archlinux.org/packages/antimony/ ?
Offline
# Maintainer: Kyle Keen <keenerd@gmail.com>
# Contributor: Earnestly
pkgname=antimony-git
pkgver=0.9.0b.r61.gabea539
pkgrel=1
pkgdesc="Graph-based 3D CSG CAD modeller"
url="http://www.mattkeeter.com/projects/antimony/3/"
provides=('antimony')
conflicts=('antimony')
arch=('i686' 'x86_64')
license=('MIT')
depends=('qt5-base' 'boost-libs' 'python' 'libpng' 'lemon')
makedepends=('boost' 'git')
source=("git+https://github.com/mkeeter/antimony.git")
md5sums=('SKIP')
# todo, replace bundled eigen with official
_gitname="antimony"
_gitbranch="develop"
pkgver() {
cd "$_gitname"
#git show -s --format="%ci" HEAD | sed -e 's/-//g' -e 's/ .*//'
git describe | sed 's/-/.r/; s/-/./'
}
build() {
cd "$_gitname"
sed -i 's|\(executable.path =\).*|\1 /usr/bin|' app/app.pro
sed -i 's|\(nodes_folder.path =\).*|\1 /usr/share/antimony/sb/nodes|' app/app.pro
sed -i 's|\(fab_folder.path =\).*|\1 /usr/lib/python3.5/site-packages/fab|' app/app.pro
sed -i 's|return path.join("/");|return "/usr/share/antimony/sb/nodes";|' app/src/app/app.cpp
mkdir -p build
cd build
qmake-qt5 PREFIX="/usr" ../sb.pro
sed -i 's|/local/bin|/bin|g' Makefile
make
}
check() {
cd "$_gitname"
return 0
mkdir -p tests
cd tests
qmake-qt5 PREFIX="/usr" ../qt/antimony-tests.pro
make
# failure involving QNetworkAccessManager
}
package() {
cd "$_gitname/build"
make INSTALL_ROOT="$pkgdir" install
install -Dm755 app/antimony "$pkgdir/usr/bin/antimony"
}
This is an updated and working PKGBUILD for antimony-git. What it still doesn't do is create a desktop file so you can start it from a menu. In antimony there seems to be code to do that > https://github.com/mkeeter/antimony/blo … /mkdesktop but it doesn't happen.
Does it need one to be created and supplied along the PKGBUILD? Seen some packages do that.
Offline
In case anyone is trying to build antimony git and it fails just use the PKGBUILD below: (until keenerd updates the one in AUR)
# Maintainer: Kyle Keen <keenerd@gmail.com>
# Contributor: Earnestly
pkgname=antimony-git
pkgver=0.9.0b.r61.gabea539
pkgrel=1
pkgdesc="Graph-based 3D CSG CAD modeller"
url="http://www.mattkeeter.com/projects/antimony/3/"
provides=('antimony')
conflicts=('antimony')
arch=('i686' 'x86_64')
license=('MIT')
depends=('qt5-base' 'boost-libs' 'python' 'libpng' 'lemon')
makedepends=('boost' 'git')
source=("git+https://github.com/mkeeter/antimony.git")
md5sums=('SKIP')
# todo, replace bundled eigen with official
_gitname="antimony"
_gitbranch="develop"
pkgver() {
cd "$_gitname"
#git show -s --format="%ci" HEAD | sed -e 's/-//g' -e 's/ .*//'
git describe | sed 's/-/.r/; s/-/./'
}
build() {
cd "$_gitname"
sed -i 's|\(executable.path =\).*|\1 /usr/bin|' app/app.pro
sed -i 's|\(nodes_folder.path =\).*|\1 /usr/share/antimony/sb/nodes|' app/app.pro
sed -i 's|\(fab_folder.path =\).*|\1 /usr/lib/python3.5/site-packages/fab|' app/app.pro
sed -i 's|return path.join("/");|return "/usr/share/antimony/sb/nodes";|' app/app/app.cpp
mkdir -p build
cd build
qmake-qt5 PREFIX="/usr" ../sb.pro
sed -i 's|/local/bin|/bin|g' Makefile
make
}
check() {
cd "$_gitname"
return 0
mkdir -p tests
cd tests
qmake-qt5 PREFIX="/usr" ../qt/antimony-tests.pro
make
# failure involving QNetworkAccessManager
}
package() {
cd "$_gitname/build"
make INSTALL_ROOT="$pkgdir" install
install -Dm755 app/antimony "$pkgdir/usr/bin/antimony"
}
Offline
Upstream changed the way to build antimony-git and as a result the PKGBUILD doesn't work.
I modified the PKGBUILD a bit and seems to build but gives an error when its about to create the package.
Could someone give some tips?
Here is the build instructions for linux > https://github.com/mkeeter/antimony/blo … UILDING.md
Below the modified PKGBUILD
# Maintainer: Kyle Keen <keenerd@gmail.com>
# Contributor: Earnestly
pkgname=antimony-git
pkgver=0.9.1c.r38.g317eeaf
pkgrel=1
pkgdesc="Graph-based 3D CSG CAD modeller"
url="http://www.mattkeeter.com/projects/antimony/3/"
provides=('antimony')
conflicts=('antimony')
arch=('i686' 'x86_64')
license=('MIT')
depends=('qt5-base' 'boost-libs' 'python' 'libpng' 'lemon' 'ninja' 'cmake')
makedepends=('boost' 'git')
source=("git+https://github.com/mkeeter/antimony.git")
md5sums=('SKIP')
# todo, replace bundled eigen with official
_gitname="antimony"
_gitbranch="develop"
pkgver() {
cd "$_gitname"
#git show -s --format="%ci" HEAD | sed -e 's/-//g' -e 's/ .*//'
git describe | sed 's/-/.r/; s/-/./'
}
build() {
cd "$_gitname"
mkdir -p build
cd build
cmake -GNinja ..
ninja ./app/antimony
}
check() {
cd "$_gitname"
return 0
mkdir -p tests
cd tests
qmake-qt5 PREFIX="/usr" ../lib/fab/fab-tests.pro
qmake-qt5 PREFIX="/usr" ../lib/graph/graph-tests.pro
make
}
package() {
cd "$_gitname/build"
ninja install
install -Dm755 app/antimony "$pkgdir/usr/bin/antimony"
}
The error:
[13/14] Install the project...
-- Install configuration: "RELEASE"
-- Installing: /usr/local/bin/antimony
CMake Error at app/cmake_install.cmake:50 (file):
file INSTALL cannot copy file
"/home/dert/Builds/antimony-git/src/antimony/build/app/antimony" to
"/usr/local/bin/antimony".
Call Stack (most recent call first):
cmake_install.cmake:39 (include)
FAILED: CMakeFiles/install.util
cd /home/dert/Builds/antimony-git/src/antimony/build && /usr/bin/cmake -P cmake_install.cmake
ninja: build stopped: subcommand failed.
==> ERROR: A failure occurred in package().
Aborting...
Last edited by 89c51 (2016-07-01 19:28:26)
Offline
Got to this again. Since INSTALL cannot copy the file is it a permission problem or the problem lies elsewhere?
Maybe someone can provide some pointers?
Offline
cmake tries to install a file in /usr/local/bin/ folder .
Normal users / makepkg are not allowed to write into /usr/local and AL packages should never use it to install.
Usually this is solved by using something like DESTDIR = "$pkgdir/usr" .
Last edited by Lone_Wolf (2016-07-31 23:18:05)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
(A works at time B) && (time C > time B ) ≠ (A works at time C)
Online
Where am i supposed to add the DESTDIR
Something like:
ninja DESTDIR = "$pkgdir/usr" install
doesn't work. Is there another way of specifying the install dir.
Offline
DESTDIR is an autotools variable, cmake has different ways of setting the install destination. Look at the CMakeCache.txt file, find where /usr/local is being set, then change the value of this setting by amending the cmake command in the PKGBUILD (hint: check 'man cmake' and look into creating a cmake cache entry).
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
It worked thanks. I get this message but the package seems to work.
==> Creating package "antimony-git"...
-> Generating .PKGINFO file...
-> Generating .BUILDINFO file...
-> Generating .MTREE file...
-> Compressing package...
: Can't translate pathname 'usr/share/antimony/nodes/2D → 3D/' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/3D → 2D/' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/3D → 2D/slice_xy.node' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/3D → 2D/slice_xz.node' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/3D → 2D/slice_yz.node' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/2D → 3D/Revolve/' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/2D → 3D/extrude.node' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/2D → 3D/loft.node' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/2D → 3D/Revolve/revolve_xy_x.node' to UTF-8: Can't translate pathname 'usr/share/antimony/nodes/2D → 3D/Revolve/revolve_xy_y.node' to UTF-8==> Leaving fakeroot environment.
==> Finished making: antimony-git 0.9.2b.r16.g3409336-1 (Mon Aug 1 14:06:12 EEST 2016)
The lack of desktop entry on the menus remains though
The PKGBUILD:
# Maintainer: Kyle Keen <keenerd@gmail.com>
# Contributor: Earnestly
pkgname=antimony-git
pkgver=0.9.2b.r16.g3409336
pkgrel=1
pkgdesc="Graph-based 3D CSG CAD modeller"
url="http://www.mattkeeter.com/projects/antimony/3/"
provides=('antimony')
conflicts=('antimony')
arch=('i686' 'x86_64')
license=('MIT')
depends=('qt5-base' 'boost-libs' 'python' 'libpng' 'lemon' 'ninja' 'cmake')
makedepends=('boost' 'git')
source=("git+https://github.com/mkeeter/antimony.git")
md5sums=('SKIP')
# todo, replace bundled eigen with official
_gitname="antimony"
_gitbranch="develop"
pkgver() {
cd "$_gitname"
#git show -s --format="%ci" HEAD | sed -e 's/-//g' -e 's/ .*//'
git describe | sed 's/-/.r/; s/-/./'
}
build() {
cd "$_gitname"
mkdir -p build
cd build
cmake -D CMAKE_INSTALL_PREFIX:PATH="$pkgdir/usr" -GNinja ..
ninja ./app/antimony
}
check() {
cd "$_gitname"
return 0
mkdir -p tests
cd tests
qmake-qt5 PREFIX="/usr" ../lib/fab/fab-tests.pro
qmake-qt5 PREFIX="/usr" ../lib/graph/graph-tests.pro
make
}
package() {
cd "$_gitname/build"
ninja install
}
Could someone take a look at it and suggest improvements? Extra internet points if he can give pointers in fixing the desktop entry.
Offline
No, wait, I goofed here. You don't want to set install prefix to $pkgdir/usr, just /usr. You will need to find the equivalent to DISTDIR for ninja. (otherwise the package will install files to $pkgdir). As for the desktop file, if the build makes one, you may just need to install it manually. Otherwise, can you call the mkdesktop script during build()?
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
I looked (briefly) for an equivalent command but didn't find something that looked to do what we want (DESTDIR). (i might be totally wrong since this is the first time i am doing something more than adding a few deps to a PKGBUILD).
From what i read on their site ninja is supposed to be udes in conjunction with cmake so the way we do it now might be ok.
Regarding the .desktop there is a mkdesktop file in the code so i assume i'll just have to call this from build()
Offline
Ahem ...
the mkdesktop file is in antimony-git/src/antimony/deploy/linux
is there an elegant way of calling the script than cd and ./mkdesktop?
And a way to remove it when someone uninstalls the app.
Last edited by 89c51 (2016-08-01 13:59:46)
Offline
I've built a few cmake projects with "Unix Makefiles", and the standard install target accepts the DESTDIR="${pkgdir}" variable. It is not just autotools we have a commonly-used, sensible name for it so why not reuse it in other build systems?
I don't know anything about ninja (or ninja builds generated with cmake), maybe they use DESTDIR too but one thing is for sure -- using spaces around the "=" sign when invoking it in post #8 won't work regardless of whether ninja wants to or not.
This is bash. You don't set variables that way.
Unless ninja actually expects to receive three (four counting "install") positional parameters (which is a silly thing to suggest, and I say it only to highlight the extent that it isn't so):
ninja "DESTDIR" "=" "$pkgdir/usr" "install"
Last edited by eschwartz (2016-08-01 19:00:54)
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
Just to update.
The last PKGBUILD i posted builds it. Tried with just /usr in the cmake and it didn't work. Anyway.
The remaining issues are the translate issue and the desktop issue.
Offline
The last PKGBUILD i posted builds it. Tried with just /usr in the cmake and it didn't work.
It may build it, but check the finished package with 'tar tf'. If there are any instances of 'home/dert/Builds/antimony-git/pkg' then the PKGBUILD is wrong.
Looking at this webpage, you need to declare DESTDIR before the call to 'ninja install'.
the mkdesktop file is in antimony-git/src/antimony/deploy/linux
is there an elegant way of calling the script than cd and ./mkdesktop?
And a way to remove it when someone uninstalls the app.
You probably don't need to cd, you can probably call the script from $srcdir. Generate it in build() and remember to install it in package().
If you do it this way, then it will be installed and removed as part of the package.
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
How do i install it in package()?
I run the script manually (for science) and it put a .desktop in .local/share/applications. I suspect that the same will happen if i call it with /srcdir/antimony/deploy/linux/mkdesktop from the build() .
Last edited by 89c51 (2016-08-02 09:07:40)
Offline
You don't need a script to generate a desktop file, unless (as is the case here) it was meant to find the binary and icon file in the application build directory, with no intent to run the "install" target.
In other words, for packaging purposes the script is several degrees worse than useless and should not be relied upon under any circumstances.
...
Ship your own desktop file with the contents of the template in that script, but replacing {exec} and {icon} with "antimony" and "antimony". (The script itself will try to use absolute paths from "$srcdir".)
Copy that yourself with `install -Dm644 antimony.desktop "${pkgdir}"/usr/share/applications/antimony.desktop`.
And copy the icon with `install -Dm644 deploy/icon.svg "${pkgdir}"/usr/share/pixmaps/antimony.svg`.
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
Working PKGBUILD
# Maintainer: Kyle Keen <keenerd@gmail.com>
# Contributor: Earnestly
pkgname=antimony-git
pkgver=0.9.2b.r16.g3409336
pkgrel=1
pkgdesc="Graph-based 3D CSG CAD modeller"
url="http://www.mattkeeter.com/projects/antimony/3/"
provides=('antimony')
conflicts=('antimony')
arch=('i686' 'x86_64')
license=('MIT')
depends=('qt5-base' 'boost-libs' 'python' 'libpng' 'lemon')
makedepends=('boost' 'git' 'ninja' 'cmake')
source=("git+https://github.com/mkeeter/antimony.git"
"antimony.desktop")
md5sums=('SKIP'
'SKIP')
# todo, replace bundled eigen with official
_gitname="antimony"
_gitbranch="develop"
pkgver() {
cd "$_gitname"
#git show -s --format="%ci" HEAD | sed -e 's/-//g' -e 's/ .*//'
git describe | sed 's/-/.r/; s/-/./'
}
build() {
cd "$_gitname"
mkdir -p build
cd build
cmake -D CMAKE_INSTALL_PREFIX:PATH="$pkgdir/usr" -GNinja ..
ninja ./app/antimony
}
package() {
cd "$_gitname/build"
ninja install
install -Dm644 "${srcdir}"/antimony.desktop "${pkgdir}"/usr/share/applications/antimony.desktop
install -Dm644 "${srcdir}"/antimony/deploy/icon.svg "${pkgdir}"/usr/share/pixmaps/antimony.svg
}
.Desktop file
[Desktop Entry]
Type=Application
Version=1.0
Name=Antimony
Comment=Tree-based Modeler
GenericName=CAD Application
Exec=antimony %f
Icon=antimony
Terminal=false
Categories=Graphics;Science;Engineering;
MimeType=application/x-extension-sb;application/x-antimony;
StartupWMClass=antimony
Thanks @Eschwartz and @WorMzy for the help.
Last edited by 89c51 (2016-08-05 10:14:55)
Offline
Please use "$srcdir" rather than "$startdir", add the destop file to your sources array, and quote all references to variables which you do not control.
Users can and do use a custom "$SRCDEST" which means sources get stored elsewhere and do not appear in "$startdir" -- for this reason "$startdir" is officially deprecated and should never be used.
Additionally, the package can be downloaded to and built from a path that contains spaces, in which case all references to files using the unquoted $srcdir $pkgdir $startdir variables will break hard.
...
Do not use
cmake -DCMAKE_INSTALL_PREFIX:PATH="$pkgdir/usr"
and
ninja install
You should be able to use an install prefix of "/usr" and use ninja with
DESTDIR="${pkgdir}"/usr ninja install
if I read the ninja documentation correctly. (They support prefixing ninja with environment variables, but not passing variable definitions as parameters to ninja. The traditional Make supports both and is usually used the second way.)
As it is, you are compiling the code so it expect to be in "${pkgdir}/usr" and installing it directly to its final location... which may not break here but is still not a good idea, e.g. it will do weird RPATH-y things in the general case.
...
Style nit: I usually use "${pkgname%-git}" rather than $_gitname, and you can also use it in the url and the source array.
Last edited by eschwartz (2016-08-03 15:50:30)
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
the DESTDIR stuff with ninja didn't work so i'll stick to the cmake way.
Updated the PKGBUILD on the previous message to use &srcdir for the .desktop.
Offline
the DESTDIR stuff with ninja didn't work
If you want to learn how to package, then please learn how to package properly.
Some other points to add to Eschwartz's:
* the package doesn't "depend" on ninja or cmake. These are only needed for building the package so should only be listed as "makedepends".
* I'm not sure about the lemon dependency either.
* You're skipping file integrity checks on your .desktop file, don't.
* As this is MIT licensed (i.e. not included in the core/licences package), you should install the license file that comes with the source code.
* The check function is useless, fix it or remove it.
* You don't appear to have contacted the maintainer of this package, nor is the package flagged out of date. Unless you have contacted them privately, how are you expecting them to know that their package needs updating?
Last edited by WorMzy (2016-08-04 20:32:08)
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
@WorMzy,
What *.install file, I don't see one.
Plus, *.install files are never listed in the source or checksum arrays.
@89c51,
You may have switched to $srcdir, but you still didn't put it in quotes. This is an actual problem -- not just a style/standards-conformance nit.
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
Whoops, I meant .desktop file, not .install file.
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
First of i don't aspire to be a package maintainer or dev or whatever. I just needed something that worked and by copy pasting and looking at other PKGBUILDs i reached a point where i couldn't move further. As i said it was all about getting something working and TBH i didn't care much about correctness or standards etc as long as it didn't give me an error. Most things not included or implemented the wrong way were/are result of lack of knowledge on how to do them.
Updated the PKGBUILD with some of your suggestions.
Offline