You are not logged in.

#1 2009-08-08 23:29:22

gladstone
Member
Registered: 2009-01-03
Posts: 74

midimon build error

midimon is a GTK equivelent to KMidimon to monitor MIDI events.

I began writing a PKGBUILD for it, but:

Firstly, I didn't know which depends to list (later found out manually hit-and-miss from the configure.log) -- is there a better way of doing this?
Secondly, it fails to compile. Can some one help with this?

# Contributor: Gladstone <h2oz7v@gmail.com>
pkgname=midimon
pkgver=0.3
pkgrel=1
pkgdesc="A GTK based application to monitor midi events."
url="http://sourceforge.net/projects/midimon/"
arch=('i686')
license="GPL"
depends=('libglademm')
optdepends=('lash: for session management')
source=(http://dl.sourceforge.net/sourceforge/midimon/$pkgname-$pkgver.tar.gz)
md5sums=('dcfd9d135768438f67fab0322a2636f4')

build() {
  cd $srcdir/$pkgname-$pkgver

  ./configure --prefix=/usr
  make || return 1
  make DESTDIR=${pkgdir}/ install
}

Last edited by gladstone (2009-08-08 23:30:07)

Offline

#2 2009-08-08 23:54:23

skottish
Forum Fellow
From: Here
Registered: 2006-06-16
Posts: 7,942

Re: midimon build error

"it fails to compile" isn't helpful. You'll need to post the first error message of the compiler output to get any help.

Does that package have an INSTALL or README file that has the dependency information? If not, it should, but you can get the information from scouring configure.ac file.

Offline

#3 2009-08-09 04:18:06

djszapi
Member
From: Cambridge, United Kingdom
Registered: 2009-06-14
Posts: 1,439
Website

Re: midimon build error

Hello Gladstone!

# Maintainer: Gladstone <h2oz7v@gmail.com>
pkgname=midimon
pkgver=0.3
pkgrel=1
pkgdesc="A GTK based application to monitor midi events."
url="http://sourceforge.net/projects/midimon/"
arch=('i686')
license=('GPL')
depends=('libglademm' 'jack-audio-connection-kit')
optdepends=('lash: for session management')
source=(http://downloads.sourceforge.net/sourceforge/midimon/$pkgname-$pkgver.tar.gz)
md5sums=('dcfd9d135768438f67fab0322a2636f4')

build() {
  cd $srcdir/$pkgname-$pkgver
  ./configure --prefix=/usr --docdir=/usr/share/doc
  sed -i 's/\"mm_signal.\h"/\"mm_signal.h\"\n#include <stdio.h>/g' src/mm_signal.cc
  make || return 1
  make DESTDIR=${pkgdir}/ install || return 1
  install -d ${pkgdir}/usr/share/
  mv -f ${pkgdir}/usr/doc ${pkgdir}/usr/share/
}

Please report the patch to the author too.
In last case, you can check the dependency with namcap on the *.pkg.tar.gz

Offline

#4 2009-08-09 10:26:50

gladstone
Member
Registered: 2009-01-03
Posts: 74

Re: midimon build error

skottish wrote:

Does that package have an INSTALL or README file that has the dependency information?

No, both those files were empty.

djszapi: I tried your patch, but make returns these errors:

mm_lash.cc: In function 'bool lash_load_cb(lash_config_handle_t*, void*)':
mm_lash.cc:91: error: 'printf' was not declared in this scope
mm_lash.cc:95: error: 'printf' was not declared in this scope
mm_lash.cc:97: error: 'printf' was not declared in this scope
mm_lash.cc:99: error: 'printf' was not declared in this scope
mm_lash.cc:101: error: 'printf' was not declared in this scope
mm_lash.cc:103: error: 'printf' was not declared in this scope
make[2]: *** [mm_lash.o] Error 1
make[2]: Leaving directory `/home/user/bin/midimon/src/midimon-0.3/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/user/bin/midimon/src/midimon-0.3/src'
make: *** [all-recursive] Error 1

Last edited by gladstone (2009-08-09 10:27:20)

Offline

#5 2009-08-09 19:21:27

Stefan Husmann
Member
From: Germany
Registered: 2007-08-07
Posts: 1,391

Re: midimon build error

There seems to be more patching needed. Ther are many ways one can patch something. I alwas do it the following way.

1. Remove the unpacked stuff fro $srcdir.
2. Unpack  the tarball  and rename it using .orig suffix.
3. Unpack  the tarball  again and rename it using .new suffix.
4. Alter some files in the .new branch. In this case, add a

#include <cstdio>

somewhere at the beginning of the affected files.src/mm_signal.cc and mm_lash.cc
5. cd to $scrdir and do a

diff -aur dir.orig dir.new > ../somefile.diff

6. add somefile.diff to the sources array of the PKGBUILD and insert

patch -p1 < $srcdir/somefile.diff

into it, in most cases after the cd $srcdir/pkgnam-pkgver line.
7. run makepkg.

Offline

Board footer

Powered by FluxBB