You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The 2>NUL is there because if you search for files that dont exist, dir will output a File not found error. So if you called make clean twice in a row it would output a bunch of File not founds.
This PR introduces a findfiles function that is a recursive version of the makefiles wildcard function. findfiles=$(foreach d,$(wildcard $(addsuffix *,$(1))),$(call findfiles,$(d)/,$(2)) $(filter $(subst *,%,$(2)),$(d)))
This PR also excludes the generaton of distribution tests on Windows. This means that make generate-tests will not be available on Windows by default. This functionality is currently not working on Windows and just produces a bunch of warnings. Making this functionality available on Windows should be addressed separately. That requires a larger overhaul and since its a functionality aimed at developers its not something that needs to be addressed before the next release. The unnecessary warnings seen by users compiling models is a priority in my opinion.
Tests
/
Side Effects
/
Copyright holder: Rok Češnovar
The copyright holder is typically you or your assignee, such as a university or company. By submitting this pull request, the copyright holder is agreeing to the license the submitted work under the following licenses:
- Code: BSD 3-clause (https://opensource.org/licenses/BSD-3-Clause)
- Documentation: CC-BY 4.0 (https://creativecommons.org/licenses/by/4.0/)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR fixes the Stan Math side of stan-dev/cmdstan#786
The issue is that our makefiles rely on the gnu
findcommand that is not available on Windows.This PR introduces a makefile subroutine that callsdiron Windows and find on Unix systems.ifeq ($(OS),Windows_NT)findfiles=$(shell cmd.exe /C "dir /b /s $(subst /,,$1)$2 2>NUL")elsefindfiles=$(shell find $1 -type f -name $2)endifThe 2>NUL is there because if you search for files that dont exist,dirwill output aFile not founderror. So if you calledmake cleantwice in a row it would output a bunch ofFile not founds.This PR introduces a findfiles function that is a recursive version of the makefiles wildcard function.
findfiles=$(foreach d,$(wildcard $(addsuffix *,$(1))),$(call findfiles,$(d)/,$(2)) $(filter $(subst *,%,$(2)),$(d)))This PR also excludes the generaton of distribution tests on Windows. This means that
make generate-testswill not be available on Windows by default. This functionality is currently not working on Windows and just produces a bunch of warnings. Making this functionality available on Windows should be addressed separately. That requires a larger overhaul and since its a functionality aimed at developers its not something that needs to be addressed before the next release. The unnecessary warnings seen by users compiling models is a priority in my opinion.Tests
/
Side Effects
/
Copyright holder: Rok Češnovar
The copyright holder is typically you or your assignee, such as a university or company. By submitting this pull request, the copyright holder is agreeing to the license the submitted work under the following licenses:
- Code: BSD 3-clause (https://opensource.org/licenses/BSD-3-Clause)
- Documentation: CC-BY 4.0 (https://creativecommons.org/licenses/by/4.0/)