premake / premake/premake-core

Supporting Win32 and WinRT platforms for the same project

Open
#1,653 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

I'm using the WinRT platform module found here to support both Win32 and Universal Windows for the same project. To choose between them I filter through them like

filter "platforms:Win64"
system "Windows"

and

filter "platforms:XboxOne"
system "WindowsUniversal"

The problem is when I run the premake script the platform is permanently set to Universal Windows in Visual Studio until I comment out the filter "platforms:XboxOne" filter. So my question is: Is this a bug in premake or the module? Or is it not possible to switch between these two platforms in Visual Studio? It would be great to be able to simply switch the platforms in the VS editor to compile for the two different platforms instead of possibly having to comment out code or run premake again. If it's not possible, does anyone have any suggestions for handling multiple platforms like this in premake?

Platform: Windows 10
Premake version: 5.0.0-alpha16-windows
Visual Studio version: 2019

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 with the premake script and the linked premake-winrt module, then inspect the generated Visual Studio 2019 project for the Win32 and WinRT platform definitions. Reproduce the behavior on Windows 10 with Premake 5.0.0-alpha16 and check whether both platforms can be selected in Visual Studio. No specific source file or test is named; done means identifying the responsible component or documenting the platform limitation.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, lua
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.