summaryrefslogtreecommitdiff
path: root/packages/libedit/libedit_20050118.bb
blob: 472397c8816c3e007f3360976f93f98e09132048 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
DESCRIPTION = "BSD replacement for libreadline"
HOMEPAGE = "http://cvsweb.netbsd.org/bsdweb.cgi/src/lib/libedit/"
SECTION = "libs"
MAINTAINER = "Bruno Randolf <bruno.randolf@4g-systems.biz>"
LICENSE="BSD"
DEPENDS = "ncurses"
PR = "r1"

SRC_URI = "ftp://ftp.linux.ee/pub/gentoo/distfiles/distfiles/libedit-${PV}.tar.bz2 \
	file://20031222-debian-to-gentoo.patch;patch=1;pnum=1 \
	file://libedit-add-soname.diff;patch=1;pnum=0"

S = "${WORKDIR}/netbsd-cvs"

CFLAGS += "-I. -include ../glibc-bsd-glue/bsdcompat.h -I../glibc-compat -I../glibc-bsd-glue"

do_configure() {
	mv ${WORKDIR}/glibc-*/*.c .
	oe_runmake .depend
}

do_compile() {
	oe_runmake LIBS="-lncurses ${LDFLAGS}"
}

do_stage() {
	oe_libinstall -a -so libedit ${STAGING_LIBDIR}
	install -d ${STAGING_INCDIR}/editline/
	install readline/readline.h ${STAGING_INCDIR}/editline/
	install histedit.h ${STAGING_INCDIR}/editline/
}

do_install() {
	install -d ${D}${libdir} ${D}${includedir}/editline ${D}${mandir}
	oe_libinstall -a -so libedit ${D}${libdir}
	install readline/readline.h ${D}${includedir}/editline/
	install histedit.h ${D}${includedir}/editline/
	install *.[35] ${D}${mandir}
}

FILES_${PN} = "${libdir}/libedit.so"