* trying to build with MinGW under cygwin, but no luck, can't find dllcrt2.o
@ 2006-06-02 15:13 Ed Hartnett
2006-06-02 15:21 ` Brian Dessent
0 siblings, 1 reply; 2+ messages in thread
From: Ed Hartnett @ 2006-06-02 15:13 UTC (permalink / raw)
To: cygwin, libtool
Howdy all!
I am trying to build my libtool-based library package on Cygwin, with
the -mno-cygwin option.
However, I am getting the following problem:
libtool: link: cc -shared .libs/attr.o .libs/ncx.o .libs/putget.o
.libs/dim.o .libs/error.o .libs/libvers.o .libs/nc.o .libs/string.o
.libs/v1hpg.o .libs/var.o .libs/posixio.o -Wl,--whole-archive
./.libs/libnetcdf2.a ../fortran/.libs/libnetcdff.a
-Wl,--no-whole-archive -mno-cygwin -o .libs/cygnetcdf-1.dll
-Wl,--enable-auto-image-base -Xlinker --out-implib -Xlinker
.libs/libnetcdf.dll.a
/usr/bin/ld: dllcrt2.o: No such file: No such file or directory
collect2: ld returned 1 exit status
make[2]: *** [libnetcdf.la] Error 1
make[2]: Leaving directory `/cygdrive/c/netcdf-3/libsrc'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/cygdrive/c/netcdf-3'
make: *** [all] Error 2
I am trying to figure out what is wrong. Does anyone have an easy
answer for me?
Thanks!
Ed
--
Ed Hartnett -- ed@unidata.ucar.edu
--
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/
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: trying to build with MinGW under cygwin, but no luck, can't find dllcrt2.o
2006-06-02 15:13 trying to build with MinGW under cygwin, but no luck, can't find dllcrt2.o Ed Hartnett
@ 2006-06-02 15:21 ` Brian Dessent
0 siblings, 0 replies; 2+ messages in thread
From: Brian Dessent @ 2006-06-02 15:21 UTC (permalink / raw)
To: Ed Hartnett; +Cc: cygwin, libtool
Ed Hartnett wrote:
First, a note: the Cygwin list generally does not like to field
questions about -mno-cygwin because when doing so you are using another
project's toolchain, and so it's kind of off-topic. However, I think
your problem is actually build-environment related and not gcc related,
so I will continue, with reply-to set to the libtool list.
> I am trying to build my libtool-based library package on Cygwin, with
> the -mno-cygwin option.
>
> However, I am getting the following problem:
>
> libtool: link: cc -shared .libs/attr.o .libs/ncx.o .libs/putget.o
> .libs/dim.o .libs/error.o .libs/libvers.o .libs/nc.o .libs/string.o
> .libs/v1hpg.o .libs/var.o .libs/posixio.o -Wl,--whole-archive
> ./.libs/libnetcdf2.a ../fortran/.libs/libnetcdff.a
> -Wl,--no-whole-archive -mno-cygwin -o .libs/cygnetcdf-1.dll
> -Wl,--enable-auto-image-base -Xlinker --out-implib -Xlinker
> .libs/libnetcdf.dll.a
> /usr/bin/ld: dllcrt2.o: No such file: No such file or directory
> collect2: ld returned 1 exit status
> make[2]: *** [libnetcdf.la] Error 1
> make[2]: Leaving directory `/cygdrive/c/netcdf-3/libsrc'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory `/cygdrive/c/netcdf-3'
> make: *** [all] Error 2
>
> I am trying to figure out what is wrong. Does anyone have an easy
> answer for me?
Something here looks rather broken. First, a non-cygwin DLL should
never be named "cygnetcdf-1.dll" because the prefix "cyg" is
specifically used for this purpose, i.e. so that they are never found by
non-Cygwin apps. A mingw DLL should be named libnetcdf-1.dll. So this
makes me think libtool is confused and thinks you're trying to build a
native package.
Second, dllcrt2.o is a mingw startup file and should be present in
/usr/lib/mingw. If not then you certainly have an installation
problem. Confirm that you can compile and link a hello world program
with "gcc -mno-cygwin" before continuing.
It would help if you would post more details, such as how you configured
the package. When trying to build a mingw package under Cygwin you are
in effect cross compiling, so the configury should probably look
something like the following, although there are many ways to skin a
cat:
./configure --host=i686-pc-mingw32 --build=i686-pc-cygwin CC="gcc
-mno-cygwin"
(And if you use C++ then CXX="g++ -mno-cygwin", and so on.)
Brian
--
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/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2006-06-02 15:13 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-06-02 15:13 trying to build with MinGW under cygwin, but no luck, can't find dllcrt2.o Ed Hartnett
2006-06-02 15:21 ` Brian Dessent
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).