You are not logged in.
I'm writing my first PKGBUILD for an app I wrote. In the PKGBUILD my build and package functions look like this :
build() {
cd "$srcdir/$pkgname-${pkgver//_/-}"
qmake
make PREFIX=/usr
}
package() {
cd "$srcdir/$pkgname-${pkgver//_/-}"
make DESTDIR="$pkgdir/" install
}
but makepkg builds an empty package without the binary. What am I doing wrong?
Last edited by yungtrizzle (2014-02-01 14:40:20)
Offline
It's probably a Makefile that doesn't respect the DESTDIR you're passing it. You could verify this by running `find ./pkg/` from the directory where you build; you'll probably get no results either. Looking at the Google results, qmake should accept a destdir too, so I'd try that
Offline
Actually /pkg/ and subdirectories exist but are empty. The binary remains in the source directory and make says nothing to be done for 'install'.
Offline
Well, you wrote this app - what would you do if you were installing it manually i.e. without a PKGBUILD?
Offline
Can you manually build and install successfully?
qmake
make PREFIX=/usr
make install DESTDIR=test
Do the needed files exist in ./test is the question.
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
Well, you wrote this app - what would you do if you were installing it manually i.e. without a PKGBUILD?
hard code the install path and run make install
Offline
Can you manually build and install successfully?
qmake make PREFIX=/usr make install DESTDIR=test
Do the needed files exist in ./test is the question.
./test does not exist after compiling.
Offline
Doesn't sound like your Makefile is using $(DESTDIR) then... modify it to do so. Use this as an example if you need one: https://github.com/graysky2/profile-syn … r/Makefile
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
Actually /pkg/ and subdirectories exist but are empty. The binary remains in the source directory and make says nothing to be done for 'install'.
Did you try passing DESTDIR to qmake as I suggested?
Offline
Doesn't sound like your Makefile is using $(DESTDIR) then... modify it to do so. Use this as an example if you need one: https://github.com/graysky2/profile-syn … r/Makefile
That won't work in my case, the makefile is generated from qmake, anything I change will be overwritten.
@Spider.007 add DESTDIR doesn't make any changes
Last edited by yungtrizzle (2014-02-01 12:36:35)
Offline
qmake project files should include DESTDIR. This is in every tutorial I can fnd on qmake, and would come up with a google search of "qmake DESTDIR" or just "qmake".
If you want more help you're going to have to share the actual files you're creating - particularly the project file.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
You might have success with make INSTALL_ROOT=... install
http://davmac.wordpress.com/2007/02/21/qts-qmake/
| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |
Offline
QT += core gui multimedia multimediawidgets dbus
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
TARGET = cleps
TEMPLATE = app
DESTDIR = /usr/bin
This my .pro relevant section. make now complains about permissions.
@progandy
can't view your link I'm behind the gfw so its blocked
Offline
I think I got it to work. Had to make changes to the .pro file and use INSTALL_ROOT
Offline
Could you share these changes? Do they happen in the snippet of code of the qmake file you have posted?
Offline
@thiagowfx sorry i just say your postbut here's what working for me
QT += core gui multimedia multimediawidgets dbus
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
TARGET = cleps
TEMPLATE = app
target.path = /usr/bin/
INSTALLS += target
Offline