Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Help writing ebuild for Agar-1.3.4
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
tenspd137
Guru
Guru


Joined: 22 Aug 2006
Posts: 391

PostPosted: Thu Nov 05, 2009 4:36 am    Post subject: Help writing ebuild for Agar-1.3.4 Reply with quote

Hello all

I was trying to make an ebuild for agar, which is a cross platform toolkit for gui's I wanted to look at. Before I even tried, I made sure the ./configure and make worked, it did. I then proceeded to create the following ebuild following the ebuild developer manual as best I could:

Code:

# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI="0"

DESCRIPTION="Open source, cross platform toolkit for grphical apps implemented in C, C++, Perl, and Ada."
HOMEPAGE="http://libagar.org/"
SRC_URI="http://stable.hypertriton.com/${PN}/${P}.tar.gz"
KEYWORDS="~x86"
LICENSE="BSD"
SLOT="0"
IUSE="ctags db4 sdl gl jpeg freetype sse nls threads debug legacy network examples"

DEPEND="sdl? ( media-libs/libsdl )
   db4? ( sys-libs/db )
   gl? ( virtual/opengl )
   jpeg? ( media-libs/jpeg )
   freetype? ( media-libs/freetype )
   nls? ( sys-devel/gettext )"


src_unpack() {
   unpack ${A}
   cd "${S}"
}

src_compile() {
   ./configure \
   $(use_enable nls) \
   $(use_enable threads) \
   $(use_enable debug) \
   $(use_enable legacy) \
   $(use_enable threads) \
   $(use_with sdl) \
   $(use_with gl) \
   $(use_with db4) \
   $(use_with ctags) \
   $(use_with jpeg) \
   $(use_with freetype) \
   $(use_with sse)

   emake || die

}

src_install() {
   einstall || die "einstall failed"
}


The I did ebuild agar-1.3.4.ebuild digest. Finally, the ebuild agar-1.3.4.ebuild compile errors with:
Code:


* Using existing includes
*
* Configuration successful.
* Use "make depend" if you plan on editing the source code.
* Use "make" and "make install" to build and install Agar.
*
==> core
make[1]: Entering directory `/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/core'
make[2]: Entering directory `/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/core'
make[2]: `variable.lo' is up to date.
make[2]: Leaving directory `/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/core'
make[2]: Entering directory `/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/core'
../mk/libtool/libtool --mode=compile cc  -O2 -march=i686 -pipe -D_AGAR_INTERNAL -D_BSD_SOURCE  -I/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/include -I/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/include/agar -D_AGAR_CORE_INTERNAL -U_XOPEN_SOURCE -D_XOPEN_SOURCE=600      -o config.lo -c config.c
rm -f .libs/config.lo
cc -O2 -march=i686 -pipe -D_AGAR_INTERNAL -D_BSD_SOURCE -I/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/include -I/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/include/agar -D_AGAR_CORE_INTERNAL -U_XOPEN_SOURCE -D_XOPEN_SOURCE=600 -c config.c  -fPIC -DPIC -o .libs/config.lo
config.c: In function 'AG_ConfigInit':
config.c:109: error: 'AG_OBJECT_RELOAD_PROPS' undeclared (first use in this function)
config.c:109: error: (Each undeclared identifier is reported only once
config.c:109: error: for each function it appears in.)
make[2]: *** [config.lo] Error 1
make[2]: Leaving directory `/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/core'
make: failure
make[1]: *** [_lib_shobjs] Error 1
make[1]: Leaving directory `/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4/core'
make: *** [all-subdir] Error 1
 * ERROR: x11-libs/agar-1.3.4 failed:
 *   (no error message)
 *
 * Call stack:
 *     ebuild.sh, line  49:  Called src_compile
 *   environment, line 179:  Called die
 * The specific snippet of code:
 *       make || die
 *
 * If you need support, post the output of 'emerge --info =x11-libs/agar-1.3.4',
 * the complete build log and the output of 'emerge -pqv =x11-libs/agar-1.3.4'.
 * This ebuild is from an overlay named 'portage-local': '/usr/local/portage/'
 * The complete build log is located at '/var/tmp/portage/x11-libs/agar-1.3.4/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/x11-libs/agar-1.3.4/temp/environment'.
 * S: '/var/tmp/portage/x11-libs/agar-1.3.4/work/agar-1.3.4'


I had to use ./configure instead of econf because econf gives me the error:
Code:

 * econf: updating agar-1.3.4/Packages/config.guess with /usr/share/gnuconfig/config.guess
./configure --prefix=/usr --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --enable-nls --enable-threads --disable-debug --disable-legacy --enable-threads --with-sdl --without-gl --without-db4 --without-ctags --with-jpeg --without-freetype --without-sse
invalid argument: --build=i686-pc-linux-gnu
try ./configure --help


If anyone could look and/or suggest some strategies for debugging, that would be very appreciated. Also, I do know that the authors use the BSDBuild to generate the makefiles - while it seemed to work from just downloading the tarball, I was wondering if this is necessarily compatible with econf, or am I going to need to make some patches to the source to make it use GNU Autotools?

Thanks for any help!

(Just trying to do it the *right* way :) )
Back to top
View user's profile Send private message
tenspd137
Guru
Guru


Joined: 22 Aug 2006
Posts: 391

PostPosted: Thu Nov 05, 2009 4:41 am    Post subject: Reply with quote

I did find an older bug requesting the package, but it is a year old. I don't necesarily want to maintian this, just add it to my own overlay. I guess I could start with that as well.

Still any help/guidance would be very aprreciated.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum