#1 2016-12-21 10:46:18

reddwarf
Member
Registered: 2010-06-28
Posts: 40
Website

mORMot and current FPC trunk doesn't work

When initializing mORMot with current FPC trunk the following exception is raised:

[Debugger Exception Notification]

Project Server raised exception class 'ESynException' with message:
TJSONRecordTextDefinition.Create: TSynMapSymbol text definition is not accurate, or the type has not been defined as PACKED record: RTTI size is 7735812 bytes but text definition generated 12 bytes

In file '..\..\units\SynCommons.pas' at line 38490

Backtrace:

#0 fpc_raiseexception(0x760a28, 0x1, 0x18655f8) at ..\inc\except.inc:158
#1 CREATE(0x18655f8, 0x1, 0x760a28, 0x760948 'Name:RawUTF8 Start,Stop:integer') at ..\..\units\SynCommons.pas:38490
#2 FROMCACHE(0x754994, 0x760a28, 0x760948 'Name:RawUTF8 Start,Stop:integer') at ..\..\units\SynCommons.pas:38471
#3 REGISTERFROMTEXT(0x180a920, 0x760a28, 0x760948 'Name:RawUTF8 Start,Stop:integer') at ..\..\units\SynCommons.pas:37428
#4 REGISTERCUSTOMJSONSERIALIZERFROMTEXT(0x754650, {}, 3) at ..\..\units\SynCommons.pas:46831
#5 SYNLOG_$$_init at :5500
#6 fpc_initializeunits at ..\inc\system.inc:914
#7 main at Server.lpr:16

This issue was opened somewhere in revisions 35123-35128 by svenbarth, which basically were patches by Maciej Izak for http://mantis.freepascal.org/view.php?id=30687.

Any chance to get this working?

+ SynSSPI.pas doesn't compile in FPC either (easy to fix: semicolons are missing).

Offline

#2 2016-12-21 11:42:55

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,231
Website

Re: mORMot and current FPC trunk doesn't work

SynSSPI compilation should be fixed by http://synopse.info/fossil/info/0afb1b7cd7

About RTTI, I do not know the current state of the trunk...
It is a very moving/unstable area.
I'm currently using a NewPascal build from a few days ago, with no problem.

Online

#3 2016-12-21 22:10:59

hnb
Member
Registered: 2015-06-15
Posts: 291

Re: mORMot and current FPC trunk doesn't work

At the moment we need to wait - I am working with Sven from FPC core team on some important changes for RTTI (few notes : http://synopse.info/forum/viewtopic.php?id=3689 ). mORMot will be updated too, but it has not much sense at the moment. Generally for mORMot NewPascal is recommended. If for some reasons you like to use "pure FPC trunk" the latest stable and recommended for mORMot is r35095 (pre RTTI.pas). Latest NewPascal (v1.0.39) is synced with r35095.

TLTR: For mORMot users I see 2 options:

* use NewPascal (for latest fresh stuff) instead of FPC trunk otherwise you will have many troubles tongue
* use latest stable FPC 3.0.x (older FPC stable like 2.6.x means also many troubles)


best regards,
Maciej Izak

Offline

#4 2016-12-21 22:29:32

reddwarf
Member
Registered: 2010-06-28
Posts: 40
Website

Re: mORMot and current FPC trunk doesn't work

Thanks for the info! I'll stick with r35095 for now.

Offline

#5 2017-01-31 02:45:40

Vitaly
Member
From: UAE
Registered: 2017-01-31
Posts: 168
Website

Re: mORMot and current FPC trunk doesn't work

hnb wrote:

At the moment we need to wait

The problem becomes very actual for me. Is there any hope that it will be solved soon?

Last edited by Vitaly (2017-01-31 02:45:55)

Offline

#6 2017-01-31 11:19:22

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

Re: mORMot and current FPC trunk doesn't work

@Vitaly
Why not use NewPascal ? That is trunk !

Offline

#7 2017-01-31 12:24:37

hnb
Member
Registered: 2015-06-15
Posts: 291

Re: mORMot and current FPC trunk doesn't work

AOG is right. Usage of pure FPC trunk for mORMot has no sense and is extremely risky. I have special version of mORMot which is *almost* ready and compatible both with current FPC trunk and with next NewPascal release:

https://github.com/maciej-izak/mORMot/tree/fpc_newrtti

The branch of mORMot is incomplete yet (we have some serious bug around - and ready to use by FPC core team related patch):

http://bugs.freepascal.org/view.php?id=31249
http://bugs.freepascal.org/view.php?id=31305

#31249 will be fixed directly in NewPascal (or even in FPC trunk).

Last edited by hnb (2017-01-31 14:01:13)


best regards,
Maciej Izak

Offline

#8 2017-01-31 15:31:43

Vitaly
Member
From: UAE
Registered: 2017-01-31
Posts: 168
Website

Re: mORMot and current FPC trunk doesn't work

AOG wrote:

@Vitaly
Why not use NewPascal ? That is trunk !

I use CT. Unfortunately, It uses fpc trunk. Everything was ok before yesterday's CT 6.0 release.

Offline

#9 2017-01-31 16:15:11

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

Re: mORMot and current FPC trunk doesn't work

You can use fpcupdeluxe to install only NewPascal FPC.
Then point CT towards this FPC.

Offline

#10 2017-01-31 17:07:22

Vitaly
Member
From: UAE
Registered: 2017-01-31
Posts: 168
Website

Re: mORMot and current FPC trunk doesn't work

hnb wrote:

I have special version of mORMot which is *almost* ready and compatible both with current FPC trunk and with next NewPascal release:

https://github.com/maciej-izak/mORMot/tree/fpc_newrtti

Thank you very much! Your special mORMot version seems workable for me.

Offline

#11 2017-01-31 17:13:42

Vitaly
Member
From: UAE
Registered: 2017-01-31
Posts: 168
Website

Re: mORMot and current FPC trunk doesn't work

AOG wrote:

You can use fpcupdeluxe to install only NewPascal FPC.
Then point CT towards this FPC.

Thank you, I'll try it. Can you prompt me how to "point CT towards this FPC" correctly?

Offline

Board footer

Powered by FluxBB