Building TXR under Yocto: update.

 new new list compose Reply to this message Top page
Attachments:
+ (text/plain)
+ (text/html)

Delete this message
Author: Kaz Kylheku
Date:  
To: TXR Users
Subject: Building TXR under Yocto: update.

Hi All, Below is an updated recipe for building TXR in a Yocto environment.

It handles cross-compilation: a "nativesdk-txr" package is built first, so that when TXR is being built for a target like ARM, a native txr executable is available for compiling the ".tl" files to ".tlo".

We put this into a txr_208.bb file:

require txr.inc

SRC_URI[md5sum] = "139c468bba4674679ea89591d525f9fe"
LIC_FILES_CHKSUM = "file://LICENSE;md5=139c468bba4674679ea89591d525f9fe"

and the following into txr.inc:

SUMMARY = "TXR Language"
DESCRIPTION = "A Pattern-Matching Language and Lisp Dialect"
HOMEPAGE = "http://nongnu.org/txr"

SECTION = "devel"
LICENSE = "BSD"
DEPENDS += "bison-native flex-native libffi"

# target txr depends on nativesdk-txr, for cross-compiling the Lisp files:
DEPENDS += "${@base_conditional('PN', 'txr', 'nativesdk-txr', '', d)}"

# target txr uses "txr" for compiling Lisp; native uses the built "./txr"
TXR = "${@base_conditional('PN', 'txr', 'txr', './txr', d)}"

SRC_URI = "git://kylheku.com/git/txr;protocol=http;tag=txr-${PV}"

BBCLASSEXTEND = "native nativesdk"

S = "${WORKDIR}/git"
B = "${WORKDIR}/build"

do_configure() {
  ${S}/configure prefix=${prefix}
}

do_compile() {
  make TXR=${TXR}
}

do_install() {
  make DESTDIR=${D} install
}