premake / premake/premake-core

Support additional non-build tasks in generated projects

Open
#714 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement gmake
Dominant language
C
Stars
3.6k
Forks
654
Avg merge
1d 1h
Merged PRs (30d)
13

Description

Hello, I appreciate premake developers. I am a kernel developer, and our projects have been changed to use premake instead of pure makefiles.

There are many build-unrelated things by Makefile in our projects such as running image buidling script, debugging script, generating documents, running QEMU and so on. Before, we just make it phony target for these uses.

I ran into several problems for making just newaction syntax for them.

  1. "premake5 doc" is rather unfamiliar with common users as compared with "make doc". Although it is trivial and controversial for each people, I think seamless integration with Makefile looks better.

  2. newaction syntax can be added only for structured premake.lua. If I have several premake.lua files in sub projects and root premake.lua includes them, I could not run newaction in sub folder tree. (It can be executed only in root project folder.

  3. Phony target has dependency of pre-build target, and Makefile is for that. For example, debugging or testing is only effective after binary made.

For those reasons, I think phony target is required for premake. I am afraid of those kind of problem comes from my misunderstanding of premake. So any kind of negative feedback also appreciated. Thanks.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing Premake's newaction syntax and how root premake.lua files include subprojects. Compare the requested behavior with the existing Makefile phony targets, including dependencies on pre-build targets and commands such as documentation generation, debugging, testing, and QEMU. Done would require a decided scope for supporting these non-build tasks and their dependencies.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, lua
Domain
build-system, tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.