File tree Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -63,10 +63,7 @@ after_test:
63
63
throw "$env:MSYSTEM build exited with code $LASTEXITCODE"
64
64
}
65
65
cd (Join-Path $env:APPVEYOR_BUILD_FOLDER 'mpy-cross')
66
- # Building of mpy-cross hasn't been fixed across all possible windows/WSL/...
67
- # variations and the STRIP step tries to strip mpy-cross whereas that should be
68
- # mpy-cross.exe. Workaround for now by skipping actual strip and size commands.
69
- C:\msys64\usr\bin\bash.exe -l -c "make -B -j4 V=1 STRIP=echo SIZE=echo"
66
+ C:\msys64\usr\bin\bash.exe -l -c "make -B -j4 V=1"
70
67
if ($LASTEXITCODE -ne 0) {
71
68
throw "$env:MSYSTEM mpy_cross build exited with code $LASTEXITCODE"
72
69
}
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ include ../../py/mkenv.mk
2
2
-include mpconfigport.mk
3
3
4
4
# define main target
5
- PROG = micropython.exe
5
+ PROG = micropython
6
6
7
7
# qstr definitions (must come before including py.mk)
8
8
QSTR_DEFS = ../unix/qstrdefsport.h
Original file line number Diff line number Diff line change @@ -178,6 +178,13 @@ endif
178
178
ifneq ($(PROG ) ,)
179
179
# Build a standalone executable (unix does this)
180
180
181
+ # The executable should have an .exe extension for builds targetting 'pure'
182
+ # Windows, i.e. msvc or mingw builds, but not when using msys or cygwin's gcc.
183
+ COMPILER_TARGET := $(shell $(CC ) -dumpmachine)
184
+ ifneq (,$(findstring mingw,$(COMPILER_TARGET ) ) )
185
+ PROG := $(PROG ) .exe
186
+ endif
187
+
181
188
all : $(PROG )
182
189
183
190
$(PROG ) : $(OBJ )
@@ -186,9 +193,9 @@ $(PROG): $(OBJ)
186
193
# we may want to compile using Thumb, but link with non-Thumb libc.
187
194
$(Q)$(CC) -o $@ $^ $(LIB) $(LDFLAGS)
188
195
ifndef DEBUG
189
- $(Q)$(STRIP) $(STRIPFLAGS_EXTRA) $(PROG)
196
+ $(Q)$(STRIP) $(STRIPFLAGS_EXTRA) $@
190
197
endif
191
- $(Q)$(SIZE) $$(find $(BUILD) -path "$(BUILD)/build/frozen*.o") $(PROG)
198
+ $(Q)$(SIZE) $$(find $(BUILD) -path "$(BUILD)/build/frozen*.o") $@
192
199
193
200
clean : clean-prog
194
201
clean-prog :
You can’t perform that action at this time.
0 commit comments