Pull requests

#78 Declined
Repository
triton/premake-cs-fixes premake-cs-fixes
Branch
cs-translate
Repository
premake/premake-dev premake-dev
Branch
default

Fixed C# Make files in OSX by translating the source files path.

Author
  1. João Matos
Reviewers
Description

Hey Jason, so there are some problems in OSX C# Makefiles, they fail because of some path issues. Is this the correct way to go about fixing the issue?

Comments (3)

  1. Jason Perkins

    No this isn't correct, and will break the Visual Studio exporters. How did the paths become incorrect in the first place? They should always be specified with forward slashes.

    1. Jason Filsinger

      I think the problem is cs.listsources calls path.translate which defaults to using double backslashes if no path delimiter is specified. Replacing path.translate(value) with path.translate(value, '/') inside cs.listsources should fix the problem.

      1. Jason Perkins

        I think this the cause, yes. Right solution would be to remove the call to translate entirely, as paths should already be using forward slashes. Or wrap it with something like:

        if _OS == premake.WINDOWS then value = path.translate(value) end
        

        But I think the forward slashes should work?