Skip to content

Use dir instead of ls on Windows#72

Closed
mniak wants to merge 1 commit intopure-data:masterfrom
mniak:mniak-patch-1
Closed

Use dir instead of ls on Windows#72
mniak wants to merge 1 commit intopure-data:masterfrom
mniak:mniak-patch-1

Conversation

@mniak
Copy link

@mniak mniak commented May 29, 2022

No description provided.

@danomatika
Copy link
Contributor

Another approach would be to use a Makefile variable:

# command defaults ala CC=... etc
LS=ls

# main platform detection section...
ifeq ($(system), Windows)
    ...
    LS=dir
...

# store path to Pd API m_pd.h if it is found
 ifdef PDINCLUDEDIR
   mpdh := $(shell $(LS) "$(PDINCLUDEDIR)/m_pd.h")

...

@umlaeute
Copy link
Contributor

umlaeute commented Jun 9, 2022

as mentioned in the original issue (and to add more opinions here):

i figure, pd-lib-builder targets MinGW/MSYS environments (on Windows), where MSYS should provide ls (so the problem really seems to be an edge-case: many people are using pd-lib-builder on Windows without a problem).

however, i wonder why we can't use a Make-builtin instead of using external programs, e.g. a simple $(wildcard "$(PDINCLUDEDIR)/m_pd.h") (on all platforms).

@danomatika
Copy link
Contributor

danomatika commented Jun 9, 2022 via email

@mniak mniak closed this by deleting the head repository May 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants