[CWB] [PATCH] Fix CWB-CL Makefile

Alberto Simões ambs at di.uminho.pt
Wed Jan 5 18:22:27 CET 2011


Makefile.PL on CWB-CL fails when cwb-config returns the glib-config command:

[ambs at search CWB-CL]$ cwb-config -L
-L/share/apps/amalandro/lib -lcl -lm -lpcre `pkg-config --libs glib-2.0`

because ExtUtils::MakeMaker tries to split that string by spaces, and 
gets messy.

This patch fixes it into the Makefile.PL code.

I do *not* think this is the correct fix (the fix should be done in CWB 
itself making it to print a clear line with cwb-config) but this makes 
CWB-CL to work with current SVN CWB version.

Therefore, My suggestion is: apply this patch, and remove it (it is just 
a line) when CWB gets fixed :)

Alberto Simões
-------------- next part --------------
Index: Makefile.PL
--- Makefile.PL	(revision 199)
+++ Makefile.PL	(working copy)
@@ -68,6 +68,7 @@
 my $CFLAGS = `'$config_util' -I`;
 chomp $CFLAGS;
 my $LDFLAGS = `'$config_util' -L`;
+$LDFLAGS=~s/(`[^`]+`)/chomp($_ = eval $1); $_/eg;
 chomp $LDFLAGS;

More information about the CWB mailing list