summaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
authorRichard Hughes <richard@hughsie.com>2015-03-04 13:05:49 +0000
committerRichard Hughes <richard@hughsie.com>2015-03-04 13:12:25 +0000
commit0472be058442848920fd6112b8ba681ec90c57f0 (patch)
treee6af03c21c068c6b055903f80306243b254d3594 /data
parenta49cf668d2f3725773007b27925699faa7e645be (diff)
downloadappstream-glib-0472be058442848920fd6112b8ba681ec90c57f0.tar.gz
Create firmware AppStream components from .cab files
See http://blogs.gnome.org/hughsie/2015/03/03/updating-firmware-on-linux/ for more infomation on how this will be used.
Diffstat (limited to 'data')
-rw-r--r--data/tests/Makefile.am29
-rw-r--r--data/tests/firmware/2_0_0/firmware.bin1
-rw-r--r--data/tests/firmware/2_0_0/firmware.inf19
-rw-r--r--data/tests/firmware/2_0_1/firmware.bin1
-rw-r--r--data/tests/firmware/2_0_1/firmware.inf15
-rw-r--r--data/tests/firmware/2_0_1/firmware.metainfo.xml30
-rw-r--r--data/tests/firmware/2_0_2/firmware.bin1
-rw-r--r--data/tests/firmware/2_0_2/firmware.inf15
-rw-r--r--data/tests/firmware/2_0_2/firmware.metainfo.xml33
9 files changed, 144 insertions, 0 deletions
diff --git a/data/tests/Makefile.am b/data/tests/Makefile.am
index dd7033c..45e5e32 100644
--- a/data/tests/Makefile.am
+++ b/data/tests/Makefile.am
@@ -21,6 +21,14 @@ test_files = \
example.yml \
extra-appdata/test.xml \
extra-appdata/local.xml \
+ firmware/2_0_0/firmware.bin \
+ firmware/2_0_0/firmware.inf \
+ firmware/2_0_1/firmware.bin \
+ firmware/2_0_1/firmware.inf \
+ firmware/2_0_1/firmware.metainfo.xml \
+ firmware/2_0_2/firmware.bin \
+ firmware/2_0_2/firmware.inf \
+ firmware/2_0_2/firmware.metainfo.xml \
font-1-1.fc21.noarch.rpm \
font-serif-1-1.fc21.noarch.rpm \
intltool.appdata.xml.in \
@@ -44,7 +52,28 @@ test_files = \
usr/share/pixmaps/test.png \
validate.xml.gz
+colorhug-als-2.0.0.cab: $(srcdir)/firmware/2_0_0/firmware.*
+ $(AM_V_GEN) gcab --create --nopath $@ \
+ $(srcdir)/firmware/2_0_0/firmware.bin \
+ $(srcdir)/firmware/2_0_0/firmware.inf
+colorhug-als-2.0.1.cab: $(srcdir)/firmware/2_0_1/firmware.*
+ $(AM_V_GEN) gcab --create --nopath $@ \
+ $(srcdir)/firmware/2_0_1/firmware.bin \
+ $(srcdir)/firmware/2_0_1/firmware.inf \
+ $(srcdir)/firmware/2_0_1/firmware.metainfo.xml
+colorhug-als-2.0.2.cab: $(srcdir)/firmware/2_0_2/firmware.*
+ $(AM_V_GEN) gcab --create --nopath $@ \
+ $(srcdir)/firmware/2_0_2/firmware.bin \
+ $(srcdir)/firmware/2_0_2/firmware.inf \
+ $(srcdir)/firmware/2_0_2/firmware.metainfo.xml
+
+BUILT_SOURCES = \
+ colorhug-als-2.0.0.cab \
+ colorhug-als-2.0.1.cab \
+ colorhug-als-2.0.2.cab
+
CLEANFILES = \
+ $(BUILT_SOURCES) \
rpmbuild/app.bin \
rpmbuild/en_GB.mo \
rpmbuild/ru.mo
diff --git a/data/tests/firmware/2_0_0/firmware.bin b/data/tests/firmware/2_0_0/firmware.bin
new file mode 100644
index 0000000..d07b709
--- /dev/null
+++ b/data/tests/firmware/2_0_0/firmware.bin
@@ -0,0 +1 @@
+a binary file
diff --git a/data/tests/firmware/2_0_0/firmware.inf b/data/tests/firmware/2_0_0/firmware.inf
new file mode 100644
index 0000000..19cfecf
--- /dev/null
+++ b/data/tests/firmware/2_0_0/firmware.inf
@@ -0,0 +1,19 @@
+; Copyright (C) 2015 Hughski Limited
+
+[Version]
+Class=Firmware
+ClassGuid=84f40464-9272-4ef7-9399-cd95f12da696
+DriverVer=03/01/2015,2.0.0
+
+; this is a nonstandard section
+[Location]
+URLs=http://www.hughski.com/downloads/colorhug2/firmware/colorhug-2.0.0.cab
+
+[Firmware_CopyFiles]
+firmware.bin
+
+[Strings]
+Provider = "Hughski"
+MfgName = "Hughski Limited"
+FirmwareDesc = "ColorHug Firmware"
+DiskName = "Firmware for the ColorHug Colorimeter"
diff --git a/data/tests/firmware/2_0_1/firmware.bin b/data/tests/firmware/2_0_1/firmware.bin
new file mode 100644
index 0000000..d07b709
--- /dev/null
+++ b/data/tests/firmware/2_0_1/firmware.bin
@@ -0,0 +1 @@
+a binary file
diff --git a/data/tests/firmware/2_0_1/firmware.inf b/data/tests/firmware/2_0_1/firmware.inf
new file mode 100644
index 0000000..3b38181
--- /dev/null
+++ b/data/tests/firmware/2_0_1/firmware.inf
@@ -0,0 +1,15 @@
+; Copyright (C) 2015 Hughski Limited
+
+[Version]
+Class=Firmware
+ClassGuid=84f40464-9272-4ef7-9399-cd95f12da696
+DriverVer=03/01/2015,2.0.1
+
+[Firmware_CopyFiles]
+firmware.bin
+
+[Strings]
+Provider = "Hughski"
+MfgName = "Hughski Limited"
+FirmwareDesc = "ColorHug Firmware"
+DiskName = "Firmware for the ColorHug Colorimeter"
diff --git a/data/tests/firmware/2_0_1/firmware.metainfo.xml b/data/tests/firmware/2_0_1/firmware.metainfo.xml
new file mode 100644
index 0000000..ba448b6
--- /dev/null
+++ b/data/tests/firmware/2_0_1/firmware.metainfo.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright 2015 Richard Hughes <richard@hughsie.com> -->
+<component type="firmware">
+ <id>84f40464-9272-4ef7-9399-cd95f12da696</id>
+ <name>ColorHug Firmware</name>
+ <summary>Firmware for the ColorHug Colorimeter</summary>
+ <description>
+ <p>
+ Updating the firmware on your ColorHug device improves performance and
+ adds new features.
+ </p>
+ </description>
+ <url type="homepage">http://www.hughski.com/</url>
+ <metadata_license>CC0-1.0</metadata_license>
+ <project_license>GPL-2.0+</project_license>
+ <updatecontact>richard_at_hughsie.com</updatecontact>
+ <developer_name>Hughski Limited</developer_name>
+ <releases>
+ <release version="2.0.1" timestamp="1424116753">
+ <location>http://www.hughski.com/downloads/colorhug2/firmware/colorhug-2.0.1.cab</location>
+ <description>
+ <p>This unstable release adds the following features:</p>
+ <ul>
+ <li>Use TakeReadings() to do a quick non-adaptive measurement</li>
+ <li>Scale XYZ measurement with a constant factor to make the CCMX more sane</li>
+ </ul>
+ </description>
+ </release>
+ </releases>
+</component>
diff --git a/data/tests/firmware/2_0_2/firmware.bin b/data/tests/firmware/2_0_2/firmware.bin
new file mode 100644
index 0000000..d07b709
--- /dev/null
+++ b/data/tests/firmware/2_0_2/firmware.bin
@@ -0,0 +1 @@
+a binary file
diff --git a/data/tests/firmware/2_0_2/firmware.inf b/data/tests/firmware/2_0_2/firmware.inf
new file mode 100644
index 0000000..07b0f7d
--- /dev/null
+++ b/data/tests/firmware/2_0_2/firmware.inf
@@ -0,0 +1,15 @@
+; Copyright (C) 2015 Hughski Limited
+
+[Version]
+Class=Firmware
+ClassGuid=84f40464-9272-4ef7-9399-cd95f12da696
+DriverVer=03/03/2015,2.0.2
+
+[Firmware_CopyFiles]
+firmware.bin
+
+[Strings]
+Provider = "Hughski"
+MfgName = "Hughski Limited"
+FirmwareDesc = "ColorHug Firmware"
+DiskName = "Firmware for the ColorHug Colorimeter"
diff --git a/data/tests/firmware/2_0_2/firmware.metainfo.xml b/data/tests/firmware/2_0_2/firmware.metainfo.xml
new file mode 100644
index 0000000..91f2941
--- /dev/null
+++ b/data/tests/firmware/2_0_2/firmware.metainfo.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright 2015 Richard Hughes <richard@hughsie.com> -->
+<component type="firmware">
+ <id>84f40464-9272-4ef7-9399-cd95f12da696</id>
+ <name>ColorHug Firmware</name>
+ <summary>Firmware for the ColorHug Colorimeter</summary>
+ <description>
+ <p>
+ Updating the firmware on your ColorHug device improves performance and
+ adds new features.
+ </p>
+ </description>
+ <url type="homepage">http://www.hughski.com/</url>
+ <metadata_license>CC0-1.0</metadata_license>
+ <project_license>GPL-2.0+</project_license>
+ <updatecontact>richard_at_hughsie.com</updatecontact>
+ <developer_name>Hughski Limited</developer_name>
+ <releases>
+ <release version="2.0.2" timestamp="1424116753">
+ <location>http://www.hughski.com/downloads/colorhug2/firmware/colorhug-2.0.2.cab</location>
+ <description>
+ <p>This unstable release adds the following features:</p>
+ <ul>
+ <li>Add TakeReadingArray to enable panel latency measurements</li>
+ <li>
+ Speed up the auto-scaled measurements considerably, using 256ms
+ as the smallest sample duration
+ </li>
+ </ul>
+ </description>
+ </release>
+ </releases>
+</component>