File waydroid-image-gapps.spec of Package waydroid-image-gapps
#
# spec file for package waydroid-image-gapps
#
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
#
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define lineagever 20.0
%define buildver 20250809
Name: waydroid-image-gapps
Version: %{lineagever}.%{buildver}
Release: 1
Summary: LineageOS-based Android images with Google Apps for Waydroid
License: LGPL-3.0-only
URL: https://sourceforge.net/projects/waydroid/files/images/
# System/vendor images for x86_64 and arm64
Source0: https://sourceforge.net/projects/waydroid/files/images/system/lineage/waydroid_x86_64/lineage-%{lineagever}-%{buildver}-GAPPS-waydroid_x86_64-system.zip
Source1: https://sourceforge.net/projects/waydroid/files/images/vendor/waydroid_x86_64/lineage-%{lineagever}-%{buildver}-MAINLINE-waydroid_x86_64-vendor.zip
Source2: https://sourceforge.net/projects/waydroid/files/images/system/lineage/waydroid_arm64/lineage-%{lineagever}-%{buildver}-GAPPS-waydroid_arm64-system.zip
Source3: https://sourceforge.net/projects/waydroid/files/images/vendor/waydroid_arm64/lineage-%{lineagever}-%{buildver}-MAINLINE-waydroid_arm64-vendor.zip
BuildRequires: unzip
Requires: waydroid
Requires: %{name}-system
Requires: %{name}-vendor
Conflicts: waydroid-image
%description
LineageOS-based Android images with Google Apps (GApps) for Waydroid.
This package provides both `system.img` and `vendor.img` for use with Waydroid,
separated into subpackages for modular installation.
#
# Subpackages
#
%package vendor
Summary: Vendor image for Waydroid (GApps version)
Provides: waydroid(images/vendor.img)
Conflicts: waydroid-image-vendor
%description vendor
LineageOS-based Android vendor image for Waydroid.
This subpackage delivers the `vendor.img` required for running Waydroid.
%package system
Summary: System image with Google Apps for Waydroid
Provides: waydroid(images/system.img)
Conflicts: waydroid-image-system
%description system
LineageOS-based Android system image with Google Apps (GApps) for Waydroid.
This subpackage delivers the `system.img` required for running Waydroid.
#
# Arch handling
#
%{!?x86_64:%define x86_64 x86_64}
%{!?arm64:%define arm64 aarch64}
ExclusiveArch: %{?x86_64} %{?arm64}
%ifarch %{x86_64}
%define wayarch x86_64
%define sys 0
%define ven 1
%elifarch %{arm64}
%define wayarch arm64
%define sys 2
%define ven 3
%endif
#
# Build/install steps
#
%prep
%setup -q -c -T -a %{sys} -a %{ven}
%install
%{__install} -dm755 %{buildroot}%{_datadir}/waydroid-extra/images
mv system.img %{buildroot}%{_datadir}/waydroid-extra/images/
mv vendor.img %{buildroot}%{_datadir}/waydroid-extra/images/
#
# Files
#
%files system
%dir %{_datadir}/waydroid-extra
%dir %{_datadir}/waydroid-extra/images
%{_datadir}/waydroid-extra/images/system.img
%files vendor
%dir %{_datadir}/waydroid-extra
%dir %{_datadir}/waydroid-extra/images
%{_datadir}/waydroid-extra/images/vendor.img
%files
#
# Changelog
#
%changelog
* Wed Aug 20 2025 itachi_re <xanbenson99@gmail.com> - %{lineagever}.%{buildver}-1
- Initial package creation for GApps images