From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19912 invoked by alias); 13 May 2015 22:41:12 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 19904 invoked by uid 89); 13 May 2015 22:41:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=3.4 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2 X-HELO: carsmail2.cars.aps.anl.gov Received: from carsmail2.cars.aps.anl.gov (HELO carsmail2.cars.aps.anl.gov) (164.54.162.47) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Wed, 13 May 2015 22:41:11 +0000 Received: from CARSMAIL2.CARS.APS.ANL.GOV ([fe80::4897:547a:21eb:898b]) by CARSMAIL2.CARS.APS.ANL.GOV ([fe80::4897:547a:21eb:898b%15]) with mapi id 14.03.0224.002; Wed, 13 May 2015 17:41:08 -0500 From: Mark Rivers To: "'cygwin@cygwin.com'" Subject: Problem linking with an import library (.lib) file: Date: Wed, 13 May 2015 23:38:00 -0000 Message-ID: <70AE7462E7AD054C89DCBA45343D499A65860EBD@CARSMAIL2.CARS.APS.ANL.GOV> References: <70AE7462E7AD054C89DCBA45343D499A65860E12@CARSMAIL2.CARS.APS.ANL.GOV> In-Reply-To: <70AE7462E7AD054C89DCBA45343D499A65860E12@CARSMAIL2.CARS.APS.ANL.GOV> Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-SW-Source: 2015-05/txt/msg00151.txt.bz2 Folks, I am having trouble linking with a normal Windows import library file when = creating a DLL on Cygwin.=A0 These same import libraries worked fine when c= reating static Cygwin executables with older versions of Cygwin. The error is: "error adding symbols: File in wrong format". This is an example of the error (I have reformatted the long g++ command on= to multiple lines to make it more legible): $ make make -C O.cygwin-x86 -f ../Makefile TOP=3D../../.. \ =A0=A0=A0 T_A=3Dcygwin-x86 install make[1]: Entering directory '/cygdrive/j/epics/devel/dxp/dxpApp/handelSrc/O= .cygwin-x86' g++ -o handel.dll -shared -Wl,--out-implib,handel.lib -L/cygdrive/j/epics/d= evel/dxp/lib/cygwin-x86=20 -L/cygdrive/h/epics/base-3.14.12.5/lib/cygwin-x86=A0=A0=A0=A0=A0=A0=A0 = -m32=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 xerxes.o xerxes_log.o md_log.o handel.o fdd.o psl.o handel_dbg.o handel= _detchan.o handel_dyn_default.o=20 handel_dyn_detector.o handel_dyn_firmware.o handel_dyn_module.o handel_= file.o handel_log.o handel_memdbg_win32.o=20 handel_run_control.o handel_run_params.o handel_sort.o handel_system.o = handel_xerxes.o xia_assert.o xia_file.o=20 xia_mem.o xia_mem_point.o saturn.o saturn_psl.o xmap.o xmap_psl.o mercu= ry.o mercury_psl.o xia_epp.o xia_plx.o=20 xia_usb.o xia_usb2.o md_win32.o=A0=A0=A0=20 -lrecIoc -lsoftDevIoc -lmiscIoc -lrsrvIoc -ldbtoolsIoc -lasIoc -ldbIoc = -lregistryIoc -ldbStaticIoc -lca -lCom -lDLPORTIO -lPlxApi=A0 -lsetupapi -= lUser32 -lpthread=A0=A0=A0 -lm /cygdrive/j/epics/devel/dxp/lib/cygwin-x86/PlxApi.lib: error adding symbols= : File in wrong format collect2: error: ld returned 1 exit status /corvette/usr/local/epics/base-3.14.12.5/configure/RULES_BUILD:300: recipe = for target 'handel.dll' failed make[1]: *** [handel.dll] Error 1 make[1]: Leaving directory '/cygdrive/j/epics/devel/dxp/dxpApp/handelSrc/O.= cygwin-x86' /corvette/usr/local/epics/base-3.14.12.5/configure/RULES_ARCHS:64: recipe f= or target 'install.cygwin-x86' failed make: *** [install.cygwin-x86] Error 2 So it is complaining that the library PlxApi.lib is not in the correct form= at.=A0 However, this is definitely a valid Windows import library file. Thanks, Mark Rivers -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple