Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix appveyor crashing issue and use latest MinGW #2124

Merged
merged 3 commits into from
Oct 24, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions .appveyor/build.cmd
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
REM Windows build script

set SMING_HOME=%APPVEYOR_BUILD_FOLDER%\Sming
subst Z: %APPVEYOR_BUILD_FOLDER%
set SMING_HOME=Z:\Sming

if "%build_compiler%" == "udk" set ESP_HOME=%UDK_ROOT%
if "%build_compiler%" == "eqt" set ESP_HOME=%EQT_ROOT%

cd %SMING_HOME%
cd /d %SMING_HOME%
gcc -v

set MAKE_PARALLEL=make -j2

REM Move samples and tests into directory outside of the Sming repo.
set SMING_PROJECTS_DIR=%APPVEYOR_BUILD_FOLDER%\..
move ../samples %SMING_PROJECTS_DIR%
move ../tests %SMING_PROJECTS_DIR%
move ..\samples %SMING_PROJECTS_DIR%
move ..\tests %SMING_PROJECTS_DIR%

REM This will build the Basic_Blink application and most of the framework Components
cd %SMING_PROJECTS_DIR%/samples/Basic_Blink
Expand Down
2 changes: 1 addition & 1 deletion .appveyor/install.cmd
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
REM Windows install script

rmdir /s /q c:\MinGW
curl -LO %SMINGTOOLS%/MinGW.7z
curl -Lo MinGW.7z %SMINGTOOLS%/MinGW-2020-10-19.7z
7z -oC:\ x MinGW.7z

goto :%SMING_ARCH%
Expand Down
17 changes: 15 additions & 2 deletions Sming/component-wrapper.mk
Original file line number Diff line number Diff line change
Expand Up @@ -166,10 +166,23 @@ include $(wildcard $(ABS_BUILD_DIRS:=/*.c.d))
include $(wildcard $(ABS_BUILD_DIRS:=/*.cpp.d))

# Provide a target unless Component is custom built, in which case the component.mk will have defined this already
$(COMPONENT_LIBPATH): $(OBJ) $(EXTRA_OBJ)
$(COMPONENT_LIBPATH): build.ar
$(vecho) "AR $@"
$(Q) test ! -f $@ || rm $@
$(Q) $(AR) rcsP $@ $^
$(Q) $(AR) -M < build.ar
$(Q) mv $(notdir $(COMPONENT_LIBPATH)) $(COMPONENT_LIBPATH)

define addmod
@echo ADDMOD $2 >> $1

endef

build.ar: $(OBJ) $(EXTRA_OBJ)
@echo CREATE $(notdir $(COMPONENT_LIBPATH)) > $@
$(foreach o,$(OBJ) $(EXTRA_OBJ),$(call addmod,$@,$o))
@echo SAVE >> $@
@echo END >> $@


endif # ifeq (,$(CUSTOM_BUILD))
endif # ifneq (,$(COMPONENT_LIBNAME))
Expand Down