xcruiser: fix gcc6 build

The order of object files and libraries is important. Create a
Makefile that puts the $(LIBS) after the *.o files.
This commit is contained in:
Juergen Buchmueller 2016-10-21 14:54:52 +02:00
parent 9f5a5e3a03
commit aa4e646b18

View file

@ -10,12 +10,14 @@ license="GPL-2"
homepage="http://${pkgname}.sourceforge.net/"
distfiles="${SOURCEFORGE_SITE}/${pkgname}/${pkgname}/${pkgname}-${version}/${pkgname}-${version}.tar.gz"
checksum=917b68dc06389bfcdde742f0798f61cdeaea2ae3c6567960c33f7634d4861ce5
LDFLAGS="-lXaw -lXmu -lXt -lX11 -lm"
LIBS="-lXaw -lXmu -lXt -lX11 -lm"
pre_build() {
local sources
sources=(*.c)
echo "${pkgname}: ${sources[@]/%c/o}" >Makefile
echo "LIBS=${LIBS}" >Makefile
echo "${pkgname}: ${sources[@]/%c/o}" >>Makefile
echo ' $(CC) $(LDFLAGS) -o $@ $^ $(LIBS)' >>Makefile
}
do_install() {