[fpc-pascal] fpc2.6.4 compilation problem

Tomas Hajny XHajT03 at hajny.biz
Sun Jan 11 13:35:42 CET 2015

On Sun, January 11, 2015 12:43, Schindler Karl-Michael wrote:

Hello Michael,

The original poster is apparently not subscribed to the list (although he
forgot to mention this fact in his post) - adding him. In Cc: now so that
he could see your response).


> Am 11.01.2015 um 12:00 schrieb fpc-pascal-request at lists.freepascal.org:
>> Message: 4
>> Date: Sat, 10 Jan 2015 16:48:52 +0000 (UTC)
>> From: Vahe Sahakyan <vahe.sahakyan at yahoo.com>
>> To: "fpc-pascal at lists.freepascal.org"
>> 	<fpc-pascal at lists.freepascal.org>
>> Subject: [fpc-pascal] fpc2.6.4 compilation problem
>> Message-ID:
>> 	<238177706.217828.1420908532346.JavaMail.yahoo at jws10688.mail.bf1.yahoo.com>
>> Content-Type: text/plain; charset="utf-8"
>> Hello,
>> I have some difficulties to compile my PASCAL code with
>> external?subroutine in FORTRAN on MAC OS X Yosemite 10.10.1 using fpc
>> 2.6.4.
>> The problem is the following: I need to run the program in
>> Pascal?containing the external procedure in FORTRAN which uses the
>> standard?CERNLIB packages such as libpacklib. ?
>> In the attached please find the code in PASCAL (as an example)
>> with?external procedure on FORTRAN which I?m training to compile. The
>> names?of these two programs are: ?exmppas.p? ?and ?exmpfrt.f?, and
>> for?compilation I'm using the following commands:
>> $ gfortran -c exmpfrt.f$ fpc exmppas.p -Fl/sw/lib/gcc4.9/lib
>> where with the -Fl/sw/lib/gcc4.9/lib I link the required libraries
>> which?I use in my code. But I get the following error:?Free Pascal
>> Compiler version 2.6.4 [2015/01/09] for x86_64Copyright (c) 1993-2014 by
>> Florian Klaempfl and othersTarget OS: Darwin for x86_64Compiling
>> exmppas.pAssembling (pipe) exmppas.sLinking exemptsUndefined symbols for
>> architecture x86_64:? "___powisf2", referenced from:? ? ? _hbin_ in
>> libpacklib.a(hbin.o)ld: symbol(s) not found for architecture x86_64An
>> error occurred while linking?exmppas.p(15) Error: Error while
>> linkingexmppas.p(15) Fatal: There were 1 errors compiling module,
>> stoppingFatal: Compilation abortedError: /sw/bin/ppcx64 returned an
>> error exitcode (normal if you did not specify a source file to be
>> compiled)
>> I'm using fpc 2.4.6.Please note I have tried the same things on MAC OS X
>> Maverick 10.9.5?using fpc 2.4.0 and it works without any problems .
>> I cannot figure out what is the problem. My be in this new version
>> for?linking libraries I should use another command or I have done
>> mistake?somewhere else?Can someone help to solve the problems?
>> Thank you in advance.Best regards,Vahe
> As much as I know, the missing symbol ___powisf2 is part of the fortran
> library, libgfortran, which should be in /sw/lib/gcc4.9/lib/. Maybe check,
> whether this is really the case.
> Secondly, how does the linker get the information to link libgfortran?
> Through a linklib directive? If not, you may have to use the fpc options
> "-k -lgfortran" to pass the information to the linker.
> Passing -vt or even -va will give you further (in case of -va a huge
> amount) of information building your program. I do not expect any
> difference between 2.4.0 and 2.6.*. I am using 2.6.4 on 10.9 in
> combination with gfortran and it works well.
> Michael.
> P.S. can you somehow achieve, to send a plain text email. The way you did
> it results in a very hard to read output.
> _______________________________________________
> fpc-pascal maillist  -  fpc-pascal at lists.freepascal.org
> http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

More information about the fpc-pascal mailing list