summaryrefslogtreecommitdiffstats
path: root/toolkit/mozapps/installer/linux
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
commit36d22d82aa202bb199967e9512281e9a53db42c9 (patch)
tree105e8c98ddea1c1e4784a60a5a6410fa416be2de /toolkit/mozapps/installer/linux
parentInitial commit. (diff)
downloadfirefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz
firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip
Adding upstream version 115.7.0esr.upstream/115.7.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'toolkit/mozapps/installer/linux')
-rw-r--r--toolkit/mozapps/installer/linux/rpm/mozilla.desktop21
-rw-r--r--toolkit/mozapps/installer/linux/rpm/mozilla.spec116
2 files changed, 137 insertions, 0 deletions
diff --git a/toolkit/mozapps/installer/linux/rpm/mozilla.desktop b/toolkit/mozapps/installer/linux/rpm/mozilla.desktop
new file mode 100644
index 0000000000..79048fcf7c
--- /dev/null
+++ b/toolkit/mozapps/installer/linux/rpm/mozilla.desktop
@@ -0,0 +1,21 @@
+#filter substitution
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+[Desktop Entry]
+Version=1.0
+Name=@MOZ_APP_DISPLAYNAME@
+GenericName=Web Browser
+Comment=Your web, the way you like it
+Exec=@MOZ_APP_NAME@
+Icon=@MOZ_APP_NAME@
+Terminal=false
+Type=Application
+StartupWMClass=@MOZ_APP_REMOTINGNAME@
+MimeType=text/html;text/xml;application/xhtml+xml;text/mml;x-scheme-handler/http;x-scheme-handler/https;
+StartupNotify=true
+X-MultipleArgs=false
+X-Desktop-File-Install-Version=0.16
+Categories=Network;WebBrowser;
+Encoding=UTF-8
diff --git a/toolkit/mozapps/installer/linux/rpm/mozilla.spec b/toolkit/mozapps/installer/linux/rpm/mozilla.spec
new file mode 100644
index 0000000000..21f7c3a60c
--- /dev/null
+++ b/toolkit/mozapps/installer/linux/rpm/mozilla.spec
@@ -0,0 +1,116 @@
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+%global __jar_repack %{nil}
+
+#Use a consistent string to refer to the package by
+%define pr_name "%{moz_app_displayname} %{moz_app_version}"
+
+Name: %{moz_app_name}
+Version: %{moz_numeric_app_version}
+Release: %{?moz_rpm_release:%{moz_rpm_release}}%{?buildid:.%{buildid}}
+Summary: %{pr_name}
+Group: Applications/Internet
+License: MPL 2
+Vendor: Mozilla
+URL: http://www.mozilla.org/projects/firefox/
+Source0: %{name}.desktop
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
+#AutoProv: no
+
+BuildRequires: desktop-file-utils
+
+
+%description
+%{pr_name}. This package was built from
+%{moz_source_repo}/rev/%{moz_source_stamp}
+
+#We only want a subpackage for the SDK if the required
+#files were generated. Like the tests subpackage, we
+#probably only need to conditionaly define the %files
+#section.
+%if %{?createtests:1}
+%package tests
+Summary: %{pr_name} tests
+Group: Developement/Libraries
+requires: %{name} = %{version}-%{release}
+%description tests
+%{pr_name} test harness files and test cases
+%endif
+
+%prep
+echo No-op prep
+
+
+%build
+echo No-op build
+
+
+%install
+rm -rf $RPM_BUILD_ROOT
+make install DESTDIR=$RPM_BUILD_ROOT
+desktop-file-validate %{SOURCE0}
+desktop-file-install --vendor mozilla \
+ --dir $RPM_BUILD_ROOT%{_datadir}/applications \
+ %{SOURCE0}
+#In order to make branding work in a generic way, We find
+#all the icons that are likely to be used for desktop files
+#and install them appropriately
+find %{moz_branding_directory} -name "default*.png" | tee icons.list
+for i in $(cat icons.list) ; do
+ size=$(echo $i | sed "s/.*default\([0-9]*\).png$/\1/")
+ icondir=$RPM_BUILD_ROOT/%{_datadir}/icons/hicolor/${size}x${size}/apps/
+ mkdir -p $icondir
+ cp -a $i ${icondir}%{name}.png
+done
+rm icons.list #cleanup
+
+%if %{?createtests:1}
+#wastefully creates a zip file, but ensures that we stage all test suites
+make package-tests
+testdir=$RPM_BUILD_ROOT/%{_datadir}/%{_testsinstalldir}/tests
+mkdir -p $testdir
+cp -a dist/test-stage/* $testdir/
+%endif
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+
+%post
+#this is needed to get gnome-panel to update the icons
+update-desktop-database &> /dev/null || :
+touch --no-create %{_datadir}/icons/hicolor || :
+if [ -x %{_bindir}/gtk-update-icon-cache ] ; then
+ %{_bindir}/gtk-update-icon-cache --quiet ${_datadir}/icons/hicolor &> /dev/null || :
+fi
+
+
+%postun
+#this is needed to get gnome-panel to update the icons
+update-desktop-database &> /dev/null || :
+touch --no-create %{_datadir}/icons/hicolor || :
+if [ -x %{_bindir}/gtk-update-icon-cache ] ; then
+ %{_bindir}/gtk-update-icon-cache --quiet ${_datadir}/icons/hicolor &> /dev/null || :
+fi
+
+
+%files
+%defattr(-,root,root,-)
+%{_installdir}
+%{_bindir}
+%{_datadir}/applications/
+%{_datadir}/icons/
+%doc
+
+
+%if %{?createtests:1}
+%files tests
+%{_datadir}/%{_testsinstalldir}/tests/
+%endif
+
+#%changelog
+#* %{name} %{version} %{moz_rpm_release}
+#- Please see %{moz_source_repo}/shortlog/%{moz_source_stamp}