summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTimothy Gu <timothygu99@gmail.com>2014-04-26 18:09:09 (GMT)
committerTimothy Gu <timothygu99@gmail.com>2014-04-30 03:37:23 (GMT)
commit2b02ee7a9087e205d36c82a0e5f6bfb9985c25d9 (patch)
tree8de6c4af1d99a308c5a69b061a632d676401f05c
parent681921c8152bb75fc2e170c04170ad2dc361b99c (diff)
downloadmxe-2b02ee7a9087e205d36c82a0e5f6bfb9985c25d9.zip
mxe-2b02ee7a9087e205d36c82a0e5f6bfb9985c25d9.tar.gz
mxe-2b02ee7a9087e205d36c82a0e5f6bfb9985c25d9.tar.bz2
Add build matrix generation target
Based on a patch by Tobias Gruetzmacher <tobias-git@23.gs> (@TobiX). Fixes #346. Signed-off-by: Timothy Gu <timothygu99@gmail.com>
-rw-r--r--.gitignore1
-rw-r--r--Makefile54
-rw-r--r--assets/build-matrix.css15
-rw-r--r--index.html7
4 files changed, 76 insertions, 1 deletions
diff --git a/.gitignore b/.gitignore
index 6bc7548..4309bcf 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,5 @@
/settings.mk
+/build-matrix.html
/usr/
/gits/
/log*/
diff --git a/Makefile b/Makefile
index 5943565..b60fd0c 100644
--- a/Makefile
+++ b/Makefile
@@ -430,7 +430,7 @@ show-upstream-deps-%:
.PHONY: clean
clean:
- rm -rf $(call TMP_DIR,*) $(PREFIX)/*
+ rm -rf $(call TMP_DIR,*) $(PREFIX)/* build-matrix.html
.PHONY: clean-pkg
clean-pkg:
@@ -491,3 +491,55 @@ cleanup-style:
rm -f $(TOP_DIR)/tmp-cleanup-style; \
)
+build-matrix.html: $(foreach PKG,$(PKGS), $(TOP_DIR)/src/$(PKG).mk)
+ @echo '<!DOCTYPE html>' > $@
+ @echo '<html>' >> $@
+ @echo '<head>' >> $@
+ @echo '<meta http-equiv="content-type" content="text/html; charset=utf-8">' >> $@
+ @echo '<title>MXE Build Matrix</title>' >> $@
+ @echo '<link rel="stylesheet" href="assets/common.css">' >> $@
+ @echo '<link rel="stylesheet" href="assets/build-matrix.css">' >> $@
+ @echo '</head>' >> $@
+ @echo '<body>' >> $@
+ @echo '<h2>MXE Build Matrix</h2>' >> $@
+ @echo '<p>' >> $@
+ @echo 'This is a table of all supported package/target' >> $@
+ @echo 'matrix. Being supported means that this specific' >> $@
+ @echo 'combination is working to the best of our knowledge,' >> $@
+ @echo 'but does not mean that it is tested daily.' >> $@
+ @echo '</p>' >> $@
+ @echo '<p>' >> $@
+ @echo 'If you found that some package is not working properly,'>> $@
+ @echo 'please file a ticket on GitHub. If you figured out a' >> $@
+ @echo 'way to make the package work for unsupported targets,' >> $@
+ @echo 'feel free to submit a pull request.' >> $@
+ @echo '</p>' >> $@
+ @echo '<table class="fullscreen">' >> $@
+ @echo '<thead>' >> $@
+ @echo '<tr>' >> $@
+ @echo '<th rowspan="2">Package</th>' >> $@
+ @$(foreach TRIPLET,$(MXE_TRIPLETS), \
+ echo '<th colspan="$(words $(MXE_LIB_TYPES))">$(TRIPLET)</th>' >> $@;)
+ @echo '<th rowspan="2">Native</th>' >> $@
+ @echo '</tr>' >> $@
+ @echo '<tr>' >> $@
+ @$(foreach TRIPLET,$(MXE_TRIPLETS), \
+ $(foreach LIB, $(MXE_LIB_TYPES), \
+ echo '<th>$(LIB)</th>' >> $@;))
+ @echo '</tr>' >> $@
+ @echo '</thead>' >> $@
+ @echo '<tbody>' >> $@
+ @$(foreach PKG,$(PKGS), \
+ echo '<tr>' >> $@; \
+ echo '<th class="row">$(PKG)</th>' >> $@; \
+ $(foreach TARGET,$(MXE_TARGET_LIST), \
+ $(if $(value $(call LOOKUP_PKG_RULE,$(PKG),BUILD,$(TARGET))), \
+ echo '<td class="supported">Y</td>' >> $@;, \
+ echo '<td class="unsupported">N</td>' >> $@;)) \
+ $(if $(call set_is_member,$(PKG),$(BUILD_PKGS)), \
+ echo '<td class="supported">Y</td>' >> $@;, \
+ echo '<td class="unsupported">N</td>' >> $@;))
+ @echo '</tbody>' >> $@
+ @echo '</table>' >> $@
+ @echo '</body>' >> $@
+
diff --git a/assets/build-matrix.css b/assets/build-matrix.css
new file mode 100644
index 0000000..4d03da1
--- /dev/null
+++ b/assets/build-matrix.css
@@ -0,0 +1,15 @@
+/* This file is part of MXE.
+ * See index.html for further information. */
+
+table.fullscreen {
+ width: 100%;
+}
+
+td.supported {
+ background-color: #98fb98;
+ text-align: center;
+}
+td.unsupported {
+ background-color: #f99;
+ text-align: center;
+}
diff --git a/index.html b/index.html
index aa8ff07..2ee1896 100644
--- a/index.html
+++ b/index.html
@@ -999,6 +999,13 @@ local-pkg-list: $(LOCAL_PKG_LIST)</pre>
suitable for usage in shell scripts
</dd>
+ <dt>make build-matrix.html</dt>
+
+ <dd>
+ generate a report of what packages are
+ supported on what targets to build-matrix.html
+ </dd>
+
<dt>make update</dt>
<dd>