Skip to content
This repository was archived by the owner on Mar 20, 2023. It is now read-only.

Use of DELETE_ON_ERROR for generating mod files#423

Merged
pramodk merged 1 commit into
masterfrom
DELETE_ON_ERROR
Nov 12, 2020
Merged

Use of DELETE_ON_ERROR for generating mod files#423
pramodk merged 1 commit into
masterfrom
DELETE_ON_ERROR

Conversation

@alkino

@alkino alkino commented Nov 12, 2020

Copy link
Copy Markdown
Member

If mod2c fail, the file is generated but empty, because of that they are
not generated again and it fails later in a complicated way

If mod2c fail, the file is generated but empty, because of that they are
not generated again and it fails later in a complicated way
$(VERBOSE).SILENT:

# delete cpp files if mod2c error, otherwise they are not generated again
.DELETE_ON_ERROR:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.DELETE_ON_ERROR
If .DELETE_ON_ERROR is mentioned as a target anywhere in the makefile, then make will delete the target of a rule if it has changed and its recipe exits with a nonzero exit status, just as it does when it receives a signal. 

Never used this before! ⭐ Does this work as expected?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes ;) Works like a charm.

@alkino

alkino commented Nov 12, 2020

Copy link
Copy Markdown
Member Author

Please retest

@pramodk

pramodk commented Nov 12, 2020

Copy link
Copy Markdown
Collaborator

Ignoring Travis as it's almost dead.

@pramodk pramodk merged commit 5322b1e into master Nov 12, 2020
@pramodk pramodk deleted the DELETE_ON_ERROR branch November 12, 2020 22:06
pramodk pushed a commit to neuronsimulator/nrn that referenced this pull request Nov 2, 2022
…#423)

- If mod2c fail, the file is generated but empty, because of that
   they are not generated again and it fails later in a complicated way.

CoreNEURON Repo SHA: BlueBrain/CoreNeuron@5322b1e
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants