M: MyungJoo Ham <myungjoo.ham@samsung.com>
F: packaging/epicfeature-development.inc
+
+PLATFORM PRESET: Mobile
+M: TBD
+F: packaging/platform-preset-mobile.inc
+
+PLATFORM PRESET: Wearable
+M: TBD
+F: packaging/platform-preset-wearable.inc
+
+PLATFORM PRESET: TV
+M: TBD
+F: packaging/platform-preset-tv.inc
+
+PLATFORM PRESET: IVI
+M: TBD
+F: packaging/platform-preset-ivi.inc
+
+PLATFORM PRESET: IoT
+M: TBD
+F: packaging/platform-preset-iot.inc
+
+PLATFORM PRESET: Common
+M: TBD
+F: packaging/platform-preset-common.inc
+
+PLATFORM PRESET: Home Appliance
+M: TBD
+F: packaging/platform-preset-home_appliance.inc
+
Source2020: epicfeature-platform.inc
Source3000: platform-preset.inc
-Source3101: preset_tm1.packages
-Source3102: preset_tm2_aarch64.packages
-Source3103: preset_tm2_armv7l.packages
+Source3100: platform-preset-mobile.inc
+Source3200: platform-preset-wearable.inc
+Source3300: platform-preset-tv.inc
+Source3400: platform-preset-ivi.inc
+Source3500: platform-preset-iot.inc
+Source3600: platform-preset-common.inc
+Source3700: platform-preset-home_appliance.inc
+
+# To get .ks files
+BuildRequires: image-configurations
# Do not try to include files unless RPMBUILD has already expanded source files to SOURCES
# Use Source1001 (domain-kernel) as the probing point.
-%define include_if_mainbuild() %{expand:%{lua:if posix.access(rpm.expand("%{SOURCE1001}"), "f") then print("%include "..rpm.expand("%{1}")) end}}
+%define include_if_mainbuild() %{expand:%{lua:if posix.access(rpm.expand("%{SOURCE1001}"), "f") then print("%include "..rpm.expand("%{1}").."\\n") end}}
+
+# Create a target device preset from .ks file used to create device iamge.
+# This script writes build-spec when building the build-spec itself. :)
+# Importing .kg file with list_with_require() based on image-configuration will work
+# after Tizen:Unified starts to generate its own platform images.
+%define list_with_require() %{expand:%{lua:if posix.access(rpm.expand("%{SOURCE1001}"), "f") then \
+ local start = 0 \
+ for line in io.lines(rpm.expand("%{1}")) do \
+ if (string.match(line, '%%end')) then break end \
+ if (string.match(line, '%%packages')) then \
+ start = 1 \
+ else \
+ if (start == 1) then \
+ if (string.match(line, '^#')) then \
+ elseif (string.match(line, '^$')) then \
+ else \
+ print("Requires: "..line.."\\n") \
+ end \
+ end \
+ end \
+ end \
+end}}
Suggests: %{name}-root-UI
"Recommened" is reserved for future usage.
"Conflicts" is to unselect unconditionally.
+%build
+ls /usr/share/image-configurations/
+
%files
--- /dev/null
+# Maintainer: Tizen Common PM
+# You need ACK (+1) from the maintainer to be reviewed by building-blocks maintainers.
+
+
+%package sub1-preset-common
+Summary: Common Profile Presets
+Conflicts: %{name}-sub1-preset-mobile
+Conflicts: %{name}-sub1-preset-tv
+Conflicts: %{name}-sub1-preset-wearable
+Conflicts: %{name}-sub1-preset-iot
+Conflicts: %{name}-sub1-preset-ivi
+%description sub1-preset-common
+Tizen Platform Presets for "Common Profile"
+%files sub1-preset-common
--- /dev/null
+# Maintainer: Tizen Home Appliance PM
+# You need ACK (+1) from the maintainer to be reviewed by building-blocks maintainers.
+
+
+%package sub1-preset-home_appliance
+Summary: Common Profile Presets
+Conflicts: %{name}-sub1-preset-mobile
+Conflicts: %{name}-sub1-preset-tv
+Conflicts: %{name}-sub1-preset-wearable
+Conflicts: %{name}-sub1-preset-iot
+Conflicts: %{name}-sub1-preset-ivi
+Conflicts: %{name}-sub1-preset-common
+%description sub1-preset-home_appliance
+Tizen Platform Presets for "Home Appliances"
+%files sub1-preset-home_appliance
--- /dev/null
+# Maintainer: Tizen IoT PM
+# You need ACK (+1) from the maintainer to be reviewed by building-blocks maintainers.
+
+%package sub1-preset-iot
+Summary: IOT Device Presets
+Conflicts: %{name}-sub1-preset-mobile
+Conflicts: %{name}-sub1-preset-tv
+Conflicts: %{name}-sub1-preset-wearable
+Conflicts: %{name}-sub1-preset-ivi
+Suggests: %{name}-sub2-preset-iot-rpi3_minimal
+%description sub1-preset-iot
+Tizen IoT Device Presets
+%files sub1-preset-iot
+
+
+%package sub2-preset-iot-rpi3_minimal
+Summary: IoT RPI3 Headless/Minimal Preset
+%description sub2-preset-iot-rpi3_minimal
+Tizen IoT Headless/Minimal Preset for RPI3
+%files sub2-preset-iot-rpi3_minimal
+
+
--- /dev/null
+# Maintainer: Tizen IVI PM
+# You need ACK (+1) from the maintainer to be reviewed by building-blocks maintainers.
+
+%package sub1-preset-ivi
+Summary: IVI Profile Presets
+Conflicts: %{name}-sub1-preset-mobile
+Conflicts: %{name}-sub1-preset-tv
+Conflicts: %{name}-sub1-preset-wearable
+Conflicts: %{name}-sub1-preset-iot
+Suggests: %{name}-sub2-preset-ivi-proto
+%description sub1-preset-ivi
+Tizen IVI Platform Presets
+%files sub1-preset-ivi
+
+%package sub2-preset-ivi-proto
+Summary: IVI Prototype Preset
+# image-configuration must have this file supplied.
+%list_with_require %{_datadir}/image-configurations/ivi-target-odroidxu3.ks
+%description sub2-preset-ivi-proto
+Tizen IVI Prototype Preset
+%files sub2-preset-ivi-proto
+
--- /dev/null
+# Maintainer: Tizen Mobile PM
+# You need ACK (+1) from the maintainer to be reviewed by building-blocks maintainers.
+
+%package sub1-preset-mobile
+Summary: Mobile Profile Presets
+Conflicts: %{name}-sub1-preset-tv
+Conflicts: %{name}-sub1-preset-wearable
+Conflicts: %{name}-sub1-preset-ivi
+Conflicts: %{name}-sub1-preset-iot
+Suggests: %{name}-sub2-preset-mobile-tm1
+Suggests: %{name}-sub2-preset-mobile-tm2-aarch64
+Suggests: %{name}-sub2-preset-mobile-tm2-armv7l
+Suggests: %{name}-sub2-preset-mobile-minimal
+%description sub1-preset-mobile
+Tizen Mobile Platform Presets
+%files sub1-preset-mobile
+
+
+%package sub2-preset-mobile-tm1
+Summary: Mobile-TM1 Preset
+Conflicts: %{name}-sub2-preset-mobile-tm2-aarch64
+Conflicts: %{name}-sub2-preset-mobile-tm2-armv7l
+Conflicts: %{name}-sub2-preset-mobile-minimal
+# image-configuration must have this file supplied.
+%list_with_require %{_datadir}/image-configurations/mobile-wayland-armv7l-tm1.ks
+%description sub2-preset-mobile-tm1
+Tizen Mobile TM1 Preset, which is using armv7l.
+You may use this preset for other architectures; however,
+please note that the TM1 model itself is for armv7l only.
+This block is allowed for other architectures only to let
+other arch devices start with TM1 packages.
+You may need mobile + tm1 MIC post script as well.
+(TIC RECIPE for POST is not READY YET)
+%files sub2-preset-mobile-tm1
+
+%package sub2-preset-mobile-tm2-aarch64
+Summary: Mobile-TM2 Preset
+Conflicts: %{name}-sub2-preset-mobile-tm1
+Conflicts: %{name}-sub2-preset-mobile-tm2-armv7l
+Conflicts: %{name}-sub2-preset-mobile-minimal
+# image-configuration must have this file supplied.
+%list_with_require %{_datadir}/image-configurations/mobile-wayland-arm64-tm2.ks
+%description sub2-preset-mobile-tm2-aarch64
+Tizen Mobile TM2 Preset. This is for aarch64 architecture only.
+For architectural/post-script note, please refer to tm1 twin.
+%files sub2-preset-mobile-tm2-aarch64
+
+%package sub2-preset-mobile-tm2-armv7l
+Summary: Mobile-TM2 Preset
+Conflicts: %{name}-sub2-preset-mobile-tm1
+Conflicts: %{name}-sub2-preset-mobile-tm2-aarch64
+Conflicts: %{name}-sub2-preset-mobile-minimal
+# image-configuration must have this file supplied.
+%list_with_require %{_datadir}/image-configurations/mobile-wayland-armv7l-tm2.ks
+%description sub2-preset-mobile-tm2-armv7l
+Tizen Mobile TM2 Preset. This is for armv7l architecture only.
+Although TM2 has 64bit processor, we may use 32bit userspace binaries for it.
+For architectural/post-script note, please refer to tm1 twin.
+%files sub2-preset-mobile-tm2-armv7l
+
+%package sub2-preset-mobile-minimal
+Summary: Mobile Minimal Preset
+Conflicts: %{name}-sub2-preset-mobile-tm1
+Conflicts: %{name}-sub2-preset-mobile-tm2
+%description sub2-preset-mobile-minimal
+Tizen Mobile Minimal Platform Preset
+
+Mobile-PM: fill in minimal API sets for mobile profile.
+
+%files sub2-preset-mobile-minimal
--- /dev/null
+# Maintainer: Tizen TV PM
+# You need ACK (+1) from the maintainer to be reviewed by building-blocks maintainers.
+
+%package sub1-preset-tv
+Summary: TV Profile Presets
+Conflicts: %{name}-sub1-preset-mobile
+Conflicts: %{name}-sub1-preset-wearable
+Conflicts: %{name}-sub1-preset-ivi
+Conflicts: %{name}-sub1-preset-iot
+Suggests: %{name}-sub2-preset-tv-odroid
+%list_with_require %{SOURCE4001}
+%description sub1-preset-tv
+Tizen TV Platform Presets
+%files sub1-preset-tv
+
+
+%package sub2-preset-tv-odroid
+Summary: TV-Odroid Preset
+# image-configuration must have this file supplied.
+%list_with_require %{_datadir}/image-configurations/tv-wayland-armv7l-odroidu3.ks
+%description sub2-preset-tv-odroid
+Tizen TV Odroid Preset
+%files sub2-preset-tv-odroid
+
--- /dev/null
+# Maintainer: Tizen Wearable PM
+# You need ACK (+1) from the maintainer to be reviewed by building-blocks maintainers.
+
+%package sub1-preset-wearable
+Summary: Wearable Profile Presets
+Conflicts: %{name}-sub1-preset-mobile
+Conflicts: %{name}-sub1-preset-tv
+Conflicts: %{name}-sub1-preset-ivi
+Conflicts: %{name}-sub1-preset-iot
+Suggests: %{name}-sub2-preset-wearable-tw2
+%description sub1-preset-wearable
+Tizen Wearable Platform Presets
+%files sub1-preset-wearable
+
+
+%package sub2-preset-wearable-tw2
+Summary: Wearable-TW2 Preset
+# image-configuration must have this file supplied.
+%list_with_require %{_datadir}/image-configurations/wearable-wayland-armv7l-tw2.ks
+%description sub2-preset-wearable-tw2
+Tizen Wearable TW1 (Gear 2) Preset
+%files sub2-preset-wearable-tw2
+
Suggests: %{name}-sub1-preset-wearable
Suggests: %{name}-sub1-preset-ivi
Suggests: %{name}-sub1-preset-iot
+Suggests: %{name}-sub1-preset-common
+Suggests: %{name}-sub1-preset-home_appliance
%description root-preset
Tizen Platform Presets as Package Selection Example
%files root-preset
-
-%package sub1-preset-mobile
-Summary: Mobile Profile Presets
-Conflicts: %{name}-sub1-preset-tv
-Conflicts: %{name}-sub1-preset-wearable
-Conflicts: %{name}-sub1-preset-ivi
-Conflicts: %{name}-sub1-preset-iot
-Suggests: %{name}-sub2-preset-mobile-tm1
-Suggests: %{name}-sub2-preset-mobile-tm2-aarch64
-Suggests: %{name}-sub2-preset-mobile-tm2-armv7l
-Suggests: %{name}-sub2-preset-mobile-minimal
-%description sub1-preset-mobile
-Tizen Mobile Platform Presets
-%files sub1-preset-mobile
-
-
-%package sub1-preset-tv
-Summary: TV Profile Presets
-Conflicts: %{name}-sub1-preset-mobile
-Conflicts: %{name}-sub1-preset-wearable
-Conflicts: %{name}-sub1-preset-ivi
-Conflicts: %{name}-sub1-preset-iot
-Suggests: %{name}-sub2-preset-tv-odroid
-%description sub1-preset-tv
-Tizen TV Platform Presets
-%files sub1-preset-tv
-
-
-%package sub1-preset-wearable
-Summary: Wearable Profile Presets
-Conflicts: %{name}-sub1-preset-mobile
-Conflicts: %{name}-sub1-preset-tv
-Conflicts: %{name}-sub1-preset-ivi
-Conflicts: %{name}-sub1-preset-iot
-Suggests: %{name}-sub2-preset-wearable-tw1
-%description sub1-preset-wearable
-Tizen Wearable Platform Presets
-%files sub1-preset-wearable
-
-
-%package sub1-preset-ivi
-Summary: IVI Profile Presets
-Conflicts: %{name}-sub1-preset-mobile
-Conflicts: %{name}-sub1-preset-tv
-Conflicts: %{name}-sub1-preset-wearable
-Conflicts: %{name}-sub1-preset-iot
-Suggests: %{name}-sub2-preset-ivi-proto
-%description sub1-preset-ivi
-Tizen IVI Platform Presets
-%files sub1-preset-ivi
-
-
-%package sub1-preset-iot
-Summary: IOT Device Presets
-Conflicts: %{name}-sub1-preset-mobile
-Conflicts: %{name}-sub1-preset-tv
-Conflicts: %{name}-sub1-preset-wearable
-Conflicts: %{name}-sub1-preset-ivi
-Suggests: %{name}-sub2-preset-iot-rpi3_minimal
-%description sub1-preset-iot
-Tizen IoT Device Presets
-%files sub1-preset-iot
-
-%package sub2-preset-mobile-tm1
-Summary: Mobile-TM1 Preset
-Conflicts: %{name}-sub2-preset-mobile-tm2-aarch64
-Conflicts: %{name}-sub2-preset-mobile-tm2-armv7l
-Conflicts: %{name}-sub2-preset-mobile-minimal
-%include_if_mainbuild %{SOURCE3101}
-%description sub2-preset-mobile-tm1
-Tizen Mobile TM1 Preset, which is using armv7l.
-You may use this preset for other architectures; however,
-please note that the TM1 model itself is for armv7l only.
-This block is allowed for other architectures only to let
-other arch devices start with TM1 packages.
-You may need mobile + tm1 MIC post script as well.
-(TIC RECIPE for POST is not READY YET)
-%files sub2-preset-mobile-tm1
-
-%package sub2-preset-mobile-tm2-aarch64
-Summary: Mobile-TM2 Preset
-Conflicts: %{name}-sub2-preset-mobile-tm1
-Conflicts: %{name}-sub2-preset-mobile-tm2-armv7l
-Conflicts: %{name}-sub2-preset-mobile-minimal
-%include_if_mainbuild %{SOURCE3102}
-%description sub2-preset-mobile-tm2-aarch64
-Tizen Mobile TM2 Preset. This is for aarch64 architecture only.
-For architectural/post-script note, please refer to tm1 twin.
-%files sub2-preset-mobile-tm2-aarch64
-
-%package sub2-preset-mobile-tm2-armv7l
-Summary: Mobile-TM2 Preset
-Conflicts: %{name}-sub2-preset-mobile-tm1
-Conflicts: %{name}-sub2-preset-mobile-tm2-aarch64
-Conflicts: %{name}-sub2-preset-mobile-minimal
-%include_if_mainbuild %{SOURCE3103}
-%description sub2-preset-mobile-tm2-armv7l
-Tizen Mobile TM2 Preset. This is for armv7l architecture only.
-Although TM2 has 64bit processor, we may use 32bit userspace binaries for it.
-For architectural/post-script note, please refer to tm1 twin.
-%files sub2-preset-mobile-tm2-armv7l
-
-%package sub2-preset-mobile-minimal
-Summary: Mobile Minimal Preset
-Conflicts: %{name}-sub2-preset-mobile-tm1
-Conflicts: %{name}-sub2-preset-mobile-tm2
-%description sub2-preset-mobile-minimal
-Tizen Mobile Minimal Platform Preset
-%files sub2-preset-mobile-minimal
-
-%package sub2-preset-tv-odroid
-Summary: TV-Odroid Preset
-%description sub2-preset-tv-odroid
-Tizen TV Odroid Preset
-%files sub2-preset-tv-odroid
-
-%package sub2-preset-wearable-tw1
-Summary: Wearable-TW1 Preset
-%description sub2-preset-wearable-tw1
-Tizen Wearable TW1 (Gear 2) Preset
-%files sub2-preset-wearable-tw1
-
-%package sub2-preset-ivi-proto
-Summary: IVI Prototype Preset
-%description sub2-preset-ivi-proto
-Tizen IVI Prototype Preset
-%files sub2-preset-ivi-proto
-
-
-%package sub2-preset-iot-rpi3_minimal
-Summary: IoT RPI3 Headless/Minimal Preset
-%description sub2-preset-iot-rpi3_minimal
-Tizen IoT Headless/Minimal Preset for RPI3
-%files sub2-preset-iot-rpi3_minimal
-
+%include_if_mainbuild %{SOURCE3100}
+%include_if_mainbuild %{SOURCE3200}
+%include_if_mainbuild %{SOURCE3300}
+%include_if_mainbuild %{SOURCE3400}
+%include_if_mainbuild %{SOURCE3500}
+%include_if_mainbuild %{SOURCE3600}
+%include_if_mainbuild %{SOURCE3700}