]> granicus.if.org Git - icu/commitdiff
ICU-20221 Add support for building with Cygwin/GCC to the AppVeyor CI builds.
authorJeff Genovy <29107334+jefgen@users.noreply.github.com>
Fri, 26 Oct 2018 18:18:35 +0000 (11:18 -0700)
committerJeff Genovy <29107334+jefgen@users.noreply.github.com>
Tue, 30 Oct 2018 17:26:07 +0000 (10:26 -0700)
.appveyor.yml
icu4c/source/config/mh-cygwin
icu4c/source/config/mh-cygwin64

index 56fbbe1c4fb9d614d552db9a558b4b352c7e6c8c..2d233b5aa3723cf1d00c843763affdedf0df93b5 100644 (file)
@@ -1,8 +1,57 @@
-image:         Visual Studio 2017
-platform:      x64
-configuration: Release
-build:
-    project: icu4c/source/allinone/allinone.sln
-
-test_script:
-    - icu4c/source/allinone/icucheck.bat x64 Release
+# AppVeyor configuration for CI Builds of ICU4C.
+
+image: Visual Studio 2017
+platform: x64
+
+# Don't clone the entire repo.
+clone_depth: 3
+
+# Cache the Cygwin downloaded setup packages between builds to speed things up.
+cache:
+  - c:\cygwin-setup-cache
+
+environment:
+  CYG_URL: https://cygwin.com/setup-x86_64.exe
+  CYG_MIRROR: http://cygwin.mirror.constant.com
+  CYG_PACKAGES: automake,gcc-core,gcc-g++,make,pkg-config,perl,python3-devel
+  CYG_ROOT: c:\cygwin-root
+  CYG_CACHE: c:\cygwin-setup-cache
+
+  matrix:
+    - BUILDSYSTEM: VS2017
+      configuration: Release
+      APPVEYOR_CACHE_SKIP_RESTORE: true
+      APPVEYOR_CACHE_SKIP_SAVE: true
+
+    - BUILDSYSTEM: cygwin64-gcc
+      CC: gcc
+      CXX: g++
+
+for:
+  -
+    matrix:
+      only:
+        - BUILDSYSTEM: cygwin64-gcc
+
+    install:
+      - ps: Invoke-WebRequest $env:CYG_URL -OutFile c:\cygwin-setup.exe
+      - c:\cygwin-setup.exe --quiet-mode --no-shortcuts --no-startmenu --no-desktop --upgrade-also --only-site --site "%CYG_MIRROR%" --root "%CYG_ROOT%"  --local-package-dir "%CYG_CACHE%" --packages "%CYG_PACKAGES%"
+
+    # Check that we have a working Cygwin environment before building.
+    before_build:
+      - "%CYG_ROOT%\\bin\\sh -lc 'echo Hello'"
+      - "%CYG_ROOT%\\bin\\sh -lc 'uname -a'"
+
+    build_script:
+      - '%CYG_ROOT%\\bin\\bash -lc "cd $(cygpath ${APPVEYOR_BUILD_FOLDER}) && cd icu4c/source && ./runConfigureICU Cygwin && make check"'
+
+  -
+    matrix:
+      only:
+        - BUILDSYSTEM: VS2017
+
+    build:
+      project: icu4c/source/allinone/allinone.sln
+
+    test_script:
+      - icu4c/source/allinone/icucheck.bat x64 Release
index c5a37179cab73e5c17f366647a684c612213f4fc..efba5511dd72898352283057b9e252f567290d16 100644 (file)
@@ -7,7 +7,7 @@
 
 ## Commands to generate dependency files
 GEN_DEPS.c=    $(CC) -E -MM $(DEFS) $(CPPFLAGS)
-GEN_DEPS.cc=   $(CXX) -E -MM -std=c++11 $(DEFS) $(CPPFLAGS)
+GEN_DEPS.cc=   $(CXX) -E -MM $(DEFS) $(CPPFLAGS) $(CXXFLAGS)
 
 ## Flags to create/use a static library
 ifneq ($(ENABLE_SHARED),YES)
index dc9d1a1ab010311f8c15d3dc4bf606eff9e321d5..6be8db77026bd75a44819b40dee3cd29ba902e9d 100644 (file)
@@ -7,7 +7,7 @@
 
 ## Commands to generate dependency files
 GEN_DEPS.c=    $(CC) -E -MM $(DEFS) $(CPPFLAGS)
-GEN_DEPS.cc=   $(CXX) -E -MM -std=c++11 $(DEFS) $(CPPFLAGS)
+GEN_DEPS.cc=   $(CXX) -E -MM $(DEFS) $(CPPFLAGS) $(CXXFLAGS)
 
 ## Flags to create/use a static library
 ifneq ($(ENABLE_SHARED),YES)