Upgrade to GNOME 45

Updated Recipes:

  gcr4                      3.92   -> 4.0.0
  geoclue                   2.5.7  -> 2.7.0
  gjs                       1.73.2 -> 1.77.90
  gnome-backgrounds         42.0   -> 45.0
  gnome-control-center      43.0   -> 45.0
  gnome-desktop             43.rc  -> 44.0
  gsettings-desktop-schema  43.0   -> 45.0
  libblockdev               2.26   -> 2.28
  libgweather4              4.0.0  -> 4.2.0
  libnma                    1.8.38 -> 1.10.6
  mozjs                     102    -> 115
  nss                       3.64   -> 3.74
  ovmf                      202205 -> 202211

New recipes:

  appstream                 0.16.3
  libei                     1.1.0
  libxmlb                   0.3.14
  tecla                     45.0
  webm/libvpx               1.13

Recipes updated to replace poky recipes with insufficient version:

  glib-2.0                  2.78.0
  gtk+/gtk+3                3.24.38
  gtk+/gtk4                 4.12.1
  icu                       73_2
  wayland/wayland           1.22.0
  wayland/wayland-protocols 1.32
  wayland/libinput          1.24.0
  libadwaita                1.4.0
This commit is contained in:
Bruce Leidl 2023-09-29 12:46:16 -04:00
parent c6410b7d91
commit e20e601129
147 changed files with 4761 additions and 1585 deletions

View File

@ -0,0 +1 @@
PACKAGECONFIG="orc soup3 pulseaudio x11 asm bz2 cairo flac gdk-pixbuf gudev jpeg lame libpng mpg123 speex taglib v4l2 vpx"

View File

@ -1,2 +0,0 @@
# rest requires libsoup-gnome-2.4
PACKAGECONFIG = "gnome"

View File

@ -15,6 +15,7 @@ RDEPENDS:${PN} = "\
gnome-disk-utility \
gnome-system-monitor \
libgnome-desktop \
libsoup \
mutter \
gjs \
gvfs \

View File

@ -8,32 +8,36 @@ SECTION = "devel/lib"
LIC_FILES_CHKSUM = "file://LICENSE;md5=c07cb499d259452f324bb90c3067d85c"
inherit autotools gobject-introspection pkgconfig
inherit autotools gobject-introspection pkgconfig lib_package
SRC_URI = "git://github.com/storaged-project/libblockdev;branch=2.x-branch;protocol=https"
SRCREV = "47ff12242c89e36a33259d18b7068b26c3bb1c64"
DEPENDS = "autoconf-archive-native glib-2.0 kmod udev"
SRC_URI = "git://github.com/storaged-project/libblockdev;branch=2.x-branch;protocol=https \
"
SRCREV = "1412dc51c8f76bf8d9a6008228737db4a9a26d69"
S = "${WORKDIR}/git"
FILES:${PN} += "${libdir}/python2.7/dist-packages ${libdir}/python3.*/site-packages"
PACKAGECONFIG ??= "python3 lvm dm kmod parted fs escrow btrfs crypto mdraid kbd mpath nvdimm"
PACKAGECONFIG ??= "python3 lvm dm kmod parted fs escrow btrfs crypto mdraid kbd mpath nvdimm tools"
PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3"
PACKAGECONFIG[python2] = "--with-python2, --without-python2,,python"
PACKAGECONFIG[lvm] = "--with-lvm, --without-lvm, multipath-tools, lvm2"
PACKAGECONFIG[lvm-dbus] = "--with-lvm_dbus, --without-lvm_dbus, multipath-tools, lvm2"
PACKAGECONFIG[dm] = "--with-dm, --without-dm, multipath-tools, lvm2"
PACKAGECONFIG[dmraid] = "--with-dmraid, --without-dmraid"
PACKAGECONFIG[kmod] = "--with-kbd, --without-kbd, kmod"
PACKAGECONFIG[kmod] = "--with-kbd, --without-kbd,libbytesize"
PACKAGECONFIG[parted] = "--with-part, --without-part, parted"
PACKAGECONFIG[fs] = "--with-fs, --without-fs, util-linux"
PACKAGECONFIG[doc] = "--with-gtk-doc, --without-gtk-doc, gtk-doc-native"
PACKAGECONFIG[nvdimm] = "--with-nvdimm, --without-nvdimm, ndctl util-linux"
PACKAGECONFIG[vdo] = "--with-vdo, --without-vdo"
PACKAGECONFIG[vdo] = "--with-vdo, --without-vdo,libbytesize"
PACKAGECONFIG[escrow] = "--with-escrow, --without-escrow, nss volume-key"
PACKAGECONFIG[btrfs] = "--with-btrfs,--without-btrfs,libbytesize btrfs-tools"
PACKAGECONFIG[crypto] = "--with-crypto,--without-crypto,cryptsetup nss volume-key"
PACKAGECONFIG[mdraid] = "--with-mdraid,--without-mdraid,libbytesize"
PACKAGECONFIG[kbd] = "--with-kbd,--without-kbd,libbytesize"
PACKAGECONFIG[mpath] = "--with-mpath,--without-mpath, multipath-tools, lvm2"
PACKAGECONFIG[tools] = "--with-tools,--without-tools,libbytesize libdevmapper"
export GIR_EXTRA_LIBS_PATH="${B}/src/utils/.libs"

View File

@ -0,0 +1,64 @@
From 1109c1b8259ad840ac1688d533f76ca268c67b6b Mon Sep 17 00:00:00 2001
From: "John M. Schanck" <jschanck@mozilla.com>
Date: Sat, 5 Feb 2022 11:12:43 +0000
Subject: [PATCH] Bug 1750624 - Pin validation date for PayPalEE test cert.
r=nss-reviewers,bbeurdouche,rrelyea
Differential Revision: https://phabricator.services.mozilla.com/D136289
--HG--
extra : moz-landing-system : lando
Upstream-Status: Backport
---
tests/chains/chains.sh | 6 +++++-
tests/chains/scenarios/realcerts.cfg | 1 +
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/tests/chains/chains.sh b/tests/chains/chains.sh
index 32c7ef54c..e13ae52f9 100755
--- a/nss/tests/chains/chains.sh
+++ b/nss/tests/chains/chains.sh
@@ -917,7 +917,7 @@ verify_cert()
done
VFY_OPTS_TNAME="${DB_OPT} ${ENGINE} ${TRUST_AND_DB_OPT} ${REV_OPTS} ${FETCH_OPT} ${USAGE_OPT} ${POLICY_OPT} ${TRUST_OPT}"
- VFY_OPTS_ALL="${DB_OPT} ${ENGINE} -vv ${TRUST_AND_DB_OPT} ${REV_OPTS} ${FETCH_OPT} ${USAGE_OPT} ${POLICY_OPT} ${VFY_CERTS} ${TRUST_OPT}"
+ VFY_OPTS_ALL="${DB_OPT} ${ENGINE} -vv ${VFY_TIME_OPT} ${TRUST_AND_DB_OPT} ${REV_OPTS} ${FETCH_OPT} ${USAGE_OPT} ${POLICY_OPT} ${VFY_CERTS} ${TRUST_OPT}"
TESTNAME="Verifying certificate(s) ${VFY_LIST} with flags ${VFY_OPTS_TNAME}"
echo "${SCRIPTNAME}: ${TESTNAME}"
@@ -1118,6 +1118,7 @@ parse_config()
;;
"verify")
VERIFY="${VALUE}"
+ VFY_TIME_OPT=
TRUST=
TRUST_AND_DB=
POLICY=
@@ -1126,6 +1127,9 @@ parse_config()
REV_OPTS=
USAGE_OPT=
;;
+ "at_time")
+ VFY_TIME_OPT="-b ${VALUE}"
+ ;;
"cert")
VERIFY="${VERIFY} ${VALUE}"
;;
diff --git a/tests/chains/scenarios/realcerts.cfg b/tests/chains/scenarios/realcerts.cfg
index 305443fc3..f8b0fc452 100644
--- a/nss/tests/chains/scenarios/realcerts.cfg
+++ b/nss/tests/chains/scenarios/realcerts.cfg
@@ -22,6 +22,7 @@ verify TestUser51:x
verify PayPalEE:x
policy OID.2.16.840.1.114412.2.1
+ at_time 2201010000Z
result pass
verify BrAirWaysBadSig:x
--
2.25.1

View File

@ -1,4 +1,4 @@
From 8b67c22b057e158f61c9fdd5b01f37195c6f5ca4 Mon Sep 17 00:00:00 2001
From 9937e89c22eb2f2db9a936e7bc4442857b4192f5 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Wed, 18 Dec 2019 12:29:50 +0100
Subject: [PATCH] freebl: add a configure option to disable ARM HW crypto
@ -15,19 +15,19 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
2 files changed, 5 insertions(+)
diff --git a/nss/lib/freebl/Makefile b/nss/lib/freebl/Makefile
index fe8c526..922f67c 100644
index b38889f..4616aac 100644
--- a/nss/lib/freebl/Makefile
+++ b/nss/lib/freebl/Makefile
@@ -125,6 +125,8 @@ else
DEFINES += -DNSS_X86
endif
@@ -139,6 +139,8 @@ endif
endif
endif
endif
+ifdef NSS_USE_ARM_HW_CRYPTO
+ DEFINES += -DNSS_USE_ARM_HW_CRYPTO
ifeq ($(CPU_ARCH),aarch64)
ifdef CC_IS_CLANG
DEFINES += -DUSE_HW_AES -DUSE_HW_SHA1 -DUSE_HW_SHA2
@@ -166,6 +168,7 @@ endif
@@ -180,6 +182,7 @@ endif
endif
endif
endif
@ -36,7 +36,7 @@ index fe8c526..922f67c 100644
ifeq ($(OS_TARGET),OSF1)
DEFINES += -DMP_ASSEMBLY_MULTIPLY -DMP_NO_MP_WORD
diff --git a/nss/lib/freebl/gcm.c b/nss/lib/freebl/gcm.c
index c2cc18d..b77f573 100644
index ac461b4..04cb180 100644
--- a/nss/lib/freebl/gcm.c
+++ b/nss/lib/freebl/gcm.c
@@ -18,6 +18,7 @@

View File

@ -1,4 +1,4 @@
From 8cea16e7550ae14494fbb3a8fe9f5452e6bd1407 Mon Sep 17 00:00:00 2001
From 919fc5d674fae99fe21ba1351d98b75e466f425f Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Wed, 22 Feb 2017 11:36:11 +0200
Subject: [PATCH] nss: fix support cross compiling
@ -15,10 +15,15 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/nss/coreconf/arch.mk b/nss/coreconf/arch.mk
index 790372d..2563134 100644
index 2012d18..78fca62 100644
--- a/nss/coreconf/arch.mk
+++ b/nss/coreconf/arch.mk
@@ -30,7 +30,7 @@ OS_TEST := $(shell uname -m)
@@ -26,11 +26,11 @@ OS_ARCH := $(subst /,_,$(shell uname -s)
# Attempt to differentiate between sparc and x86 Solaris
#
-OS_TEST := $(shell uname -m)
+OS_TEST ?= $(shell uname -m)
ifeq ($(OS_TEST),i86pc)
OS_RELEASE := $(shell uname -r)_$(OS_TEST)
else
@ -28,7 +33,7 @@ index 790372d..2563134 100644
#
diff --git a/nss/lib/freebl/Makefile b/nss/lib/freebl/Makefile
index 52d827c..f99f769 100644
index 0b8c6f4..b38889f 100644
--- a/nss/lib/freebl/Makefile
+++ b/nss/lib/freebl/Makefile
@@ -36,6 +36,12 @@ ifdef USE_64

View File

@ -1,4 +1,4 @@
From c5b2c6327f3692ed07bf8d212123e0bf08485722 Mon Sep 17 00:00:00 2001
From f613c9a9107435a40d91329f33f12cfb16927f07 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sat, 7 Mar 2020 08:34:02 -0800
Subject: [PATCH] nss,nspr: Add recipes

View File

@ -1,4 +1,4 @@
From 028ec9c7e9f7a6f083eec987f3ad7e7623398d9d Mon Sep 17 00:00:00 2001
From 2ce67b1f4b1f582d556ae058da10698bbaa0edc1 Mon Sep 17 00:00:00 2001
From: Ovidiu Panait <ovidiu.panait@windriver.com>
Date: Mon, 13 Jul 2020 12:12:31 +0300
Subject: [PATCH] nss: fix incorrect shebang of perl

View File

@ -1,4 +1,4 @@
From 2701905e689cf7c1ee7ca2d116f20b5bbc146431 Mon Sep 17 00:00:00 2001
From f9b2b1c738576a17460aebd005f511f427aa1974 Mon Sep 17 00:00:00 2001
From: Wenzong Fan <wenzong.fan@windriver.com>
Date: Sat, 7 Mar 2020 08:34:02 -0800
Subject: [PATCH] Fix nss multilib build on openSUSE 11.x 32bit

View File

@ -1,4 +1,4 @@
From dc51214895bcd63fc8eb8d1fe7941cd3e5500620 Mon Sep 17 00:00:00 2001
From 73edfbdf33fe4e41724e7e947033d8caeec8f3d0 Mon Sep 17 00:00:00 2001
From: Hongxu Jia <hongxu.jia@windriver.com>
Date: Sat, 7 Mar 2020 08:34:02 -0800
Subject: [PATCH] nss:no rpath for cross compiling

View File

@ -1,4 +1,4 @@
From a550bdf458f11dff46ebddbac94cf48c27d3471e Mon Sep 17 00:00:00 2001
From cbd367160338847b28fc801a12c74f1c8b5b03ee Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sat, 7 Mar 2020 08:34:02 -0800
Subject: [PATCH] nss does not build on mips with clang because wrong types are
@ -16,7 +16,7 @@ Upstream-Status: Pending
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/nss/lib/freebl/pqg.c b/nss/lib/freebl/pqg.c
index 626b2fb..052ad36 100644
index 1b03278..ad895b7 100644
--- a/nss/lib/freebl/pqg.c
+++ b/nss/lib/freebl/pqg.c
@@ -326,8 +326,8 @@ generate_h_candidate(SECItem *hit, mp_int *H)

View File

@ -9,7 +9,7 @@ HOMEPAGE = "http://www.mozilla.org/projects/security/pki/nss/"
SECTION = "libs"
DEPENDS = "sqlite3 nspr zlib nss-native"
DEPENDS_class-native = "sqlite3-native nspr-native zlib-native"
DEPENDS:class-native = "sqlite3-native nspr-native zlib-native"
LICENSE = "(MPL-2.0 & MIT) | (MPL-2.0 & GPL-2.0-or-later & MIT) | (MPL-2.0 & LGPL-2.1-or-later & MIT)"
@ -20,7 +20,7 @@ LIC_FILES_CHKSUM = "file://nss/COPYING;md5=3b1e88e1b9c0b5a4b2881d46cce06a18 \
VERSION_DIR = "${@d.getVar('BP').upper().replace('-', '_').replace('.', '_') + '_RTM'}"
SRC_URI = "http://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/${VERSION_DIR}/src/${BP}.tar.gz \
SRC_URI = "http://ftp.mozilla.org/pub/security/nss/releases/${VERSION_DIR}/src/${BP}.tar.gz \
file://nss.pc.in \
file://0001-nss-fix-support-cross-compiling.patch \
file://nss-no-rpath-for-cross-compiling.patch \
@ -32,8 +32,9 @@ SRC_URI = "http://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/${VERSIO
file://system-pkcs11.txt \
file://nss-fix-nsinstall-build.patch \
file://0001-freebl-add-a-configure-option-to-disable-ARM-HW-cryp.patch \
file://0001-Bug-1750624-Pin-validation-date-for-PayPalEE-test-ce.patch \
"
SRC_URI[sha256sum] = "d3175427172e9c3a6f1ebc74452cb791590f28191c6a1a443dbc0d87c9df1126"
SRC_URI[sha256sum] = "88928811f9f40f87d42e2eaccdf6e454562e51486067f2ddbe90aa47ea6cd056"
UPSTREAM_CHECK_URI = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_Releases"
UPSTREAM_CHECK_REGEX = "NSS_(?P<pver>.+)_release_notes"
@ -43,12 +44,10 @@ inherit siteinfo
TD = "${S}/tentative-dist"
TDS = "${S}/tentative-dist-staging"
# cortex-a55 is ARMv8.2-a based but libatomic explicitly asks for -march=armv8.1-a
# which caused -march conflicts in gcc
TUNE_CCARGS:remove = "-mcpu=cortex-a55+crc -mcpu=cortex-a55 -mcpu=cortex-a55+crc+crypto"
TARGET_CC_ARCH += "${LDFLAGS}"
CFLAGS:append:class-native = " -D_XOPEN_SOURCE "
do_configure:prepend:libc-musl () {
sed -i -e '/-DHAVE_SYS_CDEFS_H/d' ${S}/nss/lib/dbm/config/config.mk
}
@ -96,6 +95,7 @@ do_compile() {
export NS_USE_GCC=1
export NSS_USE_SYSTEM_SQLITE=1
export NSS_ENABLE_ECC=1
export NSS_ENABLE_WERROR=0
${@bb.utils.contains("TUNE_FEATURES", "crypto", "export NSS_USE_ARM_HW_CRYPTO=1", "", d)}
@ -280,3 +280,11 @@ FILES:${PN}-dev = "\
RDEPENDS:${PN}-smime = "perl"
BBCLASSEXTEND = "native nativesdk"
CVE_PRODUCT += "network_security_services"
CVE_STATUS_GROUPS += "CVE_STATUS_NSS"
CVE_STATUS_NSS[status] = "not-applicable-config: This only affect the legacy db (libnssdbm), only compiled with --enable-legacy-db"
CVE_STATUS_NSS = "CVE-2017-11695 CVE-2017-11696 CVE-2017-11697 CVE-2017-11698"
CVE_STATUS[CVE-2022-3479] = "not-applicable-config: vulnerability was introduced in 3.77 and fixed in 3.87"

View File

@ -1,21 +0,0 @@
DESCRIPTION = "boot image with UEFI shell and tools"
COMPATIBLE_HOST:class-target='(i.86|x86_64).*'
# For this image recipe, only the wic format with a
# single vfat partition makes sense. Because we have no
# boot loader and no rootfs partition, not additional
# tools are needed for this .wks file.
IMAGE_FSTYPES:forcevariable = 'wic'
WKS_FILE = "ovmf/ovmf-shell-image.wks"
WKS_FILE_DEPENDS = ""
inherit image
# We want a minimal image with just ovmf-shell-efi unpacked in it. We
# avoid installing unnecessary stuff as much as possible, but some
# things still get through and need to be removed.
PACKAGE_INSTALL = "ovmf-shell-efi"
LINGUAS_INSTALL = ""
do_image () {
rm -rf `ls -d ${IMAGE_ROOTFS}/* | grep -v efi`
}

View File

@ -1,33 +0,0 @@
From 1125f5a02c2f327aeffe2d6b66a9d816ad2eeec0 Mon Sep 17 00:00:00 2001
From: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
Date: Thu, 9 Jun 2016 02:23:01 -0700
Subject: [PATCH 1/6] ovmf: update path to native BaseTools
BaseTools is a set of utilities to build EDK-based firmware. These utilities
are used during the build process. Thus, they need to be built natively.
When cross-compiling, we need to provide a path to the location of these
tools. The BBAKE_EDK_TOOLS_PATH string is used as a pattern to be replaced
with the appropriate location before building.
Signed-off-by: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
Upstream-Status: Pending
---
OvmfPkg/build.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/OvmfPkg/build.sh b/OvmfPkg/build.sh
index 91b1442ade..1858dae31a 100755
--- a/OvmfPkg/build.sh
+++ b/OvmfPkg/build.sh
@@ -24,7 +24,7 @@ then
# this assumes svn pulls have the same root dir
# export EDK_TOOLS_PATH=`pwd`/../BaseTools
# This version is for the tools source in edk2
- export EDK_TOOLS_PATH=`pwd`/BaseTools
+ export EDK_TOOLS_PATH=BBAKE_EDK_TOOLS_PATH/BaseTools
echo $EDK_TOOLS_PATH
source edksetup.sh BaseTools
else
--
2.32.0

View File

@ -1,66 +0,0 @@
From 19d4c7f9812062a683b3ba60b35aac0461190456 Mon Sep 17 00:00:00 2001
From: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
Date: Fri, 26 Jul 2019 17:34:26 -0400
Subject: [PATCH 2/6] BaseTools: makefile: adjust to build in under bitbake
Prepend the build flags with those of bitbake. This is to build
using the bitbake native sysroot include and library directories.
Signed-off-by: Ricardo Neri <ricardo.neri@linux.intel.com>
Upstream-Status: Pending
---
BaseTools/Source/C/Makefiles/header.makefile | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/BaseTools/Source/C/Makefiles/header.makefile b/BaseTools/Source/C/Makefiles/header.makefile
index 0df728f327..1299d47c87 100644
--- a/BaseTools/Source/C/Makefiles/header.makefile
+++ b/BaseTools/Source/C/Makefiles/header.makefile
@@ -75,35 +75,36 @@ $(error Bad HOST_ARCH)
endif
INCLUDE = $(TOOL_INCLUDE) -I $(MAKEROOT) -I $(MAKEROOT)/Include/Common -I $(MAKEROOT)/Include/ -I $(MAKEROOT)/Include/IndustryStandard -I $(MAKEROOT)/Common/ -I .. -I . $(ARCH_INCLUDE)
-BUILD_CPPFLAGS = $(INCLUDE)
+BUILD_CPPFLAGS += $(INCLUDE)
# keep EXTRA_OPTFLAGS last
BUILD_OPTFLAGS = -O2 $(EXTRA_OPTFLAGS)
ifeq ($(DARWIN),Darwin)
# assume clang or clang compatible flags on OS X
-BUILD_CFLAGS = -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror \
+BUILD_CFLAGS += -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror \
-Wno-deprecated-declarations -Wno-self-assign -Wno-unused-result -nostdlib -g
else
ifeq ($(CXX), llvm)
-BUILD_CFLAGS = -MD -fshort-wchar -fno-strict-aliasing -fwrapv \
+BUILD_CFLAGS += -MD -fshort-wchar -fno-strict-aliasing -fwrapv \
-fno-delete-null-pointer-checks -Wall -Werror \
-Wno-deprecated-declarations -Wno-self-assign \
-Wno-unused-result -nostdlib -g
else
-BUILD_CFLAGS = -MD -fshort-wchar -fno-strict-aliasing -fwrapv \
+BUILD_CFLAGS += -MD -fshort-wchar -fno-strict-aliasing -fwrapv \
-fno-delete-null-pointer-checks -Wall -Werror \
-Wno-deprecated-declarations -Wno-stringop-truncation -Wno-restrict \
-Wno-unused-result -nostdlib -g
endif
endif
ifeq ($(CXX), llvm)
-BUILD_LFLAGS =
-BUILD_CXXFLAGS = -Wno-deprecated-register -Wno-unused-result
+BUILD_LFLAGS = $(LDFLAGS)
+BUILD_CXXFLAGS += -Wno-deprecated-register -Wno-unused-result
else
-BUILD_LFLAGS =
-BUILD_CXXFLAGS = -Wno-unused-result
+BUILD_LFLAGS = $(LDFLAGS)
+BUILD_CXXFLAGS += -Wno-unused-result
endif
+
ifeq ($(HOST_ARCH), IA32)
#
# Snow Leopard is a 32-bit and 64-bit environment. uname -m returns i386, but gcc defaults
--
2.32.0

View File

@ -1,104 +0,0 @@
From 860bb1979f3578bb83257076fe0f3bd33f9d68bf Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Mon, 14 Jun 2021 19:56:28 +0200
Subject: [PATCH 5/6] debug prefix map
We want to pass ${DEBUG_PREFIX_MAP} to gcc commands and also pass in
--debug-prefix-map to nasm (we carry a patch to nasm for this). The
tools definitions file is built by ovmf-native so we need to pass this in
at target build time when we know the right values so we use the environment.
By using determininistc file paths during the ovmf build, it removes the
opportunitity for gcc/ld to change the output binaries due to path lengths
overflowing section sizes and causing small changes in the binary output.
Previously we relied on the stripped output being the same which isn't always
the case if the size of the debug symbols varies.
Upstream-Status: Submitted [https://github.com/tianocore/edk2/pull/2202]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
BaseTools/Conf/tools_def.template | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template
index 36241b6ede..947fbf2e8d 100755
--- a/BaseTools/Conf/tools_def.template
+++ b/BaseTools/Conf/tools_def.template
@@ -1863,7 +1863,7 @@ NOOPT_*_*_OBJCOPY_ADDDEBUGFLAG = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_N
*_*_*_DTCPP_PATH = DEF(DTCPP_BIN)
*_*_*_DTC_PATH = DEF(DTC_BIN)
-DEFINE GCC_ALL_CC_FLAGS = -g -Os -fshort-wchar -fno-builtin -fno-strict-aliasing -Wall -Werror -Wno-array-bounds -include AutoGen.h -fno-common
+DEFINE GCC_ALL_CC_FLAGS = -g -Os -fshort-wchar -fno-builtin -fno-strict-aliasing -Wall -Werror -Wno-array-bounds -include AutoGen.h -fno-common ENV(GCC_PREFIX_MAP)
DEFINE GCC_IA32_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -m32 -malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-stack-arg-probe
DEFINE GCC_X64_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mno-red-zone -Wno-address -mno-stack-arg-probe
DEFINE GCC_ARM_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mlittle-endian -mabi=aapcs -fno-short-enums -funsigned-char -ffunction-sections -fdata-sections -fomit-frame-pointer -Wno-address -mthumb -mfloat-abi=soft -fno-pic -fno-pie
@@ -1881,8 +1881,8 @@ DEFINE GCC_IA32_X64_ASLDLINK_FLAGS = DEF(GCC_IA32_X64_DLINK_COMMON) --entry _Ref
DEFINE GCC_ARM_ASLDLINK_FLAGS = DEF(GCC_ARM_DLINK_FLAGS) -Wl,--entry,ReferenceAcpiTable -u $(IMAGE_ENTRY_POINT) DEF(GCC_ARM_AARCH64_ASLDLINK_FLAGS)
DEFINE GCC_AARCH64_ASLDLINK_FLAGS = DEF(GCC_AARCH64_DLINK_FLAGS) -Wl,--entry,ReferenceAcpiTable -u $(IMAGE_ENTRY_POINT) DEF(GCC_ARM_AARCH64_ASLDLINK_FLAGS)
DEFINE GCC_IA32_X64_DLINK_FLAGS = DEF(GCC_IA32_X64_DLINK_COMMON) --entry _$(IMAGE_ENTRY_POINT) --file-alignment 0x20 --section-alignment 0x20 -Map $(DEST_DIR_DEBUG)/$(BASE_NAME).map
-DEFINE GCC_ASM_FLAGS = -c -x assembler -imacros AutoGen.h
-DEFINE GCC_PP_FLAGS = -E -x assembler-with-cpp -include AutoGen.h
+DEFINE GCC_ASM_FLAGS = -c -x assembler -imacros AutoGen.h ENV(GCC_PREFIX_MAP)
+DEFINE GCC_PP_FLAGS = -E -x assembler-with-cpp -include AutoGen.h ENV(GCC_PREFIX_MAP)
DEFINE GCC_VFRPP_FLAGS = -x c -E -P -DVFRCOMPILE --include $(MODULE_NAME)StrDefs.h
DEFINE GCC_ASLPP_FLAGS = -x c -E -include AutoGen.h
DEFINE GCC_ASLCC_FLAGS = -x c
@@ -2027,7 +2027,7 @@ DEFINE GCC_PP_FLAGS = -E -x assembler-with-cpp -include A
*_GCC48_IA32_DLINK2_FLAGS = DEF(GCC48_IA32_DLINK2_FLAGS)
*_GCC48_IA32_RC_FLAGS = DEF(GCC_IA32_RC_FLAGS)
*_GCC48_IA32_OBJCOPY_FLAGS =
-*_GCC48_IA32_NASM_FLAGS = -f elf32
+*_GCC48_IA32_NASM_FLAGS = -f elf32 ENV(NASM_PREFIX_MAP)
DEBUG_GCC48_IA32_CC_FLAGS = DEF(GCC48_IA32_CC_FLAGS) -Os
RELEASE_GCC48_IA32_CC_FLAGS = DEF(GCC48_IA32_CC_FLAGS) -Os -Wno-unused-but-set-variable
@@ -2055,7 +2055,7 @@ RELEASE_GCC48_IA32_CC_FLAGS = DEF(GCC48_IA32_CC_FLAGS) -Os -Wno-unused-but
*_GCC48_X64_DLINK2_FLAGS = DEF(GCC48_X64_DLINK2_FLAGS)
*_GCC48_X64_RC_FLAGS = DEF(GCC_X64_RC_FLAGS)
*_GCC48_X64_OBJCOPY_FLAGS =
-*_GCC48_X64_NASM_FLAGS = -f elf64
+*_GCC48_X64_NASM_FLAGS = -f elf64 ENV(NASM_PREFIX_MAP)
DEBUG_GCC48_X64_CC_FLAGS = DEF(GCC48_X64_CC_FLAGS) -Os
RELEASE_GCC48_X64_CC_FLAGS = DEF(GCC48_X64_CC_FLAGS) -Os -Wno-unused-but-set-variable
@@ -2167,7 +2167,7 @@ RELEASE_GCC48_AARCH64_CC_FLAGS = DEF(GCC48_AARCH64_CC_FLAGS) -Wno-unused-but-s
*_GCC49_IA32_DLINK2_FLAGS = DEF(GCC49_IA32_DLINK2_FLAGS)
*_GCC49_IA32_RC_FLAGS = DEF(GCC_IA32_RC_FLAGS)
*_GCC49_IA32_OBJCOPY_FLAGS =
-*_GCC49_IA32_NASM_FLAGS = -f elf32
+*_GCC49_IA32_NASM_FLAGS = -f elf32 ENV(NASM_PREFIX_MAP)
DEBUG_GCC49_IA32_CC_FLAGS = DEF(GCC49_IA32_CC_FLAGS) -Os
RELEASE_GCC49_IA32_CC_FLAGS = DEF(GCC49_IA32_CC_FLAGS) -Os -Wno-unused-but-set-variable -Wno-unused-const-variable
@@ -2195,7 +2195,7 @@ RELEASE_GCC49_IA32_CC_FLAGS = DEF(GCC49_IA32_CC_FLAGS) -Os -Wno-unused-but
*_GCC49_X64_DLINK2_FLAGS = DEF(GCC49_X64_DLINK2_FLAGS)
*_GCC49_X64_RC_FLAGS = DEF(GCC_X64_RC_FLAGS)
*_GCC49_X64_OBJCOPY_FLAGS =
-*_GCC49_X64_NASM_FLAGS = -f elf64
+*_GCC49_X64_NASM_FLAGS = -f elf64 ENV(NASM_PREFIX_MAP)
DEBUG_GCC49_X64_CC_FLAGS = DEF(GCC49_X64_CC_FLAGS) -Os
RELEASE_GCC49_X64_CC_FLAGS = DEF(GCC49_X64_CC_FLAGS) -Os -Wno-unused-but-set-variable -Wno-unused-const-variable
@@ -2313,7 +2313,7 @@ RELEASE_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-size=0x20
*_GCC5_IA32_DLINK2_FLAGS = DEF(GCC5_IA32_DLINK2_FLAGS) -no-pie
*_GCC5_IA32_RC_FLAGS = DEF(GCC_IA32_RC_FLAGS)
*_GCC5_IA32_OBJCOPY_FLAGS =
-*_GCC5_IA32_NASM_FLAGS = -f elf32
+*_GCC5_IA32_NASM_FLAGS = -f elf32 ENV(NASM_PREFIX_MAP)
DEBUG_GCC5_IA32_CC_FLAGS = DEF(GCC5_IA32_CC_FLAGS) -flto -Os
DEBUG_GCC5_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Os -Wl,-m,elf_i386,--oformat=elf32-i386
@@ -2345,7 +2345,7 @@ RELEASE_GCC5_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Os -Wl,
*_GCC5_X64_DLINK2_FLAGS = DEF(GCC5_X64_DLINK2_FLAGS)
*_GCC5_X64_RC_FLAGS = DEF(GCC_X64_RC_FLAGS)
*_GCC5_X64_OBJCOPY_FLAGS =
-*_GCC5_X64_NASM_FLAGS = -f elf64
+*_GCC5_X64_NASM_FLAGS = -f elf64 ENV(NASM_PREFIX_MAP)
DEBUG_GCC5_X64_CC_FLAGS = DEF(GCC5_X64_CC_FLAGS) -flto -DUSING_LTO -Os
DEBUG_GCC5_X64_DLINK_FLAGS = DEF(GCC5_X64_DLINK_FLAGS) -flto -Os
--
2.32.0

View File

@ -1,180 +0,0 @@
From 27ed9962f5cb3afcc44d6c96c53277132a999712 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Mon, 14 Jun 2021 19:57:30 +0200
Subject: [PATCH 6/6] reproducible
This patch fixes various things which make the build more reproducible. Some changes
here only change intermediate artefacts but that means when you have two build trees
giving differing results, the differences can be isolated more easily. The issues here
usually become apparent with longer paths.
This was all debugged with:
TMPDIR = "${TOPDIR}/tmp"
vs.
TMPDIR = "${TOPDIR}/tmp-inital-mylongpath-mylongpath-mylongpath-mylongpath-mylongpath-mylongpath-mylongpath-mylongpath-mylongpath"
The patch specifically:
* Sorts output in GNUmakefile
* Always generates indirect flags files used to avoid pathlength issues else the
compile commands suddenly change when using longer paths
* Sorts the AutoGenTimeStamp file contents
* Makes the TargetDescBlock objects from BuildEngine sortable to allow the makefile fix
* Fix ElfConvert within GenFw so that only the basename of the binary being converted
is used, else the output from "GenFw XXX.bin" differs from "GenFw /long/path/XXX.bin"
with sufficiently long paths
Upstream-Status: Submitted [https://github.com/tianocore/edk2/pull/2176]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
BaseTools/Source/C/GenFw/Elf64Convert.c | 8 ++++---
.../Source/Python/AutoGen/BuildEngine.py | 3 +++
BaseTools/Source/Python/AutoGen/GenMake.py | 24 +++++++++----------
.../Source/Python/AutoGen/ModuleAutoGen.py | 5 +++-
4 files changed, 24 insertions(+), 16 deletions(-)
diff --git a/BaseTools/Source/C/GenFw/Elf64Convert.c b/BaseTools/Source/C/GenFw/Elf64Convert.c
index d097db8632..a87ae6f3d0 100644
--- a/BaseTools/Source/C/GenFw/Elf64Convert.c
+++ b/BaseTools/Source/C/GenFw/Elf64Convert.c
@@ -14,6 +14,8 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
#ifndef __GNUC__
#include <windows.h>
#include <io.h>
+#else
+#define _GNU_SOURCE
#endif
#include <assert.h>
#include <stdio.h>
@@ -769,7 +771,7 @@ ScanSections64 (
}
mCoffOffset = mDebugOffset + sizeof(EFI_IMAGE_DEBUG_DIRECTORY_ENTRY) +
sizeof(EFI_IMAGE_DEBUG_CODEVIEW_NB10_ENTRY) +
- strlen(mInImageName) + 1;
+ strlen(basename(mInImageName)) + 1;
mCoffOffset = CoffAlign(mCoffOffset);
if (SectionCount == 0) {
@@ -1608,7 +1610,7 @@ WriteDebug64 (
EFI_IMAGE_DEBUG_DIRECTORY_ENTRY *Dir;
EFI_IMAGE_DEBUG_CODEVIEW_NB10_ENTRY *Nb10;
- Len = strlen(mInImageName) + 1;
+ Len = strlen(basename(mInImageName)) + 1;
Dir = (EFI_IMAGE_DEBUG_DIRECTORY_ENTRY*)(mCoffFile + mDebugOffset);
Dir->Type = EFI_IMAGE_DEBUG_TYPE_CODEVIEW;
@@ -1618,7 +1620,7 @@ WriteDebug64 (
Nb10 = (EFI_IMAGE_DEBUG_CODEVIEW_NB10_ENTRY*)(Dir + 1);
Nb10->Signature = CODEVIEW_SIGNATURE_NB10;
- strcpy ((char *)(Nb10 + 1), mInImageName);
+ strcpy ((char *)(Nb10 + 1), basename(mInImageName));
NtHdr = (EFI_IMAGE_OPTIONAL_HEADER_UNION *)(mCoffFile + mNtHdrOffset);
diff --git a/BaseTools/Source/Python/AutoGen/BuildEngine.py b/BaseTools/Source/Python/AutoGen/BuildEngine.py
index 722fead75a..8f1c236970 100644
--- a/BaseTools/Source/Python/AutoGen/BuildEngine.py
+++ b/BaseTools/Source/Python/AutoGen/BuildEngine.py
@@ -70,6 +70,9 @@ class TargetDescBlock(object):
else:
return str(Other) == self.Target.Path
+ def __lt__(self, other):
+ return str(self) < str(other)
+
def AddInput(self, Input):
if Input not in self.Inputs:
self.Inputs.append(Input)
diff --git a/BaseTools/Source/Python/AutoGen/GenMake.py b/BaseTools/Source/Python/AutoGen/GenMake.py
index 961b2ab1c3..23c1592025 100755
--- a/BaseTools/Source/Python/AutoGen/GenMake.py
+++ b/BaseTools/Source/Python/AutoGen/GenMake.py
@@ -575,7 +575,7 @@ cleanlib:
os.remove(RespFileList)
# convert source files and binary files to build targets
- self.ResultFileList = [str(T.Target) for T in MyAgo.CodaTargetList]
+ self.ResultFileList = sorted([str(T.Target) for T in MyAgo.CodaTargetList])
if len(self.ResultFileList) == 0 and len(MyAgo.SourceFileList) != 0:
EdkLogger.error("build", AUTOGEN_ERROR, "Nothing to build",
ExtraData="[%s]" % str(MyAgo))
@@ -726,7 +726,7 @@ cleanlib:
OutputFile = ''
DepsFileList = []
- for Cmd in self.GenFfsList:
+ for Cmd in sorted(self.GenFfsList):
if Cmd[2]:
for CopyCmd in Cmd[2]:
Src, Dst = CopyCmd
@@ -759,7 +759,7 @@ cleanlib:
self.BuildTargetList.append('\t%s' % CmdString)
self.ParseSecCmd(DepsFileList, Cmd[1])
- for SecOutputFile, SecDepsFile, SecCmd in self.FfsOutputFileList :
+ for SecOutputFile, SecDepsFile, SecCmd in sorted(self.FfsOutputFileList):
self.BuildTargetList.append('%s : %s' % (self.ReplaceMacro(SecOutputFile), self.ReplaceMacro(SecDepsFile)))
self.BuildTargetList.append('\t%s' % self.ReplaceMacro(SecCmd))
self.FfsOutputFileList = []
@@ -798,13 +798,13 @@ cleanlib:
def CommandExceedLimit(self):
FlagDict = {
- 'CC' : { 'Macro' : '$(CC_FLAGS)', 'Value' : False},
- 'PP' : { 'Macro' : '$(PP_FLAGS)', 'Value' : False},
- 'APP' : { 'Macro' : '$(APP_FLAGS)', 'Value' : False},
- 'ASLPP' : { 'Macro' : '$(ASLPP_FLAGS)', 'Value' : False},
- 'VFRPP' : { 'Macro' : '$(VFRPP_FLAGS)', 'Value' : False},
- 'ASM' : { 'Macro' : '$(ASM_FLAGS)', 'Value' : False},
- 'ASLCC' : { 'Macro' : '$(ASLCC_FLAGS)', 'Value' : False},
+ 'CC' : { 'Macro' : '$(CC_FLAGS)', 'Value' : True},
+ 'PP' : { 'Macro' : '$(PP_FLAGS)', 'Value' : True},
+ 'APP' : { 'Macro' : '$(APP_FLAGS)', 'Value' : True},
+ 'ASLPP' : { 'Macro' : '$(ASLPP_FLAGS)', 'Value' : True},
+ 'VFRPP' : { 'Macro' : '$(VFRPP_FLAGS)', 'Value' : True},
+ 'ASM' : { 'Macro' : '$(ASM_FLAGS)', 'Value' : True},
+ 'ASLCC' : { 'Macro' : '$(ASLCC_FLAGS)', 'Value' : True},
}
RespDict = {}
@@ -1007,9 +1007,9 @@ cleanlib:
if not self.ObjTargetDict.get(T.Target.SubDir):
self.ObjTargetDict[T.Target.SubDir] = set()
self.ObjTargetDict[T.Target.SubDir].add(NewFile)
- for Type in self._AutoGenObject.Targets:
+ for Type in sorted(self._AutoGenObject.Targets):
resp_file_number = 0
- for T in self._AutoGenObject.Targets[Type]:
+ for T in sorted(self._AutoGenObject.Targets[Type]):
# Generate related macros if needed
if T.GenFileListMacro and T.FileListMacro not in self.FileListMacros:
self.FileListMacros[T.FileListMacro] = []
diff --git a/BaseTools/Source/Python/AutoGen/ModuleAutoGen.py b/BaseTools/Source/Python/AutoGen/ModuleAutoGen.py
index d70b0d7ae8..25dca9a6df 100755
--- a/BaseTools/Source/Python/AutoGen/ModuleAutoGen.py
+++ b/BaseTools/Source/Python/AutoGen/ModuleAutoGen.py
@@ -1484,6 +1484,9 @@ class ModuleAutoGen(AutoGen):
for File in Files:
if File.lower().endswith('.pdb'):
AsBuiltInfDict['binary_item'].append('DISPOSABLE|' + File)
+
+ AsBuiltInfDict['binary_item'] = sorted(AsBuiltInfDict['binary_item'])
+
HeaderComments = self.Module.HeaderComments
StartPos = 0
for Index in range(len(HeaderComments)):
@@ -1759,7 +1762,7 @@ class ModuleAutoGen(AutoGen):
if os.path.exists (self.TimeStampPath):
os.remove (self.TimeStampPath)
- SaveFileOnChange(self.TimeStampPath, "\n".join(FileSet), False)
+ SaveFileOnChange(self.TimeStampPath, "\n".join(sorted(FileSet)), False)
# Ignore generating makefile when it is a binary module
if self.IsBinaryModule:
--
2.32.0

View File

@ -1,4 +0,0 @@
# short-description: Create an EFI disk image with just the EFI system partition
part / --source rootfs --ondisk sda --fstype=vfat --align 1024
bootloader --ptable gpt --timeout=5

View File

@ -1,265 +0,0 @@
SUMMARY = "OVMF - UEFI firmware for Qemu and KVM"
DESCRIPTION = "OVMF is an EDK II based project to enable UEFI support for \
Virtual Machines. OVMF contains sample UEFI firmware for QEMU and KVM"
HOMEPAGE = "https://github.com/tianocore/tianocore.github.io/wiki/OVMF"
LICENSE = "BSD-2-Clause-Patent"
LICENSE:class-target = "${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'BSD-2-Clause-Patent & OpenSSL', 'BSD-2-Clause-Patent', d)}"
LIC_FILES_CHKSUM = "file://OvmfPkg/License.txt;md5=06357ddc23f46577c2aeaeaf7b776d65"
# Enabling Secure Boot adds a dependency on OpenSSL and implies
# compiling OVMF twice, so it is disabled by default. Distros
# may change that default.
PACKAGECONFIG ??= ""
PACKAGECONFIG += "${@bb.utils.contains('MACHINE_FEATURES', 'tpm', 'tpm', '', d)}"
PACKAGECONFIG += "${@bb.utils.contains('MACHINE_FEATURES', 'tpm2', 'tpm', '', d)}"
PACKAGECONFIG[secureboot] = ",,,"
PACKAGECONFIG[tpm] = "-D TPM_ENABLE=TRUE,-D TPM_ENABLE=FALSE,,"
# GCC12 trips on it
#see https://src.fedoraproject.org/rpms/edk2/blob/rawhide/f/0032-Basetools-turn-off-gcc12-warning.patch
BUILD_CFLAGS += "-Wno-error=stringop-overflow"
SRC_URI = "gitsm://github.com/tianocore/edk2.git;branch=master;protocol=https \
file://0001-ovmf-update-path-to-native-BaseTools.patch \
file://0002-BaseTools-makefile-adjust-to-build-in-under-bitbake.patch \
file://0005-debug-prefix-map.patch \
file://0006-reproducible.patch \
"
PV = "edk2-stable202205"
SRCREV = "16779ede2d366bfc6b702e817356ccf43425bcc8"
UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>edk2-stable.*)"
inherit deploy
PARALLEL_MAKE = ""
S = "${WORKDIR}/git"
DEPENDS = "nasm-native acpica-native ovmf-native util-linux-native"
EDK_TOOLS_DIR="edk2_basetools"
# OVMF has trouble building with the default optimization of -O2.
BUILD_OPTIMIZATION="-pipe"
# OVMF supports IA only, although it could conceivably support ARM someday.
COMPATIBLE_HOST:class-target='(i.86|x86_64).*'
# Additional build flags for OVMF with Secure Boot.
# Fedora also uses "-D SMM_REQUIRE -D EXCLUDE_SHELL_FROM_FD".
OVMF_SECURE_BOOT_EXTRA_FLAGS ??= ""
OVMF_SECURE_BOOT_FLAGS = "-DSECURE_BOOT_ENABLE=TRUE ${OVMF_SECURE_BOOT_EXTRA_FLAGS}"
export PYTHON_COMMAND = "${HOSTTOOLS_DIR}/python3"
do_patch[postfuncs] += "fix_basetools_location"
fix_basetools_location () {
}
fix_basetools_location:class-target() {
# Replaces the fake path inserted by 0002-ovmf-update-path-to-native-BaseTools.patch.
# Necessary for finding the actual BaseTools from ovmf-native.
sed -i -e 's#BBAKE_EDK_TOOLS_PATH#${STAGING_BINDIR_NATIVE}/${EDK_TOOLS_DIR}#' ${S}/OvmfPkg/build.sh
}
do_patch[postfuncs] += "fix_iasl"
fix_iasl() {
}
fix_iasl:class-native() {
# iasl is not installed under /usr/bin when building with OE.
sed -i -e 's#/usr/bin/iasl#${STAGING_BINDIR_NATIVE}/iasl#' ${S}/BaseTools/Conf/tools_def.template
}
# Inject CC and friends into the build. LINKER already is in GNUmakefile.
# Must be idempotent and thus remove old assignments that were inserted
# earlier.
do_patch[postfuncs] += "fix_toolchain"
fix_toolchain() {
sed -i \
-e '/^\(CC\|CXX\|AS\|AR\|LD\|LINKER\) =/d' \
-e '/^APPLICATION/a CC = ${CC}\nCXX = ${CXX}\nAS = ${AS}\nAR = ${AR}\nLD = ${LD}\nLINKER = $(CC)' \
${S}/BaseTools/Source/C/Makefiles/app.makefile
sed -i \
-e '/^\(CC\|CXX\|AS\|AR\|LD\)/d' \
-e '/^VFR_CPPFLAGS/a CC = ${CC}\nCXX = ${CXX}\nAS = ${AS}\nAR = ${AR}\nLD = ${LD}' \
${S}/BaseTools/Source/C/VfrCompile/GNUmakefile
}
fix_toolchain:append:class-native() {
# This tools_def.template is going to be used by the target ovmf and
# defines which compilers to use. For the GCC toolchain definitions,
# that will be ${HOST_PREFIX}gcc. However, "make" doesn't need that
# prefix.
#
# Injecting ENV(HOST_PREFIX) matches exporting that value as env
# variable in do_compile:class-target.
sed -i \
-e 's#\(ENV\|DEF\)(GCC.*_PREFIX)#ENV(HOST_PREFIX)#' \
-e 's#ENV(HOST_PREFIX)make#make#' \
${S}/BaseTools/Conf/tools_def.template
sed -i \
-e '/^\(LFLAGS\|CFLAGS\) +=/d' \
-e '/^LINKER/a LFLAGS += ${BUILD_LDFLAGS}\nCFLAGS += ${BUILD_CFLAGS}' \
${S}/BaseTools/Source/C/Makefiles/app.makefile \
${S}/BaseTools/Source/C/VfrCompile/GNUmakefile
# Linking with gold fails:
# internal error in do_layout, at ../../gold/object.cc:1821
# make: *** [.../OUTPUT/Facs.acpi] Error 1
# We intentionally hard-code the use of ld.bfd regardless of DISTRO_FEATURES
# to make ovmf-native reusable across distros.
sed -i \
-e 's#^\(DEFINE GCC.*DLINK.*FLAGS *=\)#\1 -fuse-ld=bfd#' \
-e 's#-flto#-fno-lto#g' \
-e 's#-DUSING_LTO##g' \
${S}/BaseTools/Conf/tools_def.template
}
# We disable lto above since the results are not reproducible and make it hard to compare
# binary build aretfacts to debug reproducibility problems.
# Surprisingly, if you disable lto, you see compiler warnings which are fatal. We therefore
# have to hack warnings overrides into GCC_PREFIX_MAP to allow it to build.
# We want to pass ${DEBUG_PREFIX_MAP} to gcc commands and also pass in
# --debug-prefix-map to nasm (we carry a patch to nasm for this). The
# tools definitions are built by ovmf-native so we need to pass this in
# at target build time when we know the right values.
export NASM_PREFIX_MAP = "--debug-prefix-map=${WORKDIR}=/usr/src/debug/ovmf/${EXTENDPE}${PV}-${PR}"
export GCC_PREFIX_MAP = "${DEBUG_PREFIX_MAP} -Wno-stringop-overflow -Wno-maybe-uninitialized"
GCC_VER="$(${CC} -v 2>&1 | tail -n1 | awk '{print $3}')"
fixup_target_tools() {
case ${1} in
4.4.*)
FIXED_GCCVER=GCC44
;;
4.5.*)
FIXED_GCCVER=GCC45
;;
4.6.*)
FIXED_GCCVER=GCC46
;;
4.7.*)
FIXED_GCCVER=GCC47
;;
4.8.*)
FIXED_GCCVER=GCC48
;;
4.9.*)
FIXED_GCCVER=GCC49
;;
*)
FIXED_GCCVER=GCC5
;;
esac
echo ${FIXED_GCCVER}
}
do_compile:class-native() {
oe_runmake -C ${S}/BaseTools
}
do_compile:class-target() {
export LFLAGS="${LDFLAGS}"
PARALLEL_JOBS="${@oe.utils.parallel_make_argument(d, '-n %d')}"
OVMF_ARCH="X64"
if [ "${TARGET_ARCH}" != "x86_64" ] ; then
OVMF_ARCH="IA32"
fi
# The build for the target uses BaseTools/Conf/tools_def.template
# from ovmf-native to find the compiler, which depends on
# exporting HOST_PREFIX.
export HOST_PREFIX="${HOST_PREFIX}"
# BaseTools/Conf gets copied to Conf, but only if that does not
# exist yet. To ensure that an updated template gets used during
# incremental builds, we need to remove the copy before we start.
rm -f `ls ${S}/Conf/*.txt | grep -v ReadMe.txt`
# ${WORKDIR}/ovmf is a well-known location where do_install and
# do_deploy will be able to find the files.
rm -rf ${WORKDIR}/ovmf
mkdir ${WORKDIR}/ovmf
OVMF_DIR_SUFFIX="X64"
if [ "${TARGET_ARCH}" != "x86_64" ] ; then
OVMF_DIR_SUFFIX="Ia32" # Note the different capitalization
fi
FIXED_GCCVER=$(fixup_target_tools ${GCC_VER})
bbnote FIXED_GCCVER is ${FIXED_GCCVER}
build_dir="${S}/Build/Ovmf$OVMF_DIR_SUFFIX/RELEASE_${FIXED_GCCVER}"
bbnote "Building without Secure Boot."
rm -rf ${S}/Build/Ovmf$OVMF_DIR_SUFFIX
${S}/OvmfPkg/build.sh $PARALLEL_JOBS -a $OVMF_ARCH -b RELEASE -t ${FIXED_GCCVER} ${PACKAGECONFIG_CONFARGS}
ln ${build_dir}/FV/OVMF.fd ${WORKDIR}/ovmf/ovmf.fd
ln ${build_dir}/FV/OVMF_CODE.fd ${WORKDIR}/ovmf/ovmf.code.fd
ln ${build_dir}/FV/OVMF_VARS.fd ${WORKDIR}/ovmf/ovmf.vars.fd
ln ${build_dir}/${OVMF_ARCH}/Shell.efi ${WORKDIR}/ovmf/
if ${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'true', 'false', d)}; then
# Repeat build with the Secure Boot flags.
bbnote "Building with Secure Boot."
rm -rf ${S}/Build/Ovmf$OVMF_DIR_SUFFIX
${S}/OvmfPkg/build.sh $PARALLEL_JOBS -a $OVMF_ARCH -b RELEASE -t ${FIXED_GCCVER} ${PACKAGECONFIG_CONFARGS} ${OVMF_SECURE_BOOT_FLAGS}
ln ${build_dir}/FV/OVMF.fd ${WORKDIR}/ovmf/ovmf.secboot.fd
ln ${build_dir}/FV/OVMF_CODE.fd ${WORKDIR}/ovmf/ovmf.secboot.code.fd
ln ${build_dir}/${OVMF_ARCH}/EnrollDefaultKeys.efi ${WORKDIR}/ovmf/
fi
}
do_install:class-native() {
install -d ${D}/${bindir}/edk2_basetools
cp -r ${S}/BaseTools ${D}/${bindir}/${EDK_TOOLS_DIR}
}
do_install:class-target() {
# Content for UEFI shell iso. We install the EFI shell as
# bootx64/ia32.efi because then it can be started even when the
# firmware itself does not contain it.
install -d ${D}/efi/boot
install ${WORKDIR}/ovmf/Shell.efi ${D}/efi/boot/boot${@ "ia32" if "${TARGET_ARCH}" != "x86_64" else "x64"}.efi
if ${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'true', 'false', d)}; then
install ${WORKDIR}/ovmf/EnrollDefaultKeys.efi ${D}
fi
}
# This always gets packaged because ovmf-shell-image depends on it.
# This allows testing that recipe in all configurations because it
# can always be part of a world build.
#
# However, EnrollDefaultKeys.efi is only included when Secure Boot is enabled.
PACKAGES =+ "ovmf-shell-efi"
FILES:ovmf-shell-efi = " \
EnrollDefaultKeys.efi \
efi/ \
"
DEPLOYDEP = ""
DEPLOYDEP:class-target = "qemu-system-native:do_populate_sysroot"
DEPLOYDEP:class-target += " ${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'openssl-native:do_populate_sysroot', '', d)}"
do_deploy[depends] += "${DEPLOYDEP}"
do_deploy() {
}
do_deploy:class-target() {
# For use with "runqemu ovmf".
for i in \
ovmf \
ovmf.code \
ovmf.vars \
${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'ovmf.secboot ovmf.secboot.code', '', d)} \
; do
qemu-img convert -f raw -O qcow2 ${WORKDIR}/ovmf/$i.fd ${DEPLOYDIR}/$i.qcow2
done
if ${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'true', 'false', d)}; then
# Create a test Platform Key and first Key Exchange Key to use with EnrollDefaultKeys
openssl req -new -x509 -newkey rsa:2048 -keyout ${DEPLOYDIR}/OvmfPkKek1.key \
-out ${DEPLOYDIR}/OvmfPkKek1.crt -nodes -days 20 -subj "/CN=OVMFSecBootTest"
openssl x509 -in ${DEPLOYDIR}/OvmfPkKek1.crt -out ${DEPLOYDIR}/OvmfPkKek1.pem -outform PEM
fi
}
addtask do_deploy after do_compile before do_build
BBCLASSEXTEND = "native"
TOOLCHAIN = "gcc"

View File

@ -0,0 +1,23 @@
From fd457da60c963588a6423f4cf263e861078e8422 Mon Sep 17 00:00:00 2001
From: Bruce Leidl <bruce@subgraph.com>
Date: Wed, 27 Sep 2023 07:29:28 -0400
Subject: [PATCH] Added case for libinput custom accel profile
---
sway/ipc-json.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/sway/ipc-json.c b/sway/ipc-json.c
index 61613f53..16c4b858 100644
--- a/sway/ipc-json.c
+++ b/sway/ipc-json.c
@@ -905,6 +905,9 @@ static json_object *describe_libinput_device(struct libinput_device *device) {
case LIBINPUT_CONFIG_ACCEL_PROFILE_ADAPTIVE:
accel_profile = "adaptive";
break;
+ case LIBINPUT_CONFIG_ACCEL_PROFILE_CUSTOM:
+ accel_profile = "custom";
+ break;
}
json_object_object_add(object, "accel_profile",
json_object_new_string(accel_profile));

View File

@ -35,11 +35,11 @@ DEPENDS += " \
# wl-clipboard \
#"
SRC_URI = " \
git://github.com/swaywm/sway.git;protocol=https;branch=master \
file://config \
file://0001-Reinstate-wayland-0-as-starting-display-socket-for-C.patch \
"
SRC_URI = "git://github.com/swaywm/sway.git;protocol=https;branch=master \
file://config \
file://0001-Reinstate-wayland-0-as-starting-display-socket-for-C.patch \
file://0001-Added-case-for-libinput-custom-accel-profile.patch \
"
SRCREV = "9d99bb956fea8922f8e0196d67eabbd510c53f1f"
PV = "1.7"

View File

@ -1,42 +0,0 @@
SUMMARY = "Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API."
DESCRIPTION = "lxml is a Pythonic, mature binding for the libxml2 and \
libxslt libraries. It provides safe and convenient access to these \
libraries using the ElementTree API. It extends the ElementTree API \
significantly to offer support for XPath, RelaxNG, XML Schema, XSLT, \
C14N and much more."
HOMEPAGE = "https://lxml.de/"
SECTION = "devel/python"
LICENSE = "BSD-3-Clause & GPL-2.0-only & MIT & PSF-2.0"
LIC_FILES_CHKSUM = "file://LICENSES.txt;md5=e4c045ebad958ead4b48008f70838403 \
file://doc/licenses/elementtree.txt;md5=eb34d036a6e3d56314ee49a6852ac891 \
file://doc/licenses/BSD.txt;md5=700a1fc17f4797d4f2d34970c8ee694b \
file://doc/licenses/GPL.txt;md5=94d55d512a9ba36caa9b7df079bae19f \
file://src/lxml/isoschematron/resources/rng/iso-schematron.rng;beginline=2;endline=7;md5=fc85684a8dd5fa272c086bceb0d99e10 \
file://src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_schematron_message.xsl;beginline=2;endline=24;md5=cc86b7b2bbc678e13f58ea403eb9929b \
file://src/lxml/isoschematron/resources/xsl/RNG2Schtrn.xsl;beginline=2;endline=7;md5=5b03236d293dc3784205542b409d2f53 \
"
DEPENDS += "libxml2 libxslt"
SRC_URI[sha256sum] = "f63f62fc60e6228a4ca9abae28228f35e1bd3ce675013d1dfb828688d50c6e23"
SRC_URI += "${PYPI_SRC_URI}"
inherit pkgconfig pypi setuptools3
# {standard input}: Assembler messages:
# {standard input}:1488805: Error: branch out of range
DEBUG_OPTIMIZATION:remove:mips = " -Og"
DEBUG_OPTIMIZATION:append:mips = " -O"
BUILD_OPTIMIZATION:remove:mips = " -Og"
BUILD_OPTIMIZATION:append:mips = " -O"
DEBUG_OPTIMIZATION:remove:mipsel = " -Og"
DEBUG_OPTIMIZATION:append:mipsel = " -O"
BUILD_OPTIMIZATION:remove:mipsel = " -Og"
BUILD_OPTIMIZATION:append:mipsel = " -O"
BBCLASSEXTEND = "native nativesdk"
RDEPENDS:${PN} += "libxml2 libxslt ${PYTHON_PN}-compression"
CLEANBROKEN = "1"

View File

@ -0,0 +1,30 @@
From 6c434bdd31d674f85a82cb83248571813c7a37ff Mon Sep 17 00:00:00 2001
From: Martin Jansa <Martin.Jansa@gmail.com>
Date: Wed, 3 May 2023 18:06:46 +0200
Subject: [PATCH] libgeoclue: don't try to use g-ir-scanner when introspection
isn't enabled
* it finds target g-ir-scanner, so gir is found(), but when it tries to call it, it fails:
http://errors.yoctoproject.org/Errors/Details/702778/
geoclue/2.7.0-r0/recipe-sysroot/usr/bin/g-ir-scanner-wrapper: line 5: g-ir-scanner: command not found
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
Upstream-Status: Pending
libgeoclue/meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libgeoclue/meson.build b/libgeoclue/meson.build
index 5f05dad..7ed06a1 100644
--- a/libgeoclue/meson.build
+++ b/libgeoclue/meson.build
@@ -77,7 +77,7 @@ gir_sources = [ libgeoclue_sources,
libgeoclue_headers,
libgeoclue_public_api_gen_sources[1] ]
-if gir.found()
+if gir.found() and get_option('introspection')
geo_gir = gnome.generate_gir(libgeoclue,
sources: gir_sources,
namespace: 'Geoclue',

View File

@ -8,12 +8,14 @@ SECTION = "console/network"
LIC_FILES_CHKSUM = "file://COPYING;md5=bdfdd4986a0853eb84eeba85f9d0c4d6"
DEPENDS = "glib-2.0 dbus json-glib libsoup-2.4 intltool-native"
DEPENDS = "glib-2.0 dbus json-glib libsoup-3.0 intltool-native"
inherit meson pkgconfig gtk-doc gobject-introspection vala
inherit meson pkgconfig gtk-doc gobject-introspection vala useradd
SRCREV = "3bb60dd600a8b247fd6049e7e5b1c73c2c5fc0e8"
SRC_URI = "git://gitlab.freedesktop.org/geoclue/geoclue.git;protocol=https;nobranch=1"
SRCREV = "bbfb6289dedb88cb8155d9f6868787d5432e1f90"
SRC_URI = "git://gitlab.freedesktop.org/geoclue/geoclue.git;protocol=https;branch=master \
file://0001-libgeoclue-don-t-try-to-use-g-ir-scanner-when-intros.patch \
"
S = "${WORKDIR}/git"
@ -25,7 +27,7 @@ PACKAGECONFIG[3g] = "-D3g-source=true,-D3g-source=false,modemmanager"
PACKAGECONFIG[modem-gps] = "-Dmodem-gps-source=true,-Dmodem-gps-source=false,modemmanager"
PACKAGECONFIG[cdma] = "-Dcdma-source=true,-Dcdma-source=false,modemmanager"
PACKAGECONFIG[nmea] = "-Dnmea-source=true,-Dnmea-source=false,avahi,avahi-daemon"
PACKAGECONFIG[lib] = "-Dlibgeoclue=true,-Dlibgeoclue=false,gobject-introspection"
PACKAGECONFIG[lib] = "-Dlibgeoclue=true,-Dlibgeoclue=false"
GTKDOC_MESON_OPTION = "gtk-doc"
@ -34,8 +36,20 @@ EXTRA_OEMESON += " \
-Ddemo-agent=false \
"
USERADD_PACKAGES = "${PN}"
USERADD_PARAM:${PN} = "--system --no-create-home --user-group --home-dir ${sysconfdir}/polkit-1 --shell /bin/nologin polkitd"
do_install:append() {
if ${@bb.utils.contains('PACKAGECONFIG', 'modem-gps', 'true', 'false', d)}; then
# Fix up permissions on polkit rules.d to work with rpm4 constraints
chmod 700 ${D}/${datadir}/polkit-1/rules.d
chown polkitd:root ${D}/${datadir}/polkit-1/rules.d
fi
}
FILES:${PN} += " \
${datadir}/dbus-1/system-services \
${datadir}/polkit-1/rules.d \
${libdir} \
${systemd_unitdir} \
${prefix}/libexec \

View File

@ -0,0 +1,80 @@
From: Utopia Maintenance Team
<pkg-utopia-maintainers@lists.alioth.debian.org>
Date: Mon, 30 Apr 2018 17:56:52 +0000
Subject: Select the current user to authenticate with by default
Bug: http://bugzilla.gnome.org/show_bug.cgi?id=596188
Bug-Ubuntu: https://launchpad.net/bugs/435227
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
src/polkitgnomeauthenticationdialog.c | 23 ++++++++++++++---------
1 file changed, 14 insertions(+), 9 deletions(-)
diff --git a/src/polkitgnomeauthenticationdialog.c b/src/polkitgnomeauthenticationdialog.c
index 743cc96..d307516 100644
--- a/src/polkitgnomeauthenticationdialog.c
+++ b/src/polkitgnomeauthenticationdialog.c
@@ -138,7 +138,7 @@ user_combobox_changed (GtkComboBox *widget,
static void
create_user_combobox (PolkitGnomeAuthenticationDialog *dialog)
{
- int n;
+ int n, i, selected_index = 0;
GtkComboBox *combo;
GtkTreeIter iter;
GtkCellRenderer *renderer;
@@ -162,7 +162,7 @@ create_user_combobox (PolkitGnomeAuthenticationDialog *dialog)
/* For each user */
- for (n = 0; dialog->priv->users[n] != NULL; n++)
+ for (i = 0, n = 0; dialog->priv->users[n] != NULL; n++)
{
gchar *gecos;
gchar *real_name;
@@ -224,6 +224,14 @@ create_user_combobox (PolkitGnomeAuthenticationDialog *dialog)
USERNAME_COL, dialog->priv->users[n],
-1);
+ i++;
+ if (passwd->pw_uid == getuid ())
+ {
+ selected_index = i;
+ g_free (dialog->priv->selected_user);
+ dialog->priv->selected_user = g_strdup (dialog->priv->users[n]);
+ }
+
g_free (real_name);
g_object_unref (pixbuf);
}
@@ -252,8 +260,8 @@ create_user_combobox (PolkitGnomeAuthenticationDialog *dialog)
user_combobox_set_sensitive,
NULL, NULL);
- /* Initially select the "Select user..." ... */
- gtk_combo_box_set_active (GTK_COMBO_BOX (combo), 0);
+ /* Select the default user */
+ gtk_combo_box_set_active (GTK_COMBO_BOX (combo), selected_index);
/* Listen when a new user is selected */
g_signal_connect (GTK_WIDGET (combo),
@@ -719,16 +727,13 @@ polkit_gnome_authentication_dialog_constructed (GObject *object)
gtk_widget_set_tooltip_markup (label, s);
g_free (s);
- if (have_user_combobox)
+ /* Disable password entry and authenticate until have a user selected */
+ if (have_user_combobox && gtk_combo_box_get_active (GTK_COMBO_BOX (dialog->priv->user_combobox)) == 0)
{
- /* ... and make the password entry and "Authenticate" button insensitive */
gtk_widget_set_sensitive (dialog->priv->prompt_label, FALSE);
gtk_widget_set_sensitive (dialog->priv->password_entry, FALSE);
gtk_widget_set_sensitive (dialog->priv->auth_button, FALSE);
}
- else
- {
- }
gtk_widget_realize (GTK_WIDGET (dialog));

View File

@ -0,0 +1,34 @@
From: Lars Uebernickel <lars@uebernic.de>
Date: Fri, 17 Oct 2014 15:35:25 +0200
Subject: Auth dialog: Make the label wrap at 70 chars
Because GtkWindow doesn't have a default width anymore.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=738688
Bug-Ubuntu: https://launchpad.net/bugs/1382566
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
src/polkitgnomeauthenticationdialog.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/polkitgnomeauthenticationdialog.c b/src/polkitgnomeauthenticationdialog.c
index d307516..efd4185 100644
--- a/src/polkitgnomeauthenticationdialog.c
+++ b/src/polkitgnomeauthenticationdialog.c
@@ -574,6 +574,7 @@ polkit_gnome_authentication_dialog_constructed (GObject *object)
g_free (s);
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_max_width_chars (GTK_LABEL (label), 70);
gtk_box_pack_start (GTK_BOX (main_vbox), label, FALSE, FALSE, 0);
/* secondary message */
@@ -601,6 +602,7 @@ polkit_gnome_authentication_dialog_constructed (GObject *object)
}
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_max_width_chars (GTK_LABEL (label), 70);
gtk_box_pack_start (GTK_BOX (main_vbox), label, FALSE, FALSE, 0);
/* user combobox */

View File

@ -0,0 +1,138 @@
From: Marc Deslauriers <marc.deslauriers@canonical.com>
Date: Mon, 30 Apr 2018 18:03:22 +0000
Subject: Get user icon from accountsservice instead of looking in ~/.face
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=669857
Bug-Ubuntu: https://launchpad.net/bugs/928249
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
src/polkitgnomeauthenticationdialog.c | 107 ++++++++++++++++++++++++++++++----
1 file changed, 97 insertions(+), 10 deletions(-)
diff --git a/src/polkitgnomeauthenticationdialog.c b/src/polkitgnomeauthenticationdialog.c
index efd4185..565da87 100644
--- a/src/polkitgnomeauthenticationdialog.c
+++ b/src/polkitgnomeauthenticationdialog.c
@@ -135,6 +135,102 @@ user_combobox_changed (GtkComboBox *widget,
}
}
+static GdkPixbuf *
+get_user_icon (char *username)
+{
+ GError *error;
+ GDBusConnection *connection;
+ GVariant *find_user_result;
+ GVariant *get_icon_result;
+ GVariant *icon_result_variant;
+ const gchar *user_path;
+ const gchar *icon_filename;
+ GdkPixbuf *pixbuf;
+
+ error = NULL;
+ connection = g_bus_get_sync (G_BUS_TYPE_SYSTEM, NULL, &error);
+
+ if (connection == NULL)
+ {
+ g_warning ("Unable to connect to system bus: %s", error->message);
+ g_error_free (error);
+ return NULL;
+ }
+
+ find_user_result = g_dbus_connection_call_sync (connection,
+ "org.freedesktop.Accounts",
+ "/org/freedesktop/Accounts",
+ "org.freedesktop.Accounts",
+ "FindUserByName",
+ g_variant_new ("(s)",
+ username),
+ G_VARIANT_TYPE ("(o)"),
+ G_DBUS_CALL_FLAGS_NONE,
+ -1,
+ NULL,
+ &error);
+
+ if (find_user_result == NULL)
+ {
+ g_warning ("Accounts couldn't find user: %s", error->message);
+ g_error_free (error);
+ return NULL;
+ }
+
+ user_path = g_variant_get_string (g_variant_get_child_value (find_user_result, 0),
+ NULL);
+
+ get_icon_result = g_dbus_connection_call_sync (connection,
+ "org.freedesktop.Accounts",
+ user_path,
+ "org.freedesktop.DBus.Properties",
+ "Get",
+ g_variant_new ("(ss)",
+ "org.freedesktop.Accounts.User",
+ "IconFile"),
+ G_VARIANT_TYPE ("(v)"),
+ G_DBUS_CALL_FLAGS_NONE,
+ -1,
+ NULL,
+ &error);
+
+ g_variant_unref (find_user_result);
+
+ if (get_icon_result == NULL)
+ {
+ g_warning ("Accounts couldn't find user icon: %s", error->message);
+ g_error_free (error);
+ return NULL;
+ }
+
+ g_variant_get_child (get_icon_result, 0, "v", &icon_result_variant);
+ icon_filename = g_variant_get_string (icon_result_variant, NULL);
+
+ if (icon_filename == NULL)
+ {
+ g_warning ("Accounts didn't return a valid filename for user icon");
+ pixbuf = NULL;
+ }
+ else
+ {
+ /* TODO: we probably shouldn't hard-code the size to 16x16 */
+ pixbuf = gdk_pixbuf_new_from_file_at_size (icon_filename,
+ 16,
+ 16,
+ &error);
+ if (pixbuf == NULL)
+ {
+ g_warning ("Couldn't open user icon: %s", error->message);
+ g_error_free (error);
+ }
+ }
+
+ g_variant_unref (icon_result_variant);
+ g_variant_unref (get_icon_result);
+
+ return pixbuf;
+}
+
static void
create_user_combobox (PolkitGnomeAuthenticationDialog *dialog)
{
@@ -197,16 +293,7 @@ create_user_combobox (PolkitGnomeAuthenticationDialog *dialog)
g_free (gecos);
/* Load users face */
- pixbuf = NULL;
- if (passwd->pw_dir != NULL)
- {
- gchar *path;
- path = g_strdup_printf ("%s/.face", passwd->pw_dir);
- /* TODO: we probably shouldn't hard-code the size to 16x16 */
- pixbuf = gdk_pixbuf_new_from_file_at_scale (path, 16, 16, TRUE, NULL);
- g_free (path);
- }
-
+ pixbuf = get_user_icon (dialog->priv->users[n]);
/* fall back to avatar-default icon */
if (pixbuf == NULL)
{

View File

@ -0,0 +1,48 @@
From: Jeffrey Knockel <jeff250@gmail.com>
Date: Mon, 30 Apr 2018 18:05:20 +0000
Subject: Use fresh X11 timestamps when displaying authentication dialog
This circumvents focus-stealing prevention.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=676076
Bug-Debian: https://bugs.debian.org/684300
Bug-Ubuntu: https://launchpad.net/bugs/946171
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
src/polkitgnomeauthenticator.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/polkitgnomeauthenticator.c b/src/polkitgnomeauthenticator.c
index 23163b4..e57d76e 100644
--- a/src/polkitgnomeauthenticator.c
+++ b/src/polkitgnomeauthenticator.c
@@ -26,6 +26,7 @@
#include <sys/types.h>
#include <pwd.h>
#include <glib/gi18n.h>
+#include <gdk/gdkx.h>
#include <polkit/polkit.h>
#include <polkitagent/polkitagent.h>
@@ -306,7 +307,17 @@ session_request (PolkitAgentSession *session,
}
gtk_widget_show_all (GTK_WIDGET (authenticator->dialog));
- gtk_window_present (GTK_WINDOW (authenticator->dialog));
+ GdkWindow *window = gtk_widget_get_window (GTK_WIDGET (authenticator->dialog));
+
+ if (GDK_IS_X11_WINDOW (window))
+ {
+ gtk_window_present_with_time (GTK_WINDOW (authenticator->dialog), gdk_x11_get_server_time (window));
+ }
+ else
+ {
+ gtk_window_present (GTK_WINDOW (authenticator->dialog));
+ }
+
password = polkit_gnome_authentication_dialog_run_until_response_for_prompt (POLKIT_GNOME_AUTHENTICATION_DIALOG (authenticator->dialog),
modified_request,
echo_on,

View File

@ -0,0 +1,29 @@
From 334abb04ff953dabec63a91094de43e3cf064d7d Mon Sep 17 00:00:00 2001
From: Markus Volk <f_l_k@t-online.de>
Date: Fri, 24 Feb 2023 17:29:24 +0100
Subject: [PATCH] configure.ac: disable gnome-tools that are not provided
Upstream-Status: Inappropriate [OE-specific]
Signed-off-by: Markus Volk <f_l_k@t-online.de>
---
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index 24eb724..02fccbd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -33,8 +33,8 @@ LT_INIT
# GNOME
# *****
-GNOME_DEBUG_CHECK
-GNOME_COMPILE_WARNINGS([maximum])
+#GNOME_DEBUG_CHECK
+#GNOME_COMPILE_WARNINGS([maximum])
#### gcc warning flags
--
2.34.1

View File

@ -0,0 +1,87 @@
[Desktop Entry]
Name=PolicyKit Authentication Agent
Name[ar]=مدير الاستيثاق PolicyKit
Name[be]=PolicyKit - аґент аўтэнтыфікацыі
Name[bn_IN]=PolicyKit
Name[ca]=Agent d'autenticació del PolicyKit
Name[cs]=Ověřovací agent PolicyKit
Name[da]=Godkendelsesprogrammet PolicyKit
Name[de]=Legitimationsdienst von PolicyKit
Name[el]=Πράκτορας πιστοποίησης PolicyKit
Name[en_GB]=PolicyKit Authentication Agent
Name[es]=Agente de autenticación de PolicyKit
Name[eu]=PolicyKit autentifikatzeko agentea
Name[fi]=PolicytKit-tunnistautumisohjelma
Name[fr]=Agent d'authentification de PolicyKit
Name[gl]=Axente de autenticación PolicyKit
Name[gu]=PolicyKit િ
Name[hi]=PolicyKit ििि
Name[hu]=PolicyKit hitelesítési ügynök
Name[it]=Agente di autenticazione per PolicyKit
Name[ja]=PolicyKit
Name[kn]=PolicyKit ಿ
Name[lt]=PolicyKit tapatybės nustatymo agentas
Name[ml]=ിിി ി
Name[mr]=PolicyKit
Name[or]=PolicyKit ି
Name[pa]=ਿ ਿ
Name[pl]=Agent uwierzytelniania PolicyKit
Name[pt]=Agente de Autenticação PolicyKit
Name[pt_BR]=Agente de autenticação PolicyKit
Name[ro]=Agent de autentificare PolicyKit
Name[sk]=Agent PolicyKit na overovanie totožnosti
Name[sl]=PolicyKit program overjanja
Name[sv]=Autentiseringsagent för PolicyKit
Name[ta]=PolicyKit
Name[te]=ి ిిి
Name[th]= PolicyKit
Name[uk]=Агент автентифікації PolicyKit
Name[zh_CN]=PolicyKit
Name[zh_HK]=PolicyKit
Name[zh_TW]=PolicyKit
Comment=PolicyKit Authentication Agent
Comment[ar]=مدير الاستيثاق PolicyKit
Comment[be]=PolicyKit - аґент аўтэнтыфікацыі
Comment[bn_IN]=PolicyKit
Comment[ca]=Agent d'autenticació del PolicyKit
Comment[cs]=Ověřovací agent PolicyKit
Comment[da]=Godkendelsesprogrammet PolicyKit
Comment[de]=Legitimationsdienst von PolicyKit
Comment[el]=Πράκτορας πιστοποίησης PolicyKit
Comment[en_GB]=PolicyKit Authentication Agent
Comment[es]=Agente de autenticación de PolicyKit
Comment[eu]=PolicyKit autentifikatzeko agentea
Comment[fi]=PolicytKit-tunnistautumisohjelma
Comment[fr]=Agent d'authentification de PolicyKit
Comment[gl]=Axente de autenticación PolicyKit
Comment[gu]=PolicyKit િ
Comment[hi]=PolicyKit ििि
Comment[hu]=PolicyKit hitelesítési ügynök
Comment[it]=Agente di autenticazione per PolicyKit
Comment[ja]=PolicyKit
Comment[kn]=PolicyKit ಿ
Comment[lt]=PolicyKit tapatybės nustatymo agentas
Comment[ml]=ിിി ി
Comment[mr]=PolicyKit
Comment[or]=PolicyKit ି
Comment[pa]=ਿ ਿ
Comment[pl]=Agent uwierzytelniania PolicyKit
Comment[pt]=Agente de Autenticação PolicyKit
Comment[pt_BR]=Agente de autenticação PolicyKit
Comment[ro]=Agent de autentificare PolicyKit
Comment[sk]=Agent PolicyKit na overovanie totožnosti
Comment[sl]=PolicyKit program overjanja
Comment[sv]=Autentiseringsagent för PolicyKit
Comment[ta]=PolicyKit
Comment[te]=ి ిిి
Comment[th]= PolicyKit
Comment[uk]=Агент автентифікації PolicyKit
Comment[zh_CN]=PolicyKit
Comment[zh_HK]=PolicyKit
Comment[zh_TW]=PolicyKit
Exec=/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
Terminal=false
Type=Application
Categories=
NoDisplay=true
OnlyShowIn=GNOME;

View File

@ -0,0 +1,29 @@
SUMMARY = "PolicyKit-gnome provides an Authentication Agent for PolicyKit"
HOMEPAGE = "https://gitlab.gnome.org/Archive/policykit-gnome"
LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=74579fab173e4c5e12aac0cd83ee98ec"
DEPENDS = "glib-2.0-native glib-2.0 gtk+3 polkit intltool-native"
inherit autotools pkgconfig features_check
REQUIRED_DISTRO_FEATURES = "polkit"
SRC_URI = " \
git://gitlab.gnome.org/Archive/policykit-gnome.git;protocol=https;branch=master \
file://0001-Select-the-current-user-to-authenticate-with-by-defa.patch \
file://0002-Auth-dialog-Make-the-label-wrap-at-70-chars.patch \
file://0003-Get-user-icon-from-accountsservice-instead-of-lookin.patch \
file://0004-Use-fresh-X11-timestamps-when-displaying-authenticat.patch \
file://0005-configure.ac-disable-gnome-tools-that-are-not-provid.patch \
file://polkit-gnome-authentication-agent-1.desktop \
"
SRCREV = "a0763a246a81188f60b0f9810143e49224dc752f"
S = "${WORKDIR}/git"
do_install:append() {
install -d ${D}${datadir}/applications
install -m644 ${WORKDIR}/polkit-gnome-authentication-agent-1.desktop \
${D}${datadir}/applications
}

View File

@ -1,24 +0,0 @@
SUMMARY = "GNOME Authentication Agent for PolicyKit"
DESCRIPTION = "PolicyKit-gnome provides an Authentication Agent for PolicyKit that integrates well with the GNOME desktop environment"
HOMEPAGE = "http://www.packagekit.org/"
BUGTRACKER = "http://bugzilla.gnome.org/"
DEPENDS = "polkit dbus-glib gconf gtk+3 glib-2.0-native intltool-native gnome-common"
LICENSE = "LGPL-2.0-or-later"
LIC_FILES_CHKSUM = "file://COPYING;md5=74579fab173e4c5e12aac0cd83ee98ec \
file://src/main.c;beginline=1;endline=20;md5=aba145d1802f2329ba561e3e48ecb795"
SRC_URI = "https://download.gnome.org/sources/polkit-gnome/${PV}/polkit-gnome-${PV}.tar.xz \
file://gtk-doc-check.patch \
"
SRC_URI[md5sum] = "50ecad37c8342fb4a52f590db7530621"
SRC_URI[sha256sum] = "1784494963b8bf9a00eedc6cd3a2868fb123b8a5e516e66c5eda48df17ab9369"
EXTRA_OECONF = "\
--disable-static \
"
inherit autotools gtk-doc pkgconfig
FILES:${PN} += " ${datadir}/dbus-1 \
${datadir}/PolicyKit \
"

View File

@ -11,9 +11,9 @@ inherit gnomebase gobject-introspection gettext gtk-doc upstream-version-is-even
DEPENDS = " \
json-glib \
libsoup-2.4 \
libsoup-3.0 \
"
SRC_URI[archive.sha256sum] = "2d9a6826d158470449a173871221596da0f83ebdcff98b90c7049089056a37aa"
EXTRA_OEMESON = "-Denable-installed-tests=false"
EXTRA_OEMESON = "-Denable-installed-tests=false -Dsoup2=false"

View File

@ -1,4 +1,4 @@
From fa47185d9c8150a0dcb0ea12b92fcf139edbef35 Mon Sep 17 00:00:00 2001
From 11a6b636ed27eb695b15a1ad6c00f1d1aa02735a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
Date: Wed, 27 Oct 2021 20:18:47 +0200
Subject: [PATCH] Support cross builds a bit better
@ -9,18 +9,19 @@ Content-Transfer-Encoding: 8bit
* Do not build/run mozjs-linked program
* Do not try to run test applications
Upstream-Status: Submitted[https://gitlab.gnome.org/GNOME/gjs/-/merge_requests/690]
Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/gjs/-/merge_requests/690]
Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
---
meson.build | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index 136e812..f5b91e0 100644
index ba81cd1..0e0b28e 100644
--- a/meson.build
+++ b/meson.build
@@ -252,6 +252,7 @@ release builds of SpiderMonkey. Try configuring SpiderMonkey with
@@ -255,6 +255,7 @@ release builds of SpiderMonkey. Try configuring SpiderMonkey with
--disable-debug.''')
endif
@ -28,7 +29,7 @@ index 136e812..f5b91e0 100644
# Check if a minimal SpiderMonkey program compiles, links, and runs. If not,
# it's most likely the case that SpiderMonkey was configured incorrectly, for
# example by building mozglue as a shared library.
@@ -282,6 +283,7 @@ elif minimal_program.returncode() != 0
@@ -285,6 +286,7 @@ elif minimal_program.returncode() != 0
failed to execute. Most likely you should build it with a different
configuration.''' + recommended_configuration)
endif
@ -36,7 +37,7 @@ index 136e812..f5b91e0 100644
have_printf_alternative_int = cc.compiles('''
#include <stdio.h>
@@ -682,7 +684,7 @@ subdir('installed-tests')
@@ -683,7 +685,7 @@ subdir('installed-tests')
# Note: The test program in test/ needs to be ported
# to Windows before we can build it on Windows.

View File

@ -1,26 +1,32 @@
From 2b8aa1ea4a4d1836164c934b1ab2556a32cb5af7 Mon Sep 17 00:00:00 2001
From d46af224b10d9ff9f1e88f9381fd046ad554e373 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
Date: Wed, 27 Oct 2021 20:04:02 +0200
Subject: [PATCH] meson.build: Do not add dir installed-tests when
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
installed_tests is false
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Upstream-Status: Submitted[https://gitlab.gnome.org/GNOME/gjs/-/merge_requests/690]
Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/gjs/-/merge_requests/690]
Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
---
meson.build | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index f5b91e0..3110530 100644
index 0e0b28e..321b243 100644
--- a/meson.build
+++ b/meson.build
@@ -680,7 +680,9 @@ if not get_option('skip_gtk_tests')
have_gtk4 = dependency('gtk4', required: false).found()
endif
@@ -681,7 +681,9 @@ endif
### Tests and test setups ######################################################
-subdir('installed-tests')
+if get_option('installed_tests')

View File

@ -4,11 +4,12 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=8dcea832f6acf45d856abfeb2d51ec48"
GNOMEBASEBUILDCLASS = "meson"
DEPENDS = "mozjs-102 cairo"
DEPENDS = "mozjs-115 cairo"
inherit gnomebase gsettings gobject-introspection vala gettext features_check upstream-version-is-even pkgconfig
SRC_URI[archive.sha256sum] = "cf2b84b174a049c911a69ec619f4c5ca6b96d609be5200ca3db5131c98beda75"
SRC_URI[archive.sha256sum] = "70db967ae98bde69b38475ef60bb9a3302990fa615baf46820194b302a29dbf8"
SRC_URI += " \
file://0001-Support-cross-builds-a-bit-better.patch \
file://0002-meson.build-Do-not-add-dir-installed-tests-when-inst.patch \

View File

@ -8,7 +8,8 @@ GNOMEBASEBUILDCLASS = "meson"
inherit gnomebase gettext allarch
SRC_URI[archive.sha256sum] = "4c7fe1a09f459c5f77189a5982524fce05d888944955d679910f234606c1295d"
SRC_URI[archive.sha256sum] = "cee0e688fbae5ef7a75f335ada2d10779e08ebca9445f1586de32c5a9b6dee2d"
FILES:${PN} += " \
${datadir}/backgrounds \

View File

@ -19,7 +19,7 @@ Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/meson_options.txt b/meson_options.txt
index dbca723..af0f871 100644
index 8ee7b6e..7e6adc6 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -1,3 +1,4 @@
@ -28,18 +28,28 @@ index dbca723..af0f871 100644
option('ibus', type: 'boolean', value: true, description: 'build with IBus support')
option('privileged_group', type: 'string', value: 'wheel', description: 'name of group that has elevated permissions')
diff --git a/panels/background/meson.build b/panels/background/meson.build
index 3634c47..459ccfe 100644
index 9bf5435..96f2ac0 100644
--- a/panels/background/meson.build
+++ b/panels/background/meson.build
@@ -25,7 +25,7 @@ common_sources = []
@@ -19,7 +19,7 @@ common_sources = []
enums = 'gdesktop-enums-types'
enums_header = files(
- gsettings_desktop_dep.get_pkgconfig_variable('prefix') + '/include/gsettings-desktop-schemas/gdesktop-enums.h',
- gsettings_desktop_dep.get_variable(pkgconfig: 'prefix') + '/include/gsettings-desktop-schemas/gdesktop-enums.h',
+ get_option('oe_sysroot') + gsettings_desktop_dep.get_pkgconfig_variable('prefix') + '/include/gsettings-desktop-schemas/gdesktop-enums.h',
'cc-background-item.h'
)
--
2.34.1
diff --git a/panels/datetime/meson.build b/panels/datetime/meson.build
index 8cb3b63..1665632 100644
--- a/panels/datetime/meson.build
+++ b/panels/datetime/meson.build
@@ -37,7 +37,7 @@ sources = files(
enums = 'gdesktop-enums-types'
enums_header = files(
- gsettings_desktop_dep.get_variable(pkgconfig: 'prefix') + '/include/gsettings-desktop-schemas/gdesktop-enums.h',
+ get_option('oe_sysroot') + gsettings_desktop_dep.get_pkgconfig_variable('prefix') + '/include/gsettings-desktop-schemas/gdesktop-enums.h',
'cc-datetime-panel.h'
)

View File

@ -1,296 +0,0 @@
From 2f5368dd4eef27ee3afaed761932601393e4875e Mon Sep 17 00:00:00 2001
From: Bruce Leidl <bruce@subgraph.com>
Date: Thu, 22 Sep 2022 20:31:50 -0400
Subject: [PATCH] Add options for Citadel and disabling GOA/CUPS
---
meson.build | 14 ++++++++++++++
meson_options.txt | 5 +++++
panels/meson.build | 23 ++++++++++++++++-------
shell/cc-panel-list.c | 14 ++++++++++++++
shell/cc-panel-loader.c | 28 ++++++++++++++++++++++++++++
tests/meson.build | 2 +-
6 files changed, 78 insertions(+), 8 deletions(-)
diff --git a/meson.build b/meson.build
index b7b595e..9c86afb 100644
--- a/meson.build
+++ b/meson.build
@@ -110,6 +110,15 @@ libgvc = subproject(
)
libgvc_dep = libgvc.get_variable('libgvc_dep')
+enable_goa = get_option('online_accounts')
+enable_cups = get_option('cups')
+enable_user_accounts = get_option('user_accounts')
+enable_citadel = get_option('citadel')
+config_h.set('WITH_GOA', enable_goa, description: 'Define to enable support for Gnome Online Accounts')
+config_h.set('WITH_CUPS', enable_goa, description: 'Define to enable support for CUPS')
+config_h.set('WITH_USER_ACCOUNTS', enable_user_accounts, description: 'Define to enable user accounts panel')
+config_h.set('CITADEL', enable_citadel, description: 'Define to enable the removal of components unneeded in Citadel')
+
goa_req_version = '>= 3.25.3'
pulse_req_version = '>= 2.0'
@@ -129,7 +138,9 @@ gnome_desktop_dep = dependency('gnome-desktop-4')
gnome_bg_dep = dependency('gnome-bg-4')
gnome_rr_dep = dependency('gnome-rr-4')
gnome_settings_dep = dependency('gnome-settings-daemon', version: '>= 41.0')
+if enable_goa
goa_dep = dependency('goa-1.0', version: goa_req_version)
+endif
gsettings_desktop_dep = dependency('gsettings-desktop-schemas', version: '>= 42.alpha')
libxml_dep = dependency('libxml-2.0')
pulse_dep = dependency('libpulse', version: pulse_req_version)
@@ -164,6 +175,8 @@ foreach polkit_file: polkit_files
endforeach
# Check for CUPS 1.4 or newer
+
+if enable_cups
cups_dep = dependency('cups', version : '>= 1.4', required: false)
assert(cups_dep.found(), 'CUPS 1.4 or newer not found')
@@ -186,6 +199,7 @@ endforeach
config_h.set10('HAVE_CUPS_HTTPCONNECT2',
cc.has_function('httpConnect2', dependencies: cups_dep),
description: 'Define if httpConnect2() is available in CUPS')
+endif
# IBus support
enable_ibus = get_option('ibus')
diff --git a/meson_options.txt b/meson_options.txt
index 0a6f12b..4435bd3 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -10,3 +10,8 @@ option('profile', type: 'combo', choices: ['default','development'], value: 'def
option('malcontent', type: 'boolean', value: false, description: 'build with malcontent support')
option('distributor_logo', type: 'string', description: 'absolute path to distributor logo for the About panel')
option('dark_mode_distributor_logo', type: 'string', description: 'absolute path to distributor logo dark mode variant')
+option('staging_dir', type: 'string', description: 'set staging directory for cross-compile')
+option('online_accounts', type: 'boolean', value: false, description: 'build with support for gnome-online-accounts')
+option('cups', type: 'boolean', value: false, description: 'build with support for CUPS')
+option('user_accounts', type: 'boolean', value: false, description: 'build with support for user accounts panel')
+option('citadel', type: 'boolean', value: true, description: 'build with Citadel support, which removes unneeded components')
diff --git a/panels/meson.build b/panels/meson.build
index cb732f2..26f6465 100644
--- a/panels/meson.build
+++ b/panels/meson.build
@@ -1,12 +1,10 @@
subdir('common')
panels = [
- 'applications',
'background',
'camera',
'color',
'datetime',
- 'default-apps',
'diagnostics',
'display',
'firmware-security',
@@ -17,18 +15,13 @@ panels = [
'mouse',
'multitasking',
'notifications',
- 'online-accounts',
'power',
- 'printers',
'region',
- 'removable-media',
'screen',
'search',
- 'sharing',
'sound',
'universal-access',
'usage',
- 'user-accounts',
'wwan',
]
@@ -44,6 +37,22 @@ if host_is_linux_not_s390
]
endif
+if enable_goa
+ panels += ['online-accounts']
+endif
+
+if enable_cups
+ panels += ['printers']
+endif
+
+if enable_user_accounts
+ panels += ['user-accounts']
+endif
+
+if not enable_citadel
+ panel_names += ['applications', 'default-apps', 'removable-media', 'sharing']
+endif
+
panels_list = []
panels_libs = []
foreach cappletname: panels
diff --git a/shell/cc-panel-list.c b/shell/cc-panel-list.c
index 185b16d..a893018 100644
--- a/shell/cc-panel-list.c
+++ b/shell/cc-panel-list.c
@@ -395,10 +395,16 @@ static const gchar * const panel_order[] = {
"notifications",
"search",
"multitasking",
+#ifndef CITADEL
"applications",
+#endif
"privacy",
+#ifndef WITH_GOA
"online-accounts",
+#endif
+#ifndef CITADEL
"sharing",
+#endif
/* Privacy page */
"location",
@@ -416,16 +422,24 @@ static const gchar * const panel_order[] = {
"display",
"mouse",
"keyboard",
+#ifndef WITH_CUPS
"printers",
+#endif
+#ifndef CITADEL
"removable-media",
+#endif
"wacom",
"color",
/* Details page */
"region",
"universal-access",
+#ifndef WITH_USER_ACCOUNTS
"user-accounts",
+#endif
+#ifndef CITADEL
"default-apps",
+#endif
"reset-settings",
"datetime",
"info-overview",
diff --git a/shell/cc-panel-loader.c b/shell/cc-panel-loader.c
index 17f9601..db30bac 100644
--- a/shell/cc-panel-loader.c
+++ b/shell/cc-panel-loader.c
@@ -31,14 +31,18 @@
#ifndef CC_PANEL_LOADER_NO_GTYPES
/* Extension points */
+#ifndef CITADEL
extern GType cc_applications_panel_get_type (void);
+#endif
extern GType cc_background_panel_get_type (void);
#ifdef BUILD_BLUETOOTH
extern GType cc_bluetooth_panel_get_type (void);
#endif /* BUILD_BLUETOOTH */
extern GType cc_color_panel_get_type (void);
extern GType cc_date_time_panel_get_type (void);
+#ifndef CITADEL
extern GType cc_default_apps_panel_get_type (void);
+#endif
extern GType cc_display_panel_get_type (void);
extern GType cc_info_overview_panel_get_type (void);
extern GType cc_keyboard_panel_get_type (void);
@@ -49,19 +53,29 @@ extern GType cc_network_panel_get_type (void);
extern GType cc_wifi_panel_get_type (void);
#endif /* BUILD_NETWORK */
extern GType cc_notifications_panel_get_type (void);
+#ifdef WITH_GOA
extern GType cc_online_accounts_panel_get_type (void);
+#endif
extern GType cc_power_panel_get_type (void);
+#ifdef WITH_CUPS
extern GType cc_printers_panel_get_type (void);
+#endif
extern GType cc_region_panel_get_type (void);
+#ifndef CITADEL
extern GType cc_removable_media_panel_get_type (void);
+#endif
extern GType cc_search_panel_get_type (void);
+#ifndef CITADEL
extern GType cc_sharing_panel_get_type (void);
+#endif
extern GType cc_sound_panel_get_type (void);
#ifdef BUILD_THUNDERBOLT
extern GType cc_bolt_panel_get_type (void);
#endif /* BUILD_THUNDERBOLT */
extern GType cc_ua_panel_get_type (void);
+#ifdef WITH_USER_ACCOUNTS
extern GType cc_user_panel_get_type (void);
+#endif
#ifdef BUILD_WACOM
extern GType cc_wacom_panel_get_type (void);
#endif /* BUILD_WACOM */
@@ -99,7 +113,9 @@ extern void cc_firmware_security_panel_static_init_func (void);
static CcPanelLoaderVtable default_panels[] =
{
+#ifndef CITADEL
PANEL_TYPE("applications", cc_applications_panel_get_type, NULL),
+#endif
PANEL_TYPE("background", cc_background_panel_get_type, NULL),
#ifdef BUILD_BLUETOOTH
PANEL_TYPE("bluetooth", cc_bluetooth_panel_get_type, NULL),
@@ -107,7 +123,9 @@ static CcPanelLoaderVtable default_panels[] =
PANEL_TYPE("camera", cc_camera_panel_get_type, NULL),
PANEL_TYPE("color", cc_color_panel_get_type, NULL),
PANEL_TYPE("datetime", cc_date_time_panel_get_type, NULL),
+#ifndef CITADEL
PANEL_TYPE("default-apps", cc_default_apps_panel_get_type, NULL),
+#endif
PANEL_TYPE("diagnostics", cc_diagnostics_panel_get_type, cc_diagnostics_panel_static_init_func),
PANEL_TYPE("display", cc_display_panel_get_type, NULL),
PANEL_TYPE("info-overview", cc_info_overview_panel_get_type, NULL),
@@ -122,21 +140,31 @@ static CcPanelLoaderVtable default_panels[] =
PANEL_TYPE("wifi", cc_wifi_panel_get_type, cc_wifi_panel_static_init_func),
#endif
PANEL_TYPE("notifications", cc_notifications_panel_get_type, NULL),
+#ifdef WITH_GOA
PANEL_TYPE("online-accounts", cc_online_accounts_panel_get_type, NULL),
+#endif
PANEL_TYPE("power", cc_power_panel_get_type, NULL),
+#ifdef WITH_CUPS
PANEL_TYPE("printers", cc_printers_panel_get_type, NULL),
+#endif
PANEL_TYPE("region", cc_region_panel_get_type, NULL),
+#ifndef CITADEL
PANEL_TYPE("removable-media", cc_removable_media_panel_get_type, NULL),
+#endif
PANEL_TYPE("screen", cc_screen_panel_get_type, NULL),
PANEL_TYPE("search", cc_search_panel_get_type, NULL),
+#ifndef CITADEL
PANEL_TYPE("sharing", cc_sharing_panel_get_type, NULL),
+#endif
PANEL_TYPE("sound", cc_sound_panel_get_type, NULL),
#ifdef BUILD_THUNDERBOLT
PANEL_TYPE("thunderbolt", cc_bolt_panel_get_type, NULL),
#endif
PANEL_TYPE("universal-access", cc_ua_panel_get_type, NULL),
PANEL_TYPE("usage", cc_usage_panel_get_type, NULL),
+#ifdef WITH_USER_ACCOUNTS
PANEL_TYPE("user-accounts", cc_user_panel_get_type, NULL),
+#endif
#ifdef BUILD_WACOM
PANEL_TYPE("wacom", cc_wacom_panel_get_type, cc_wacom_panel_static_init_func),
#endif
diff --git a/tests/meson.build b/tests/meson.build
index 69667ac..0910162 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -6,6 +6,6 @@ endif
subdir('interactive-panels')
-subdir('printers')
+#subdir('printers')
subdir('info')
subdir('keyboard')

View File

@ -8,10 +8,10 @@ Subject: [PATCH] Don't update icon cache
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index 9c86afb..138b10a 100644
index 6b31d76..11d1b9e 100644
--- a/meson.build
+++ b/meson.build
@@ -311,7 +311,7 @@ endif
@@ -339,7 +339,7 @@ endif
gnome.post_install(
glib_compile_schemas: true,

View File

@ -0,0 +1,196 @@
From 2f5368dd4eef27ee3afaed761932601393e4875e Mon Sep 17 00:00:00 2001
From: Bruce Leidl <bruce@subgraph.com>
Date: Thu, 22 Sep 2022 20:31:50 -0400
Subject: [PATCH] Remove panels for Citadel
---
diff --git a/meson.build b/meson.build
index 6b31d76..d997ed2 100644
--- a/meson.build
+++ b/meson.build
@@ -172,7 +172,6 @@ gnome_desktop_dep = dependency('gnome-desktop-4')
gnome_bg_dep = dependency('gnome-bg-4')
gnome_rr_dep = dependency('gnome-rr-4')
gnome_settings_dep = dependency('gnome-settings-daemon', version: '>= 41.0')
-goa_dep = dependency('goa-1.0', version: goa_req_version)
gsettings_desktop_dep = dependency('gsettings-desktop-schemas', version: '>= 42.alpha')
libxml_dep = dependency('libxml-2.0')
pulse_dep = dependency('libpulse', version: pulse_req_version)
@@ -206,30 +205,6 @@ foreach polkit_file: polkit_files
assert(r.returncode() == 0, 'ITS support missing from polkit, please upgrade or contact your distribution')
endforeach
-# Check for CUPS 1.4 or newer
-cups_dep = dependency('cups', version : '>= 1.4', required: false)
-assert(cups_dep.found(), 'CUPS 1.4 or newer not found')
-
-# https://bugzilla.gnome.org/show_bug.cgi?id=696766
-cups_cflags = []
-if cups_dep.version().version_compare('>= 1.6')
- cups_cflags += '-D_PPD_DEPRECATED='
-endif
-
-# cups headers
-check_headers = [
- ['HAVE_CUPS_CUPS_H', 'cups/cups.h'],
- ['HAVE_CUPS_PPD_H', 'cups/ppd.h']
-]
-
-foreach header: check_headers
- assert(cc.has_header(header[1], args: cups_cflags), 'CUPS headers not found: ' + header[1])
-endforeach
-
-config_h.set10('HAVE_CUPS_HTTPCONNECT2',
- cc.has_function('httpConnect2', dependencies: cups_dep),
- description: 'Define if httpConnect2() is available in CUPS')
-
# IBus support
enable_ibus = get_option('ibus')
if enable_ibus
diff --git a/panels/meson.build b/panels/meson.build
index 502fa3b..d8b2e25 100644
--- a/panels/meson.build
+++ b/panels/meson.build
@@ -1,28 +1,21 @@
subdir('common')
panels = [
- 'applications',
'background',
'color',
'datetime',
- 'default-apps',
'display',
'info-overview',
'keyboard',
'mouse',
'multitasking',
'notifications',
- 'online-accounts',
'power',
- 'printers',
'privacy',
'region',
- 'removable-media',
'search',
- 'sharing',
'sound',
'universal-access',
- 'user-accounts',
'wwan',
]
diff --git a/shell/cc-panel-list.c b/shell/cc-panel-list.c
index a39c880..9f95193 100644
--- a/shell/cc-panel-list.c
+++ b/shell/cc-panel-list.c
@@ -365,10 +365,7 @@ static const gchar * const panel_order[] = {
"notifications",
"search",
"multitasking",
- "applications",
"privacy",
- "online-accounts",
- "sharing",
/* Devices page */
"sound",
@@ -376,16 +373,12 @@ static const gchar * const panel_order[] = {
"display",
"mouse",
"keyboard",
- "printers",
- "removable-media",
"wacom",
"color",
/* Details page */
"region",
"universal-access",
- "user-accounts",
- "default-apps",
"reset-settings",
"datetime",
"info-overview",
diff --git a/shell/cc-panel-loader.c b/shell/cc-panel-loader.c
index 3b33f4e..6eff958 100644
--- a/shell/cc-panel-loader.c
+++ b/shell/cc-panel-loader.c
@@ -31,14 +31,12 @@
#ifndef CC_PANEL_LOADER_NO_GTYPES
/* Extension points */
-extern GType cc_applications_panel_get_type (void);
extern GType cc_background_panel_get_type (void);
#ifdef BUILD_BLUETOOTH
extern GType cc_bluetooth_panel_get_type (void);
#endif /* BUILD_BLUETOOTH */
extern GType cc_color_panel_get_type (void);
extern GType cc_date_time_panel_get_type (void);
-extern GType cc_default_apps_panel_get_type (void);
extern GType cc_display_panel_get_type (void);
extern GType cc_info_overview_panel_get_type (void);
extern GType cc_keyboard_panel_get_type (void);
@@ -49,17 +47,12 @@ extern GType cc_network_panel_get_type (void);
extern GType cc_wifi_panel_get_type (void);
#endif /* BUILD_NETWORK */
extern GType cc_notifications_panel_get_type (void);
-extern GType cc_online_accounts_panel_get_type (void);
extern GType cc_power_panel_get_type (void);
-extern GType cc_printers_panel_get_type (void);
extern GType cc_privacy_panel_get_type (void);
extern GType cc_region_panel_get_type (void);
-extern GType cc_removable_media_panel_get_type (void);
extern GType cc_search_panel_get_type (void);
-extern GType cc_sharing_panel_get_type (void);
extern GType cc_sound_panel_get_type (void);
extern GType cc_ua_panel_get_type (void);
-extern GType cc_user_panel_get_type (void);
#ifdef BUILD_WACOM
extern GType cc_wacom_panel_get_type (void);
#endif /* BUILD_WACOM */
@@ -88,14 +81,12 @@ extern void cc_wwan_panel_static_init_func (void);
static CcPanelLoaderVtable default_panels[] =
{
- PANEL_TYPE("applications", cc_applications_panel_get_type, NULL),
PANEL_TYPE("background", cc_background_panel_get_type, NULL),
#ifdef BUILD_BLUETOOTH
PANEL_TYPE("bluetooth", cc_bluetooth_panel_get_type, NULL),
#endif
PANEL_TYPE("color", cc_color_panel_get_type, NULL),
PANEL_TYPE("datetime", cc_date_time_panel_get_type, NULL),
- PANEL_TYPE("default-apps", cc_default_apps_panel_get_type, NULL),
PANEL_TYPE("display", cc_display_panel_get_type, NULL),
PANEL_TYPE("info-overview", cc_info_overview_panel_get_type, NULL),
PANEL_TYPE("keyboard", cc_keyboard_panel_get_type, NULL),
@@ -106,17 +97,12 @@ static CcPanelLoaderVtable default_panels[] =
PANEL_TYPE("wifi", cc_wifi_panel_get_type, cc_wifi_panel_static_init_func),
#endif
PANEL_TYPE("notifications", cc_notifications_panel_get_type, NULL),
- PANEL_TYPE("online-accounts", cc_online_accounts_panel_get_type, NULL),
PANEL_TYPE("power", cc_power_panel_get_type, NULL),
- PANEL_TYPE("printers", cc_printers_panel_get_type, NULL),
PANEL_TYPE("privacy", cc_privacy_panel_get_type, NULL),
PANEL_TYPE("region", cc_region_panel_get_type, NULL),
- PANEL_TYPE("removable-media", cc_removable_media_panel_get_type, NULL),
PANEL_TYPE("search", cc_search_panel_get_type, NULL),
- PANEL_TYPE("sharing", cc_sharing_panel_get_type, NULL),
PANEL_TYPE("sound", cc_sound_panel_get_type, NULL),
PANEL_TYPE("universal-access", cc_ua_panel_get_type, NULL),
- PANEL_TYPE("user-accounts", cc_user_panel_get_type, NULL),
#ifdef BUILD_WACOM
PANEL_TYPE("wacom", cc_wacom_panel_get_type, cc_wacom_panel_static_init_func),
#endif
diff --git a/tests/meson.build b/tests/meson.build
index 37334b7..d942799 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -9,6 +9,4 @@ if not libadwaita_is_subproject
subdir('interactive-panels')
endif
-subdir('printers')
subdir('info')
-subdir('keyboard')

View File

@ -1,93 +0,0 @@
SUMMARY = "GNOME Settings"
DESCRIPTION = "GNOME Settings is GNOME's main interface for configuration of various aspects of your desktop"
LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=75859989545e37968a99b631ef42722e"
GNOMEBASEBUILDCLASS = "meson"
inherit gnomebase gtk-icon-cache gsettings gettext vala upstream-version-is-even bash-completion features_check
DEPENDS = " \
gdk-pixbuf-native \
colord-gtk \
udisks2 \
upower \
polkit \
pulseaudio \
accountsservice \
gsettings-desktop-schemas \
gnome-settings-daemon \
gnome-desktop \
modemmanager \
networkmanager \
network-manager-applet \
gnome-bluetooth \
libnma \
libgtop \
libgudev \
gsound \
libpwquality \
ibus \
libadwaita \
"
REQUIRED_DISTRO_FEATURES += " pulseaudio systemd x11"
SRC_URI += "file://0001-Add-meson-option-to-pass-sysroot.patch"
SRC_URI += " file://0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch"
SRC_URI += " file://0001-Don-t-update-icon-cache.patch"
SRC_URI[archive.sha256sum] = "988c933592cbdc4e7f0dba9a93262e617b739e25927aa16e177960c754e31c48"
#
# Extra options have been added to meson_options.txt to make some components of the control
# center optional. One reason is that these components drag in heavy dependencies, and some
# of these dependencies have not been packaged and tested yet.
#
# Gnome Online Accounts support
#
# EXTRA_OEMESON += "-Donline_accounts=true"
# DEPENDS += "grilo gnome-online-accounts webkitgtk rest"
#
# Printer Panel
#
# EXTRA_OEMESON += "-Dcups=true"
# DEPENDS += "cups samba" (only smbclient needed from samba)
#
# User Accounts Panel
#
# EXTRA_OEMESON += "-Duser_accounts=true"
# DEPENDS += "accountsservice krb5"
#
# Citadel
#
# This option disables some things in gnome-control-center such as certain
# panels that are not used in Citadel, defaults to true in meson_options.
# To re-enable these things, set the option to false:
#
# EXTRA_OEMESON += "-Dcitadel=false"
#
#SRC_URI += " file://0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch"
EXTRA_OEMESON = " \
-Doe_sysroot=${STAGING_DIR_HOST} \
"
do_install:append() {
# If polkit is setup fixup permissions and ownership
if [ -d ${D}${datadir}/polkit-1/rules.d ]; then
chmod 700 ${D}${datadir}/polkit-1/rules.d
chown polkitd:root ${D}${datadir}/polkit-1/rules.d
fi
}
FILES:${PN} += " \
${datadir}/dbus-1 \
${datadir}/gnome-shell \
${datadir}/metainfo \
"
FILES:${PN}-dev += "${datadir}/gettext"
RDEPENDS:${PN} += "gsettings-desktop-schemas"

View File

@ -0,0 +1,77 @@
SUMMARY = "GNOME Settings"
DESCRIPTION = "GNOME Settings is GNOME's main interface for configuration of various aspects of your desktop"
LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=75859989545e37968a99b631ef42722e"
GNOMEBASEBUILDCLASS = "meson"
GTKIC_VERSION = "4"
export XDG_DATA_DIRS = "${STAGING_DATADIR}:${STAGING_LIBDIR}"
DEPENDS = " \
accountsservice \
colord-gtk \
gcr3 \
gdk-pixbuf \
glib-2.0 \
gnome-bluetooth \
gnome-desktop \
gnome-settings-daemon \
gsettings-desktop-schemas \
gstreamer1.0-plugins-base \
gtk4 \
libadwaita \
libepoxy \
libgtop \
libgudev \
libnma \
libpwquality \
libxml2 \
modemmanager \
polkit \
pulseaudio \
tecla \
udisks2 \
upower \
"
RDEPENDS:${PN} = "gstreamer1.0-plugins-base gstreamer1.0-plugins-good"
inherit gtk-icon-cache pkgconfig gnomebase gsettings gettext upstream-version-is-even bash-completion features_check useradd
REQUIRED_DISTRO_FEATURES += "opengl polkit pulseaudio systemd x11"
SRC_URI += " \
file://0001-Add-meson-option-to-pass-sysroot.patch \
file://0002-Don-t-update-icon-cache.patch \
file://0003-Remove-panels-for-citadel.patch \
"
SRC_URI[archive.sha256sum] = "83df6a90f98914f2c19a872ce06562acef40927637f679c383099265ccfa42cf"
PACKAGECONFIG ??= "ibus ${@bb.utils.filter('DISTRO_FEATURES', 'wayland', d)}"
PACKAGECONFIG[cups] = ",,cups,cups"
PACKAGECONFIG[ibus] = "-Dibus=true, -Dibus=false, ibus"
PACKAGECONFIG[wayland] = "-Dwayland=true, -Dwayland=false, wayland"
EXTRA_OEMESON = " \
-Doe_sysroot=${STAGING_DIR_HOST} \
"
USERADD_PACKAGES = "${PN}"
USERADD_PARAM:${PN} = "--system --no-create-home --user-group --home-dir ${sysconfdir}/polkit-1 polkitd"
do_install:append() {
if [ -d ${D}${datadir}/polkit-1/rules.d ]; then
chmod 700 ${D}${datadir}/polkit-1/rules.d
chown polkitd:root ${D}${datadir}/polkit-1/rules.d
fi
}
FILES:${PN} += " \
${datadir}/dbus-1 \
${datadir}/gnome-shell \
${datadir}/metainfo \
"
FILES:${PN}-dev += "${datadir}/gettext"
RDEPENDS:${PN} += "gsettings-desktop-schemas"

View File

@ -0,0 +1,29 @@
From 6937685426aff8059b68b2941a0fe549eca21ce5 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Fri, 3 Mar 2023 23:04:56 -0800
Subject: [PATCH] meson: Add riscv32 to seccomp unsupported list
rv32 needs to upstream the libseccomp support
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index 6a888b8..a87c419 100644
--- a/meson.build
+++ b/meson.build
@@ -65,7 +65,7 @@ udev_dep = dependency('libudev', required: get_option('udev'))
host_os = host_machine.system()
host_cpu = host_machine.cpu()
supported_os = ['linux']
-unsupported_cpus = ['alpha', 'ia64', 'm68k', 'sh4', 'sparc', 'sparc64']
+unsupported_cpus = ['alpha', 'ia64', 'm68k', 'riscv32', 'sh4', 'sparc', 'sparc64']
if supported_os.contains(host_os) and not unsupported_cpus.contains(host_cpu)
seccomp_dep = dependency('libseccomp')
else
--
2.39.2

View File

@ -1,40 +0,0 @@
From de0d33b068a5d8e61cc0c82d88d15b9a8aa97977 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
Date: Sat, 6 Apr 2019 18:07:17 +0200
Subject: [PATCH] meson.build: Disable libseccomp for all archs
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
It does not seem mandatory and can cause unsatisfied dependency [1].
[1] https://errors.yoctoproject.org/Errors/Details/235565/
Upstream-Status: Inappropriate [configuration]
Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
---
meson.build | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/meson.build b/meson.build
index 1dc8a73..87d72fe 100644
--- a/meson.build
+++ b/meson.build
@@ -65,12 +65,7 @@ udev_dep = dependency('libudev', required: get_option('udev'))
host_os = host_machine.system()
host_cpu = host_machine.cpu()
supported_os = ['linux']
-unsupported_cpus = ['alpha', 'ia64', 'm68k', 'sh4', 'sparc', 'sparc64']
-if supported_os.contains(host_os) and not unsupported_cpus.contains(host_cpu)
- seccomp_dep = dependency('libseccomp')
-else
- seccomp_dep = dependency('', required: false)
-endif
+seccomp_dep = dependency('', required: false)
fontconfig_cache_path = fontconfig_dep.get_variable(pkgconfig: 'cachedir')
xkb_base = xkb_config_dep.get_variable(pkgconfig: 'xkb_base')
--
2.34.1

View File

@ -10,29 +10,31 @@ GNOMEBASEBUILDCLASS = "meson"
inherit gnomebase itstool pkgconfig upstream-version-is-even gobject-introspection features_check gtk-doc
REQUIRED_DISTRO_FEATURES = "x11"
# gobject-introspection is mandatory and cannot be configured
REQUIRED_DISTRO_FEATURES += "gobject-introspection-data"
REQUIRED_DISTRO_FEATURES = "x11 opengl"
GIR_MESON_OPTION = ""
SRC_URI[archive.sha256sum] = "2a203d76e04f0ebba3dd17bf33474ac19fc4768b6e84fc9177132ed4ceca6ced"
SRC_URI += " \
file://gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch \
file://0001-meson.build-Disable-libseccomp-for-all-archs.patch \
"
SRC_URI += "file://gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch \
file://0001-meson-Add-riscv32-to-seccomp-unsupported-list.patch"
SRC_URI[archive.sha256sum] = "42c773745d84ba14bc1cf1c4c6f4606148803a5cd337941c63964795f3c59d42"
DEPENDS += " \
fontconfig \
gdk-pixbuf \
glib-2.0 \
gsettings-desktop-schemas \
virtual/libx11 \
gtk+3 \
gtk4 \
startup-notification \
xkeyboard-config \
iso-codes \
udev \
xext \
libseccomp \
libxkbcommon \
xkeyboard-config \
xrandr \
"
DEPENDS:remove:riscv32 = "libseccomp"
GTKDOC_MESON_OPTION = "gtk_doc"
EXTRA_OEMESON = "-Ddesktop_docs=false"

View File

@ -26,12 +26,13 @@ DEPENDS = " \
REQUIRED_DISTRO_FEATURES = "x11 polkit pulseaudio systemd gobject-introspection-data"
GIR_MESON_OPTION = ""
SRC_URI[archive.sha256sum] = "3513bb24fc6f8181667223a64a067534fdccf3bf66326a9403d38b0f0d6013d0"
SRC_URI += "file://0001-disable-power-tests-and-sharing.patch"
SRC_URI[archive.sha256sum] = "bb4dc46950e2a90f38f23225848856d2a7b1b718c89d0285ce197b7016bb1dc8"
PACKAGECONFIG ??= " \
nm \
alsa gudev \
smartcard \
${@bb.utils.filter('DISTRO_FEATURES', 'wayland', d)} \
"
PACKAGECONFIG[alsa] = "-Dalsa=true,-Dalsa=false,alsa-lib"
@ -41,13 +42,11 @@ PACKAGECONFIG[nm] = "-Dnetwork_manager=true,-Dnetwork_manager=false,networkmanag
PACKAGECONFIG[smartcard] = "-Dsmartcard=true,-Dsmartcard=false,nss"
PACKAGECONFIG[wayland] = "-Dwayland=true,-Dwayland=false,wayland"
FILES:${PN} += " \
${systemd_user_unitdir} \
${libdir}/gnome-settings-daemon-43/libgsd.so \
"
EXTRA_OEMESON += "\
-Dwwan=false \
-Dusb-protection=false \
-Dsystemd=true \
"
FILES:${PN} += " \
${systemd_user_unitdir} \
/usr/lib/gnome-settings-daemon-45/libgsd.so \
"

View File

@ -6,10 +6,10 @@ REQUIRED_DISTRO_FEATURES = "x11 systemd pam"
GIR_MESON_OPTION = ""
GTKIC_VERSION = "4"
SRCREV = "2c8f4aeaa4ffb9b80b1965b8cfadfb3be9205b1e"
SRCREV = "4474416d653af44a9ba9724583ddff091a92a948"
EXTERNAL_TREE_VAR="CITADEL_GNOME_SHELL_PATH"
GIT_URI = "gitsm://github.com/brl/gnome-shell.git;branch=citadel-43.0;protocol=https"
GIT_URI = "gitsm://github.com/brl/gnome-shell.git;branch=citadel-45.0;protocol=https"
GNOMEBASEBUILDCLASS = "meson"
@ -18,12 +18,12 @@ DEPENDS = " \
sassc-native \
gtk4 \
mutter \
gcr4 \
gcr \
gjs \
mozjs-102 \
network-manager-applet \
gnome-autoar \
polkit \
libsoup-3.0 \
libcroco \
startup-notification \
ibus \
@ -32,7 +32,7 @@ DEPENDS = " \
inherit gnomebase gsettings gettext gobject-introspection gtk-icon-cache features_check external-tree
RDEPENDS:${PN} = "gsettings-desktop-schemas librsvg-gtk"
RDEPENDS:${PN} = "gsettings-desktop-schemas librsvg-gtk tecla"
FILES:${PN} += "\
${datadir}/dbus-1 \
@ -57,4 +57,4 @@ do_configure:append () {
sed --in-place=.old1 "s;=${MUTTER_DIR};=${PKG_CONFIG_SYSROOT_DIR}${MUTTER_DIR};" ${B}/build.ninja
}
EXTRA_OEMESON += "-Dman=false -Dsystemd=true -Dnetworkmanager=true -Dextensions_app=false -Dtests=false"
EXTRA_OEMESON += "-Dman=false -Dsystemd=true -Dnetworkmanager=true -Dextensions_app=false -Dtests=false -Dcamera_monitor=false"

View File

@ -1,21 +0,0 @@
SUMMARY = "GNOME desktop-wide GSettings schemas"
HOMEPAGE = "http://live.gnome.org/gsettings-desktop-schemas"
BUGTRACKER = "https://bugzilla.gnome.org/"
LICENSE = "LGPL-2.1-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
DEPENDS = "glib-2.0 intltool-native"
GNOMEBASEBUILDCLASS = "meson"
inherit gnomebase gsettings gettext gobject-introspection upstream-version-is-even
EXTRA_OEMESON = "-Dintrospection=true"
def gnome_verdir(v):
return oe.utils.trim_version(v, 1)
SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive"
SRC_URI[archive.sha256sum] = "5d5568282ab38b95759d425401f7476e56f8cbf2629885587439f43bd0b84bbe"

View File

@ -0,0 +1,16 @@
SUMMARY = "GNOME desktop-wide GSettings schemas"
DESCRIPTION = "GSettings desktop-wide schemas contains a collection of \
GSettings schemas for settings shared by various components of a desktop."
HOMEPAGE = "https://gitlab.gnome.org/GNOME/gsettings-desktop-schemas"
BUGTRACKER = "https://gitlab.gnome.org/GNOME/gsettings-desktop-schemas/issues"
LICENSE = "LGPL-2.1-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
DEPENDS = "glib-2.0"
GNOMEBASEBUILDCLASS = "meson"
inherit gnomebase gsettings gobject-introspection gettext
SRC_URI[archive.sha256sum] = "365c8d04daf79b38c8b3dc9626349a024f9e4befdd31fede74b42f7a9fbe0ae2"

View File

@ -1,17 +1,18 @@
SUMMARY = "Building blocks for modern GNOME applications"
HOMEPAGE = "https://gitlab.gnome.org/GNOME/libadwaita"
LICENSE="LGPL-2.1-or-later"
LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
GNOMEBASEBUILDCLASS = "meson"
DEPENDS = " \
sassc-native \
gtk4 \
appstream \
"
inherit gnomebase gobject-introspection gtk-doc vala features_check
inherit gnomebase gobject-introspection gi-docgen vala features_check
SRC_URI[archive.sha256sum] = "322f3e1be39ba67981d9fe7228a85818eccaa2ed0aa42bcafe263af881c6460c"
SRC_URI[archive.sha256sum] = "e51a098a54d43568218fc48fcf52e80e36f469b3ce912d8ce9c308a37e9f47c2"
ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
REQUIRED_DISTRO_FEATURES = "opengl"
@ -23,3 +24,5 @@ GTKDOC_MESON_OPTION = 'gtk_doc'
PACKAGECONFIG[examples] = "-Dexamples=true,-Dexamples=false"
FILES:${PN} += "${datadir}/metainfo"
EXTRA_OEMESON += "${@bb.utils.contains('GI_DATA_ENABLED', 'True', '-Dvapi=true', '-Dvapi=false', d)}"

View File

@ -11,23 +11,16 @@ For us this works perfectly fine
Upstream-Status: Inappropriate [OE-specific]
Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
---
libgweather/meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Signed-off-by: Markus Volk <f_l_k@t-online.de>
diff --git a/libgweather/meson.build b/libgweather/meson.build
index 08311af..ef554f2 100644
--- a/libgweather/meson.build
+++ b/libgweather/meson.build
@@ -208,7 +208,7 @@ lib_libgweather = library('gweather-4',
)
--- a/meson.build 2022-09-18 14:48:53.000000000 +0200
+++ b/meson.build 2022-11-26 14:05:13.302487232 +0100
@@ -51,7 +51,7 @@
gen_locations_variant = find_program('build-aux/meson/gen_locations_variant.py')
g_ir_scanner = find_program('g-ir-scanner', required: get_option('introspection'))
-build_gir = get_option('introspection') and g_ir_scanner.found() and not meson.is_cross_build()
+build_gir = get_option('introspection') and g_ir_scanner.found()
build_docs = get_option('gtk_doc') and build_gir
enable_vala = get_option('enable_vala')
vapigen = find_program('vapigen', required: enable_vala == 'true')
--
2.34.1
schemas_srcdir = meson.project_source_root() / 'schemas'

View File

@ -7,18 +7,20 @@ GNOMEBASEBUILDCLASS = "meson"
GNOMEBN = "libgweather"
S = "${WORKDIR}/${GNOMEBN}-${PV}"
inherit gnomebase gsettings gobject-introspection gettext gtk-doc vala
inherit gnomebase gsettings gobject-introspection gettext gi-docgen vala features_check
REQUIRED_DISTRO_FEATURES = "opengl"
SRC_URI += "file://0001-Allow-building-gir-in-cross-environments.patch"
SRC_URI[archive.sha256sum] = "440d44801b6f72b48c676e5e37f9109cfee1394fd74cc92725e1b1ba4fae834c"
SRC_URI[archive.sha256sum] = "af8a812da0d8976a000e1d62572c256086a817323fbf35b066dbfdd8d2ca6203"
GTKDOC_MESON_OPTION = "gtk_doc"
DEPENDS = " \
geocode-glib \
gtk+3 \
gtk4 \
json-glib \
libsoup-2.4 \
libsoup-3.0 \
python3-pygobject-native \
"

View File

@ -11,6 +11,7 @@ DEPENDS = " \
libwacom \
xcomposite \
libinput \
libei \
libcanberra \
mesa \
upower \
@ -25,6 +26,7 @@ DEPENDS = " \
gnome-settings-daemon \
libxtst \
libxkbfile \
startup-notification \
xinerama \
graphene \
graphene-native \
@ -37,10 +39,10 @@ DEPENDS = " \
RDEPENDS:${PN} += " xwayland zenity"
SRCREV = "901190c5a5edbef9c41f8101f3b9ded50ea26c9e"
SRCREV = "d195a063858494cf9c222c5928b1ca1d5eec8624"
EXTERNAL_TREE_VAR="CITADEL_MUTTER_PATH"
GIT_URI = "git://github.com/brl/mutter.git;branch=citadel-43.0;protocol=https"
GIT_URI = "git://github.com/brl/mutter.git;branch=citadel-45.0;protocol=https"
GNOMEBASEBUILDCLASS = "meson"
@ -65,7 +67,7 @@ EXTRA_OEMESON += " \
-Dgles2_libname=libGLESv2.so.2 \
"
MUTTER_API_NAME = "mutter-11"
MUTTER_API_NAME = "mutter-13"
do_install:append() {
# Add gir links in standard paths. That makes dependents life much easier

View File

@ -0,0 +1,36 @@
From 79bf322768990b28c29a9d907edcca52ff48e0b8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= <marcandre.lureau@redhat.com>
Date: Wed, 26 Jul 2023 23:21:10 +0400
Subject: meson: do not rely on an exe wrapper
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Upstream-Status: Backport [https://github.com/ximion/appstream/commit/79bf322768990b28c29a9d907edcca52ff48e0b8]
---
data/meson.build | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/data/meson.build b/data/meson.build
index aea0cb25..ec0e434f 100644
--- a/data/meson.build
+++ b/data/meson.build
@@ -7,6 +7,13 @@ install_data('its/metainfo.its',
install_data('its/metainfo.loc',
install_dir: join_paths(get_option('datadir'), 'gettext', 'its'))
+# Do not rely on an exe wrapper for rel-info, use the system one in that case
+if meson.is_cross_build()
+ dependency('appstream', version: '>=' + as_version, native: true,
+ not_found_message: 'Native appstream required for cross-building')
+ ascli_exe = find_program('appstreamcli')
+endif
+
# NOTE: We do not translate the release notes on purpose here.
# If you do want to give translators a chance to translate them,
# ascli news-to-metainfo needs to produce a temporary file to translate
--
2.41.0

View File

@ -0,0 +1,31 @@
From 6ab00a4279823829a9b82dc9e4d055da4de88c6e Mon Sep 17 00:00:00 2001
From: Markus Volk <f_l_k@t-online.de>
Date: Mon, 12 Dec 2022 15:42:42 +0100
Subject: [PATCH] remove hardcoded path
Signed-off-by: Markus Volk <f_l_k@t-online.de>
Dont include hardcoded path. This fixes:
| cc1: error: include location "/usr/include" is unsafe for cross-compilation [-Werror=poison-system-directories]
Upstream-Status: Inappropriate [oe-specific]
---
meson.build | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/meson.build b/meson.build
index fd0e3373..2f273ada 100644
--- a/meson.build
+++ b/meson.build
@@ -124,7 +124,7 @@ if get_option ('gir')
dependency('gobject-introspection-1.0', version: '>=1.56')
endif
-stemmer_inc_dirs = include_directories(['/usr/include'])
+stemmer_inc_dirs = include_directories([''])
if get_option('stemming')
stemmer_lib = cc.find_library('stemmer', required: true)
if not cc.has_header('libstemmer.h')
--
2.34.1

View File

@ -0,0 +1,45 @@
SUMMARY = "AppStream is a collaborative effort for making machine-readable software metadata easily available."
HOMEPAGE = "https://github.com/ximion/appstream"
LICENSE = "LGPL-2.1-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=435ed639f84d4585d93824e7da3d85da"
DEPENDS = " \
appstream-native \
curl-native \
curl \
docbook-xml-dtd4-native \
gperf-native \
glib-2.0 \
libyaml \
libxml2 \
libxmlb \
libxslt-native \
itstool-native \
docbook-xsl-stylesheets-native \
python3-pygments-native \
"
inherit meson gobject-introspection gettext gtk-doc pkgconfig vala
GIR_MESON_OPTION = "gir"
GTKDOC_MESON_OPTION = "apidocs"
SRC_URI = " \
https://www.freedesktop.org/software/appstream/releases/AppStream-${PV}.tar.xz \
file://0001-remove-hardcoded-path.patch \
file://0001-meson-do-not-rely-on-an-exe-wrapper.patch \
"
SRC_URI[sha256sum] = "081c917646e94d7221c9e4aae54dacda95a27c607fa93cd8e6344a2b318b98b1"
S = "${WORKDIR}/AppStream-${PV}"
PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
PACKAGECONFIG[systemd] = "-Dsystemd=true,-Dsystemd=false,systemd"
PACKAGECONFIG[stemming] = "-Dstemming=true,-Dstemming=false,libstemmer"
FILES:${PN} += "${datadir}"
EXTRA_OEMESON += "${@bb.utils.contains('GI_DATA_ENABLED', 'True', '-Dvapi=true', '-Dvapi=false', d)}"
BBCLASSEXTEND = "native"

View File

@ -1,35 +0,0 @@
From eadb72985d59d66684225591ec395610a3877c0b Mon Sep 17 00:00:00 2001
From: Bruce Leidl <bruce@subgraph.com>
Date: Thu, 22 Sep 2022 18:01:51 -0400
Subject: [PATCH] Don't require ssh binaries for build
---
meson.build | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/meson.build b/meson.build
index ad41582..d16ef48 100644
--- a/meson.build
+++ b/meson.build
@@ -58,8 +58,8 @@ if p11_system_config_modules == ''
error('Couldn\'t find location for pkcs11 module config')
endif
libsecret_dep = dependency('libsecret-1', version: '>= 0.20', required: get_option('ssh_agent'))
-ssh_add_path = find_program('ssh-add', required: get_option('ssh_agent')).full_path()
-ssh_agent_path = find_program('ssh-agent', required: get_option('ssh_agent')).full_path()
+#ssh_add_path = find_program('ssh-add', required: get_option('ssh_agent')).full_path()
+#ssh_agent_path = find_program('ssh-agent', required: get_option('ssh_agent')).full_path()
with_systemd = false
libsystemd_deps = []
@@ -96,8 +96,8 @@ conf.set('HAVE_TIMEGM', cc.has_function('timegm'))
conf.set('HAVE_MLOCK', cc.has_function('mlock'))
conf.set_quoted('GPG_EXECUTABLE', gpg_path)
conf.set_quoted('LIBGCRYPT_VERSION', libgcrypt_dep.version())
-conf.set_quoted('SSH_ADD_EXECUTABLE', ssh_add_path)
-conf.set_quoted('SSH_AGENT_EXECUTABLE', ssh_agent_path)
+#conf.set_quoted('SSH_ADD_EXECUTABLE', ssh_add_path)
+#conf.set_quoted('SSH_AGENT_EXECUTABLE', ssh_agent_path)
conf.set10('WITH_SYSTEMD', with_systemd)
config_file = configure_file(
output: 'config.h',

View File

@ -1,37 +0,0 @@
From cb3708bad88e713e4ccf705cb8c14c5996cd9d06 Mon Sep 17 00:00:00 2001
From: Changqing Li <changqing.li@windriver.com>
Date: Fri, 23 Apr 2021 16:32:38 +0800
Subject: [PATCH] gcr/meson.build: fix one parallel build failure
ui/gcr-live-search.c includes gcr/gcr-marshal.h. Because missing
dependency, following error occurred intermittently during doing parallel
build:
-o ui/libgcr-ui-3.so.1.0.0.p/gcr-live-search.c.o -c ../gcr-3.38.1/ui/gcr-live-search.c
../gcr-3.38.1/ui/gcr-live-search.c:32:10: fatal error: gcr/gcr-marshal.h: No such file or directory
32 | #include "gcr/gcr-marshal.h"
| ^~~~~~~~~~~~~~~~~~~
compilation terminated.
Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/gcr/-/merge_requests/68/diffs]
Signed-off-by: Changqing Li <changqing.li@windriver.com>
---
gcr/meson.build | 1 +
1 file changed, 1 insertion(+)
diff --git a/gcr/meson.build b/gcr/meson.build
index 06c3a63..d9d4b8f 100644
--- a/gcr/meson.build
+++ b/gcr/meson.build
@@ -181,6 +181,7 @@ gcr_base_dep = declare_dependency(
sources: [
gcr_enums_gen[1],
gcr_oids[1],
+ gcr_marshal_gen[1],
],
)
--
2.17.1

View File

@ -1,61 +0,0 @@
From b3ca1d02bb0148ca787ac4aead164d7c8ce2c4d8 Mon Sep 17 00:00:00 2001
From: Jakub Jirutka <jakub@jirutka.cz>
Date: Wed, 12 Jan 2022 00:24:20 +0100
Subject: [PATCH] meson: Fix unknown kw argument in gnome.generate_gir
This argument has been removed in Meson 0.61.0:
gck/meson.build:130:2: ERROR: gnome.generate_gir got unknown keyword arguments "packages"
https://github.com/mesonbuild/meson/commit/f8fc5cb860465718fe7c79a1bf1fe00659f138de:
> The packages argument to gnome.generate_gir was allowed, but never did anything, so stop passing it.
Fixes #89
Upstream-Status: Backport
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
gck/meson.build | 1 -
gcr/meson.build | 1 -
ui/meson.build | 1 -
3 files changed, 3 deletions(-)
diff --git a/gck/meson.build b/gck/meson.build
index 756b486..a21a1e9 100644
--- a/gck/meson.build
+++ b/gck/meson.build
@@ -131,7 +131,6 @@ if get_option('introspection')
sources: gck_gir_sources,
namespace: 'Gck',
nsversion: '@0@'.format(gck_major_version),
- packages: gck_deps,
export_packages: 'gck-@0@'.format(gck_major_version),
includes: [ 'GObject-2.0', 'Gio-2.0' ],
header: 'gck/gck.h',
diff --git a/gcr/meson.build b/gcr/meson.build
index 2233a44..c83641b 100644
--- a/gcr/meson.build
+++ b/gcr/meson.build
@@ -190,7 +190,6 @@ if get_option('introspection')
sources: [ gcr_base_public_sources, gcr_base_headers ],
namespace: 'Gcr',
nsversion: '@0@'.format(gcr_major_version),
- packages: gcr_base_deps,
export_packages: 'gcr-base-@0@'.format(gcr_major_version),
includes: [
'GObject-2.0',
diff --git a/ui/meson.build b/ui/meson.build
index e656ea2..32ee057 100644
--- a/ui/meson.build
+++ b/ui/meson.build
@@ -152,7 +152,6 @@ if get_option('introspection')
export_packages: 'gcr-ui-@0@'.format(gcr_major_version),
identifier_prefix: 'Gcr',
symbol_prefix: 'gcr',
- packages: gcr_ui_deps,
includes: [
'GObject-2.0',
'Gio-2.0',
--
GitLab

View File

@ -1,52 +0,0 @@
SUMMARY = "A library for bits of crypto UI and parsing etc"
DESCRIPTION = "GCR is a library for displaying certificates, and crypto UI, \
accessing key stores. It also provides the viewer for crypto files on the \
GNOME desktop."
HOMEPAGE = "https://gitlab.gnome.org/GNOME/gcr"
BUGTRACKER = "https://gitlab.gnome.org/GNOME/gcr/issues"
LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=55ca817ccb7d5b5b66355690e9abc605"
DEPENDS = "p11-kit glib-2.0 libgcrypt gnupg-native \
${@bb.utils.contains('GI_DATA_ENABLED', 'True', 'libxslt-native', '', d)}"
CACHED_CONFIGUREVARS += "ac_cv_path_GPG='gpg2'"
CFLAGS += "-D_GNU_SOURCE"
GNOMEBASEBUILDCLASS = "meson"
GTKDOC_MESON_OPTION = "gtk_doc"
inherit gnomebase gtk-icon-cache gtk-doc features_check upstream-version-is-even vala gobject-introspection gettext mime mime-xdg
UPSTREAM_CHECK_REGEX = "[^\d\.](?P<pver>\d+\.(?!9\d+)(\d*[02468])+(\.\d+)+)\.tar"
SRC_URI = "https://download.gnome.org/sources/gcr/3.92/gcr-3.92.0.tar.xz;name=archive"
SRC_URI += " file://0001-Don-t-require-ssh-binaries-for-build.patch"
SRC_URI[archive.sha256sum] = "896abf8e1db0f40eb28073f364f36a72385ac8abf8cd1362b1016e97721ff518"
S="${WORKDIR}/gcr-${PV}"
PACKAGECONFIG ??= " \
${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk', '', d)} \
${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'gtk', '', d)} \
"
PACKAGECONFIG[gtk] = "-Dgtk4=true,-Dgtk4=false,gtk4"
FILES:${PN} += " \
${datadir}/dbus-1 \
${datadir}/gcr-3 \
"
# http://errors.yoctoproject.org/Errors/Details/20229/
ARM_INSTRUCTION_SET:armv4 = "arm"
ARM_INSTRUCTION_SET:armv5 = "arm"
ARM_INSTRUCTION_SET:armv6 = "arm"
EXTRA_OEMESON += "--cross-file ${WORKDIR}/meson-${PN}.cross"
EXTRA_OEMESON += "-Dssh_agent=false"
do_write_config:append() {
cat >${WORKDIR}/meson-${PN}.cross <<EOF
[binaries]
gpg2 = '${bindir}/gpg2'
EOF
}

View File

@ -0,0 +1,61 @@
From 9ec4eedeb3f67db0bff09f5d859318d05ff47964 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Fri, 15 Feb 2019 11:17:27 +0100
Subject: [PATCH] Do not write $bindir into pkg-config files
This would otherwise break when using the files to build other target
components (we need to rely on PATH containing the paths to utilities,
rather than use target paths).
Upstream-Status: Inappropriate [upstream wants the paths in .pc files]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
gio/meson.build | 16 ++++++++--------
glib/meson.build | 6 +++---
2 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/gio/meson.build b/gio/meson.build
index a320c0f..86ce7c4 100644
--- a/gio/meson.build
+++ b/gio/meson.build
@@ -884,14 +884,14 @@ pkg.generate(libgio,
'dtdsdir=' + '${datadir}' / dtds_subdir,
'bindir=' + '${prefix}' / get_option('bindir'),
'giomoduledir=' + pkgconfig_giomodulesdir,
- 'gio=' + '${bindir}' / 'gio',
- 'gio_querymodules=' + pkgconfig_multiarch_bindir / 'gio-querymodules',
- 'glib_compile_schemas=' + pkgconfig_multiarch_bindir / 'glib-compile-schemas',
- 'glib_compile_resources=' + '${bindir}' / 'glib-compile-resources',
- 'gdbus=' + '${bindir}' /'gdbus',
- 'gdbus_codegen=' + '${bindir}' / 'gdbus-codegen',
- 'gresource=' + '${bindir}' / 'gresource',
- 'gsettings=' + '${bindir}' / 'gsettings',
+ 'gio=gio',
+ 'gio_querymodules=gio-querymodules',
+ 'glib_compile_schemas=glib-compile-schemas',
+ 'glib_compile_resources=glib-compile-resources',
+ 'gdbus=gdbus',
+ 'gdbus_codegen=gdbus-codegen',
+ 'gresource=gresource',
+ 'gsettings=gsettings',
],
version : glib_version,
install_dir : glib_pkgconfigreldir,
diff --git a/glib/meson.build b/glib/meson.build
index c26a35e..1d8ca6b 100644
--- a/glib/meson.build
+++ b/glib/meson.build
@@ -447,9 +447,9 @@ pkg.generate(libglib,
variables : [
'bindir=' + '${prefix}' / get_option('bindir'),
'datadir=' + '${prefix}' / get_option('datadir'),
- 'glib_genmarshal=' + '${bindir}' / 'glib-genmarshal',
- 'gobject_query=' + '${bindir}' / 'gobject-query',
- 'glib_mkenums=' + '${bindir}' / 'glib-mkenums',
+ 'glib_genmarshal=glib-genmarshal',
+ 'gobject_query=gobject-query',
+ 'glib_mkenums=glib-mkenums',
'glib_valgrind_suppressions=' + '${datadir}' /
valgrind_suppression_file_install_subdir /
fs.name(valgrind_suppression_file),

View File

@ -0,0 +1,31 @@
From c94e669de98a3892c699bd8d0d2b5164b2de747e Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sat, 15 Mar 2014 22:42:29 -0700
Subject: [PATCH] Fix DATADIRNAME on uclibc/Linux
translation files are always installed under PREFIX/share/locale in uclibc
based systems therefore lets set DATADIRNAME to "share".
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Upstream-Status: Pending
---
m4macros/glib-gettext.m4 | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/m4macros/glib-gettext.m4 b/m4macros/glib-gettext.m4
index df6fbf0..47db864 100644
--- a/m4macros/glib-gettext.m4
+++ b/m4macros/glib-gettext.m4
@@ -293,6 +293,10 @@ msgstr ""
CATOBJEXT=.mo
DATADIRNAME=share
;;
+ *-*-musl* | *-*-linux-uclibc*)
+ CATOBJEXT=.gmo
+ DATADIRNAME=share
+ ;;
*)
CATOBJEXT=.mo
DATADIRNAME=lib

View File

@ -0,0 +1,27 @@
From 0015db45cd1bfefc04959dffab5dabeead93136f Mon Sep 17 00:00:00 2001
From: Jussi Kukkonen <jussi.kukkonen@intel.com>
Date: Tue, 22 Mar 2016 15:14:58 +0200
Subject: [PATCH] Install gio-querymodules as libexec_PROGRAM
We want to install this binary with the gio library, and debian
renamer does not cope with library packages with files in ${bindir}
Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
Upstream-Status: Inappropriate [OE specific]
---
gio/meson.build | 1 +
1 file changed, 1 insertion(+)
diff --git a/gio/meson.build b/gio/meson.build
index 2ef60ed..532b086 100644
--- a/gio/meson.build
+++ b/gio/meson.build
@@ -936,6 +936,7 @@ gio_querymodules = executable('gio-querymodules', 'gio-querymodules.c', 'giomodu
c_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
+ install_dir: glib_libexecdir,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
glib_compile_schemas = executable('glib-compile-schemas',

View File

@ -0,0 +1,40 @@
From 4f47b8a8d650d185aa61aec2f56a283522a723c4 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Fri, 12 Jun 2015 17:08:46 +0300
Subject: [PATCH] Remove the warning about deprecated paths in schemas
Some schemas in gsettings-desktop-schemas (such as proxy and locale)
are still using deprecated paths, as of 3.16.1. This causes warning
messages, and meta/lib/oe/rootfs.py complaints about them.
Upstream-Status: Inappropriate
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
gio/glib-compile-schemas.c | 13 -------------
1 file changed, 13 deletions(-)
diff --git a/gio/glib-compile-schemas.c b/gio/glib-compile-schemas.c
index 7888120..7acbd5b 100644
--- a/gio/glib-compile-schemas.c
+++ b/gio/glib-compile-schemas.c
@@ -1232,19 +1232,6 @@ parse_state_start_schema (ParseState *state,
return;
}
- if (path && (g_str_has_prefix (path, "/apps/") ||
- g_str_has_prefix (path, "/desktop/") ||
- g_str_has_prefix (path, "/system/")))
- {
- gchar *message = NULL;
- message = g_strdup_printf (_("Warning: Schema “%s” has path “%s”. "
- "Paths starting with "
- "“/apps/”, “/desktop/” or “/system/” are deprecated."),
- id, path);
- g_printerr ("%s\n", message);
- g_free (message);
- }
-
state->schema_state = schema_state_new (path, gettext_domain,
extends, extends_name, list_of);

View File

@ -0,0 +1,81 @@
From ba1728bc27c88597164957d000b70ec4be6edf28 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Wed, 13 Feb 2019 15:32:05 +0100
Subject: [PATCH] Set host_machine correctly when building with mingw32
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
gio/tests/meson.build | 8 ++++----
glib/tests/meson.build | 2 +-
meson.build | 3 +++
3 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/gio/tests/meson.build b/gio/tests/meson.build
index f644aa2..64a8684 100644
--- a/gio/tests/meson.build
+++ b/gio/tests/meson.build
@@ -29,7 +29,7 @@ endif
test_cpp_args = test_c_args
-if host_machine.system() == 'windows'
+if host_system == 'windows'
common_gio_tests_deps += [iphlpapi_dep, winsock2, cc.find_library ('secur32')]
endif
@@ -210,7 +210,7 @@ if have_dbus_daemon
endif
# Test programs buildable on UNIX only
-if host_machine.system() != 'windows'
+if host_system != 'windows'
gio_tests += {
'file' : {},
'gdbus-peer-object-manager' : {},
@@ -462,7 +462,7 @@ if host_machine.system() != 'windows'
endif # unix
# Test programs buildable on Windows only
-if host_machine.system() == 'windows'
+if host_system == 'windows'
gio_tests += {'win32-streams' : {}}
endif
@@ -532,7 +532,7 @@ if cc.get_id() != 'msvc' and cc.get_id() != 'clang-cl'
}
endif
-if host_machine.system() != 'windows'
+if host_system != 'windows'
test_extra_programs += {
'gdbus-example-unix-fd-client' : {
'install' : false,
diff --git a/glib/tests/meson.build b/glib/tests/meson.build
index db01b54..6950817 100644
--- a/glib/tests/meson.build
+++ b/glib/tests/meson.build
@@ -188,7 +188,7 @@ if glib_conf.has('HAVE_EVENTFD')
}
endif
-if host_machine.system() == 'windows'
+if host_system == 'windows'
if winsock2.found()
glib_tests += {
'gpoll' : {
diff --git a/meson.build b/meson.build
index 43bb468..5f9b59c 100644
--- a/meson.build
+++ b/meson.build
@@ -43,6 +43,9 @@ else
endif
host_system = host_machine.system()
+if host_system == 'mingw32'
+ host_system = 'windows'
+endif
if host_system == 'darwin'
ios_test_code = '''#include <TargetConditionals.h>

View File

@ -0,0 +1,28 @@
From 92de6c7eb30b961b24a2dce812d5276487b7d23d Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Wed, 8 Jan 2020 18:22:46 +0100
Subject: [PATCH] gio/tests/resources.c: comment out a build host-only test
This test requires building resources in a way that is
not cross-compatible (hardcodes ld and objcopy).
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
gio/tests/resources.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gio/tests/resources.c b/gio/tests/resources.c
index c44d214..e289a01 100644
--- a/gio/tests/resources.c
+++ b/gio/tests/resources.c
@@ -993,7 +993,7 @@ main (int argc,
g_test_add_func ("/resource/automatic", test_resource_automatic);
/* This only uses automatic resources too, so it tests the constructors and destructors */
g_test_add_func ("/resource/module", test_resource_module);
- g_test_add_func ("/resource/binary-linked", test_resource_binary_linked);
+ /* g_test_add_func ("/resource/binary-linked", test_resource_binary_linked); */
#endif
g_test_add_func ("/resource/uri/query-info", test_uri_query_info);
g_test_add_func ("/resource/uri/file", test_uri_file);

View File

@ -0,0 +1,29 @@
From 4b97f457b7b44117e27d2a218c4b68e7fe3fe4ce Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sat, 12 Oct 2019 17:46:26 -0700
Subject: [PATCH] meson: Run atomics test on clang as well
Fixes
./glib-2.62.1/glib/gatomic.c:675:2: error: G_ATOMIC_LOCK_FREE defined, but incapable of lock-free atomics.
^
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index afb6eaa..6aa70f5 100644
--- a/meson.build
+++ b/meson.build
@@ -1692,7 +1692,7 @@ atomicdefine = '''
# We know that we can always use real ("lock free") atomic operations with MSVC
if cc.get_id() == 'msvc' or cc.get_id() == 'clang-cl' or cc.links(atomictest, name : 'atomic ops')
have_atomic_lock_free = true
- if cc.get_id() == 'gcc' and not cc.compiles(atomicdefine, name : 'atomic ops define')
+ if (cc.get_id() == 'gcc' or cc.get_id() == 'clang') and not cc.compiles(atomicdefine, name : 'atomic ops define')
# Old gcc release may provide
# __sync_bool_compare_and_swap but doesn't define
# __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4

View File

@ -0,0 +1,32 @@
From 9aa9574861fad39d0679025e35fe1e188345f685 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex@linutronix.de>
Date: Sat, 16 Sep 2023 22:28:27 +0200
Subject: [PATCH] meson.build: do not enable pidfd features on native glib
builds
We still use host distros like alma 8 with kernels older than 5.4,
where these features are not implemented.
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
meson.build | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index 1c36993..bbf97fc 100644
--- a/meson.build
+++ b/meson.build
@@ -981,7 +981,8 @@ if cc.links('''#include <sys/syscall.h>
waitid (P_PIDFD, 0, &child_info, WEXITED | WNOHANG);
return 0;
}''', name : 'pidfd_open(2) system call')
- glib_conf.set('HAVE_PIDFD', 1)
+ #requires kernel 5.4+
+ #glib_conf.set('HAVE_PIDFD', 1)
endif
# Check for __uint128_t (gcc) by checking for 128-bit division
--
2.30.2

View File

@ -0,0 +1,44 @@
From 79ce7e545dd3a93f77d2146d50b6fa061fbceed9 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Tue, 3 Oct 2017 10:45:55 +0300
Subject: [PATCH] Do not hardcode python path into various tools
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
gio/gdbus-2.0/codegen/gdbus-codegen.in | 2 +-
gobject/glib-genmarshal.in | 2 +-
gobject/glib-mkenums.in | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/gio/gdbus-2.0/codegen/gdbus-codegen.in b/gio/gdbus-2.0/codegen/gdbus-codegen.in
index 67d3675..4e92a7a 100755
--- a/gio/gdbus-2.0/codegen/gdbus-codegen.in
+++ b/gio/gdbus-2.0/codegen/gdbus-codegen.in
@@ -1,4 +1,4 @@
-#!/usr/bin/env @PYTHON@
+#!/usr/bin/env python3
# GDBus - GLib D-Bus Library
#
diff --git a/gobject/glib-genmarshal.in b/gobject/glib-genmarshal.in
index 7380f24..c8abeaa 100755
--- a/gobject/glib-genmarshal.in
+++ b/gobject/glib-genmarshal.in
@@ -1,4 +1,4 @@
-#!/usr/bin/env @PYTHON@
+#!/usr/bin/env python3
# pylint: disable=too-many-lines, missing-docstring, invalid-name
diff --git a/gobject/glib-mkenums.in b/gobject/glib-mkenums.in
index 91ad779..3ebef62 100755
--- a/gobject/glib-mkenums.in
+++ b/gobject/glib-mkenums.in
@@ -1,4 +1,4 @@
-#!/usr/bin/env @PYTHON@
+#!/usr/bin/env python3
# If the code below looks horrible and unpythonic, do not panic.
#

View File

@ -0,0 +1,3 @@
[properties]
# On all known supported architectures the stack grows down
growing_stack = false

View File

@ -0,0 +1,6 @@
[properties]
have_c99_vsnprintf = true
have_c99_snprintf = true
have_unix98_printf = true
va_val_copy = true
have_strlcpy = true

View File

@ -0,0 +1,5 @@
[properties]
have_proc_self_cmdline = true
[binaries]
env = '/usr/bin/env'

View File

@ -0,0 +1,6 @@
[properties]
have_c99_vsnprintf = false
have_c99_snprintf = false
have_unix98_printf = false
va_val_copy = true
have_proc_self_cmdline = false

View File

@ -0,0 +1,6 @@
[properties]
have_c99_vsnprintf = true
have_c99_snprintf = true
have_unix98_printf = true
va_val_copy = true
have_strlcpy = true

View File

@ -0,0 +1,45 @@
From b90d13900dd2777c2ab90c5b0be1a872c10a17da Mon Sep 17 00:00:00 2001
From: Ross Burton <ross.burton@intel.com>
Date: Fri, 11 Mar 2016 15:35:55 +0000
Subject: [PATCH] glib-2.0: relocate the GIO module directory for native builds
Instead of hard-coding GIO_MODULE_PATH when glib is built, use dladdr() to
determine where libglib.so is and use that path to calculate GIO_MODULES_DIR.
This solves relocation problems with GIOModule for native builds of glib.
Upstream-Status: Inappropriate
Signed-off-by: Ross Burton <ross.burton@intel.com>
Port patch to 2.48
Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
---
gio/giomodule.c | 7 -------
1 file changed, 7 deletions(-)
diff --git a/gio/giomodule.c b/gio/giomodule.c
index 17fabe6..8021208 100644
--- a/gio/giomodule.c
+++ b/gio/giomodule.c
@@ -1271,11 +1271,6 @@ get_gio_module_dir (void)
g_free (install_dir);
#else
module_dir = g_strdup (GIO_MODULE_DIR);
-#ifdef __APPLE__
-#include "TargetConditionals.h"
-/* Only auto-relocate on macOS, not watchOS etc; older macOS SDKs only define TARGET_OS_MAC */
-#if (defined (TARGET_OS_OSX) && TARGET_OS_OSX) || \
- (!defined (TARGET_OS_OSX) && defined (TARGET_OS_MAC) && TARGET_OS_MAC)
#include <dlfcn.h>
{
g_autofree gchar *path = NULL;
@@ -1294,8 +1289,6 @@ get_gio_module_dir (void)
}
}
}
-#endif
-#endif
#endif
}

View File

@ -0,0 +1,10 @@
#! /bin/sh
set -eux
if id -u glib2-test; then
userdel glib2-test
fi
useradd glib2-test
cd /tmp
su glib2-test -c 'G_TEST_TMPDIR=`readlink -f /tmp` gnome-desktop-testing-runner glib'
userdel glib2-test

View File

@ -0,0 +1,53 @@
require glib.inc
PE = "1"
SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}"
SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \
file://run-ptest \
file://0001-Fix-DATADIRNAME-on-uclibc-Linux.patch \
file://0001-Remove-the-warning-about-deprecated-paths-in-schemas.patch \
file://0001-Install-gio-querymodules-as-libexec_PROGRAM.patch \
file://0010-Do-not-hardcode-python-path-into-various-tools.patch \
file://0001-Set-host_machine-correctly-when-building-with-mingw3.patch \
file://0001-Do-not-write-bindir-into-pkg-config-files.patch \
file://0001-meson-Run-atomics-test-on-clang-as-well.patch \
file://0001-gio-tests-resources.c-comment-out-a-build-host-only-.patch \
"
SRC_URI:append:class-native = " file://relocate-modules.patch \
file://0001-meson.build-do-not-enable-pidfd-features-on-native-g.patch \
"
SRC_URI[sha256sum] = "44eaab8b720877ce303c5540b657b126f12dc94972d9880b52959f43fb537b30"
# Find any meson cross files in FILESPATH that are relevant for the current
# build (using siteinfo) and add them to EXTRA_OEMESON.
inherit siteinfo
def find_meson_cross_files(d):
if bb.data.inherits_class('native', d):
return ""
thisdir = os.path.normpath(d.getVar("THISDIR"))
import collections
sitedata = siteinfo_data(d)
# filename -> found
files = collections.OrderedDict()
for path in d.getVar("FILESPATH").split(":"):
for element in sitedata:
filename = os.path.normpath(os.path.join(path, "meson.cross.d", element))
sanitized_path = filename.replace(thisdir, "${THISDIR}")
if sanitized_path == filename:
if os.path.exists(filename):
bb.error("Cannot add '%s' to --cross-file, because it's not relative to THISDIR '%s' and sstate signature would contain this full path" % (filename, thisdir))
continue
files[filename.replace(thisdir, "${THISDIR}")] = os.path.exists(filename)
items = ["--cross-file=" + k for k,v in files.items() if v]
d.appendVar("EXTRA_OEMESON", " " + " ".join(items))
items = ["%s:%s" % (k, "True" if v else "False") for k,v in files.items()]
d.appendVarFlag("do_configure", "file-checksums", " " + " ".join(items))
python () {
find_meson_cross_files(d)
}

View File

@ -0,0 +1,202 @@
SUMMARY = "A general-purpose utility library"
DESCRIPTION = "GLib is a general-purpose utility library, which provides many useful data types, macros, type conversions, string utilities, file utilities, a main loop abstraction, and so on."
HOMEPAGE = "https://developer.gnome.org/glib/"
# pcre is under BSD;
# docs/reference/COPYING is with a 'public domain'-like license!
LICENSE = "LGPL-2.1-or-later & BSD-3-Clause & PD"
LIC_FILES_CHKSUM = "file://COPYING;md5=41890f71f740302b785c27661123bff5 \
file://glib/glib.h;beginline=4;endline=17;md5=72f7cc2847407f65d8981ef112e4e630 \
file://LICENSES/LGPL-2.1-or-later.txt;md5=41890f71f740302b785c27661123bff5 \
file://gmodule/gmodule.h;beginline=4;endline=17;md5=72f7cc2847407f65d8981ef112e4e630 \
file://docs/reference/COPYING;md5=f51a5100c17af6bae00735cd791e1fcc"
BUGTRACKER = "http://bugzilla.gnome.org"
SECTION = "libs"
CVE_PRODUCT = "glib"
BBCLASSEXTEND = "native nativesdk"
DEPENDS = "glib-2.0-native \
virtual/libintl \
virtual/libiconv \
libffi \
libpcre2 \
zlib"
PACKAGES += "${PN}-codegen ${PN}-utils"
LEAD_SONAME = "libglib-2.0.*"
inherit meson gettext gtk-doc pkgconfig ptest-gnome upstream-version-is-even bash-completion gio-module-cache manpages
DEPENDS:append:class-target = "${@' gtk-doc' if d.getVar('GTKDOC_ENABLED') == 'True' else ''}"
GTKDOC_MESON_OPTION = "gtk_doc"
S = "${WORKDIR}/glib-${PV}"
PACKAGECONFIG ??= "libmount \
${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)}"
PACKAGECONFIG[libmount] = "-Dlibmount=enabled,-Dlibmount=disabled,util-linux"
PACKAGECONFIG[manpages] = "-Dman=true, -Dman=false, libxslt-native xmlto-native"
PACKAGECONFIG[libelf] = "-Dlibelf=enabled,-Dlibelf=disabled,elfutils"
PACKAGECONFIG[tests] = "-Dinstalled_tests=true,-Dinstalled_tests=false,"
PACKAGECONFIG[selinux] = "-Dselinux=enabled,-Dselinux=disabled,libselinux"
EXTRA_OEMESON = "-Ddtrace=false -Dsystemtap=false"
do_configure:prepend() {
sed -i -e '1s,#!.*,#!${USRBINPATH}/env python3,' ${S}/gio/gdbus-2.0/codegen/gdbus-codegen.in
}
FILES:${PN} = "${libdir}/lib*${SOLIBS} \
${libdir}/gio \
${libexecdir}/*gio-querymodules \
${libexecdir}/*gio-launch-desktop \
${datadir}/glib-2.0/dtds \
${datadir}/glib-2.0/schemas"
FILES:${PN}-utils += "${bindir}/glib-genmarshal \
${bindir}/glib-gettextize \
${bindir}/glib-mkenums \
${bindir}/glib-compile-resources"
FILES:${PN}-dev += "${libdir}/glib-2.0/include \
${libdir}/gio/modules/lib*${SOLIBSDEV} \
${libdir}/gio/modules/*.la \
${datadir}/glib-2.0/gettext/po/Makefile.in.in \
${datadir}/glib-2.0/schemas/gschema.dtd \
${datadir}/glib-2.0/valgrind/glib.supp \
${datadir}/gettext/its"
FILES:${PN}-dbg += "${datadir}/glib-2.0/gdb ${datadir}/gdb"
FILES:${PN}-codegen = "${datadir}/glib-2.0/codegen/*.py \
${bindir}/gdbus-codegen"
FILES:${PN}-utils = "${bindir}/*"
SHAREDMIMEDEP = "shared-mime-info"
SHAREDMIMEDEP:class-native = ""
# When cross compiling for Windows we don't want to include this
SHAREDMIMEDEP:mingw32 = ""
RRECOMMENDS:${PN} += "${SHAREDMIMEDEP}"
ARM_INSTRUCTION_SET:armv4 = "arm"
ARM_INSTRUCTION_SET:armv5 = "arm"
# Valgrind runtime detection works using hand-written assembly, which
# doesn't support mips16e
CPPFLAGS:append:class-target:mips16e = " -DNVALGRIND=1"
# GLib generally requires gettext to be present so for USE_NLS to yes. For
# native builds as i18n is disabled globally we have to add a gettext-native dependency.
USE_NLS:class-target = "yes"
USE_NLS:class-nativesdk = "yes"
DEPENDS:append:class-native = " gettext-native"
EXEEXT = ""
EXEEXT:mingw32 = ".exe"
do_install:append () {
if [ -f ${D}${bindir}/gtester-report ]; then
sed ${D}${bindir}/gtester-report -i -e '1s|^#!.*|#!/usr/bin/env python3|'
fi
# Remove some unpackaged files
rm -rf ${D}${datadir}/glib-2.0/codegen/__pycache__
rm -f ${D}${datadir}/glib-2.0/codegen/*.pyc
rm -f ${D}${datadir}/glib-2.0/codegen/*.pyo
if [ -e ${D}${libdir}/charset.alias ]; then
rm -f ${D}${libdir}/charset.alias
fi
# Make sure gio-querymodules is unique among multilibs
if test "x${MLPREFIX}" != "x"; then
mv ${D}${libexecdir}/gio-querymodules${EXEEXT} ${D}${libexecdir}/${MLPREFIX}gio-querymodules${EXEEXT}
fi
# Autotools does this, meson does not
mkdir -p ${D}${libdir}/gio/modules
}
do_install:append:class-target () {
# Tests are only installed on targets, not native builds. Separating this out
# keeps glib-2.0-native from depending on DISTRO_FEATURES
if [ -f ${D}${datadir}/installed-tests/glib/gdbus-serialization.test ]; then
if ${@bb.utils.contains("DISTRO_FEATURES", "x11", "false", "true", d)}; then
rm ${D}${datadir}/installed-tests/glib/gdbus-serialization.test
fi
fi
if [ -f ${D}${datadir}/installed-tests/glib/static-link.test ]; then
if test "x${MLPREFIX}" != "x"; then
mv ${D}${datadir}/installed-tests/glib/static-link.test ${D}${datadir}/installed-tests/glib/${MLPREFIX}static-link.test
fi
fi
# https://gitlab.gnome.org/GNOME/glib/-/issues/2810
rm -f ${D}${datadir}/installed-tests/glib/thread-pool-slow.test
}
# As we do not build python3 for windows, makes no sense to ship the script that's using it
do_install:append:mingw32() {
rm -f ${D}${bindir}/gtester-report
}
CODEGEN_PYTHON_RDEPENDS = "python3 python3-distutils python3-xml"
CODEGEN_PYTHON_RDEPENDS:mingw32 = ""
RDEPENDS:${PN}-codegen += "${CODEGEN_PYTHON_RDEPENDS}"
RDEPENDS:${PN}-ptest += "${PN}-utils"
RDEPENDS:${PN}-ptest += "\
coreutils \
libgcc \
dbus \
desktop-file-utils \
gnome-desktop-testing \
tzdata \
tzdata-americas \
tzdata-asia \
tzdata-europe \
tzdata-posix \
shared-mime-info \
${PN}-locale-ja \
${PN}-locale-fr \
${PN}-locale-el \
${PN}-locale-hr \
${PN}-locale-lt \
${PN}-locale-pl \
${PN}-locale-ru \
${PN}-locale-th \
python3-core \
python3-modules \
${@bb.utils.contains('GI_DATA_ENABLED', 'True', 'python3-dbusmock', '', d)} \
${PN}-codegen \
"
RDEPENDS:${PN}-ptest:append:libc-glibc = "\
glibc-gconv-utf-16 \
glibc-charmap-utf-8 \
glibc-gconv-cp1255 \
glibc-charmap-cp1255 \
glibc-gconv-utf-32 \
glibc-gconv-utf-7 \
glibc-gconv-euc-jp \
glibc-gconv-iso8859-1 \
glibc-gconv-iso8859-15 \
glibc-charmap-invariant \
glibc-localedata-translit-cjk-variants \
locale-base-tr-tr \
locale-base-lt-lt \
locale-base-ja-jp.euc-jp \
locale-base-fa-ir \
locale-base-ru-ru \
locale-base-de-de \
locale-base-hr-hr \
locale-base-el-gr \
locale-base-fr-fr \
locale-base-es-es \
locale-base-en-gb \
locale-base-en-us \
locale-base-pl-pl \
locale-base-pl-pl.iso-8859-2 \
"

View File

@ -1,22 +0,0 @@
SUMMARY = "A thin layer of graphic data types"
HOMEPAGE = "http://ebassi.github.io/graphene/"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=a7d871d9e23c450c421a85bb2819f648"
GNOMEBASEBUILDCLASS = "meson"
inherit gnomebase gobject-introspection gtk-doc
SRC_URI[archive.sha256sum] = "a37bb0e78a419dcbeaa9c7027bcff52f5ec2367c25ec859da31dfde2928f279a"
# gtk4 & mutter 41.0 requires graphene build with introspection
PACKAGECONFIG ?= "introspection"
PACKAGECONFIG[introspection] = "-Dintrospection=enabled,-Dintrospection=disabled,"
GTKDOC_MESON_OPTION = "gtk_doc"
EXTRA_OEMESON = "-Dinstalled_tests=false"
FILES:${PN} += "${libdir}/graphene-1.0"
BBCLASSEXTEND = "native nativesdk"

View File

@ -0,0 +1,151 @@
SUMMARY = "Multi-platform toolkit for creating GUIs"
DESCRIPTION = "GTK+ is a multi-platform toolkit for creating graphical user interfaces. Offering a complete \
set of widgets, GTK+ is suitable for projects ranging from small one-off projects to complete application suites."
HOMEPAGE = "http://www.gtk.org"
BUGTRACKER = "https://bugzilla.gnome.org/"
SECTION = "libs"
DEPENDS = "glib-2.0 cairo pango atk jpeg libpng gdk-pixbuf gdk-pixbuf-native"
LICENSE = "LGPL-2.0-only & LGPL-2.0-or-later & LGPL-2.1-or-later"
inherit meson gettext pkgconfig gtk-doc update-alternatives gtk-immodules-cache gsettings features_check gobject-introspection
BBCLASSEXTEND = "native nativesdk"
GSETTINGS_PACKAGE:class-native = ""
# versions >= 3.90 are development versions, otherwise like upstream-version-is-even
UPSTREAM_CHECK_REGEX = "[^\d\.](?P<pver>3\.([1-8]?[02468])+(\.\d+)+)\.tar"
ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
do_configure:prepend() {
# These files are generated by wayland-scanner but will race over modification
# time between the copies in the sysroot from wayland-protocols and the copy
# in the source tree. Solve the race by deleting so they need to be regenerated.
rm -f ${S}/modules/input/*-text-input-*.[ch]
}
GTKDOC_MESON_OPTION = 'gtk_doc'
EXTRA_OEMESON = "-Dxinerama=no -Dtests=false"
EXTRA_OEMESON:append:class-native = " -Ddemos=false -Dexamples=false"
PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'opengl wayland x11', d)}"
PACKAGECONFIG:class-native = "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
PACKAGECONFIG:class-nativesdk = "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
PACKAGECONFIG[x11] = "-Dx11_backend=true,-Dx11_backend=false,at-spi2-atk fontconfig libx11 libxext libxcursor libxi libxdamage libxrandr libxrender libxcomposite libxfixes"
# this is provided by oe-core patch that removes epoxy/gl dependency from a X11 build
PACKAGECONFIG[opengl] = "-Dopengl=true,-Dopengl=false,libepoxy"
PACKAGECONFIG[wayland] = "-Dwayland_backend=true,-Dwayland_backend=false,wayland wayland-protocols libxkbcommon virtual/egl virtual/libgles2 wayland-native"
PACKAGECONFIG[cups] = ",,cups,cups"
PACKAGECONFIG[colord] = "-Dcolord=yes,-Dcolord=no,colord"
PACKAGECONFIG[cloudproviders] = "-Dcloudproviders=true,-Dcloudproviders=false,libcloudproviders"
PACKAGECONFIG[tracker3] = "-Dtracker3=true,-Dtracker3=false,tracker,tracker-miners"
prepare_gtk_scripts() {
mv ${D}${bindir}/gtk-update-icon-cache ${D}${bindir}/gtk-update-icon-cache-3.0
# duplicate gtk-query-immodules for post install script update_gtk_immodules_cache
mkdir -p ${D}${libexecdir}
ln ${D}${bindir}/gtk-query-immodules-3.0 ${D}${libexecdir}/${MLPREFIX}gtk-query-immodules-3.0
}
do_install:append:class-target() {
prepare_gtk_scripts
}
do_install:append:class-nativesdk() {
prepare_gtk_scripts
}
do_install:append:class-native() {
create_wrapper ${D}/${bindir}/gtk-update-icon-cache \
GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
create_wrapper ${D}/${bindir}/gtk-encode-symbolic-svg \
GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
}
PROVIDES += "gtk-icon-utils"
PACKAGES =+ "${PN}-demo"
LIBV = "3.0.0"
FILES:${PN}-demo = "${bindir}/gtk3-demo \
${bindir}/gtk3-demo-application \
${bindir}/gtk3-icon-browser \
${bindir}/gtk3-widget-factory \
${datadir}/gtk-3.0/demo \
${datadir}/applications/gtk3-demo.desktop \
${datadir}/applications/gtk3-icon-browser.desktop \
${datadir}/applications/gtk3-widget-factory.desktop \
${datadir}/icons/hicolor/*/apps/gtk3-demo*.png \
${datadir}/icons/hicolor/*/apps/gtk3-widget-factory*.png"
FILES:${PN}:append = " ${bindir}/gtk-update-icon-cache-3.0 \
${bindir}/gtk-query-immodules-3.0 \
${bindir}/gtk-launch \
${datadir}/themes ${datadir}/gtk-3.0/emoji \
${sysconfdir} ${datadir}/glib-2.0/schemas/ \
${libdir}/gtk-3.0/${LIBV}/engines/libpixmap.so \
${libdir}/gtk-3.0/modules/*.so"
FILES:${PN}-dev += " \
${datadir}/gtk-3.0/gtkbuilder.rng \
${datadir}/gtk-3.0/include \
${datadir}/gtk-3.0/valgrind \
${datadir}/gettext/its \
${libdir}/gtk-3.0/include \
${libdir}/gtk-3.0/${LIBV}/loaders/*.la \
${libdir}/gtk-3.0/${LIBV}/immodules/*.la \
${libdir}/gtk-3.0/3.0.0/printbackends/*.la \
${libdir}/gtk-3.0/${LIBV}/engines/*.la \
${libdir}/gtk-3.0/modules/*.la \
${bindir}/gtk-builder-convert \
${bindir}/gtk-encode-symbolic-svg \
${bindir}/gtk-builder-tool \
${bindir}/gtk-query-settings \
"
GTKBASE_RRECOMMENDS ?= "liberation-fonts \
gdk-pixbuf-loader-png \
gdk-pixbuf-loader-jpeg \
gdk-pixbuf-loader-gif \
gdk-pixbuf-loader-xpm \
shared-mime-info \
adwaita-icon-theme-symbolic \
"
GTKBASE_RRECOMMENDS:class-native ?= "\
"
GTKGLIBC_RRECOMMENDS ?= "${GTKBASE_RRECOMMENDS} glibc-gconv-iso8859-1"
RRECOMMENDS:${PN} = "${GTKBASE_RRECOMMENDS}"
RRECOMMENDS:${PN}:libc-glibc = "${GTKGLIBC_RRECOMMENDS}"
RDEPENDS:${PN}-dev += "${@bb.utils.contains("PACKAGECONFIG", "wayland", "wayland-protocols", "", d)}"
PACKAGES_DYNAMIC += "^gtk3-immodule-.* ^gtk3-printbackend-.*"
ALTERNATIVE:${PN} = "gtk-update-icon-cache"
ALTERNATIVE_TARGET[gtk-update-icon-cache] = "${bindir}/gtk-update-icon-cache-3.0"
ALTERNATIVE_PRIORITY = "30"
python populate_packages:prepend () {
import os.path
gtk_libdir = d.expand('${libdir}/gtk-3.0/${LIBV}')
immodules_root = os.path.join(gtk_libdir, 'immodules')
printmodules_root = os.path.join(gtk_libdir, 'printbackends');
immodules = do_split_packages(d, immodules_root, r'^im-(.*)\.so$', 'gtk3-immodule-%s', 'GTK input module for %s')
if immodules:
d.setVar("GTKIMMODULES_PACKAGES", " ".join(immodules))
do_split_packages(d, printmodules_root, r'^libprintbackend-(.*)\.so$', 'gtk3-printbackend-%s', 'GTK printbackend module for %s')
if (d.getVar('DEBIAN_NAMES')):
d.setVar(d.expand('PKG:${PN}'), '${MLPREFIX}libgtk-3.0')
}

View File

@ -0,0 +1,737 @@
From 4a0716f04fb25b51b08e994bd5a900b2e7f7fed5 Mon Sep 17 00:00:00 2001
From: Jussi Kukkonen <jussi.kukkonen@intel.com>
Date: Fri, 16 Oct 2015 16:35:16 +0300
Subject: [PATCH] Do not try to initialize GL without libGL
_gdk_x11_screen_update_visuals_for_gl() will end up calling epoxys
GLX api which will exit() if libGL.so.1 is not present. We do not
want that to happen and we don't want every app to have to set
"GDK_GL=disabled" environment variable: so use #ifdef set based on
opengl distro feature.
Upstream is not interested in the fix as it is: Either epoxy should be
fixed (to not exit) or GTK+ possibly could do some additional probing
before calling epoxy APIs.
Upstream-Status: Denied
Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
---
demos/gtk-demo/meson.build | 5 ++++-
docs/tools/meson.build | 7 +++++--
docs/tools/widgets.c | 6 +++++-
gdk/gdkconfig.h.meson | 1 +
gdk/gdkdisplay.c | 4 ++++
gdk/gdkgl.c | 10 ++++++++++
gdk/gdkglcontext.c | 6 ++++++
gdk/gdkwindow.c | 13 +++++++++++++
gdk/meson.build | 8 +++++++-
gdk/x11/gdkdisplay-x11.c | 6 +++++-
gdk/x11/gdkvisual-x11.c | 5 +++++
gdk/x11/gdkwindow-x11.c | 4 ++++
gdk/x11/gdkx-autocleanups.h | 2 ++
gdk/x11/gdkx.h | 2 ++
gdk/x11/meson.build | 7 +++++--
gtk/gtkglarea.c | 19 +++++++++++++++++++
gtk/inspector/general.c | 6 ++++++
meson.build | 17 ++++++++++++++---
meson_options.txt | 2 ++
tests/meson.build | 9 +++++++--
testsuite/gtk/objects-finalize.c | 2 ++
21 files changed, 128 insertions(+), 13 deletions(-)
diff --git a/demos/gtk-demo/meson.build b/demos/gtk-demo/meson.build
index 252da16d05..4b57cff6ac 100644
--- a/demos/gtk-demo/meson.build
+++ b/demos/gtk-demo/meson.build
@@ -28,7 +28,6 @@ demos = files([
'fishbowl.c',
'foreigndrawing.c',
'gestures.c',
- 'glarea.c',
'headerbar.c',
'hypertext.c',
'iconview.c',
@@ -87,6 +86,10 @@ elif harfbuzz_dep.found() and pangoft_dep.found()
gtkdemo_deps += [harfbuzz_dep, pangoft_dep]
endif
+if opengl_enabled
+ demos += files('glarea.c')
+endif
+
if os_unix
demos += files('pagesetup.c')
endif
diff --git a/docs/tools/meson.build b/docs/tools/meson.build
index 05621ee7ed..3d0a333b32 100644
--- a/docs/tools/meson.build
+++ b/docs/tools/meson.build
@@ -2,10 +2,13 @@ if x11_enabled
doc_shooter_sources = [
'shadow.c',
'shooter.c',
- 'widgets.c',
- '../../tests/gtkgears.c',
+ 'widgets.c'
]
+ if opengl_enabled
+ doc_shooter_sources += ['../../tests/gtkgears.c']
+ endif
+
doc_shooter = executable('doc-shooter', doc_shooter_sources,
include_directories: [ confinc, gdkinc, gtkinc, testinc, ],
dependencies: libgtk_dep)
diff --git a/docs/tools/widgets.c b/docs/tools/widgets.c
index 932daf1746..348807e133 100644
--- a/docs/tools/widgets.c
+++ b/docs/tools/widgets.c
@@ -8,7 +8,9 @@
#include <X11/Xatom.h>
#include <gdkx.h>
#include "widgets.h"
+#ifdef HAVE_OPENGL
#include "gtkgears.h"
+#endif
#define SMALL_WIDTH 240
#define SMALL_HEIGHT 75
@@ -1526,9 +1528,11 @@ create_gl_area (void)
widget = gtk_frame_new (NULL);
gtk_frame_set_shadow_type (GTK_FRAME (widget), GTK_SHADOW_IN);
+#ifdef HAVE_OPENGL
gears = gtk_gears_new ();
gtk_container_add (GTK_CONTAINER (widget), gears);
-
+#endif
+
info = new_widget_info ("glarea", widget, MEDIUM);
return info;
diff --git a/gdk/gdkconfig.h.meson b/gdk/gdkconfig.h.meson
index 7db19e0470..088651bafa 100644
--- a/gdk/gdkconfig.h.meson
+++ b/gdk/gdkconfig.h.meson
@@ -15,6 +15,7 @@ G_BEGIN_DECLS
#mesondefine GDK_WINDOWING_WAYLAND
#mesondefine GDK_WINDOWING_WIN32
#mesondefine GDK_WINDOWING_QUARTZ
+#mesondefine GDK_WITH_OPENGL
G_END_DECLS
diff --git a/gdk/gdkdisplay.c b/gdk/gdkdisplay.c
index 748f54860c..04ef2c09d4 100644
--- a/gdk/gdkdisplay.c
+++ b/gdk/gdkdisplay.c
@@ -2420,7 +2420,11 @@ gboolean
gdk_display_make_gl_context_current (GdkDisplay *display,
GdkGLContext *context)
{
+#ifdef HAVE_OPENGL
return GDK_DISPLAY_GET_CLASS (display)->make_gl_context_current (display, context);
+#else
+ return FALSE;
+#endif
}
GdkRenderingMode
diff --git a/gdk/gdkgl.c b/gdk/gdkgl.c
index 9690077cc2..55f85ef605 100644
--- a/gdk/gdkgl.c
+++ b/gdk/gdkgl.c
@@ -26,7 +26,9 @@
# include "win32/gdkwin32.h"
#endif
+#ifdef HAVE_OPENGL
#include <epoxy/gl.h>
+#endif
#include <math.h>
#include <string.h>
@@ -40,6 +42,7 @@ gdk_cairo_surface_mark_as_direct (cairo_surface_t *surface,
g_object_ref (window), g_object_unref);
}
+#ifdef HAVE_OPENGL
static const char *
get_vertex_type_name (int type)
{
@@ -212,6 +215,7 @@ use_texture_rect_program (GdkGLContextPaintData *paint_data)
glUseProgram (paint_data->current_program->program);
}
}
+#endif
void
gdk_gl_texture_quads (GdkGLContext *paint_context,
@@ -220,6 +224,7 @@ gdk_gl_texture_quads (GdkGLContext *paint_context,
GdkTexturedQuad *quads,
gboolean flip_colors)
{
+#ifdef HAVE_OPENGL
GdkGLContextPaintData *paint_data = gdk_gl_context_get_paint_data (paint_context);
GdkGLContextProgram *program;
GdkWindow *window = gdk_gl_context_get_window (paint_context);
@@ -293,6 +298,7 @@ gdk_gl_texture_quads (GdkGLContext *paint_context,
glDisableVertexAttribArray (program->position_location);
glDisableVertexAttribArray (program->uv_location);
+#endif
}
/* x,y,width,height describes a rectangle in the gl render buffer
@@ -341,6 +347,7 @@ gdk_cairo_draw_from_gl (cairo_t *cr,
int width,
int height)
{
+#ifdef HAVE_OPENGL
GdkGLContext *paint_context;
cairo_surface_t *image;
cairo_matrix_t matrix;
@@ -718,6 +725,7 @@ out:
if (clip_region)
cairo_region_destroy (clip_region);
+#endif
}
/* This is always called with the paint context current */
@@ -725,6 +733,7 @@ void
gdk_gl_texture_from_surface (cairo_surface_t *surface,
cairo_region_t *region)
{
+#ifdef HAVE_OPENGL
GdkGLContext *paint_context;
cairo_surface_t *image;
double device_x_offset, device_y_offset;
@@ -825,4 +834,5 @@ gdk_gl_texture_from_surface (cairo_surface_t *surface,
glDisable (GL_SCISSOR_TEST);
glDeleteTextures (1, &texture_id);
+#endif
}
diff --git a/gdk/gdkglcontext.c b/gdk/gdkglcontext.c
index 3b23639e1c..1f04f8e0b2 100644
--- a/gdk/gdkglcontext.c
+++ b/gdk/gdkglcontext.c
@@ -85,7 +85,9 @@
#include "gdkintl.h"
#include "gdk-private.h"
+#ifdef HAVE_OPENGL
#include <epoxy/gl.h>
+#endif
typedef struct {
GdkDisplay *display;
@@ -243,6 +245,7 @@ gdk_gl_context_upload_texture (GdkGLContext *context,
int height,
guint texture_target)
{
+#ifdef HAVE_OPENGL
GdkGLContextPrivate *priv = gdk_gl_context_get_instance_private (context);
g_return_if_fail (GDK_IS_GL_CONTEXT (context));
@@ -286,6 +289,7 @@ gdk_gl_context_upload_texture (GdkGLContext *context,
glTexSubImage2D (texture_target, 0, 0, i, width, 1, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, (unsigned char*) data + (i * stride));
}
}
+#endif
}
static gboolean
@@ -774,6 +778,7 @@ gdk_gl_context_realize (GdkGLContext *context,
static void
gdk_gl_context_check_extensions (GdkGLContext *context)
{
+#ifdef HAVE_OPENGL
GdkGLContextPrivate *priv = gdk_gl_context_get_instance_private (context);
gboolean has_npot, has_texture_rectangle;
@@ -853,6 +858,7 @@ gdk_gl_context_check_extensions (GdkGLContext *context)
priv->use_texture_rectangle ? "yes" : "no"));
priv->extensions_checked = TRUE;
+#endif
}
/**
diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c
index 727b0cf1f4..d4d91b0d16 100644
--- a/gdk/gdkwindow.c
+++ b/gdk/gdkwindow.c
@@ -45,7 +45,9 @@
#include <math.h>
+#ifdef HAVE_OPENGL
#include <epoxy/gl.h>
+#endif
/* for the use of round() */
#include "fallback-c89.c"
@@ -2844,6 +2846,13 @@ gdk_window_get_paint_gl_context (GdkWindow *window,
{
GError *internal_error = NULL;
+#ifndef HAVE_OPENGL
+ g_set_error_literal (error, GDK_GL_ERROR,
+ GDK_GL_ERROR_NOT_AVAILABLE,
+ _("GL support disabled with --disable-opengl"));
+ return NULL;
+#endif
+
if (_gdk_gl_flags & GDK_GL_DISABLE)
{
g_set_error_literal (error, GDK_GL_ERROR,
@@ -2979,6 +2988,7 @@ gdk_window_begin_paint_internal (GdkWindow *window,
}
else
{
+#ifdef HAVE_OPENGL
gdk_gl_context_make_current (context);
/* With gl we always need a surface to combine the gl
drawing with the native drawing. */
@@ -2993,6 +3003,7 @@ gdk_window_begin_paint_internal (GdkWindow *window,
glBlendFunc (GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
glViewport (0, 0, ww, wh);
+#endif
}
}
@@ -3056,6 +3067,7 @@ gdk_window_end_paint_internal (GdkWindow *window)
gdk_gl_context_make_current (window->gl_paint_context);
+#ifdef HAVE_OPENGL
if (!cairo_region_is_empty (opaque_region))
gdk_gl_texture_from_surface (window->current_paint.surface,
opaque_region);
@@ -3066,6 +3078,7 @@ gdk_window_end_paint_internal (GdkWindow *window)
window->current_paint.need_blend_region);
glDisable(GL_BLEND);
}
+#endif
cairo_region_destroy (opaque_region);
diff --git a/gdk/meson.build b/gdk/meson.build
index 4bb1bf2b6c..64172b8d3e 100644
--- a/gdk/meson.build
+++ b/gdk/meson.build
@@ -56,7 +56,6 @@ gdk_gir_public_headers = files(
'gdkdrawingcontext.h',
'gdkevents.h',
'gdkframetimings.h',
- 'gdkglcontext.h',
'gdkkeys.h',
'gdkkeysyms.h',
'gdkmain.h',
@@ -78,6 +77,12 @@ gdk_gir_public_headers = files(
'gdkwindow.h',
)
gdk_nogir_public_headers = [files('gdkkeysyms-compat.h')]
+if opengl_enabled
+gdk_gir_public_headers += files('gdkglcontext.h')
+else
+gdk_nogir_public_headers += files('gdkglcontext.h')
+endif
+
gdk_public_headers = gdk_gir_public_headers + gdk_nogir_public_headers
install_headers(gdk_public_headers, subdir : 'gtk-3.0/gdk')
@@ -166,6 +171,7 @@ gdkconfig_cdata.set('GDK_WINDOWING_WAYLAND', wayland_enabled)
gdkconfig_cdata.set('GDK_WINDOWING_WIN32', win32_enabled)
gdkconfig_cdata.set('GDK_WINDOWING_BROADWAY', broadway_enabled)
gdkconfig_cdata.set('GDK_WINDOWING_QUARTZ', quartz_enabled)
+gdkconfig_cdata.set('GDK_WITH_OPENGL', opengl_enabled)
gdkconfig = configure_file(
input : 'gdkconfig.h.meson',
diff --git a/gdk/x11/gdkdisplay-x11.c b/gdk/x11/gdkdisplay-x11.c
index 7e08f472cc..30fd7b6089 100644
--- a/gdk/x11/gdkdisplay-x11.c
+++ b/gdk/x11/gdkdisplay-x11.c
@@ -37,7 +37,9 @@
#include "gdkdisplay-x11.h"
#include "gdkprivate-x11.h"
#include "gdkscreen-x11.h"
+#ifdef HAVE_OPENGL
#include "gdkglcontext-x11.h"
+#endif
#include "gdk-private.h"
#include "gdkprofilerprivate.h"
@@ -3191,7 +3193,9 @@ gdk_x11_display_class_init (GdkX11DisplayClass * class)
display_class->text_property_to_utf8_list = _gdk_x11_display_text_property_to_utf8_list;
display_class->utf8_to_string_target = _gdk_x11_display_utf8_to_string_target;
- display_class->make_gl_context_current = gdk_x11_display_make_gl_context_current;
+#ifdef HAVE_OPENGL
+ display_class->make_gl_context_current = gdk_x11_display_make_gl_context_current;
+#endif
display_class->get_default_seat = gdk_x11_display_get_default_seat;
diff --git a/gdk/x11/gdkvisual-x11.c b/gdk/x11/gdkvisual-x11.c
index 81479d81f4..3c8c5c02ff 100644
--- a/gdk/x11/gdkvisual-x11.c
+++ b/gdk/x11/gdkvisual-x11.c
@@ -306,7 +306,12 @@ _gdk_x11_screen_init_visuals (GdkScreen *screen)
/* If GL is available we want to pick better default/rgba visuals,
as we care about glx details such as alpha/depth/stencil depth,
stereo and double buffering */
+ /* update_visuals_for_gl() will end up calling epoxy GLX api which
+ will exit if libgl is not there: so only do this if we know GL
+ is available */
+#ifdef HAVE_GLX
_gdk_x11_screen_update_visuals_for_gl (screen);
+#endif
}
gint
diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
index 194bc82e29..0302bb68d4 100644
--- a/gdk/x11/gdkwindow-x11.c
+++ b/gdk/x11/gdkwindow-x11.c
@@ -36,7 +36,9 @@
#include "gdkasync.h"
#include "gdkeventsource.h"
#include "gdkdisplay-x11.h"
+#ifdef HAVE_OPENGL
#include "gdkglcontext-x11.h"
+#endif
#include "gdkprivate-x11.h"
#include "gdk-private.h"
@@ -5888,7 +5890,9 @@ gdk_window_impl_x11_class_init (GdkWindowImplX11Class *klass)
impl_class->set_opaque_region = gdk_x11_window_set_opaque_region;
impl_class->set_shadow_width = gdk_x11_window_set_shadow_width;
impl_class->show_window_menu = gdk_x11_window_show_window_menu;
+#ifdef HAVE_OPENGL
impl_class->create_gl_context = gdk_x11_window_create_gl_context;
impl_class->invalidate_for_new_frame = gdk_x11_window_invalidate_for_new_frame;
+#endif
impl_class->get_unscaled_size = gdk_x11_window_get_unscaled_size;
}
diff --git a/gdk/x11/gdkx-autocleanups.h b/gdk/x11/gdkx-autocleanups.h
index edb0ea7dbf..a317d61cca 100644
--- a/gdk/x11/gdkx-autocleanups.h
+++ b/gdk/x11/gdkx-autocleanups.h
@@ -30,7 +30,9 @@ G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11DeviceXI2, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11Display, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11DisplayManager, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11DragContext, g_object_unref)
+#ifdef HAVE_OPENGL
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11GLContext, g_object_unref)
+#endif
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11Keymap, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11Screen, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GdkX11Visual, g_object_unref)
diff --git a/gdk/x11/gdkx.h b/gdk/x11/gdkx.h
index 1f64bccb6d..4db6c18351 100644
--- a/gdk/x11/gdkx.h
+++ b/gdk/x11/gdkx.h
@@ -43,7 +43,9 @@
#include <gdk/x11/gdkx11display.h>
#include <gdk/x11/gdkx11displaymanager.h>
#include <gdk/x11/gdkx11dnd.h>
+#ifdef GDK_WITH_OPENGL
#include <gdk/x11/gdkx11glcontext.h>
+#endif
#include <gdk/x11/gdkx11keys.h>
#include <gdk/x11/gdkx11monitor.h>
#include <gdk/x11/gdkx11property.h>
diff --git a/gdk/x11/meson.build b/gdk/x11/meson.build
index 754ae0a615..0318c83877 100644
--- a/gdk/x11/meson.build
+++ b/gdk/x11/meson.build
@@ -14,7 +14,6 @@ gdk_x11_sources = files(
'gdkeventsource.c',
'gdkeventtranslator.c',
'gdkgeometry-x11.c',
- 'gdkglcontext-x11.c',
'gdkkeys-x11.c',
'gdkmain-x11.c',
'gdkproperty-x11.c',
@@ -42,7 +41,6 @@ gdk_x11_public_headers = files(
'gdkx11display.h',
'gdkx11displaymanager.h',
'gdkx11dnd.h',
- 'gdkx11glcontext.h',
'gdkx11keys.h',
'gdkx11monitor.h',
'gdkx11property.h',
@@ -53,6 +51,11 @@ gdk_x11_public_headers = files(
'gdkx11window.h',
)
+if opengl_enabled
+ gdk_x11_sources += files('gdkglcontext-x11.c')
+ gdk_x11_public_headers += files('gdkx11glcontext.h')
+endif
+
install_headers(gdk_x11_public_headers, subdir: 'gtk-3.0/gdk/x11/')
install_headers('gdkx.h', subdir: 'gtk-3.0/gdk/')
diff --git a/gtk/gtkglarea.c b/gtk/gtkglarea.c
index 802303ea9f..6439d7745d 100644
--- a/gtk/gtkglarea.c
+++ b/gtk/gtkglarea.c
@@ -29,7 +29,9 @@
#include "gtkprivate.h"
#include "gtkrender.h"
+#ifdef HAVE_OPENGL
#include <epoxy/gl.h>
+#endif
/**
* SECTION:gtkglarea
@@ -369,9 +371,12 @@ gtk_gl_area_real_create_context (GtkGLArea *area)
static void
gtk_gl_area_resize (GtkGLArea *area, int width, int height)
{
+#ifdef HAVE_OPENGL
glViewport (0, 0, width, height);
+#endif
}
+#ifdef HAVE_OPENGL
/*
* Creates all the buffer objects needed for rendering the scene
*/
@@ -483,6 +488,7 @@ gtk_gl_area_allocate_buffers (GtkGLArea *area)
priv->needs_render = TRUE;
}
+#endif
/**
* gtk_gl_area_attach_buffers:
@@ -501,6 +507,7 @@ gtk_gl_area_allocate_buffers (GtkGLArea *area)
void
gtk_gl_area_attach_buffers (GtkGLArea *area)
{
+#ifdef HAVE_OPENGL
GtkGLAreaPrivate *priv = gtk_gl_area_get_instance_private (area);
g_return_if_fail (GTK_IS_GL_AREA (area));
@@ -533,11 +540,13 @@ gtk_gl_area_attach_buffers (GtkGLArea *area)
glFramebufferRenderbuffer (GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT,
GL_RENDERBUFFER, priv->depth_stencil_buffer);
}
+#endif
}
static void
gtk_gl_area_delete_buffers (GtkGLArea *area)
{
+#ifdef HAVE_OPENGL
GtkGLAreaPrivate *priv = gtk_gl_area_get_instance_private (area);
if (priv->context == NULL)
@@ -569,6 +578,7 @@ gtk_gl_area_delete_buffers (GtkGLArea *area)
glDeleteFramebuffers (1, &priv->frame_buffer);
priv->frame_buffer = 0;
}
+#endif
}
static void
@@ -679,6 +689,7 @@ gtk_gl_area_draw (GtkWidget *widget,
GtkGLArea *area = GTK_GL_AREA (widget);
GtkGLAreaPrivate *priv = gtk_gl_area_get_instance_private (area);
gboolean unused;
+#ifdef HAVE_OPENGL
int w, h, scale;
GLenum status;
@@ -736,6 +747,14 @@ gtk_gl_area_draw (GtkWidget *widget,
}
return TRUE;
+#else
+ if (priv->error != NULL)
+ gtk_gl_area_draw_error_screen (area,
+ cr,
+ gtk_widget_get_allocated_width (widget),
+ gtk_widget_get_allocated_height (widget));
+ return FALSE;
+#endif
}
static gboolean
diff --git a/gtk/inspector/general.c b/gtk/inspector/general.c
index 4fd0c3039c..a8e59ed077 100644
--- a/gtk/inspector/general.c
+++ b/gtk/inspector/general.c
@@ -33,8 +33,10 @@
#ifdef GDK_WINDOWING_X11
#include "x11/gdkx.h"
+#ifdef HAVE_OPENGL
#include <epoxy/glx.h>
#endif
+#endif
#ifdef GDK_WINDOWING_WIN32
#include "win32/gdkwin32.h"
@@ -217,6 +219,7 @@ add_label_row (GtkInspectorGeneral *gen,
gtk_size_group_add_widget (GTK_SIZE_GROUP (gen->priv->labels), label);
}
+#ifdef HAVE_OPENGL
#ifdef GDK_WINDOWING_X11
static void
append_glx_extension_row (GtkInspectorGeneral *gen,
@@ -226,6 +229,7 @@ append_glx_extension_row (GtkInspectorGeneral *gen,
add_check_row (gen, GTK_LIST_BOX (gen->priv->gl_box), ext, epoxy_has_glx_extension (dpy, 0, ext), 0);
}
#endif
+#endif
#ifdef GDK_WINDOWING_WAYLAND
static void
@@ -275,6 +279,7 @@ wayland_get_display (struct wl_display *wl_display)
static void
init_gl (GtkInspectorGeneral *gen)
{
+#ifdef HAVE_OPENGL
#ifdef GDK_WINDOWING_X11
if (GDK_IS_X11_DISPLAY (gdk_display_get_default ()))
{
@@ -301,6 +306,7 @@ init_gl (GtkInspectorGeneral *gen)
}
else
#endif
+#endif
#ifdef GDK_WINDOWING_WAYLAND
if (GDK_IS_WAYLAND_DISPLAY (gdk_display_get_default ()))
{
diff --git a/meson.build b/meson.build
index aed48fc3f6..bfc33af0f6 100644
--- a/meson.build
+++ b/meson.build
@@ -137,6 +137,7 @@ wayland_enabled = get_option('wayland_backend')
broadway_enabled = get_option('broadway_backend')
quartz_enabled = get_option('quartz_backend')
win32_enabled = get_option('win32_backend')
+opengl_enabled = get_option('opengl')
os_unix = false
os_linux = false
@@ -430,7 +431,7 @@ pangocairo_dep = dependency('pangocairo', version: cairo_req,
fallback : ['pango', 'libpangocairo_dep'])
pixbuf_dep = dependency('gdk-pixbuf-2.0', version: gdk_pixbuf_req,
fallback : ['gdk-pixbuf', 'gdkpixbuf_dep'])
-epoxy_dep = dependency('epoxy', version: epoxy_req,
+epoxy_dep = dependency('epoxy', version: epoxy_req, required: opengl_enabled,
fallback: ['libepoxy', 'libepoxy_dep'])
atk_dep = dependency('atk', version: atk_req,
fallback : ['atk', 'libatk_dep'])
@@ -476,6 +477,10 @@ if tracker3_enabled
endif
endif
+if opengl_enabled
+ cdata.set('HAVE_OPENGL', 1)
+endif
+
if iso_codes_dep.found()
cdata.set_quoted('ISO_CODES_PREFIX', iso_codes_dep.get_variable(pkgconfig: 'prefix'))
else
@@ -912,9 +917,15 @@ else
gio_packages = ['gio-2.0', glib_req]
endif
+if opengl_enabled
+ epoxy_packages = ['epoxy', epoxy_req]
+else
+ epoxy_packages = []
+endif
+
pkgconf.set('GDK_PRIVATE_PACKAGES',
' '.join(gio_packages + x11_pkgs + wayland_pkgs + cairo_backends +
- ['epoxy', epoxy_req] + cloudproviders_packages +
+ epoxy_packages + cloudproviders_packages +
['fribidi', fribidi_req]))
gtk_packages = ' '.join([
@@ -928,7 +939,7 @@ pkgconf.set('GTK_PACKAGES', gtk_packages)
# Requires.private
pc_gdk_extra_libs += cairo_libs
-gtk_private_packages = atk_pkgs + wayland_pkgs + ['epoxy', epoxy_req, 'fribidi', fribidi_req]
+gtk_private_packages = atk_pkgs + wayland_pkgs + epoxy_packages + ['fribidi', fribidi_req]
if wayland_enabled or x11_enabled
gtk_private_packages += ['pangoft2']
endif
diff --git a/meson_options.txt b/meson_options.txt
index 94099aa01e..8bd096896d 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -19,6 +19,8 @@ option('profiler', type: 'boolean', value: false,
description : 'Enable profiler support')
option('tracker3', type: 'boolean', value: false,
description : 'Enable Tracker3 filechooser search')
+option('opengl', type: 'boolean', value: true,
+ description : 'Enable use of GL')
# Print backends
option('print_backends', type : 'string', value : 'auto',
diff --git a/tests/meson.build b/tests/meson.build
index 586fe2f45e..6ecf317dde 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -5,7 +5,6 @@ gtk_tests = [
['scrolling-performance', ['frame-stats.c', 'variable.c']],
['blur-performance', ['../gtk/gtkcairoblur.c']],
['flicker'],
- ['gdkgears', ['gtkgears.c']],
['listmodel'],
['motion-compression'],
['styleexamples'],
@@ -54,7 +53,6 @@ gtk_tests = [
['testfullscreen'],
['testgeometry'],
['testgiconpixbuf'],
- ['testglblending', ['gtkgears.c']],
['testgmenu'],
['testgrid'],
['testgrouping'],
@@ -137,6 +135,13 @@ if x11_enabled
]
endif
+if opengl_enabled
+ gtk_tests += [
+ ['gdkgears', ['gtkgears.c']],
+ ['testglblending', ['gtkgears.c']],
+ ]
+endif
+
if os_linux
gtk_tests += [['testfontchooserdialog']]
endif
diff --git a/testsuite/gtk/objects-finalize.c b/testsuite/gtk/objects-finalize.c
index 24540e313f..e0f863ab6a 100644
--- a/testsuite/gtk/objects-finalize.c
+++ b/testsuite/gtk/objects-finalize.c
@@ -116,7 +116,9 @@ main (int argc, char **argv)
all_types[i] != GDK_TYPE_X11_DEVICE_MANAGER_CORE &&
all_types[i] != GDK_TYPE_X11_DEVICE_MANAGER_XI2 &&
all_types[i] != GDK_TYPE_X11_DISPLAY_MANAGER &&
+#ifdef HAVE_OPENGL
all_types[i] != GDK_TYPE_X11_GL_CONTEXT &&
+#endif
#endif
/* Not allowed to finalize a GdkPixbufLoader without calling gdk_pixbuf_loader_close() */
all_types[i] != GDK_TYPE_PIXBUF_LOADER &&
--
2.30.2

View File

@ -0,0 +1,15 @@
require gtk+3.inc
MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk+/${MAJ_VER}/gtk+-${PV}.tar.xz \
file://opengl.patch \
"
SRC_URI[sha256sum] = "ce11decf018b25bdd8505544a4f87242854ec88be054d9ade5f3a20444dd8ee7"
S = "${WORKDIR}/gtk+-${PV}"
LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
file://gtk/gtk.h;endline=25;md5=1d8dc0fccdbfa26287a271dce88af737 \
file://gdk/gdk.h;endline=25;md5=c920ce39dc88c6f06d3e7c50e08086f2 \
file://tests/testgtk.c;endline=25;md5=cb732daee1d82af7a2bf953cf3cf26f1"

View File

@ -6,25 +6,29 @@ BUGTRACKER = "https://bugzilla.gnome.org/"
SECTION = "libs"
DEPENDS = " \
sassc-native \
glib-2.0 \
libepoxy \
graphene \
cairo \
pango \
atk \
cairo \
fribidi \
gdk-pixbuf \
gdk-pixbuf-native \
gi-docgen \
glib-2.0 \
graphene \
harfbuzz \
jpeg \
libepoxy \
libpng \
librsvg \
libxkbcommon \
pango \
tiff \
gdk-pixbuf-native gdk-pixbuf \
"
LICENSE = "LGPL-2.0-only & LGPL-2.0-or-later & LGPL-2.1-or-later"
LIC_FILES_CHKSUM = " \
file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
file://gtk/gtk.h;endline=25;md5=1d8dc0fccdbfa26287a271dce88af737 \
file://gdk/gdk.h;endline=25;md5=c920ce39dc88c6f06d3e7c50e08086f2 \
file://gtk/gtk.h;endline=25;md5=61900d77e8d5bc67cf15ad93de9a3490 \
file://gdk/gdk.h;endline=25;md5=a0fb26c1f6b94e66d148279e192c333f \
file://tests/testgtk.c;endline=25;md5=49d06770681b8322466b52ed19d29fb2 \
"
@ -33,11 +37,11 @@ MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
UPSTREAM_CHECK_REGEX = "gtk-(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)\.tar.xz"
SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk/${MAJ_VER}/gtk-${PV}.tar.xz"
SRC_URI[sha256sum] = "effd2e7c4b5e2a5c7fad43e0f24adea68baa4092abb0b752caff278e6bb010e8"
SRC_URI[sha256sum] = "b8b61d6cf94fac64bf3a0bfc7af137c9dd2f8360033fdeb0cfe9612b77a99a72"
S = "${WORKDIR}/gtk-${PV}"
inherit meson gettext pkgconfig gtk-doc update-alternatives gsettings features_check gobject-introspection
inherit meson gettext pkgconfig gi-docgen update-alternatives gsettings features_check gobject-introspection
# TBD: nativesdk
# gobject-introspection.bbclass pins introspection off for nativesk. As long as
@ -49,53 +53,36 @@ GSETTINGS_PACKAGE:class-native = ""
ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
REQUIRED_DISTRO_FEATURES = "opengl"
GTKDOC_MESON_OPTION = "documentation"
GIR_MESON_ENABLE_FLAG = 'enabled'
GIR_MESON_DISABLE_FLAG = 'disabled'
GTKDOC_MESON_OPTION = 'gtk_doc'
EXTRA_OEMESON = " -Dbuild-tests=false"
EXTRA_OEMESON = " -Dbuild-tests=false -Dbuild-testsuite=false -Dbuild-demos=false"
PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11', d)}"
PACKAGECONFIG ??= "gstreamer ${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11 vulkan', d)}"
PACKAGECONFIG:class-native = "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
PACKAGECONFIG:class-nativesdk = "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
PACKAGECONFIG[x11] = "-Dx11-backend=true,-Dx11-backend=false,at-spi2-atk fontconfig libx11 libxext libxcursor libxi libxdamage libxrandr libxrender libxcomposite libxfixes xinerama"
PACKAGECONFIG[wayland] = "-Dwayland-backend=true,-Dwayland-backend=false,wayland wayland-protocols libxkbcommon virtual/egl virtual/libgles2 wayland-native"
PACKAGECONFIG[cups] = "-Dprint-cups=enabled,-Dprint-cups=disabled,cups"
PACKAGECONFIG[wayland] = "-Dwayland-backend=true,-Dwayland-backend=false,wayland wayland-protocols virtual/egl virtual/libgles2 wayland-native"
PACKAGECONFIG[cloudproviders] = "-Dcloudproviders=enabled,-Dcloudproviders=disabled,libcloudproviders"
PACKAGECONFIG[cups] = "-Dprint-cups=enabled,-Dprint-cups=disabled,cups,cups"
PACKAGECONFIG[colord] = "-Dcolord=enabled,-Dcolord=disabled,colord"
PACKAGECONFIG[iso-codes] = ",,iso-codes,iso-codes"
PACKAGECONFIG[ffmpeg] = "-Dmedia-ffmpeg=enabled,-Dmedia-ffmpeg=disabled,ffmpeg"
# gtk4 wants gstreamer-player-1.0 -> gstreamer1.0-plugins-bad
PACKAGECONFIG[gstreamer] = "-Dmedia-gstreamer=enabled,-Dmedia-gstreamer=disabled,gstreamer1.0-plugins-bad"
PACKAGECONFIG[tracker] = "-Dtracker=enabled,-Dtracker=disabled,tracker"
PACKAGECONFIG[tracker] = "-Dtracker=enabled,-Dtracker=disabled,tracker,tracker-miners"
PACKAGECONFIG[vulkan] = "-Dvulkan=enabled,-Dvulkan=disabled, vulkan-loader vulkan-headers shaderc-native"
do_compile:prepend() {
export GIR_EXTRA_LIBS_PATH="${B}/gdk/.libs"
}
PACKAGES =+ "${PN}-demo"
LIBV = "4.0.0"
FILES:${PN}-demo = " \
${datadir}/applications/org.gtk.Demo4.desktop \
${datadir}/applications/org.gtk.IconBrowser4.desktop \
${datadir}/applications/org.gtk.WidgetFactory4.desktop \
${datadir}/icons/hicolor/*/apps/org.gtk.Demo4*.* \
${datadir}/icons/hicolor/*/apps/org.gtk.IconBrowser4*.* \
${datadir}/icons/hicolor/*/apps/org.gtk.WidgetFactory4*.* \
${bindir}/gtk4-demo \
${bindir}/gtk4-demo-application \
${bindir}/gtk4-icon-browser \
${bindir}/gtk4-widget-factory \
"
FILES:${PN}:append = " \
${datadir}/glib-2.0/schemas/ \
${datadir}/gtk-4.0/emoji/ \
${datadir}/metainfo/ \
${datadir}/icons/hicolor/*/apps/org.gtk.PrintEditor4*.* \
${libdir}/gtk-4.0/${LIBV}/printbackends \
${libdir}/gtk-4.0/${LIBV}/media \
${bindir}/gtk4-update-icon-cache \
${bindir}/gtk4-launch \
"
@ -132,7 +119,7 @@ PACKAGES_DYNAMIC += "^gtk4-printbackend-.*"
python populate_packages:prepend () {
import os.path
gtk_libdir = d.expand('${libdir}/gtk-3.0/${LIBV}')
gtk_libdir = d.expand('${libdir}/gtk-4.0/${LIBV}')
printmodules_root = os.path.join(gtk_libdir, 'printbackends');
do_split_packages(d, printmodules_root, r'^libprintbackend-(.*)\.so$', 'gtk4-printbackend-%s', 'GTK printbackend module for %s')

View File

@ -0,0 +1,28 @@
From 0c82d6aa02c08e41b13c83b14782bd7024e25d59 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sat, 15 Feb 2014 21:06:42 +0000
Subject: [PATCH] Disable LDFLAGSICUDT for Linux
Upstream-Status: Inappropriate [ OE Configuration ]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
source/config/mh-linux | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/config/mh-linux b/config/mh-linux
index 366f0cc..2689aab 100644
--- a/config/mh-linux
+++ b/config/mh-linux
@@ -21,7 +21,7 @@ LD_RPATH= -Wl,-zorigin,-rpath,'$$'ORIGIN
LD_RPATH_PRE = -Wl,-rpath,
## These are the library specific LDFLAGS
-LDFLAGSICUDT=-nodefaultlibs -nostdlib
+# LDFLAGSICUDT=-nodefaultlibs -nostdlib
## Compiler switch to embed a library name
# The initial tab in the next line is to prevent icu-config from reading it.
--
1.7.10.4

View File

@ -0,0 +1,28 @@
From e3c25af4b40d64f098e7b8ae5a91fdc3c90163c4 Mon Sep 17 00:00:00 2001
From: Lei Maohui <leimaohui@cn.fujitsu.com>
Date: Wed, 8 May 2019 14:42:30 +0900
Subject: [PATCH] icu: Added armeb support.
Make icu support arm32 BE.
Upstream-Status: Pending
Signed-off-by: Lei Maohui <leimaohui@cn.fujitsu.com>
---
i18n/double-conversion-utils.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/source/i18n/double-conversion-utils.h b/source/i18n/double-conversion-utils.h
index 7f23e0a..7f89094 100644
--- a/i18n/double-conversion-utils.h
+++ b/i18n/double-conversion-utils.h
@@ -115,7 +115,7 @@ int main(int argc, char** argv) {
//
// If it prints "correct" then the architecture should be here, in the "correct" section.
#if defined(_M_X64) || defined(__x86_64__) || \
- defined(__ARMEL__) || defined(__avr32__) || defined(_M_ARM) || defined(_M_ARM64) || \
+ defined(__arm__) || defined(__avr32__) || defined(_M_ARM) || defined(_M_ARM64) || \
defined(__hppa__) || defined(__ia64__) || \
defined(__mips__) || \
defined(__loongarch__) || \

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,54 @@
From a6ddabc8cadb76bfe2d2e374a6702442cfe51cce Mon Sep 17 00:00:00 2001
From: Ross Burton <ross.burton@intel.com>
Date: Fri, 9 Oct 2015 17:50:41 +0100
Subject: [PATCH] icu: fix install race
The generic recursive target calls target-local so also adding it to the
dependency list results in races due to install-local being executed twice in
parallel. For example, install-manx can fail if the two install processes race
and one process tries to chown a file that the other process has just deleted.
Also install-manx should be a phony target, and for clarity use $^ instead of $?
in the install command.
Upstream-Status: Pending
Signed-off-by: Ross Burton <ross.burton@intel.com>
---
source/Makefile.in | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Makefile.in b/Makefile.in
index be9435b..ada20d7 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -77,7 +77,7 @@ EXTRA_DATA =
## List of phony targets
.PHONY : all all-local all-recursive install install-local install-udata install-udata-files install-udata-dlls \
-install-recursive clean clean-local clean-recursive distclean \
+install-recursive install-manx clean clean-local clean-recursive distclean \
distclean-local distclean-recursive doc dist dist-local dist-recursive \
check check-local check-recursive clean-recursive-with-twist install-icu \
doc install-doc tests icu4j-data icu4j-data-install update-windows-makefiles xcheck-local xcheck-recursive xperf xcheck xperf-recursive \
@@ -88,9 +88,9 @@ check-exhaustive check-exhaustive-local check-exhaustive-recursive releaseDist
## List of standard targets
all: all-local all-recursive
-install: install-recursive install-local
+install: install-recursive
clean: clean-recursive-with-twist clean-local
-distclean : distclean-recursive distclean-local
+distclean : distclean-recursive
dist: dist-recursive
check: all check-recursive
check-recursive: all
@@ -357,7 +357,7 @@ config.status: $(srcdir)/configure $(srcdir)/common/unicode/uvernum.h
install-manx: $(MANX_FILES)
$(MKINSTALLDIRS) $(DESTDIR)$(mandir)/man$(SECTION)
ifneq ($(MANX_FILES),)
- $(INSTALL_DATA) $? $(DESTDIR)$(mandir)/man$(SECTION)
+ $(INSTALL_DATA) $^ $(DESTDIR)$(mandir)/man$(SECTION)
endif
config/%.$(SECTION): $(srcdir)/config/%.$(SECTION).in

View File

@ -0,0 +1,149 @@
SUMMARY = "International Component for Unicode libraries"
DESCRIPTION = "The International Component for Unicode (ICU) is a mature, \
portable set of C/C++ and Java libraries for Unicode support, software \
internationalization (I18N) and globalization (G11N), giving applications the \
same results on all platforms."
HOMEPAGE = "http://site.icu-project.org/"
LICENSE = "ICU"
DEPENDS = "icu-native autoconf-archive-native"
CVE_PRODUCT = "international_components_for_unicode"
S = "${WORKDIR}/icu/source"
SPDX_S = "${WORKDIR}/icu"
STAGING_ICU_DIR_NATIVE = "${STAGING_DATADIR_NATIVE}/${BPN}/${PV}"
ICU_MAJOR_VER = "${@d.getVar('PV').split('-')[0]}"
inherit autotools pkgconfig github-releases
# ICU needs the native build directory as an argument to its --with-cross-build option when
# cross-compiling. Taken the situation that different builds may share a common sstate-cache
# into consideration, the native build directory needs to be staged.
EXTRA_OECONF = "--with-cross-build=${STAGING_ICU_DIR_NATIVE} --disable-icu-config"
EXTRA_OECONF:class-native = "--disable-icu-config"
EXTRA_OECONF:class-nativesdk = "--with-cross-build=${STAGING_ICU_DIR_NATIVE} --disable-icu-config"
EXTRA_OECONF:append:class-target = "${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'be', ' --with-data-packaging=archive', '', d)}"
TARGET_CXXFLAGS:append = "${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'be', ' -DICU_DATA_DIR=\\""${datadir}/${BPN}/${PV}\\""', '', d)}"
ASNEEDED = ""
do_compile:prepend:class-target () {
# Make sure certain build host references do not end up being compiled
# in the image. This only affects libicutu and icu-dbg
sed \
-e 's,DU_BUILD=,DU_BUILD_unused=,g' \
-e '/^CPPFLAGS.*/ s,--sysroot=${STAGING_DIR_TARGET},,g' \
-i ${B}/tools/toolutil/Makefile
}
PREPROCESS_RELOCATE_DIRS = "${datadir}/${BPN}/${PV}"
do_install:append:class-native() {
mkdir -p ${D}/${STAGING_ICU_DIR_NATIVE}/config
cp -r ${B}/config/icucross.mk ${D}/${STAGING_ICU_DIR_NATIVE}/config
cp -r ${B}/config/icucross.inc ${D}/${STAGING_ICU_DIR_NATIVE}/config
cp -r ${B}/lib ${D}/${STAGING_ICU_DIR_NATIVE}
cp -r ${B}/bin ${D}/${STAGING_ICU_DIR_NATIVE}
cp -r ${B}/tools ${D}/${STAGING_ICU_DIR_NATIVE}
}
do_install:append:class-target() {
# The native pkgdata can not generate the correct data file.
# Use icupkg to re-generate it.
if [ "${SITEINFO_ENDIANNESS}" = "be" ] ; then
rm -f ${D}/${datadir}/${BPN}/${@icu_install_folder(d)}/icudt${ICU_MAJOR_VER}b.dat
icupkg -tb ${S}/data/in/icudt${ICU_MAJOR_VER}l.dat ${D}/${datadir}/${BPN}/${@icu_install_folder(d)}/icudt${ICU_MAJOR_VER}b.dat
fi
# Remove build host references...
sed -i \
-e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
-e 's|${DEBUG_PREFIX_MAP}||g' \
-e 's:${HOSTTOOLS_DIR}/::g' \
${D}/${libdir}/${BPN}/${@icu_install_folder(d)}/Makefile.inc \
${D}/${libdir}/${BPN}/${@icu_install_folder(d)}/pkgdata.inc
}
PACKAGES =+ "libicudata libicuuc libicui18n libicutu libicuio"
FILES:${PN}-dev += "${libdir}/${BPN}/"
FILES:libicudata = "${libdir}/libicudata.so.*"
FILES:libicuuc = "${libdir}/libicuuc.so.*"
FILES:libicui18n = "${libdir}/libicui18n.so.*"
FILES:libicutu = "${libdir}/libicutu.so.*"
FILES:libicuio = "${libdir}/libicuio.so.*"
BBCLASSEXTEND = "native nativesdk"
LIC_FILES_CHKSUM = "file://../LICENSE;md5=80c2cf39ad8ae12b9b9482a1737c6650"
def icu_download_version(d):
pvsplit = d.getVar('PV').split('-')
return pvsplit[0] + "_" + pvsplit[1]
def icu_download_folder(d):
pvsplit = d.getVar('PV').split('-')
return pvsplit[0] + "-" + pvsplit[1]
def icu_install_folder(d):
pvsplit = d.getVar('PV').split('-')
return pvsplit[0] + "." + pvsplit[1]
ICU_PV = "${@icu_download_version(d)}"
ICU_FOLDER = "${@icu_download_folder(d)}"
# http://errors.yoctoproject.org/Errors/Details/20486/
ARM_INSTRUCTION_SET:armv4 = "arm"
ARM_INSTRUCTION_SET:armv5 = "arm"
BASE_SRC_URI = "${GITHUB_BASE_URI}/download/release-${ICU_FOLDER}/icu4c-${ICU_PV}-src.tgz"
DATA_SRC_URI = "${GITHUB_BASE_URI}/download/release-${ICU_FOLDER}/icu4c-${ICU_PV}-data.zip"
SRC_URI = "${BASE_SRC_URI};name=code \
${DATA_SRC_URI};name=data \
file://filter.json \
file://fix-install-manx.patch \
file://0001-icu-Added-armeb-support.patch \
"
SRC_URI:append:class-target = "\
file://0001-Disable-LDFLAGSICUDT-for-Linux.patch \
"
SRC_URI[code.sha256sum] = "818a80712ed3caacd9b652305e01afc7fa167e6f2e94996da44b90c2ab604ce1"
SRC_URI[data.sha256sum] = "ca1ee076163b438461e484421a7679fc33a64cd0a54f9d4b401893fa1eb42701"
UPSTREAM_CHECK_REGEX = "releases/tag/release-(?P<pver>(?!.+rc).+)"
GITHUB_BASE_URI = "https://github.com/unicode-org/icu/releases"
EXTRA_OECONF:append:libc-musl = " ac_cv_func_strtod_l=no"
PACKAGECONFIG ?= ""
PACKAGECONFIG[make-icudata] = ",,,"
do_make_icudata:class-target () {
${@bb.utils.contains('PACKAGECONFIG', 'make-icudata', '', 'exit 0', d)}
cd ${S}
rm -rf data
cp -a ${WORKDIR}/data .
AR='${BUILD_AR}' \
CC='${BUILD_CC}' \
CPP='${BUILD_CPP}' \
CXX='${BUILD_CXX}' \
RANLIB='${BUILD_RANLIB}' \
CFLAGS='${BUILD_CFLAGS}' \
CPPFLAGS='${BUILD_CPPFLAGS}' \
CXXFLAGS='${BUILD_CXXFLAGS}' \
LDFLAGS='${BUILD_LDFLAGS}' \
ICU_DATA_FILTER_FILE=${WORKDIR}/filter.json \
./runConfigureICU Linux --with-data-packaging=archive
oe_runmake
install -Dm644 ${S}/data/out/icudt${ICU_MAJOR_VER}l.dat ${S}/data/in/icudt${ICU_MAJOR_VER}l.dat
}
do_make_icudata() {
:
}
addtask make_icudata before do_configure after do_patch do_prepare_recipe_sysroot

View File

@ -0,0 +1,25 @@
SUMMARY = "libei is a library for Emulated Input, primarily aimed at the Wayland stack."
HOMEPAGE = "https://gitlab.freedesktop.org/libinput/libei"
SECTION = "graphics"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://COPYING;md5=a98fa76460f96f41696611d6f07e8d49"
DEPENDS = " \
libxkbcommon \
libevdev \
libxslt-native \
python3-attrs-native \
python3-jinja2-native \
${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', 'basu', d)} \
"
SRC_URI = "git://gitlab.freedesktop.org/libinput/libei.git;protocol=https;branch=main"
S = "${WORKDIR}/git"
SRCREV = "82cdbc9129a0e2c255fcee6bcaa7abed5578ae14"
inherit meson pkgconfig
EXTRA_OEMESON = "-Dtests=disabled"

View File

@ -7,10 +7,10 @@ DEPENDS = "glib-2.0 gtk+3 gtk4 networkmanager"
GNOMEBASEBUILDCLASS = "meson"
inherit gnomebase gobject-introspection gtk-doc gettext vala features_check
REQUIRED_DISTRO_FEATURES = "${@bb.utils.contains('PACKAGECONFIG','gcr','x11','',d)}"
REQUIRED_DISTRO_FEATURES = "${@bb.utils.contains('PACKAGECONFIG','gcr','x11','',d)} opengl"
ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
SRC_URI[archive.sha256sum] = "5ed93eae18456ff5a8a4f408178c1ee198dc8d3a46c65f9075b101916e64e8b4"
SRC_URI[archive.sha256sum] = "53a6fb2b190ad37c5986caed3e98bede7c3c602399ee4f93c8fc054303d76dab"
PACKAGECONFIG ?= "gcr iso_codes mobile_broadband_provider_info"
PACKAGECONFIG[gcr] = "-Dgcr=true,-Dgcr=false,gcr"

View File

@ -0,0 +1,35 @@
From dc208bafc57c1ccaa0ca260f99c8b4c976271ebc Mon Sep 17 00:00:00 2001
From: Markus Volk <f_l_k@t-online.de>
Date: Sat, 16 Sep 2023 14:02:57 +0200
Subject: [PATCH] xb-self-test.c: hardcode G_TEST_SRCDIR
This avoids:
libxmlb-0.3.14-r0 do_package_qa: QA Issue: File
/usr/libexec/installed-tests/libxmlb/xb-self-test in package libxmlb-ptest
contains reference to TMPDIR [buildpaths]
and also fixes the runtime for the ptest.
Upstream-Status: Inappropriate [oe-specific]
Signed-off-by: Markus Volk <f_l_k@t-online.de>
---
src/xb-self-test.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/xb-self-test.c b/src/xb-self-test.c
index 47d9728..8b3dd0e 100644
--- a/src/xb-self-test.c
+++ b/src/xb-self-test.c
@@ -2870,7 +2870,7 @@ xb_speed_func(void)
int
main(int argc, char **argv)
{
- g_setenv("G_TEST_SRCDIR", SRCDIR, FALSE);
+ g_setenv("G_TEST_SRCDIR", "/usr/libexec/installed-tests/libxmlb", FALSE);
g_test_init(&argc, &argv, NULL);
--
2.41.0

View File

@ -0,0 +1,3 @@
#! /bin/sh
gnome-desktop-testing-runner libxmlb

View File

@ -0,0 +1,25 @@
SUMMARY = "A library to help create and query binary XML blobs"
HOMEPAGE = "https://github.com/hughsie/libxmlb"
LICENSE = "LGPL-2.1-only"
LIC_FILES_CHKSUM = "file://LICENSE;md5=1803fa9c2c3ce8cb06b4861d75310742"
SRC_URI = " \
git://github.com/hughsie/libxmlb.git;branch=main;protocol=https \
file://0001-xb-selftest.c-hardcode-G_TEST_SRCDIR.patch \
file://run-ptest \
"
SRCREV = "aa577b276adc66564f5777f9a522ca3bf0bfa65e"
S = "${WORKDIR}/git"
DEPENDS = "glib-2.0 xz zstd"
inherit gobject-introspection gtk-doc meson ptest-gnome lib_package pkgconfig
PACKAGECONFIG ??= "${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)}"
PACKAGECONFIG[tests] = "-Dtests=true,-Dtests=false"
GTKDOC_MESON_OPTION = "gtkdoc"
FILES:${PN} += "${datadir}"
BBCLASSEXTEND = "native"

View File

@ -1,4 +1,4 @@
From 69ed1f6a4b0199a8c546d7cf4e96b40c13c53e91 Mon Sep 17 00:00:00 2001
From c860dcbe63b0e393c95bfb0131238f91aaac11d3 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex@linutronix.de>
Date: Thu, 7 Oct 2021 12:44:18 +0200
Subject: [PATCH] build: do not use autoconf's config.sub to 'canonicalize'

View File

@ -1,17 +1,22 @@
From bc8a4a04aec1c52ffd28b17ef593f61ef2d84e0d Mon Sep 17 00:00:00 2001
From: Bruce Leidl <bruce@subgraph.com>
Date: Thu, 22 Sep 2022 19:57:38 -0400
Subject: [PATCH] moz.configure do not look for llvm-dump
From 0133ddb86eb6e0741e02b0032c41468db6438530 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex@linutronix.de>
Date: Fri, 1 Oct 2021 13:01:10 +0200
Subject: [PATCH] moz.configure: do not look for llvm-objdump
This avoid dragging in a dependency that isn't even needed
for js builds.
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
moz.configure | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/moz.configure b/moz.configure
index 8b74afbabe..d43afbaf2b 100755
index fc66b520d0..15de9a2ee0 100755
--- a/moz.configure
+++ b/moz.configure
@@ -785,15 +785,15 @@ def llvm_tool(name):
@@ -785,15 +785,15 @@
return llvm_tool
@ -36,3 +41,4 @@ index 8b74afbabe..d43afbaf2b 100755
@depends(llvm_tool("llvm-readelf"), toolchain_prefix)

View File

@ -1,4 +1,4 @@
From c6e7e983a82b86c08a52bfd11056c1d7e12a3405 Mon Sep 17 00:00:00 2001
From bb46a8a729cc4d66ad36db40c17e36a5111f19c3 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex@linutronix.de>
Date: Fri, 1 Oct 2021 13:00:24 +0200
Subject: [PATCH] Cargo.toml: do not abort on panic

View File

@ -0,0 +1,25 @@
Backport patch from firefox bugzilla to fix compile error for qemuarm with
some armv7ve tunes such as 'armv7vethf' and 'armv7vet-vfpv3d16':
| /path/to/build/tmp/work/armv7vet2hf-vfp-poky-linux-gnueabi/mozjs-102/102.5.0-r0/build/js/src/jit/AtomicOperationsGenerated.h:240:17:
error: 'asm' operand has impossible constraints
| 240 | asm volatile (
| | ^~~
Upstream-Status: Submitted [https://bugzilla.mozilla.org/show_bug.cgi?id=1761665]
Signed-off-by: Kai Kang <kai.kang@windriver.com>
diff --git a/js/src/jit/GenerateAtomicOperations.py b/js/src/jit/GenerateAtomicOperations.py
index d8a38a0..65f91ab 100644
--- a/js/src/jit/GenerateAtomicOperations.py
+++ b/js/src/jit/GenerateAtomicOperations.py
@@ -856,7 +856,7 @@ def generate_atomics_header(c_out):
# Work around a GCC issue on 32-bit x86 by adding MOZ_NEVER_INLINE.
# See bug 1756347.
- if is_gcc and cpu_arch == "x86":
+ if is_gcc and cpu_arch in ("x86", "arm"):
contents = contents.replace("INLINE_ATTR", "MOZ_NEVER_INLINE inline")
else:
contents = contents.replace("INLINE_ATTR", "inline")

Some files were not shown because too many files have changed in this diff Show More