#1 2019-06-18 01:18:30

sstillwell
Member
From: Kansas City, MO, USA
Registered: 2019-06-18
Posts: 27

Build mORMot on current macOS

I must be missing something, but I cannot get mORMot to compile for love nor money.  I've tried using the current release/download version of Lazarus+FPC (2.0.2+3.0.4), and I've tried using fpcupdeluxe to pull various versions including TRUNK, 2_0_FIXES / 3_0_FIXES, 3.1, 2.1, ad nauseam.  Either I get a build error building Lazarus (FPC seems to build okay regardless of chosen version), or if I can get Lazarus to build, mORMot fails to build.

Using macOS Mojave 10.14.6 with either Xcode 9.2 or 10.2 and Command Line Tools installed.

Offline

#2 2019-06-18 04:12:24

sstillwell
Member
From: Kansas City, MO, USA
Registered: 2019-06-18
Posts: 27

Re: Build mORMot on current macOS

For what it's worth, my current attempt is based on this:

ab wrote:

For our production work, we picked up "preferred" revisions for FPC / Lazarus trunk, which are currently:
- FPC trunk SVN 40491
- Lazarus trunk SVN 59757

We enter those SVN revisions when building our own FPC + Lazarus, using https://github.com/newpascal/fpcupdelux … ses/latest
Just click on the "Setup +" button and enter above numbers before building.

It builds successfully (both FPC and Lazarus), but compiling marmot_base.lpk gives two errors error in SynFPCTypInfo.pas (119,31) and (175,21) Error: Identifier not found "AlignTypeData".

Trying to clone the build-fpc-linux64.sh for darwin just yields a:

./build-fpc-darwin64.sh
Free Pascal Compiler version 3.0.4 [2018/09/30] for x86_64
Copyright (c) 1993-2017 by Florian Klaempfl and others
Target OS: Darwin for x86_64
Compiling ./SQLite3/TestSQL3.dpr
SynDprUses.inc(26,9) Fatal: Can't find unit iosxwstr used by TestSQL3
Fatal: Compilation aborted
Error: /usr/local/bin/ppcx64 returned an error exitcode.

I know I'm grasping, but the documentation I've found so far doesn't go very in-depth on build and installation.

Thanks in advance for any help...it's been quite a while since I was involved in Pascal...actually I think the last version I used for production work was actually Turbo Pascal for DOS.  I had some old Windows versions, but those may have predated Delphi.  Too many years ago to remember. smile

Offline

#3 2019-06-18 05:17:19

AOG
Member
Registered: 2014-02-24
Posts: 490

Re: Build mORMot on current macOS

Using latest trunk/trunk (by fpcupdeluxe) on Mac 10.14, the latest mORMot builds ok (TestSQL3.lpi).
And runs reasonable (except for "Service Oriented Architecture").

Offline

#4 2019-06-18 06:30:30

sstillwell
Member
From: Kansas City, MO, USA
Registered: 2019-06-18
Posts: 27

Re: Build mORMot on current macOS

AOG wrote:

Using latest trunk/trunk (by fpcupdeluxe) on Mac 10.14, the latest mORMot builds ok (TestSQL3.lpi).
And runs reasonable (except for "Service Oriented Architecture").

If I open that project and compile I get:

Compile Project, Mode: default, Target: fps/bin/x86_64-darwin/TestSQL3: Exit code 256, Errors: 1
SynDprUses.inc(26,9) Fatal: Cannot find ioswxstr used by TestSQL3.

Can I ask where it's documented that this is the project you're supposed to build for everything?  I was trying to build the packages (.lpk) and getting nowhere.

Thanks for the answer...I do appreciate it.

EDIT: Oh, I forgot...for me, trunk/trunk does not build in fpcupdeluxe...FPC builds, but Lazarus will not...there's a link error.

Last edited by sstillwell (2019-06-18 06:31:44)

Offline

#5 2019-06-18 06:54:06

sstillwell
Member
From: Kansas City, MO, USA
Registered: 2019-06-18
Posts: 27

Re: Build mORMot on current macOS

Yep, trunk/trunk doesn't build for me in fpcupdeluxe...

fpcupdeluxe: Performing a SVN/GIT/HG checkout ... please wait, could take some time.
fpcupdeluxe: info: FPC native builder: Detected source version FPC: 3.3.1
fpcupdeluxe: info: FPC native builder: Using FPC bootstrap compiler with version: 3.0.4
fpcupdeluxe: Performing a SVN/GIT/HG checkout ... please wait, could take some time.
fpcupdeluxe: info: Lazarus native builder: Detected source version Lazarus: 2.1.0
fpcupdeluxe: info: Lazarus native builder: Using FPC compiler with version: 3.3.1
fpcupdeluxe: Start of compile error summary.
Error: Error while linking
fpcupdeluxe: Start of compile error summary.
Fatal: There were 1 errors compiling module, stopping
Error: Error while linking
fpcupdeluxe: Start of compile error summary.
Fatal: Compilation aborted
Fatal: There were 1 errors compiling module, stopping
fpcupdeluxe: Start of compile error summary.
Error: /Users/scott/fpcupdeluxe/fpc/bin/x86_64-darwin/ppcx64 returned an error exitcode
fpcupdeluxe: Start of compile error summary.
Error: Error while linking
fpcupdeluxe: Start of compile error summary.
Fatal: There were 1 errors compiling module, stopping
Error: Error while linking
fpcupdeluxe: Start of compile error summary.
Fatal: Compilation aborted
Fatal: There were 1 errors compiling module, stopping
fpcupdeluxe: Start of compile error summary.
Error: /Users/scott/fpcupdeluxe/fpc/bin/x86_64-darwin/ppcx64 returned an error exitcode
fpcupdeluxe: Start of compile error summary.
fpcupdeluxe: ERROR: LazarusNativeInstaller (BuildModuleCustom: Lazbuild): make returned error code #512
fpcupdeluxe: Done !!

I've captured the big build log as well - looks like the link error references something down inside the Xcode Command Line Tools.

Offline

#6 2019-06-18 07:36:34

sstillwell
Member
From: Kansas City, MO, USA
Registered: 2019-06-18
Posts: 27

Re: Build mORMot on current macOS

Looks like it was the version of Xcode Command Line Tools that was the problem.  It was set to Xcode 9.2 (9C40b) and when I changed it to Xcode 10.2.1 (10E1001) I was able to build trunk on FPC and Lazarus, and TestSQL3.lpi builds successfully.

NOW maybe I can start looking at example projects and wrapping my head around it.

Thanks!

Offline

Board footer

Powered by FluxBB