Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2016-01

FPC 3.0.0 on OSX 10.6.8 32bit Compile problem

7 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Unknown author

Hi

I have been trying to get laz 1.6 rc2 on mac osx 10.6.8, I can instal 1.4.4 FPC 2.6.4; without problem. I have run the uninstall script and attempted 1.6rc2, when I try to rebuild Lazarus, or add a component that requires a rebuild I get the below error I have googled fistpq, and found that this is 64bit related.

Any ideas

Josh

Hint: (11030) Start of reading config file /etc/fpc.cfg Hint: (11031) End of reading config file /etc/fpc.cfg Free Pascal Compiler version 3.0.0 [2015/11/14] for i386 Copyright (c) 1993-2015 by Florian Klaempfl and others (1002) Target OS: Darwin for i386
Free Pascal Compiler version 3.0.0 [2015/11/14] for i386 Copyright (c) 1993-2015 by Florian Klaempfl and others (1002) Target OS: Darwin for i386
(3104) Compiling alllclunits.pp
(3104) Compiling lclproc.pas
<stdin>:4284:2: error: invalid instruction mnemonic 'fistpq' fistpq -12(%ebp)
^~~~~~
<stdin>:4303:2: error: invalid instruction mnemonic 'fistpq' fistpq -12(%ebp)
^~~~~~
<stdin>:4326:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:4350:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
(9001) Assembling (pipe) /Developer/lazarus/lcl/units/i386-darwin/lclproc.s lclproc.pas(3221) Fatal: (10026) There were 1 errors compiling module, stopping Fatal: (1018) Compilation aborted

Reply by email

Jonas Maebe
to Unknown author
Show quoted text 6 lines
I have been trying to get laz 1.6 rc2 on mac osx 10.6.8, I can instal 1.4.4 FPC 2.6.4; without problem. I have run the uninstall script and attempted 1.6rc2, when I try to rebuild Lazarus, or add a component that requires a rebuild I get the below error I have googled fistpq, and found that this is 64bit related.

FPC 3.0 switched to using Clang by default as assembler, because the old assembler is no longer supported with newer Xcode versions. Normally, that should work fine under Mac OS X 10.6.8 too, as I tested that as well. In case I missed something, you can switch back to using the old assembler with the FPC command line parameter -Aas-darwin.

Jonas

Reply by email

Jonas Maebe
to Jonas Maebe
Jonas Maebe wrote 13 lines
wrote: > I have been trying to get laz 1.6 rc2 on mac osx 10.6.8, I can instal > 1.4.4 FPC 2.6.4; without problem. > I have run the uninstall script and attempted 1.6rc2, when I try to > rebuild Lazarus, or add a component that requires a rebuild I get the > below error > I have googled fistpq, and found that this is 64bit related. FPC 3.0 switched to using Clang by default as assembler, because the old assembler is no longer supported with newer Xcode versions. Normally, that should work fine under Mac OS X 10.6.8 too, as I tested that as well. In case I missed something, you can switch back to using the old assembler with the FPC command line parameter -Aas-darwin.

Also, which version of Xcode do you have installed? Have you tried with the latest version of Xcode available for Mac OS X 10.6.8? (Xcode 3.2.6, IIRC)

Jonas

Reply by email

Unknown author
to Jonas Maebe

Hi Jonas Maebe,

Yes using the latest xcode for 10.6.8

Sorry to sound stupid, how do I add -Aas-darwin
to the compiler for lazarus so it can rebuild ok.

Josh

Jonas Maebe wrote 13 lines
wrote: > I have been trying to get laz 1.6 rc2 on mac osx 10.6.8, I can instal > 1.4.4 FPC 2.6.4; without problem. > I have run the uninstall script and attempted 1.6rc2, when I try to > rebuild Lazarus, or add a component that requires a rebuild I get the > below error > I have googled fistpq, and found that this is 64bit related. FPC 3.0 switched to using Clang by default as assembler, because the old assembler is no longer supported with newer Xcode versions. Normally, that should work fine under Mac OS X 10.6.8 too, as I tested that as well. In case I missed something, you can switch back to using the old assembler with the FPC command line parameter -Aas-darwin.

Also, which version of Xcode do you have installed? Have you tried with the latest version of Xcode available for Mac OS X 10.6.8? (Xcode 3.2.6, IIRC)

Jonas

Reply by email

Unknown author
to Unknown author

After setting the -Aaa-darwin flag It progresses further, but now stops here

1010) Writing Resource String Table file: uPSRuntime.rsj <stdin>:3687:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:8518:2: error: invalid instruction mnemonic 'fistpq' fistpq -12(%ebp)
^~~~~~
<stdin>:8936:2: error: invalid instruction mnemonic 'fistpq' fistpq -12(%ebp)
^~~~~~
<stdin>:10178:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10189:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10200:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10211:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10223:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10232:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10241:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10249:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10257:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10266:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:10280:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
<stdin>:11146:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:11372:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:11549:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:11983:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:15014:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:20147:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:20162:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:20177:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:20192:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:20206:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:20219:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:20230:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:20242:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:20254:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ebx)
^~~~~~
<stdin>:20267:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:20277:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:20295:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:21287:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:21302:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:21317:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:21332:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:21346:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:21359:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:21370:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:21382:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:21394:2: error: invalid instruction mnemonic 'fistpq' fistpq (%edx)
^~~~~~
<stdin>:21407:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:21417:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:21435:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22402:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22420:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22438:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22456:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22470:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:22486:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22497:2: error: invalid instruction mnemonic 'fistpq' fistpq (%ecx)
^~~~~~
<stdin>:22512:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22527:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22543:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22556:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:22574:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:23928:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:23946:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:23964:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:23982:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:23996:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:24012:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:24023:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:24038:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:24053:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:24069:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:24082:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:24100:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:27813:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:35408:2: error: invalid instruction mnemonic 'fistpq' fistpq -128(%ebp)
^~~~~~
<stdin>:35424:2: error: invalid instruction mnemonic 'fistpq' fistpq -136(%ebp)
^~~~~~
<stdin>:40599:2: error: invalid instruction mnemonic 'fistpq' fistpq (%eax)
^~~~~~
<stdin>:52819:2: error: invalid instruction mnemonic 'fistpq' fistpq -16(%ebp)
^~~~~~
(9001) Assembling (pipe)
/Developer/lazarus/components/PascalScript/Source/lib/i386-darwin/uPSRuntime.s uPSRuntime.pas(12733) Fatal: (10026) There were 1 errors compiling module, stopping
Fatal: (1018) Compilation aborted

Jonas Maebe wrote 12 lines
> I have been trying to get laz 1.6 rc2 on mac osx 10.6.8, I can instal > 1.4.4 FPC 2.6.4; without problem. > I have run the uninstall script and attempted 1.6rc2, when I try to > rebuild Lazarus, or add a component that requires a rebuild I get the > below error > I have googled fistpq, and found that this is 64bit related. FPC 3.0 switched to using Clang by default as assembler, because the old assembler is no longer supported with newer Xcode versions. Normally, that should work fine under Mac OS X 10.6.8 too, as I tested that as well. In case I missed something, you can switch back to using the old assembler with the FPC command line parameter -Aas-darwin.

Also, which version of Xcode do you have installed? Have you tried with the latest version of Xcode available for Mac OS X 10.6.8? (Xcode 3.2.6, IIRC)

Jonas

Reply by email

Jonas Maebe
to Unknown author: Yes using the latest xcode for 10.6.8 Sorry to sound stupid, how do I add -Aas-darwin to…

info wrote on Sun, 17 Jan 2016:

Yes using the latest xcode for 10.6.8

What does "clang --version" show? It should be "Apple clang version 1.6 (tags/Apple/clang-70)" or newer. I just tried again and my Xcode (3.2.5) clang under 10.6.8 does accept the fistpq instructions.

If you have an older version, try running "xcode-select -print-path" to see from which Xcode installation directory the command line tools are taken. Maybe you have multiple versions installed. You can switch the command line tools to use a different version via "xcode-select -switch xcode_folder_path")

Jonas

PS: instead of (re)building all of lazarus, you should be able to use the following test program on the command line (fpc test.pas) to determine whether or not the issue is resolved:

var
   e: extended;
   i: int64;
begin
   e:=123456.67;
   i:=round(e);
   writeln(i);
end.

Reply by email