From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20057 invoked by alias); 23 Jul 2010 22:16:06 -0000 Received: (qmail 19791 invoked by uid 48); 23 Jul 2010 22:15:49 -0000 Date: Fri, 23 Jul 2010 22:16:00 -0000 Message-ID: <20100723221549.19790.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/40011] Problems with -fwhole-file In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "jv244 at cam dot ac dot uk" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-07/txt/msg02579.txt.bz2 ------- Comment #59 from jv244 at cam dot ac dot uk 2010-07-23 22:15 ------- I'm trying a recent trunk (162490), and I'm still observing that -fwhole-file causing linking errors. I have no easy testcase, the way to reproduce is: download http://www.pci.unizh.ch/vandevondele/tmp/CP2K_gcc_2007_06.tgz compile and link (takes several minutes & about 2Gb RAM) in CP2K_gcc_2007_06/src as: gfortran -fwhole-file -O0 all.f90 -llapack -lblas this leads to undefined references to: /tmp/ccSrltD0.o: In function `__fft_tools_MOD_fft3d_pb': all.f90:(.text+0xb1c61): undefined reference to `fft_1dm_' all.f90:(.text+0xb2824): undefined reference to `fft_1dm_' all.f90:(.text+0xb33f7): undefined reference to `fft_1dm_' all.f90:(.text+0xb4227): undefined reference to `fft_1dm_' all.f90:(.text+0xb4dea): undefined reference to `fft_1dm_' /tmp/ccSrltD0.o:all.f90:(.text+0xb5984): more undefined references to `fft_1dm_' follow /tmp/ccSrltD0.o: In function `mltfftsg_': all.f90:(.text+0xdbb41a): undefined reference to `ctrig_' all.f90:(.text+0xdbb895): undefined reference to `fftpre_' all.f90:(.text+0xdbb95b): undefined reference to `fftstp_' all.f90:(.text+0xdbbd14): undefined reference to `fftstp_' all.f90:(.text+0xdbbe5c): undefined reference to `fftrot_' all.f90:(.text+0xdbbf64): undefined reference to `fftstp_' but goes fine without the '-fwhole-file'. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40011