[Top][All Lists]

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

Re: Problems with getopt

From: Gisle Vanem
Subject: Re: Problems with getopt
Date: Wed, 19 Apr 2017 18:54:41 +0200
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0

Christian Egli wrote:

../tools/gnulib/.libs/libgnutools.a(getopt.o): In function 
/home/eglic/src/liblouis/tools/gnulib/getopt.c:281: undefined reference to 
/home/eglic/src/liblouis/tools/gnulib/getopt.c:295: undefined reference to 
collect2: error: ld returned 1 exit status
Makefile:1098: recipe for target 'lou_allround.exe' failed

I do not fully understand the source of gnulib/getopt.c but could it be

#  define flockfile(fp) /* nop */
#  define funlockfile(fp) /* nop */
# endif

is not invoked when cross-compiling with mingw?

Nothing to do with that. I got the same error. Since most modern
MinGW uses win-pthreads, they define:

in their <pthread_unistd.h> (line:150). So I think Gnulib should
just say:

  #  define flockfile(fp) /* nop */
  #  define funlockfile(fp) /* nop */
  # endif

instead. Similar to getdelim.c etc.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]