pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

multimedia/libkate: [patch] fix "undefined reference to yylex" build error on Linux



Hi,

on Linux (Ubuntu 10.04, Debian 8), multimedia/libkate fails to build
with the following error:

    /bin/bash ../libtool  --tag=CC   --silent --mode=link gcc -Wall -W   -I/opt/pkgsrc/include -I/opt/pkgsrc/include/libpng16  -O2 -I/opt/pkgsrc/include -I/usr/include  -L/opt/pkgsrc/lib -Wl,--enable-new-dtags,-R/opt/pkgsrc/lib -L/usr/lib -Wl,--enable-new-dtags,-R/usr/lib -o kateenc kateenc-kateenc.o  kateenc-kate_lexer.o  kateenc-kate_parser.o kateenc-kpng.o ../lib/liboggkate.la ../lib/libkate.la -L/opt/pkgsrc/lib -Wl,--enable-new-dtags,-R/opt/pkgsrc/lib -logg -L/opt/pkgsrc/lib -Wl,--enable-new-dtags,-R/opt/pkgsrc/lib -lpng16 -lfl
=>  /opt/pkgsrc/work/pkgsrc/multimedia/libkate/default/.buildlink/lib/libfl.so: undefined reference to `yylex'
    collect2: error: ld returned 1 exit status
    *** Error code 1

I found an existing patch via
http://www.linuxquestions.org/questions/slackware-14/cant-compile-libkate-on-slackware64-current-4175545811-print/
and reformatted it for pkgsrc (s. attachment)

On NetBSD 6, libkate builds ok with or without this patch.

Regards
Matthias
$NetBSD$

fixes "undefined reference to yylex" build error.

patch by David Spencer
copied from http://cgit.ponce.cc/slackbuilds/patch/?id=3bac689475f0bf99e029680d7ad785869e44b344

>From 3bac689475f0bf99e029680d7ad785869e44b344 Mon Sep 17 00:00:00 2001
From: David Spencer
Date: Sat, 30 May 2015 06:38:08 +0100
Subject: libraries/libkate: Patched to fix building with -current.

Signed-off-by: David Spencer <baildon.research%googlemail.com@localhost>

diff -u -r libkate-0.4.1-orig/Makefile.in libkate-0.4.1/Makefile.in
--- Makefile.in.orig	2011-08-21 23:46:58.000000000 +0100
+++ Makefile.in	2015-05-28 23:52:21.389946971 +0100
@@ -260,7 +260,6 @@
 LD = @LD@
 LDFLAGS = @LDFLAGS@
 LEX = @LEX@
-LEXLIB = @LEXLIB@
 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
 LIBKATE_SHARED_VERSION = @LIBKATE_SHARED_VERSION@
 LIBOBJS = @LIBOBJS@
diff -u -r libkate-0.4.1-orig/configure.ac libkate-0.4.1/configure.ac
--- configure.ac.orig	2011-08-21 23:44:32.000000000 +0100
+++ configure.ac	2015-05-30 06:28:33.306682481 +0100
@@ -7,7 +7,7 @@
 
 AC_CANONICAL_TARGET
 
-AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects])
+AM_INIT_AUTOMAKE([-Wall foreign subdir-objects])
 AC_CONFIG_HEADERS([include/config.h])
 
 ifdef([AM_SILENT_RULES],[AM_SILENT_RULES])
diff -u -r libkate-0.4.1-orig/doc/Makefile.in libkate-0.4.1/doc/Makefile.in
--- doc/Makefile.in.orig	2011-08-21 23:47:10.000000000 +0100
+++ doc/Makefile.in	2015-05-28 23:52:49.742054572 +0100
@@ -125,7 +125,6 @@
 LD = @LD@
 LDFLAGS = @LDFLAGS@
 LEX = @LEX@
-LEXLIB = @LEXLIB@
 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
 LIBKATE_SHARED_VERSION = @LIBKATE_SHARED_VERSION@
 LIBOBJS = @LIBOBJS@
diff -u -r libkate-0.4.1-orig/tests/Makefile.in libkate-0.4.1/tests/Makefile.in
--- tests/Makefile.in.orig	2011-08-21 23:46:58.000000000 +0100
+++ tests/Makefile.in	2015-05-28 23:52:36.542004463 +0100
@@ -156,7 +156,6 @@
 LD = @LD@
 LDFLAGS = @LDFLAGS@
 LEX = @LEX@
-LEXLIB = @LEXLIB@
 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
 LIBKATE_SHARED_VERSION = @LIBKATE_SHARED_VERSION@
 LIBOBJS = @LIBOBJS@
diff -u -r libkate-0.4.1-orig/tools/KateDJ/Makefile.in libkate-0.4.1/tools/KateDJ/Makefile.in
--- tools/KateDJ/Makefile.in.orig	2011-08-21 23:46:58.000000000 +0100
+++ tools/KateDJ/Makefile.in	2015-05-28 23:53:11.981139017 +0100
@@ -99,7 +99,6 @@
 LD = @LD@
 LDFLAGS = @LDFLAGS@
 LEX = @LEX@
-LEXLIB = @LEXLIB@
 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
 LIBKATE_SHARED_VERSION = @LIBKATE_SHARED_VERSION@
 LIBOBJS = @LIBOBJS@
diff -u -r libkate-0.4.1-orig/tools/Makefile.am libkate-0.4.1/tools/Makefile.am
--- tools/Makefile.am.orig	2011-08-21 13:42:10.000000000 +0100
+++ tools/Makefile.am	2015-05-28 23:54:03.293333914 +0100
@@ -20,7 +20,7 @@
 endif
 katedec_SOURCES=katedec.c kkate.c ksrt.c klrc.c kutil.c kfuzz.c kstream.c kread.c kstrings.c
 katalyzer_SOURCES=katalyzer.c kutil.c kstream.c kread.c kstrings.c kstats.c
-kateenc_LDADD=../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@ @PNG_LIBS@ @LEXLIB@
+kateenc_LDADD=../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@ @PNG_LIBS@
 katedec_LDADD=../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@
 katalyzer_LDADD=../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@
 kateenc_CFLAGS=@CWARNFLAGS_LIGHT@ @CFLAGS_FORTIFY_SOURCE@ @CFLAGS_DEBUG@ @OGG_CFLAGS@ @PNG_CFLAGS@
diff -u -r libkate-0.4.1-orig/tools/Makefile.in libkate-0.4.1/tools/Makefile.in
--- tools/Makefile.in.orig	2011-08-21 23:46:58.000000000 +0100
+++ tools/Makefile.in	2015-05-28 23:54:21.805404270 +0100
@@ -223,7 +223,6 @@
 LD = @LD@
 LDFLAGS = @LDFLAGS@
 LEX = @LEX@
-LEXLIB = @LEXLIB@
 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
 LIBKATE_SHARED_VERSION = @LIBKATE_SHARED_VERSION@
 LIBOBJS = @LIBOBJS@
@@ -351,7 +350,7 @@
 @HAVE_OGG_TRUE@	$(am__append_1)
 @HAVE_OGG_TRUE@katedec_SOURCES = katedec.c kkate.c ksrt.c klrc.c kutil.c kfuzz.c kstream.c kread.c kstrings.c
 @HAVE_OGG_TRUE@katalyzer_SOURCES = katalyzer.c kutil.c kstream.c kread.c kstrings.c kstats.c
-@HAVE_OGG_TRUE@kateenc_LDADD = ../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@ @PNG_LIBS@ @LEXLIB@
+@HAVE_OGG_TRUE@kateenc_LDADD = ../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@ @PNG_LIBS@
 @HAVE_OGG_TRUE@katedec_LDADD = ../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@
 @HAVE_OGG_TRUE@katalyzer_LDADD = ../lib/liboggkate.la ../lib/libkate.la @OGG_LIBS@
 @HAVE_OGG_TRUE@kateenc_CFLAGS = @CWARNFLAGS_LIGHT@ @CFLAGS_FORTIFY_SOURCE@ @CFLAGS_DEBUG@ @OGG_CFLAGS@ @PNG_CFLAGS@


Home | Main Index | Thread Index | Old Index