This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Compiler error - missing iconv.h with -mno-cygwin


Hi,

I have a program that uses libxml2 and compiles fine under Cygwin when I
compile it as a Cygwin app. However, I want to compile a stand-alone version
so I updated the Makefile to add CFLAGS += -mno-cygwin and LDFLAGS +=
-mno-cygwin (I'm using gcc 3.4.4), and with these it fails to compile
because it cannot find iconv.h:

gcc -I/usr/include/libxml2 -mno-cygwin   -c -o xmlParse.o xmlParse.c
In file included from /usr/include/libxml2/libxml/parser.h:797,
                 from xmlParse.c:36:
/usr/include/libxml2/libxml/encoding.h:28:19: iconv.h: No such file or
directory
In file included from /usr/include/libxml2/libxml/parser.h:797,
                 from xmlParse.c:36:
/usr/include/libxml2/libxml/encoding.h:136: error: parse error before
"iconv_t"
/usr/include/libxml2/libxml/encoding.h:136: warning: no semicolon at end of
struct or union
/usr/include/libxml2/libxml/encoding.h:137: warning: data definition has no
type or storage class
make: *** [xmlParse.o] Error 1

But iconv.h does exist in /usr/include, so why can the compiler not find it?
Is it looking somewhere different for include files when compiling with
-mno-cygwin?

Ian



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]