From: Axel S. <A....@uk...> - 2003-01-23 10:20:09
|
Hi all, there is a bug in c2hs's lexer. When my build on Solaris failed, I relaized that c2hs is using cpp from gcc version 3.1. The old preprocessor of gcc 2.95 produces at least one newline between each line directive, the new one doesn't - here are the first few lines of the preprocessed file: # 1 "/usr/local/packages/gtk-2.0.5/include/gtk-2.0/gtk/gtk.h" # 1 "<built-in>" # 1 "<command line>" # 1 "/usr/local/packages/gtk-2.0.5/include/gtk-2.0/gtk/gtk.h" # 31 "/usr/local/packages/gtk-2.0.5/include/gtk-2.0/gtk/gtk.h" # 1 "/usr/local/packages/gtk-2.0.5/include/gtk-2.0/gdk/gdk.h" 1 # 30 "/usr/local/packages/gtk-2.0.5/include/gtk-2.0/gdk/gdk.h" # 1 "/usr/local/packages/gtk-2.0.5/include/gtk-2.0/gdk/gdkcolor.h" 1 c2hs swallows the newline somehow and then chokes on the first # sign on the next line. I don't know why and debugging the scanner combinators is not trivial. So for now, be aware that you use the old gcc for preprocessing as well. Axel. |