Ioana
Ioana

Reputation: 67

# Error: VLM_0040: VHDL unit cannot be compiled as the target library name is not a legal VHDL identifier

It seems that i have some problems with the Activ-HDL student edition. When I want to compile the following error appears:

# Error: VLM_0040: VHDL unit cannot be compiled as the target library name is not a legal VHDL identifier.

I don't know why because yesterday I installed it and today I have this error. Can someone help me.

Upvotes: 1

Views: 4613

Answers (2)

joosteto
joosteto

Reputation: 198

To add to the (correct) answer above: the name of the library that your sources are added to is shown in the Design Browser below "Add New Library" (see image, where the library is called "hy-phen"). This name can be changed by clicking "Add new Library". By right-clicking the new library you can set it as active. Now the source code should compile into the new library (without renaming the whole Active-HDL design).

library named "hy-phen"

After setting the new library as active, the old one (with the invalid name) can be detached from the project (by right-clicking on it).

Upvotes: 0

favvvvvvv
favvvvvvv

Reputation: 41

As far as I understand, when you compile your sources they are added to a library that has the same name as your Active-HDL design, and, as the error message suggests, if that name doesn't fall under VHDL identifier naming conventions you get the aforementioned error.

To give your design a proper name you should follow several simple rules:

  • Names (or identifiers) may consist of letters, numbers and underscore.
  • Names must start with a letter.
  • None of the VHDL keywords (i.e. signal, bus, component, wait, etc.) may be reused as a name.

Upvotes: 4

Related Questions