Try to create new project with INET reference, got : "unexpected NAME, expecting $end" in .msg file
Asked Answered
M

1

5

I created a project which contains my linklayer and simulation source code. This project has INET as the project reference.

At build time, I got this error:

Error: syntax error, unexpected NAME, expecting $end

It comes from the message file (which contains types of messages):

import inet.common.INETDefs;

My message file is very similar to the Bmac message file (also tried with Bmac, got the same error).

Any idea please?

Mancini answered 6/5, 2019 at 12:55 Comment(0)
C
6

INET 4.X uses a new version of message compiler. But OMNeT++ by default sets in new project the old one.
In your project go to Properties, select OMNeT++ | Makemake | src folder | Options... | Custom and add the following line:

MSGC:=$(MSGC) --msg6
Custombuilt answered 6/5, 2019 at 15:30 Comment(1)
Thank you, I'm facing other errors : cannot resolve import 'inet.common.INETDefs' cannot resolve import 'inet.linklayer.base.MacHeaderBase It comes from : import inet.common.INETDefs; import inet.linklayer.base.MacHeaderBase; Knowing that INET is the project reference, I have no more idea...Mancini

© 2022 - 2024 — McMap. All rights reserved.