From 8bb03a0582ba8c487620690761087d2c58a1425d Mon Sep 17 00:00:00 2001 From: Bruce Leidl Date: Wed, 6 Oct 2021 15:27:34 -0400 Subject: [PATCH] GNOME 41, Yocto 3.3.3, and linux 5.14.9 yocto yocto-3.3 -> yocto-3.3.3 kernel 5.12.4 -> 5.14.9 cryptsetup 2.3.5 -> 2.3.6 libblockdev 2.25 -> 2.26 libbytesize 1.4 -> 2.6 nano 5.6 -> 5.8 udisks2 2.9.2 -> 2.9.3 iwd 1.13 -> 1.17 modemmanager 1.8.2 -> 1.16.8 networkmanager 1.30.2 -> 1.32.10 libgusb 0.2.11 -> 0.3.7 upower 0.99.11 -> 0.99.13 gdm 40.0 -> 41.0 gjs 1.68.0 -> 1.70.0 glib 2.68.0 -> 2.70.0 gnome-backgrounds 40.0 -> 41.0 gnome-control-center 40.0 -> 41.0 gnome-desktop 40.0 -> 41.0 gnome-disk-utility 40.1 -> 41.0 gnome-system-monitor 40.1 -> 41.0 gnome-settings-daemon 40.0.1 -> 41.0 gnome-shell 40.0 -> 41.0 mutter 40.0 -> 41.0 gsettings-desktop-schemas 40.0 -> 41.0 gtk4 4.1.12 -> 4.4.0 gvfs 1.46.1 -> 1.48.1 gnome-terminal 3.40.1 -> 3.41.1 ell 0.39 -> 0.44 mozjs 78.0.1 -> 78.11.0 vte 0.64.0 -> 0.64.2 --- .../bbappends/util-linux_%.bbappend | 1 + .../recipes-citadel/images/citadel-image.inc | 2 +- ...nel_5.12.4.bb => citadel-kernel_5.14.9.bb} | 2 +- .../citadel-kernel/files/defconfig | 233 +- ...ryptsetup_2.3.5.bb => cryptsetup_2.3.6.bb} | 35 +- ...ibblockdev_2.25.bb => libblockdev_2.26.bb} | 4 +- ...{libbytesize_1.4.bb => libbytesize_2.6.bb} | 17 +- .../nano/{nano_5.6.bb => nano_5.8.bb} | 3 +- .../{udisks2_2.9.2.bb => udisks2_2.9.3.bb} | 4 +- ...p_srcdir-instead-of-abs_srcdir-for-e.patch | 20 +- .../iwd/{iwd_1.13.bb => iwd_1.17.bb} | 2 +- ...anager_1.8.2.bb => modemmanager_1.16.8.bb} | 19 +- ...ttings-settings-property-documentati.patch | 33 +- ...Fix-build-with-musl-systemd-specific.patch | 154 - ...Fix-build-with-musl-systemd-specific.patch | 26 - ...er_1.30.2.bb => networkmanager_1.32.10.bb} | 11 +- ...n-cd_icc_create_from_edid-to-avoid-u.patch | 11 +- .../recipes-freedesktop/colord/colord.bb | 5 +- .../recipes-freedesktop/colord/colord.inc | 1 - .../libgusb/libgusb_0.2.11.bb | 14 - .../libgusb/libgusb_0.3.7.bb | 11 + .../recipes-freedesktop/plymouth/plymouth.bb | 2 +- .../{upower_0.99.11.bb => upower_0.99.13.bb} | 19 +- .../gdm/{gdm_40.0.bb => gdm_41.0.bb} | 2 +- .../gjs/0001-Fix-tests-that-cannot-run.patch | 25 +- .../0001-Fix-tests-that-cannot-run.patch.bak | 50 + .../gjs/{gjs_1.68.0.bb => gjs_1.70.0.bb} | 8 +- ...{glib-2.0_2.68.0.bb => glib-2.0_2.70.0.bb} | 3 +- meta-gnome/recipes-gnome/glib-2.0/glib.inc | 7 +- ...unds_40.0.bb => gnome-backgrounds_41.0.bb} | 2 +- ...s-for-Citadel-and-disabling-GOA-CUPS.patch | 209 +- ...-Citadel-and-disabling-GOA-CUPS.patch.blah | 293 ++ ...r_40.0.bb => gnome-control-center_41.0.bb} | 2 +- ...-desktop_40.0.bb => gnome-desktop_41.0.bb} | 2 +- ...ity_40.1.bb => gnome-disk-utility_41.0.bb} | 2 +- ...0.0.1.bb => gnome-settings-daemon_41.0.bb} | 4 +- ...001-Citadel-Gnome-Shell-changes.patch.old} | 0 ...ed-calendar-events-from-user-session.patch | 14 +- ...alendar-events-from-user-session.patch.old | 22 + .../0002-Citadel-Gnome-Shell-changes.patch | 3352 +++++++++++++++++ ...nome-shell_40.0.bb => gnome-shell_41.0.bb} | 12 +- ...r_40.1.bb => gnome-system-monitor_41.0.bb} | 2 +- ...nal_3.40.1.bb => gnome-terminal_3.41.0.bb} | 5 +- ...0.bb => gsettings-desktop-schemas_41.0.bb} | 2 +- meta-gnome/recipes-gnome/gtk4/gtk4.inc | 3 +- .../gtk4/{gtk4_4.1.2.bb => gtk4_4.4.0.bb} | 2 +- .../gvfs/{gvfs_1.46.1.bb => gvfs_1.48.1.bb} | 3 +- .../0001-Citadel-changes-to-Mutter.patch | 76 +- .../0001-Citadel-changes-to-Mutter.patch.old | 1300 +++++++ .../mutter/{mutter_40.0.bb => mutter_41.0.bb} | 4 +- .../ell/{ell_0.39.bb => ell_0.44.bb} | 2 +- .../recipes-support/libgudev/libgudev_237.bb | 26 + .../libxfixes/libxfixes_6.0.0.bb | 20 + .../libxfixes/xorg-lib-common.inc | 26 + .../libxfixes/xorgproto_2021.4.99.2.bb | 25 + .../{mozjs78_78.0.1.bb => mozjs78_78.11.0.bb} | 11 +- .../vte/{vte_0.64.0.bb => vte_0.64.2.bb} | 2 +- .../wayland/libinput/determinism.patch | 21 + .../wayland/libinput/run-ptest | 9 + .../wayland/libinput_1.19.1.bb | 49 + .../wayland/wayland-protocols_1.21.bb | 21 + poky | 2 +- 62 files changed, 5606 insertions(+), 643 deletions(-) create mode 100644 meta-citadel/recipes-citadel/bbappends/util-linux_%.bbappend rename meta-citadel/recipes-kernel/citadel-kernel/{citadel-kernel_5.12.4.bb => citadel-kernel_5.14.9.bb} (93%) rename meta-citadel/recipes-support/cryptsetup/{cryptsetup_2.3.5.bb => cryptsetup_2.3.6.bb} (85%) rename meta-citadel/recipes-support/libblockdev/{libblockdev_2.25.bb => libblockdev_2.26.bb} (95%) rename meta-citadel/recipes-support/libbytesize/{libbytesize_1.4.bb => libbytesize_2.6.bb} (71%) rename meta-citadel/recipes-support/nano/{nano_5.6.bb => nano_5.8.bb} (81%) rename meta-citadel/recipes-support/udisks/{udisks2_2.9.2.bb => udisks2_2.9.3.bb} (90%) rename meta-gnome/recipes-connectivity/iwd/{iwd_1.13.bb => iwd_1.17.bb} (94%) rename meta-gnome/recipes-connectivity/modemmanager/{modemmanager_1.8.2.bb => modemmanager_1.16.8.bb} (73%) delete mode 100644 meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0001-Fix-build-with-musl-systemd-specific.patch delete mode 100644 meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0002-Fix-build-with-musl-systemd-specific.patch rename meta-gnome/recipes-connectivity/networkmanager/{networkmanager_1.30.2.bb => networkmanager_1.32.10.bb} (94%) delete mode 100644 meta-gnome/recipes-freedesktop/libgusb/libgusb_0.2.11.bb create mode 100644 meta-gnome/recipes-freedesktop/libgusb/libgusb_0.3.7.bb rename meta-gnome/recipes-freedesktop/upower/{upower_0.99.11.bb => upower_0.99.13.bb} (74%) rename meta-gnome/recipes-gnome/gdm/{gdm_40.0.bb => gdm_41.0.bb} (94%) create mode 100644 meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch.bak rename meta-gnome/recipes-gnome/gjs/{gjs_1.68.0.bb => gjs_1.70.0.bb} (71%) rename meta-gnome/recipes-gnome/glib-2.0/{glib-2.0_2.68.0.bb => glib-2.0_2.70.0.bb} (93%) rename meta-gnome/recipes-gnome/gnome-backgrounds/{gnome-backgrounds_40.0.bb => gnome-backgrounds_41.0.bb} (83%) create mode 100644 meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch.blah rename meta-gnome/recipes-gnome/gnome-control-center/{gnome-control-center_40.0.bb => gnome-control-center_41.0.bb} (95%) rename meta-gnome/recipes-gnome/gnome-desktop/{gnome-desktop_40.0.bb => gnome-desktop_41.0.bb} (92%) rename meta-gnome/recipes-gnome/gnome-disk-utility/{gnome-disk-utility_40.1.bb => gnome-disk-utility_41.0.bb} (91%) rename meta-gnome/recipes-gnome/gnome-settings-daemon/{gnome-settings-daemon_40.0.1.bb => gnome-settings-daemon_41.0.bb} (90%) rename meta-gnome/recipes-gnome/gnome-shell/gnome-shell/{0001-Citadel-Gnome-Shell-changes.patch => 0001-Citadel-Gnome-Shell-changes.patch.old} (100%) create mode 100644 meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch.old create mode 100644 meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0002-Citadel-Gnome-Shell-changes.patch rename meta-gnome/recipes-gnome/gnome-shell/{gnome-shell_40.0.bb => gnome-shell_41.0.bb} (87%) rename meta-gnome/recipes-gnome/gnome-system-monitor/{gnome-system-monitor_40.1.bb => gnome-system-monitor_41.0.bb} (89%) rename meta-gnome/recipes-gnome/gnome-terminal/{gnome-terminal_3.40.1.bb => gnome-terminal_3.41.0.bb} (76%) rename meta-gnome/recipes-gnome/gsettings-desktop-schema/{gsettings-desktop-schemas_40.0.bb => gsettings-desktop-schemas_41.0.bb} (86%) rename meta-gnome/recipes-gnome/gtk4/{gtk4_4.1.2.bb => gtk4_4.4.0.bb} (85%) rename meta-gnome/recipes-gnome/gvfs/{gvfs_1.46.1.bb => gvfs_1.48.1.bb} (93%) create mode 100644 meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch.old rename meta-gnome/recipes-gnome/mutter/{mutter_40.0.bb => mutter_41.0.bb} (95%) rename meta-gnome/recipes-support/ell/{ell_0.39.bb => ell_0.44.bb} (90%) create mode 100644 meta-gnome/recipes-support/libgudev/libgudev_237.bb create mode 100644 meta-gnome/recipes-support/libxfixes/libxfixes_6.0.0.bb create mode 100644 meta-gnome/recipes-support/libxfixes/xorg-lib-common.inc create mode 100644 meta-gnome/recipes-support/libxfixes/xorgproto_2021.4.99.2.bb rename meta-gnome/recipes-support/mozjs78/{mozjs78_78.0.1.bb => mozjs78_78.11.0.bb} (91%) rename meta-gnome/recipes-support/vte/{vte_0.64.0.bb => vte_0.64.2.bb} (97%) create mode 100644 meta-gnome/recipes-support/wayland/libinput/determinism.patch create mode 100644 meta-gnome/recipes-support/wayland/libinput/run-ptest create mode 100644 meta-gnome/recipes-support/wayland/libinput_1.19.1.bb create mode 100644 meta-gnome/recipes-support/wayland/wayland-protocols_1.21.bb diff --git a/meta-citadel/recipes-citadel/bbappends/util-linux_%.bbappend b/meta-citadel/recipes-citadel/bbappends/util-linux_%.bbappend new file mode 100644 index 0000000..4e0a973 --- /dev/null +++ b/meta-citadel/recipes-citadel/bbappends/util-linux_%.bbappend @@ -0,0 +1 @@ +EXTRA_OECONF_append = " --disable-raw" diff --git a/meta-citadel/recipes-citadel/images/citadel-image.inc b/meta-citadel/recipes-citadel/images/citadel-image.inc index 1ee14d0..2c13255 100644 --- a/meta-citadel/recipes-citadel/images/citadel-image.inc +++ b/meta-citadel/recipes-citadel/images/citadel-image.inc @@ -5,7 +5,7 @@ CITADEL_IMAGE_VERSION_rootfs = "1" CITADEL_IMAGE_VERSION_extra = "1" CITADEL_IMAGE_VERSION_kernel = "1" -CITADEL_KERNEL_VERSION = "5.12.4" +CITADEL_KERNEL_VERSION = "5.14.9" CITADEL_KERNEL_CONFIG = "${COREBASE}/../meta-citadel/recipes-kernel/citadel-kernel/files/defconfig" diff --git a/meta-citadel/recipes-kernel/citadel-kernel/citadel-kernel_5.12.4.bb b/meta-citadel/recipes-kernel/citadel-kernel/citadel-kernel_5.14.9.bb similarity index 93% rename from meta-citadel/recipes-kernel/citadel-kernel/citadel-kernel_5.12.4.bb rename to meta-citadel/recipes-kernel/citadel-kernel/citadel-kernel_5.14.9.bb index 90f2b19..577fbe1 100644 --- a/meta-citadel/recipes-kernel/citadel-kernel/citadel-kernel_5.12.4.bb +++ b/meta-citadel/recipes-kernel/citadel-kernel/citadel-kernel_5.14.9.bb @@ -9,7 +9,7 @@ SRC_URI = "https://cdn.kernel.org/pub/linux/kernel/v5.x/linux-${PV}.tar.xz\ file://defconfig \ " -SRC_URI[sha256sum] = "5a60feee8492732a6aa8c46b9412563959945b4d7b0d27223f15ede2f84b6873" +SRC_URI[sha256sum] = "ba8f07db92d514a2636e882bcd646f79f1c8ab83f5ad82910732dd0ec83c87e6" LINUX_VERSION ?= "${PV}" S = "${WORKDIR}/linux-${LINUX_VERSION}" diff --git a/meta-citadel/recipes-kernel/citadel-kernel/files/defconfig b/meta-citadel/recipes-kernel/citadel-kernel/files/defconfig index ca688c6..59c01ff 100644 --- a/meta-citadel/recipes-kernel/citadel-kernel/files/defconfig +++ b/meta-citadel/recipes-kernel/citadel-kernel/files/defconfig @@ -1,18 +1,21 @@ # # Automatically generated file; DO NOT EDIT. -# Linux/x86 5.12.4 Kernel Configuration +# Linux/x86 5.14.9 Kernel Configuration # CONFIG_CC_VERSION_TEXT="gcc (Debian 10.2.1-6) 10.2.1 20210110" CONFIG_CC_IS_GCC=y CONFIG_GCC_VERSION=100201 CONFIG_CLANG_VERSION=0 +CONFIG_AS_IS_GNU=y +CONFIG_AS_VERSION=23700 CONFIG_LD_IS_BFD=y -CONFIG_LD_VERSION=23502 +CONFIG_LD_VERSION=23700 CONFIG_LLD_VERSION=0 CONFIG_CC_CAN_LINK=y CONFIG_CC_CAN_LINK_STATIC=y CONFIG_CC_HAS_ASM_GOTO=y CONFIG_CC_HAS_ASM_INLINE=y +CONFIG_CC_HAS_NO_PROFILE_FN_ATTR=y CONFIG_IRQ_WORK=y CONFIG_BUILDTIME_TABLE_SORT=y CONFIG_THREAD_INFO_IN_TASK=y @@ -98,12 +101,27 @@ CONFIG_NO_HZ=y CONFIG_HIGH_RES_TIMERS=y # end of Timers subsystem +CONFIG_BPF=y +CONFIG_HAVE_EBPF_JIT=y +CONFIG_ARCH_WANT_DEFAULT_BPF_JIT=y + +# +# BPF subsystem +# +CONFIG_BPF_SYSCALL=y +# CONFIG_BPF_JIT is not set +CONFIG_BPF_UNPRIV_DEFAULT_OFF=y +CONFIG_USERMODE_DRIVER=y +# CONFIG_BPF_PRELOAD is not set +# end of BPF subsystem + # CONFIG_PREEMPT_NONE is not set # CONFIG_PREEMPT_VOLUNTARY is not set CONFIG_PREEMPT=y CONFIG_PREEMPT_COUNT=y CONFIG_PREEMPTION=y CONFIG_PREEMPT_DYNAMIC=y +# CONFIG_SCHED_CORE is not set # # CPU/Task time and stats accounting @@ -183,6 +201,7 @@ CONFIG_CGROUP_DEVICE=y CONFIG_CGROUP_CPUACCT=y CONFIG_CGROUP_PERF=y CONFIG_CGROUP_BPF=y +CONFIG_CGROUP_MISC=y # CONFIG_CGROUP_DEBUG is not set CONFIG_SOCK_CGROUP_DATA=y CONFIG_NAMESPACES=y @@ -212,7 +231,6 @@ CONFIG_LD_ORPHAN_WARN=y CONFIG_SYSCTL=y CONFIG_SYSCTL_EXCEPTION_TRACE=y CONFIG_HAVE_PCSPKR_PLATFORM=y -CONFIG_BPF=y CONFIG_EXPERT=y CONFIG_MULTIUSER=y CONFIG_SGETMASK_SYSCALL=y @@ -240,10 +258,6 @@ CONFIG_KALLSYMS=y CONFIG_KALLSYMS_ALL=y CONFIG_KALLSYMS_ABSOLUTE_PERCPU=y CONFIG_KALLSYMS_BASE_RELATIVE=y -CONFIG_BPF_SYSCALL=y -CONFIG_ARCH_WANT_DEFAULT_BPF_JIT=y -CONFIG_USERMODE_DRIVER=y -# CONFIG_BPF_PRELOAD is not set # CONFIG_USERFAULTFD is not set CONFIG_ARCH_HAS_MEMBARRIER_SYNC_CORE=y CONFIG_KCMP=y @@ -294,7 +308,6 @@ CONFIG_GENERIC_BUG_RELATIVE_POINTERS=y CONFIG_ARCH_MAY_HAVE_PC_FDC=y CONFIG_GENERIC_CALIBRATE_DELAY=y CONFIG_ARCH_HAS_CPU_RELAX=y -CONFIG_ARCH_HAS_CACHE_LINE_SIZE=y CONFIG_ARCH_HAS_FILTER_PGPROT=y CONFIG_HAVE_SETUP_PER_CPU_AREA=y CONFIG_NEED_PER_CPU_EMBED_FIRST_CHUNK=y @@ -302,7 +315,6 @@ CONFIG_NEED_PER_CPU_PAGE_FIRST_CHUNK=y CONFIG_ARCH_HIBERNATION_POSSIBLE=y CONFIG_ARCH_SUSPEND_POSSIBLE=y CONFIG_ARCH_WANT_GENERAL_HUGETLB=y -CONFIG_ZONE_DMA32=y CONFIG_AUDIT_ARCH=y CONFIG_HAVE_INTEL_TXT=y CONFIG_X86_64_SMP=y @@ -314,7 +326,6 @@ CONFIG_CC_HAS_SANE_STACKPROTECTOR=y # # Processor type and features # -CONFIG_ZONE_DMA=y CONFIG_SMP=y CONFIG_X86_FEATURE_NAMES=y CONFIG_X86_X2APIC=y @@ -421,7 +432,6 @@ CONFIG_ILLEGAL_POINTER_VALUE=0xdead000000000000 # CONFIG_X86_PMEM_LEGACY is not set CONFIG_X86_CHECK_BIOS_CORRUPTION=y # CONFIG_X86_BOOTPARAM_MEMORY_CORRUPTION_CHECK is not set -CONFIG_X86_RESERVE_LOW=64 CONFIG_MTRR=y CONFIG_MTRR_SANITIZER=y CONFIG_MTRR_SANITIZER_ENABLE_DEFAULT=1 @@ -468,11 +478,8 @@ CONFIG_HAVE_LIVEPATCH=y # end of Processor type and features CONFIG_ARCH_HAS_ADD_PAGES=y -CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y +CONFIG_ARCH_MHP_MEMMAP_ON_MEMORY_ENABLE=y CONFIG_USE_PERCPU_NUMA_NODE_ID=y -CONFIG_ARCH_ENABLE_SPLIT_PMD_PTLOCK=y -CONFIG_ARCH_ENABLE_HUGEPAGE_MIGRATION=y -CONFIG_ARCH_ENABLE_THP_MIGRATION=y # # Power management and ACPI options @@ -551,6 +558,7 @@ CONFIG_ACPI_APEI=y # CONFIG_ACPI_CONFIGFS is not set # CONFIG_PMIC_OPREGION is not set CONFIG_X86_PM_TIMER=y +CONFIG_ACPI_PRMT=y # # CPU Frequency scaling @@ -678,6 +686,7 @@ CONFIG_KVM_GENERIC_DIRTYLOG_READ_PROTECT=y CONFIG_HAVE_KVM_IRQ_BYPASS=y CONFIG_HAVE_KVM_NO_POLL=y CONFIG_KVM_XFER_TO_GUEST_WORK=y +CONFIG_HAVE_KVM_PM_NOTIFIER=y CONFIG_VIRTUALIZATION=y CONFIG_KVM=y CONFIG_KVM_WERROR=y @@ -720,6 +729,7 @@ CONFIG_ARCH_HAS_SET_MEMORY=y CONFIG_ARCH_HAS_SET_DIRECT_MAP=y CONFIG_HAVE_ARCH_THREAD_STRUCT_WHITELIST=y CONFIG_ARCH_WANTS_DYNAMIC_TASK_STRUCT=y +CONFIG_ARCH_WANTS_NO_INSTR=y CONFIG_HAVE_ASM_MODVERSIONS=y CONFIG_HAVE_REGS_AND_STACK_ACCESS_API=y CONFIG_HAVE_RSEQ=y @@ -776,6 +786,8 @@ CONFIG_HAVE_RELIABLE_STACKTRACE=y # CONFIG_COMPAT_32BIT_TIME is not set CONFIG_HAVE_ARCH_VMAP_STACK=y CONFIG_VMAP_STACK=y +CONFIG_HAVE_ARCH_RANDOMIZE_KSTACK_OFFSET=y +# CONFIG_RANDOMIZE_KSTACK_OFFSET_DEFAULT is not set CONFIG_ARCH_HAS_STRICT_KERNEL_RWX=y CONFIG_STRICT_KERNEL_RWX=y CONFIG_ARCH_HAS_STRICT_MODULE_RWX=y @@ -819,8 +831,12 @@ CONFIG_MODULE_SIG_SHA1=y # CONFIG_MODULE_SIG_SHA384 is not set # CONFIG_MODULE_SIG_SHA512 is not set CONFIG_MODULE_SIG_HASH="sha1" -# CONFIG_MODULE_COMPRESS is not set +CONFIG_MODULE_COMPRESS_NONE=y +# CONFIG_MODULE_COMPRESS_GZIP is not set +# CONFIG_MODULE_COMPRESS_XZ is not set +# CONFIG_MODULE_COMPRESS_ZSTD is not set # CONFIG_MODULE_ALLOW_MISSING_NAMESPACE_IMPORTS is not set +CONFIG_MODPROBE_PATH="/sbin/modprobe" # CONFIG_TRIM_UNUSED_KSYMS is not set CONFIG_MODULES_TREE_LOOKUP=y CONFIG_BLOCK=y @@ -907,20 +923,22 @@ CONFIG_COREDUMP=y CONFIG_SELECT_MEMORY_MODEL=y CONFIG_SPARSEMEM_MANUAL=y CONFIG_SPARSEMEM=y -CONFIG_NEED_MULTIPLE_NODES=y CONFIG_SPARSEMEM_EXTREME=y CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y CONFIG_SPARSEMEM_VMEMMAP=y CONFIG_HAVE_FAST_GUP=y +CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y # CONFIG_MEMORY_HOTPLUG is not set CONFIG_SPLIT_PTLOCK_CPUS=4 +CONFIG_ARCH_ENABLE_SPLIT_PMD_PTLOCK=y CONFIG_MEMORY_BALLOON=y # CONFIG_BALLOON_COMPACTION is not set CONFIG_COMPACTION=y CONFIG_PAGE_REPORTING=y CONFIG_MIGRATION=y +CONFIG_ARCH_ENABLE_HUGEPAGE_MIGRATION=y +CONFIG_ARCH_ENABLE_THP_MIGRATION=y CONFIG_PHYS_ADDR_T_64BIT=y -CONFIG_BOUNCE=y CONFIG_VIRT_TO_BUS=y CONFIG_MMU_NOTIFIER=y CONFIG_KSM=y @@ -956,7 +974,11 @@ CONFIG_ZSMALLOC=y CONFIG_GENERIC_EARLY_IOREMAP=y # CONFIG_DEFERRED_STRUCT_PAGE_INIT is not set # CONFIG_IDLE_PAGE_TRACKING is not set +CONFIG_ARCH_HAS_CACHE_LINE_SIZE=y CONFIG_ARCH_HAS_PTE_DEVMAP=y +CONFIG_ARCH_HAS_ZONE_DMA_SET=y +CONFIG_ZONE_DMA=y +CONFIG_ZONE_DMA32=y CONFIG_HMM_MIRROR=y CONFIG_VMAP_PFN=y # CONFIG_PERCPU_STATS is not set @@ -964,6 +986,7 @@ CONFIG_VMAP_PFN=y # CONFIG_READ_ONLY_THP_FOR_FS is not set CONFIG_ARCH_HAS_PTE_SPECIAL=y CONFIG_MAPPING_DIRTY_HELPERS=y +CONFIG_SECRETMEM=y # end of Memory Management options CONFIG_NET=y @@ -1044,13 +1067,13 @@ CONFIG_BRIDGE_NETFILTER=y CONFIG_NETFILTER_INGRESS=y CONFIG_NETFILTER_NETLINK=y CONFIG_NETFILTER_FAMILY_BRIDGE=y +# CONFIG_NETFILTER_NETLINK_HOOK is not set # CONFIG_NETFILTER_NETLINK_ACCT is not set CONFIG_NETFILTER_NETLINK_QUEUE=y CONFIG_NETFILTER_NETLINK_LOG=y # CONFIG_NETFILTER_NETLINK_OSF is not set CONFIG_NF_CONNTRACK=y -CONFIG_NF_LOG_COMMON=y -# CONFIG_NF_LOG_NETDEV is not set +CONFIG_NF_LOG_SYSLOG=y CONFIG_NF_CONNTRACK_MARK=y # CONFIG_NF_CONNTRACK_SECMARK is not set # CONFIG_NF_CONNTRACK_ZONES is not set @@ -1244,7 +1267,6 @@ CONFIG_IP_NF_SECURITY=y CONFIG_NF_DEFRAG_IPV6=y CONFIG_NF_TABLES_BRIDGE=y # CONFIG_NFT_BRIDGE_META is not set -CONFIG_NF_LOG_BRIDGE=y # CONFIG_NF_CONNTRACK_BRIDGE is not set CONFIG_BRIDGE_NF_EBTABLES=y CONFIG_BRIDGE_EBT_BROUTE=y @@ -1280,7 +1302,6 @@ CONFIG_BRIDGE=y # CONFIG_BRIDGE_IGMP_SNOOPING is not set # CONFIG_BRIDGE_MRP is not set # CONFIG_BRIDGE_CFM is not set -CONFIG_HAVE_NET_DSA=y # CONFIG_NET_DSA is not set # CONFIG_VLAN_8021Q is not set # CONFIG_DECNET is not set @@ -1310,6 +1331,7 @@ CONFIG_NET_SWITCHDEV=y # CONFIG_NET_L3_MASTER_DEV is not set # CONFIG_QRTR is not set # CONFIG_NET_NCSI is not set +CONFIG_PCPU_DEV_REFCNT=y CONFIG_RPS=y CONFIG_RFS_ACCEL=y CONFIG_SOCK_RX_QUEUE_MAPPING=y @@ -1318,7 +1340,6 @@ CONFIG_XPS=y CONFIG_CGROUP_NET_CLASSID=y CONFIG_NET_RX_BUSY_POLL=y CONFIG_BQL=y -# CONFIG_BPF_JIT is not set # CONFIG_BPF_STREAM_PARSER is not set CONFIG_NET_FLOW_LIMIT=y @@ -1342,6 +1363,7 @@ CONFIG_BT_HS=y CONFIG_BT_LE=y # CONFIG_BT_LEDS is not set # CONFIG_BT_MSFTEXT is not set +# CONFIG_BT_AOSPEXT is not set CONFIG_BT_DEBUGFS=y # CONFIG_BT_SELFTEST is not set # CONFIG_BT_FEATURE_DEBUG is not set @@ -1366,6 +1388,7 @@ CONFIG_BT_HCIBTUSB_RTL=y # CONFIG_BT_MRVL is not set # CONFIG_BT_ATH3K is not set CONFIG_BT_MTKSDIO=m +# CONFIG_BT_VIRTIO is not set # end of Bluetooth device drivers # CONFIG_AF_RXRPC is not set @@ -1416,11 +1439,12 @@ CONFIG_NET_9P_VIRTIO=m # CONFIG_LWTUNNEL is not set CONFIG_DST_CACHE=y CONFIG_GRO_CELLS=y +CONFIG_NET_SELFTESTS=y +CONFIG_NET_SOCK_MSG=y CONFIG_NET_DEVLINK=y CONFIG_PAGE_POOL=y CONFIG_FAILOVER=y CONFIG_ETHTOOL_NETLINK=y -CONFIG_HAVE_EBPF_JIT=y # # Device Drivers @@ -1575,7 +1599,6 @@ CONFIG_ZRAM_DEF_COMP_LZORLE=y CONFIG_ZRAM_DEF_COMP="lzo-rle" # CONFIG_ZRAM_WRITEBACK is not set # CONFIG_ZRAM_MEMORY_TRACKING is not set -# CONFIG_BLK_DEV_UMEM is not set CONFIG_BLK_DEV_LOOP=y CONFIG_BLK_DEV_LOOP_MIN_COUNT=4 # CONFIG_BLK_DEV_CRYPTOLOOP is not set @@ -1622,9 +1645,9 @@ CONFIG_BLK_DEV_NVME=y # CONFIG_DS1682 is not set # CONFIG_LATTICE_ECP3_CONFIG is not set # CONFIG_SRAM is not set +# CONFIG_DW_XDATA_PCIE is not set # CONFIG_PCI_ENDPOINT_TEST is not set # CONFIG_XILINX_SDFEC is not set -# CONFIG_PVPANIC is not set # CONFIG_C2PORT is not set # @@ -1665,11 +1688,9 @@ CONFIG_INTEL_MEI_HDCP=m # CONFIG_MISC_RTSX_USB is not set # CONFIG_HABANA_AI is not set # CONFIG_UACCE is not set +# CONFIG_PVPANIC is not set # end of Misc devices -CONFIG_HAVE_IDE=y -# CONFIG_IDE is not set - # # SCSI device support # @@ -1733,6 +1754,7 @@ CONFIG_SCSI_MPT3SAS=m CONFIG_SCSI_MPT2SAS_MAX_SGE=128 CONFIG_SCSI_MPT3SAS_MAX_SGE=128 # CONFIG_SCSI_MPT2SAS is not set +# CONFIG_SCSI_MPI3MR is not set # CONFIG_SCSI_SMARTPQI is not set # CONFIG_SCSI_UFSHCD is not set # CONFIG_SCSI_HPTIOP is not set @@ -1934,13 +1956,6 @@ CONFIG_VIRTIO_NET=y # CONFIG_NLMON is not set # CONFIG_VSOCKMON is not set # CONFIG_ARCNET is not set - -# -# Distributed Switch Architecture drivers -# -# CONFIG_NET_DSA_MV88E6XXX_PTP is not set -# end of Distributed Switch Architecture drivers - CONFIG_ETHERNET=y CONFIG_MDIO=m # CONFIG_NET_VENDOR_3COM is not set @@ -2020,6 +2035,7 @@ CONFIG_I40EVF=m # CONFIG_ICE is not set CONFIG_FM10K=m # CONFIG_IGC is not set +CONFIG_NET_VENDOR_MICROSOFT=y # CONFIG_JME is not set CONFIG_NET_VENDOR_MARVELL=y CONFIG_MVMDIO=m @@ -2040,6 +2056,7 @@ CONFIG_MLX5_EN_ARFS=y CONFIG_MLX5_EN_RXNFC=y CONFIG_MLX5_MPFS=y CONFIG_MLX5_ESWITCH=y +CONFIG_MLX5_BRIDGE=y # CONFIG_MLX5_CORE_IPOIB is not set CONFIG_MLX5_SW_STEERING=y # CONFIG_MLX5_SF is not set @@ -2111,7 +2128,7 @@ CONFIG_FIXED_PHY=y # CONFIG_AMD_PHY is not set # CONFIG_ADIN_PHY is not set # CONFIG_AQUANTIA_PHY is not set -# CONFIG_AX88796B_PHY is not set +CONFIG_AX88796B_PHY=m CONFIG_BROADCOM_PHY=m # CONFIG_BCM54140_PHY is not set CONFIG_BCM7XXX_PHY=m @@ -2127,11 +2144,15 @@ CONFIG_LXT_PHY=m # CONFIG_LSI_ET1011C_PHY is not set CONFIG_MARVELL_PHY=m # CONFIG_MARVELL_10G_PHY is not set +# CONFIG_MARVELL_88X2222_PHY is not set +# CONFIG_MEDIATEK_GE_PHY is not set CONFIG_MICREL_PHY=m CONFIG_MICROCHIP_PHY=m # CONFIG_MICROCHIP_T1_PHY is not set # CONFIG_MICROSEMI_PHY is not set +# CONFIG_MOTORCOMM_PHY is not set # CONFIG_NATIONAL_PHY is not set +# CONFIG_NXP_C45_TJA11XX_PHY is not set # CONFIG_NXP_TJA11XX_PHY is not set # CONFIG_QSEMI_PHY is not set CONFIG_REALTEK_PHY=m @@ -2150,6 +2171,8 @@ CONFIG_SMSC_PHY=m # CONFIG_MICREL_KS8995MA is not set CONFIG_MDIO_DEVICE=y CONFIG_MDIO_BUS=y +CONFIG_FWNODE_MDIO=y +CONFIG_ACPI_MDIO=y CONFIG_MDIO_DEVRES=y # CONFIG_MDIO_BITBANG is not set CONFIG_MDIO_BCM_UNIMAC=m @@ -2329,6 +2352,13 @@ CONFIG_WLAN_VENDOR_QUANTENNA=y CONFIG_USB_NET_RNDIS_WLAN=m # CONFIG_VIRT_WIFI is not set # CONFIG_WAN is not set + +# +# Wireless WAN +# +# CONFIG_WWAN is not set +# end of Wireless WAN + # CONFIG_VMXNET3 is not set # CONFIG_FUJITSU_ES is not set # CONFIG_NETDEVSIM is not set @@ -2415,7 +2445,6 @@ CONFIG_MOUSE_SYNAPTICS_USB=m # CONFIG_INPUT_JOYSTICK is not set # CONFIG_INPUT_TABLET is not set CONFIG_INPUT_TOUCHSCREEN=y -CONFIG_TOUCHSCREEN_PROPERTIES=y CONFIG_TOUCHSCREEN_ADS7846=m CONFIG_TOUCHSCREEN_AD7877=m CONFIG_TOUCHSCREEN_AD7879=m @@ -2444,7 +2473,9 @@ CONFIG_TOUCHSCREEN_EGALAX_SERIAL=m CONFIG_TOUCHSCREEN_FUJITSU=m CONFIG_TOUCHSCREEN_GOODIX=m # CONFIG_TOUCHSCREEN_HIDEEP is not set +# CONFIG_TOUCHSCREEN_HYCON_HY46XX is not set CONFIG_TOUCHSCREEN_ILI210X=m +# CONFIG_TOUCHSCREEN_ILITEK is not set # CONFIG_TOUCHSCREEN_S6SY761 is not set CONFIG_TOUCHSCREEN_GUNZE=m # CONFIG_TOUCHSCREEN_EKTF2127 is not set @@ -2456,6 +2487,7 @@ CONFIG_TOUCHSCREEN_WACOM_I2C=m CONFIG_TOUCHSCREEN_MCS5000=m CONFIG_TOUCHSCREEN_MMS114=m # CONFIG_TOUCHSCREEN_MELFAS_MIP4 is not set +# CONFIG_TOUCHSCREEN_MSG2638 is not set CONFIG_TOUCHSCREEN_MTOUCH=m CONFIG_TOUCHSCREEN_INEXIO=m CONFIG_TOUCHSCREEN_MK712=m @@ -2530,6 +2562,7 @@ CONFIG_INPUT_UINPUT=m # CONFIG_INPUT_ADXL34X is not set # CONFIG_INPUT_IMS_PCU is not set # CONFIG_INPUT_IQS269A is not set +# CONFIG_INPUT_IQS626A is not set # CONFIG_INPUT_CMA3000 is not set # CONFIG_INPUT_IDEAPAD_SLIDEBAR is not set # CONFIG_INPUT_DRV260X_HAPTICS is not set @@ -2633,7 +2666,6 @@ CONFIG_SERIAL_MCTRL_GPIO=y # CONFIG_N_GSM is not set # CONFIG_NOZOMI is not set # CONFIG_NULL_TTY is not set -# CONFIG_TRACE_SINK is not set CONFIG_HVC_DRIVER=y # CONFIG_SERIAL_DEV_BUS is not set # CONFIG_TTY_PRINTK is not set @@ -2659,9 +2691,7 @@ CONFIG_HW_RANDOM_VIRTIO=y # CONFIG_APPLICOM is not set # CONFIG_MWAVE is not set # CONFIG_DEVMEM is not set -# CONFIG_DEVKMEM is not set CONFIG_NVRAM=y -# CONFIG_RAW_DRIVER is not set CONFIG_DEVPORT=y CONFIG_HPET=y CONFIG_HPET_MMAP=y @@ -2685,6 +2715,7 @@ CONFIG_TCG_VTPM_PROXY=m # CONFIG_TCG_TIS_ST33ZP24_SPI is not set # CONFIG_TELCLOCK is not set # CONFIG_XILLYBUS is not set +# CONFIG_XILLYUSB is not set # end of Character devices # CONFIG_RANDOM_TRUST_CPU is not set @@ -2766,6 +2797,7 @@ CONFIG_I2C_DESIGNWARE_PCI=y # External I2C/SMBus adapter drivers # # CONFIG_I2C_DIOLAN_U2C is not set +# CONFIG_I2C_CP2615 is not set # CONFIG_I2C_ROBOTFUZZ_OSIF is not set # CONFIG_I2C_TAOS_EVM is not set # CONFIG_I2C_TINY_USB is not set @@ -2796,6 +2828,7 @@ CONFIG_SPI_MASTER=y # SPI Master Controller Drivers # CONFIG_SPI_ALTERA=m +CONFIG_SPI_ALTERA_CORE=m # CONFIG_SPI_AXI_SPI_ENGINE is not set CONFIG_SPI_BITBANG=m CONFIG_SPI_CADENCE=m @@ -3012,6 +3045,8 @@ CONFIG_CHARGER_LT3651=m # CONFIG_CHARGER_BQ256XX is not set # CONFIG_CHARGER_SMB347 is not set # CONFIG_BATTERY_GAUGE_LTC2941 is not set +# CONFIG_BATTERY_GOLDFISH is not set +# CONFIG_BATTERY_RT5033 is not set # CONFIG_CHARGER_RT9455 is not set # CONFIG_CHARGER_BD99954 is not set CONFIG_HWMON=y @@ -3045,7 +3080,6 @@ CONFIG_SENSORS_AD7314=m # CONFIG_SENSORS_K8TEMP is not set # CONFIG_SENSORS_K10TEMP is not set CONFIG_SENSORS_FAM15H_POWER=m -# CONFIG_SENSORS_AMD_ENERGY is not set CONFIG_SENSORS_APPLESMC=m # CONFIG_SENSORS_ASB100 is not set # CONFIG_SENSORS_ASPEED is not set @@ -3128,12 +3162,14 @@ CONFIG_SENSORS_CORETEMP=m # CONFIG_SENSORS_NCT6775 is not set # CONFIG_SENSORS_NCT7802 is not set # CONFIG_SENSORS_NPCM7XX is not set +# CONFIG_SENSORS_NZXT_KRAKEN2 is not set # CONFIG_SENSORS_PCF8591 is not set # CONFIG_PMBUS is not set # CONFIG_SENSORS_SBTSI is not set # CONFIG_SENSORS_SHT15 is not set # CONFIG_SENSORS_SHT21 is not set # CONFIG_SENSORS_SHT3x is not set +# CONFIG_SENSORS_SHT4x is not set # CONFIG_SENSORS_SHTC1 is not set # CONFIG_SENSORS_SIS5595 is not set # CONFIG_SENSORS_DME1737 is not set @@ -3216,6 +3252,7 @@ CONFIG_PROC_THERMAL_MMIO_RAPL=m # end of ACPI INT340X thermal drivers CONFIG_INTEL_PCH_THERMAL=m +# CONFIG_INTEL_TCC_COOLING is not set # end of Intel thermal drivers # CONFIG_GENERIC_ADC_THERMAL is not set @@ -3301,13 +3338,12 @@ CONFIG_MFD_INTEL_PMT=y # CONFIG_MFD_PCF50633 is not set # CONFIG_UCB1400_CORE is not set # CONFIG_MFD_RDC321X is not set +# CONFIG_MFD_RT4831 is not set # CONFIG_MFD_RT5033 is not set # CONFIG_MFD_RC5T583 is not set -# CONFIG_MFD_SEC_CORE is not set # CONFIG_MFD_SI476X_CORE is not set # CONFIG_MFD_SM501 is not set # CONFIG_MFD_SKY81452 is not set -# CONFIG_ABX500_CORE is not set # CONFIG_MFD_SYSCON is not set # CONFIG_MFD_TI_AM335X_TSCADC is not set # CONFIG_MFD_LP3943 is not set @@ -3319,7 +3355,6 @@ CONFIG_MFD_INTEL_PMT=y # CONFIG_TPS6507X is not set # CONFIG_MFD_TPS65086 is not set # CONFIG_MFD_TPS65090 is not set -# CONFIG_MFD_TPS68470 is not set # CONFIG_MFD_TI_LP873X is not set # CONFIG_MFD_TPS6586X is not set # CONFIG_MFD_TPS65910 is not set @@ -3339,6 +3374,7 @@ CONFIG_MFD_INTEL_PMT=y # CONFIG_MFD_WM831X_SPI is not set # CONFIG_MFD_WM8350_I2C is not set # CONFIG_MFD_WM8994 is not set +# CONFIG_MFD_ATC260X_I2C is not set # CONFIG_MFD_INTEL_M10_BMC is not set # end of Multifunction device drivers @@ -3470,7 +3506,6 @@ CONFIG_VIDEO_TW686X=m # # Media digital TV PCI Adapters # -# CONFIG_DVB_AV7110 is not set # CONFIG_DVB_BUDGET_CORE is not set # CONFIG_DVB_B2C2_FLEXCOP_PCI is not set # CONFIG_DVB_PLUTO2 is not set @@ -3807,7 +3842,6 @@ CONFIG_MEDIA_TUNER_MC44S803=m # # DVB-T (terrestrial) frontends # -# CONFIG_DVB_SP8870 is not set # CONFIG_DVB_SP887X is not set # CONFIG_DVB_CX22700 is not set # CONFIG_DVB_CX22702 is not set @@ -3935,7 +3969,6 @@ CONFIG_DRM_MIPI_DSI=y # CONFIG_DRM_DEBUG_MM is not set # CONFIG_DRM_DEBUG_SELFTEST is not set CONFIG_DRM_KMS_HELPER=y -CONFIG_DRM_KMS_FB_HELPER=y # CONFIG_DRM_DEBUG_DP_MST_TOPOLOGY_REFS is not set CONFIG_DRM_FBDEV_EMULATION=y CONFIG_DRM_FBDEV_OVERALLOC=100 @@ -3968,7 +4001,6 @@ CONFIG_DRM_AMDGPU=m # CONFIG_DRM_AMDGPU_SI is not set CONFIG_DRM_AMDGPU_CIK=y CONFIG_DRM_AMDGPU_USERPTR=y -# CONFIG_DRM_AMDGPU_GART_DEBUGFS is not set # # ACP (Audio CoProcessor) Configuration @@ -3983,6 +4015,7 @@ CONFIG_DRM_AMD_DC=y CONFIG_DRM_AMD_DC_DCN=y # CONFIG_DRM_AMD_DC_HDCP is not set # CONFIG_DRM_AMD_DC_SI is not set +# CONFIG_DRM_AMD_SECURE_DISPLAY is not set # end of Display Engine Configuration # CONFIG_HSA_AMD is not set @@ -4018,6 +4051,7 @@ CONFIG_DRM_I915_GVT=y # # drm/i915 Profile Guided Optimisation # +CONFIG_DRM_I915_REQUEST_TIMEOUT=20000 CONFIG_DRM_I915_FENCE_TIMEOUT=10000 CONFIG_DRM_I915_USERFAULT_AUTOSUSPEND=250 CONFIG_DRM_I915_HEARTBEAT_INTERVAL=2500 @@ -4058,6 +4092,7 @@ CONFIG_DRM_PANEL_BRIDGE=y # CONFIG_DRM_ETNAVIV is not set CONFIG_DRM_CIRRUS_QEMU=y # CONFIG_DRM_GM12U320 is not set +# CONFIG_DRM_SIMPLEDRM is not set # CONFIG_TINYDRM_HX8357D is not set # CONFIG_TINYDRM_ILI9225 is not set # CONFIG_TINYDRM_ILI9341 is not set @@ -4067,6 +4102,7 @@ CONFIG_DRM_CIRRUS_QEMU=y # CONFIG_TINYDRM_ST7586 is not set # CONFIG_TINYDRM_ST7735R is not set # CONFIG_DRM_VBOXVIDEO is not set +# CONFIG_DRM_GUD is not set # CONFIG_DRM_LEGACY is not set CONFIG_DRM_PANEL_ORIENTATION_QUIRKS=y @@ -4139,6 +4175,7 @@ CONFIG_FB_RADEON_BACKLIGHT=y # CONFIG_FB_METRONOME is not set # CONFIG_FB_MB862XX is not set # CONFIG_FB_SIMPLE is not set +# CONFIG_FB_SSD1307 is not set # CONFIG_FB_SM712 is not set # end of Frame buffer Devices @@ -4210,6 +4247,7 @@ CONFIG_SND_VERBOSE_PROCFS=y # CONFIG_SND_DEBUG is not set CONFIG_SND_VMASTER=y CONFIG_SND_DMA_SGBUF=y +CONFIG_SND_CTL_LED=m CONFIG_SND_SEQUENCER=m CONFIG_SND_SEQ_DUMMY=m # CONFIG_SND_SEQUENCER_OSS is not set @@ -4316,7 +4354,7 @@ CONFIG_SND_HDA_DSP_LOADER=y CONFIG_SND_HDA_COMPONENT=y CONFIG_SND_HDA_I915=y CONFIG_SND_HDA_EXT_CORE=m -CONFIG_SND_HDA_PREALLOC_SIZE=4096 +CONFIG_SND_HDA_PREALLOC_SIZE=0 CONFIG_SND_INTEL_NHLT=y CONFIG_SND_INTEL_DSP_CONFIG=m CONFIG_SND_INTEL_SOUNDWIRE_ACPI=m @@ -4390,6 +4428,7 @@ CONFIG_SND_SOC_INTEL_SKYLAKE_COMMON=m CONFIG_SND_SOC_ACPI_INTEL_MATCH=m CONFIG_SND_SOC_INTEL_MACH=y # CONFIG_SND_SOC_INTEL_USER_FRIENDLY_LONG_NAMES is not set +CONFIG_SND_SOC_INTEL_HDA_DSP_COMMON=m CONFIG_SND_SOC_INTEL_HASWELL_MACH=m # CONFIG_SND_SOC_INTEL_BDW_RT5650_MACH is not set CONFIG_SND_SOC_INTEL_BDW_RT5677_MACH=m @@ -4421,6 +4460,7 @@ CONFIG_SND_SOC_INTEL_BXT_RT298_MACH=m # CONFIG_SND_SOC_INTEL_GLK_RT5682_MAX98357A_MACH is not set # CONFIG_SND_SOC_INTEL_SKL_HDA_DSP_GENERIC_MACH is not set # CONFIG_SND_SOC_INTEL_SOF_RT5682_MACH is not set +# CONFIG_SND_SOC_INTEL_SOF_CS42L42_MACH is not set # CONFIG_SND_SOC_INTEL_SOF_PCM512x_MACH is not set # CONFIG_SND_SOC_INTEL_CML_LP_DA7219_MAX98357A_MACH is not set # CONFIG_SND_SOC_INTEL_SOF_CML_RT1011_RT5682_MACH is not set @@ -4577,6 +4617,7 @@ CONFIG_SND_SOC_RT5677_SPI=m # CONFIG_SND_SOC_SIMPLE_MUX is not set CONFIG_SND_SOC_SPDIF=m # CONFIG_SND_SOC_SSM2305 is not set +# CONFIG_SND_SOC_SSM2518 is not set # CONFIG_SND_SOC_SSM2602_SPI is not set # CONFIG_SND_SOC_SSM2602_I2C is not set CONFIG_SND_SOC_SSM4567=m @@ -4593,12 +4634,14 @@ CONFIG_SND_SOC_SSM4567=m # CONFIG_SND_SOC_TAS6424 is not set # CONFIG_SND_SOC_TDA7419 is not set # CONFIG_SND_SOC_TFA9879 is not set +# CONFIG_SND_SOC_TFA989X is not set # CONFIG_SND_SOC_TLV320AIC23_I2C is not set # CONFIG_SND_SOC_TLV320AIC23_SPI is not set # CONFIG_SND_SOC_TLV320AIC31XX is not set # CONFIG_SND_SOC_TLV320AIC32X4_I2C is not set # CONFIG_SND_SOC_TLV320AIC32X4_SPI is not set -# CONFIG_SND_SOC_TLV320AIC3X is not set +# CONFIG_SND_SOC_TLV320AIC3X_I2C is not set +# CONFIG_SND_SOC_TLV320AIC3X_SPI is not set # CONFIG_SND_SOC_TLV320ADCX140 is not set CONFIG_SND_SOC_TS3A227E=m # CONFIG_SND_SOC_TSCS42XX is not set @@ -4628,7 +4671,6 @@ CONFIG_SND_SOC_TS3A227E=m # CONFIG_SND_SOC_WM8978 is not set # CONFIG_SND_SOC_WM8985 is not set # CONFIG_SND_SOC_ZL38060 is not set -# CONFIG_SND_SOC_ZX_AUD96P22 is not set # CONFIG_SND_SOC_MAX9759 is not set # CONFIG_SND_SOC_MT6351 is not set # CONFIG_SND_SOC_MT6358 is not set @@ -4650,6 +4692,7 @@ CONFIG_SND_SIMPLE_CARD_UTILS=m CONFIG_SND_SIMPLE_CARD=m CONFIG_SND_X86=y # CONFIG_HDMI_LPE_AUDIO is not set +# CONFIG_SND_VIRTIO is not set CONFIG_AC97_BUS=m # @@ -4690,6 +4733,7 @@ CONFIG_HID_CMEDIA=m CONFIG_HID_ELECOM=m CONFIG_HID_ELO=m CONFIG_HID_EZKEY=m +# CONFIG_HID_FT260 is not set # CONFIG_HID_GEMBIRD is not set # CONFIG_HID_GFRM is not set # CONFIG_HID_GLORIOUS is not set @@ -4739,6 +4783,7 @@ CONFIG_HID_PRIMAX=m CONFIG_HID_ROCCAT=m CONFIG_HID_SAITEK=m # CONFIG_HID_SAMSUNG is not set +# CONFIG_HID_SEMITEK is not set # CONFIG_HID_SONY is not set CONFIG_HID_SPEEDLINK=m # CONFIG_HID_STEAM is not set @@ -5045,6 +5090,7 @@ CONFIG_LEDS_CLASS=y # CONFIG_LEDS_PWM is not set # CONFIG_LEDS_BD2802 is not set # CONFIG_LEDS_INTEL_SS4200 is not set +# CONFIG_LEDS_LT3593 is not set # CONFIG_LEDS_TCA6507 is not set # CONFIG_LEDS_TLC591XX is not set # CONFIG_LEDS_LM355x is not set @@ -5087,11 +5133,6 @@ CONFIG_LEDS_TRIGGERS=y # CONFIG_LEDS_TRIGGER_PATTERN is not set CONFIG_LEDS_TRIGGER_AUDIO=m # CONFIG_LEDS_TRIGGER_TTY is not set - -# -# LED Blink -# -# CONFIG_LEDS_BLINK is not set # CONFIG_ACCESSIBILITY is not set # CONFIG_INFINIBAND is not set CONFIG_EDAC_ATOMIC_SCRUB=y @@ -5201,6 +5242,7 @@ CONFIG_RTC_DRV_CROS_EC=m # HID Sensor RTC drivers # CONFIG_RTC_DRV_HID_SENSOR_TIME=m +# CONFIG_RTC_DRV_GOLDFISH is not set CONFIG_DMADEVICES=y # CONFIG_DMADEVICES_DEBUG is not set @@ -5215,7 +5257,6 @@ CONFIG_INTEL_IDMA64=m # CONFIG_INTEL_IDXD is not set # CONFIG_INTEL_IOATDMA is not set # CONFIG_PLX_DMA is not set -# CONFIG_XILINX_ZYNQMP_DPDMA is not set # CONFIG_QCOM_HIDMA_MGMT is not set # CONFIG_QCOM_HIDMA is not set CONFIG_DW_DMAC_CORE=y @@ -5283,9 +5324,9 @@ CONFIG_VHOST_VSOCK=y # end of Microsoft Hyper-V guest support # CONFIG_GREYBUS is not set +# CONFIG_COMEDI is not set CONFIG_STAGING=y # CONFIG_PRISM2_USB is not set -# CONFIG_COMEDI is not set # CONFIG_RTL8192U is not set CONFIG_RTLLIB=m CONFIG_RTLLIB_CRYPTO_CCMP=m @@ -5327,7 +5368,6 @@ CONFIG_R8188EU=m # # Capacitance to digital converters # -# CONFIG_AD7150 is not set # CONFIG_AD7746 is not set # end of Capacitance to digital converters @@ -5362,6 +5402,7 @@ CONFIG_STAGING_MEDIA=y # CONFIG_INTEL_ATOMISP is not set # CONFIG_VIDEO_ZORAN is not set # CONFIG_VIDEO_IPU3_IMGU is not set +# CONFIG_DVB_AV7110 is not set # # Android @@ -5375,17 +5416,8 @@ CONFIG_STAGING_MEDIA=y # CONFIG_FB_TFT is not set # CONFIG_KS7010 is not set # CONFIG_PI433 is not set - -# -# Gasket devices -# -# CONFIG_STAGING_GASKET_FRAMEWORK is not set -# end of Gasket devices - # CONFIG_FIELDBUS_DEV is not set -# CONFIG_KPC2000 is not set # CONFIG_QLGE is not set -# CONFIG_WIMAX is not set # CONFIG_WFX is not set CONFIG_X86_PLATFORM_DEVICES=y CONFIG_ACPI_WMI=m @@ -5396,10 +5428,12 @@ CONFIG_WMI_BMOF=m CONFIG_MXM_WMI=m # CONFIG_PEAQ_WMI is not set # CONFIG_XIAOMI_WMI is not set +# CONFIG_GIGABYTE_WMI is not set CONFIG_ACERHDF=m # CONFIG_ACER_WIRELESS is not set CONFIG_ACER_WMI=m # CONFIG_AMD_PMC is not set +# CONFIG_ADV_SWBUTTON is not set CONFIG_APPLE_GMUX=m CONFIG_ASUS_LAPTOP=m CONFIG_ASUS_WIRELESS=m @@ -5418,6 +5452,7 @@ CONFIG_DELL_SMBIOS_WMI=y CONFIG_DELL_SMBIOS_SMM=y CONFIG_DELL_SMO8800=m CONFIG_DELL_WMI=m +# CONFIG_DELL_WMI_PRIVACY is not set CONFIG_DELL_WMI_AIO=m CONFIG_DELL_WMI_DESCRIPTOR=m # CONFIG_DELL_WMI_LED is not set @@ -5427,7 +5462,7 @@ CONFIG_FUJITSU_LAPTOP=m # CONFIG_FUJITSU_TABLET is not set # CONFIG_GPD_POCKET_FAN is not set # CONFIG_HP_ACCEL is not set -# CONFIG_HP_WIRELESS is not set +# CONFIG_WIRELESS_HOTKEY is not set CONFIG_HP_WMI=m # CONFIG_IBM_RTL is not set # CONFIG_IDEAPAD_LAPTOP is not set @@ -5439,6 +5474,8 @@ CONFIG_THINKPAD_ACPI_ALSA_SUPPORT=y # CONFIG_THINKPAD_ACPI_UNSAFE_LEDS is not set CONFIG_THINKPAD_ACPI_VIDEO=y CONFIG_THINKPAD_ACPI_HOTKEY_POLL=y +# CONFIG_THINKPAD_LMI is not set +CONFIG_X86_PLATFORM_DRIVERS_INTEL=y # CONFIG_INTEL_ATOMISP2_PM is not set CONFIG_INTEL_HID_EVENT=m # CONFIG_INTEL_INT0002_VGPIO is not set @@ -5503,9 +5540,17 @@ CONFIG_SURFACE_PLATFORMS=y # CONFIG_SURFACE_HOTPLUG is not set CONFIG_SURFACE_PRO3_BUTTON=m CONFIG_HAVE_CLK=y -CONFIG_CLKDEV_LOOKUP=y CONFIG_HAVE_CLK_PREPARE=y CONFIG_COMMON_CLK=y + +# +# Clock driver for ARM Reference designs +# +# CONFIG_ICST is not set +# CONFIG_CLK_SP810 is not set +# end of Clock driver for ARM Reference designs + +# CONFIG_LMK04832 is not set # CONFIG_COMMON_CLK_MAX9485 is not set # CONFIG_COMMON_CLK_SI5341 is not set # CONFIG_COMMON_CLK_SI5351 is not set @@ -5549,6 +5594,7 @@ CONFIG_INTEL_IOMMU_DEFAULT_ON=y CONFIG_INTEL_IOMMU_FLOPPY_WA=y # CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON is not set CONFIG_IRQ_REMAP=y +# CONFIG_VIRTIO_IOMMU is not set # # Remoteproc drivers @@ -5667,10 +5713,13 @@ CONFIG_IIO_CONSUMERS_PER_TRIGGER=2 # CONFIG_BMA220 is not set # CONFIG_BMA400 is not set # CONFIG_BMC150_ACCEL is not set +# CONFIG_BMI088_ACCEL is not set # CONFIG_DA280 is not set # CONFIG_DA311 is not set # CONFIG_DMARD09 is not set # CONFIG_DMARD10 is not set +# CONFIG_FXLS8962AF_I2C is not set +# CONFIG_FXLS8962AF_SPI is not set # CONFIG_HID_SENSOR_ACCEL_3D is not set # CONFIG_IIO_ST_ACCEL_3AXIS is not set # CONFIG_KXSD9 is not set @@ -5685,6 +5734,7 @@ CONFIG_IIO_CONSUMERS_PER_TRIGGER=2 # CONFIG_MXC4005 is not set # CONFIG_MXC6255 is not set # CONFIG_SCA3000 is not set +# CONFIG_SCA3300 is not set # CONFIG_STK8312 is not set # CONFIG_STK8BA50 is not set # end of Accelerometers @@ -5737,7 +5787,9 @@ CONFIG_IIO_CONSUMERS_PER_TRIGGER=2 # CONFIG_TI_ADC161S626 is not set # CONFIG_TI_ADS1015 is not set # CONFIG_TI_ADS7950 is not set +# CONFIG_TI_ADS131E08 is not set # CONFIG_TI_TLC4541 is not set +# CONFIG_TI_TSC2046 is not set # CONFIG_XILINX_XADC is not set # end of Analog to digital converters @@ -5753,6 +5805,12 @@ CONFIG_IIO_CONSUMERS_PER_TRIGGER=2 # CONFIG_HMC425 is not set # end of Amplifiers +# +# Capacitance to digital converters +# +# CONFIG_AD7150 is not set +# end of Capacitance to digital converters + # # Chemical Sensors # @@ -5763,7 +5821,7 @@ CONFIG_IIO_CONSUMERS_PER_TRIGGER=2 # CONFIG_IAQCORE is not set # CONFIG_SCD30_CORE is not set # CONFIG_SENSIRION_SGP30 is not set -# CONFIG_SPS30 is not set +# CONFIG_SPS30_I2C is not set # CONFIG_VZ89X is not set # end of Chemical Sensors @@ -5774,6 +5832,11 @@ CONFIG_HID_SENSOR_IIO_COMMON=m CONFIG_HID_SENSOR_IIO_TRIGGER=m # end of Hid Sensor IIO Common +# +# IIO SCMI Sensors +# +# end of IIO SCMI Sensors + # # SSP Sensor Common # @@ -5902,6 +5965,7 @@ CONFIG_HID_SENSOR_GYRO_3D=m # CONFIG_INV_MPU6050_I2C is not set # CONFIG_INV_MPU6050_SPI is not set # CONFIG_IIO_ST_LSM6DSX is not set +# CONFIG_IIO_ST_LSM9DS0 is not set # end of Inertial measurement units # @@ -5945,6 +6009,7 @@ CONFIG_HID_SENSOR_PROX=m # CONFIG_TCS3472 is not set # CONFIG_SENSORS_TSL2563 is not set # CONFIG_TSL2583 is not set +# CONFIG_TSL2591 is not set # CONFIG_TSL2772 is not set # CONFIG_TSL4531 is not set # CONFIG_US5182D is not set @@ -6050,6 +6115,7 @@ CONFIG_HID_SENSOR_PRESS=m # # Proximity and distance sensors # +# CONFIG_CROS_EC_MKBP_PROXIMITY is not set # CONFIG_ISL29501 is not set # CONFIG_LIDAR_LITE_V2 is not set # CONFIG_MB1232 is not set @@ -6080,6 +6146,7 @@ CONFIG_HID_SENSOR_PRESS=m # CONFIG_MLX90632 is not set # CONFIG_TMP006 is not set # CONFIG_TMP007 is not set +# CONFIG_TMP117 is not set # CONFIG_TSYS01 is not set # CONFIG_TSYS02D is not set # CONFIG_MAX31856 is not set @@ -6111,6 +6178,7 @@ CONFIG_PWM_LPSS_PLATFORM=m # CONFIG_GENERIC_PHY=y # CONFIG_USB_LGM_PHY is not set +# CONFIG_PHY_CAN_TRANSCEIVER is not set # CONFIG_BCM_KONA_USB2_PHY is not set # CONFIG_PHY_PXA_28NM_HSIC is not set # CONFIG_PHY_PXA_28NM_USB2 is not set @@ -6235,6 +6303,8 @@ CONFIG_OVERLAY_FS_METACOPY=y # # Caches # +CONFIG_NETFS_SUPPORT=m +# CONFIG_NETFS_STATS is not set CONFIG_FSCACHE=m CONFIG_FSCACHE_STATS=y # CONFIG_FSCACHE_HISTOGRAM is not set @@ -6285,6 +6355,8 @@ CONFIG_TMPFS_XATTR=y CONFIG_TMPFS_INODE64=y CONFIG_HUGETLBFS=y CONFIG_HUGETLB_PAGE=y +CONFIG_HUGETLB_PAGE_FREE_VMEMMAP=y +# CONFIG_HUGETLB_PAGE_FREE_VMEMMAP_DEFAULT_ON is not set CONFIG_MEMFD_CREATE=y CONFIG_ARCH_HAS_GIGANTIC_PAGE=y CONFIG_CONFIGFS_FS=y @@ -6324,7 +6396,6 @@ CONFIG_PSTORE_COMPRESS_DEFAULT="deflate" # CONFIG_PSTORE_CONSOLE is not set # CONFIG_PSTORE_PMSG is not set CONFIG_PSTORE_RAM=m -# CONFIG_PSTORE_BLK is not set # CONFIG_SYSV_FS is not set # CONFIG_UFS_FS is not set # CONFIG_EROFS_FS is not set @@ -6428,6 +6499,7 @@ CONFIG_SECURITY_LOCKDOWN_LSM_EARLY=y CONFIG_LOCK_DOWN_KERNEL_FORCE_NONE=y # CONFIG_LOCK_DOWN_KERNEL_FORCE_INTEGRITY is not set # CONFIG_LOCK_DOWN_KERNEL_FORCE_CONFIDENTIALITY is not set +# CONFIG_SECURITY_LANDLOCK is not set # CONFIG_INTEGRITY is not set # CONFIG_IMA_SECURE_AND_OR_TRUSTED_BOOT is not set CONFIG_DEFAULT_SECURITY_DAC=y @@ -6490,6 +6562,7 @@ CONFIG_CRYPTO_RSA=y CONFIG_CRYPTO_DH=y CONFIG_CRYPTO_ECC=m CONFIG_CRYPTO_ECDH=m +# CONFIG_CRYPTO_ECDSA is not set # CONFIG_CRYPTO_ECRDSA is not set # CONFIG_CRYPTO_SM2 is not set CONFIG_CRYPTO_CURVE25519=y @@ -6791,7 +6864,6 @@ CONFIG_ARCH_HAS_UACCESS_FLUSHCACHE=y CONFIG_ARCH_HAS_COPY_MC=y CONFIG_ARCH_STACKWALK=y CONFIG_SBITMAP=y -# CONFIG_STRING_SELFTEST is not set # end of Library routines # @@ -6803,6 +6875,7 @@ CONFIG_SBITMAP=y # CONFIG_PRINTK_TIME=y # CONFIG_PRINTK_CALLER is not set +# CONFIG_STACKTRACE_BUILD_ID is not set CONFIG_CONSOLE_LOGLEVEL_DEFAULT=7 CONFIG_CONSOLE_LOGLEVEL_QUIET=4 CONFIG_MESSAGE_LOGLEVEL_DEFAULT=4 @@ -6823,8 +6896,9 @@ CONFIG_FRAME_WARN=2048 # CONFIG_HEADERS_INSTALL is not set # CONFIG_DEBUG_SECTION_MISMATCH is not set # CONFIG_SECTION_MISMATCH_WARN_ONLY is not set -# CONFIG_DEBUG_FORCE_FUNCTION_ALIGN_32B is not set +# CONFIG_DEBUG_FORCE_FUNCTION_ALIGN_64B is not set CONFIG_STACK_VALIDATION=y +# CONFIG_VMLINUX_MAP is not set # CONFIG_DEBUG_FORCE_WEAK_PER_CPU is not set # end of Compile-time checks and compiler options @@ -6966,7 +7040,6 @@ CONFIG_DEBUG_LIST=y CONFIG_RCU_CPU_STALL_TIMEOUT=60 # CONFIG_RCU_TRACE is not set # CONFIG_RCU_EQS_DEBUG is not set -# CONFIG_RCU_STRICT_GRACE_PERIOD is not set # end of RCU Debugging # CONFIG_DEBUG_WQ_FORCE_RR_CPU is not set @@ -7000,6 +7073,8 @@ CONFIG_FTRACE=y # CONFIG_PREEMPT_TRACER is not set # CONFIG_SCHED_TRACER is not set # CONFIG_HWLAT_TRACER is not set +# CONFIG_OSNOISE_TRACER is not set +# CONFIG_TIMERLAT_TRACER is not set # CONFIG_MMIOTRACE is not set # CONFIG_ENABLE_DEFAULT_TRACERS is not set # CONFIG_FTRACE_SYSCALLS is not set @@ -7069,9 +7144,9 @@ CONFIG_CC_HAS_SANCOV_TRACE_PC=y # CONFIG_KCOV is not set CONFIG_RUNTIME_TESTING_MENU=y # CONFIG_LKDTM is not set -# CONFIG_TEST_LIST_SORT is not set # CONFIG_TEST_MIN_HEAP is not set # CONFIG_TEST_SORT is not set +# CONFIG_TEST_DIV64 is not set # CONFIG_KPROBES_SANITY_TEST is not set # CONFIG_BACKTRACE_SELF_TEST is not set # CONFIG_RBTREE_TEST is not set @@ -7080,10 +7155,12 @@ CONFIG_RUNTIME_TESTING_MENU=y # CONFIG_PERCPU_TEST is not set # CONFIG_ATOMIC64_SELFTEST is not set # CONFIG_TEST_HEXDUMP is not set +# CONFIG_STRING_SELFTEST is not set # CONFIG_TEST_STRING_HELPERS is not set # CONFIG_TEST_STRSCPY is not set # CONFIG_TEST_KSTRTOX is not set # CONFIG_TEST_PRINTF is not set +# CONFIG_TEST_SCANF is not set # CONFIG_TEST_BITMAP is not set # CONFIG_TEST_UUID is not set # CONFIG_TEST_XARRAY is not set @@ -7108,6 +7185,8 @@ CONFIG_RUNTIME_TESTING_MENU=y # CONFIG_TEST_MEMINIT is not set # CONFIG_TEST_FREE_PAGES is not set # CONFIG_TEST_FPU is not set +# CONFIG_TEST_CLOCKSOURCE_WATCHDOG is not set +CONFIG_ARCH_USE_MEMTEST=y # CONFIG_MEMTEST is not set # end of Kernel Testing and Coverage # end of Kernel hacking diff --git a/meta-citadel/recipes-support/cryptsetup/cryptsetup_2.3.5.bb b/meta-citadel/recipes-support/cryptsetup/cryptsetup_2.3.6.bb similarity index 85% rename from meta-citadel/recipes-support/cryptsetup/cryptsetup_2.3.5.bb rename to meta-citadel/recipes-support/cryptsetup/cryptsetup_2.3.6.bb index 0da9a26..0f92562 100644 --- a/meta-citadel/recipes-support/cryptsetup/cryptsetup_2.3.5.bb +++ b/meta-citadel/recipes-support/cryptsetup/cryptsetup_2.3.6.bb @@ -16,13 +16,9 @@ DEPENDS = " \ util-linux-libuuid \ " -RDEPENDS_${PN} = " \ - libdevmapper \ -" - SRC_URI = "${KERNELORG_MIRROR}/linux/utils/${BPN}/v${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}/${BP}.tar.xz" -SRC_URI[md5sum] = "408620e0df577ec04108ec0bc2b91dee" -SRC_URI[sha256sum] = "ced9946f444d132536daf92fc8aca4277638a3c2d96e20540b2bae4d36fd70c1" +SRC_URI[md5sum] = "504d1ab22cbc4d1a59a8d8c7ee5ed3bf" +SRC_URI[sha256sum] = "b296b7a21ea576c2b180611ccb19d06aec8dddaedf7c704b0c6a81210c25635f" inherit autotools gettext pkgconfig @@ -41,7 +37,7 @@ PACKAGECONFIG ??= " \ luks-adjust-xts-keysize \ openssl \ " -PACKAGECONFIG_append_class-target = " \ +PACKAGECONFIG_append:class-target = " \ udev \ " @@ -54,7 +50,7 @@ PACKAGECONFIG[veritysetup] = "--enable-veritysetup,--disable-veritysetup" PACKAGECONFIG[cryptsetup-reencrypt] = "--enable-cryptsetup-reencrypt,--disable-cryptsetup-reencrypt" PACKAGECONFIG[integritysetup] = "--enable-integritysetup,--disable-integritysetup" PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux" -PACKAGECONFIG[udev] = "--enable-udev,--disable-udev,,udev" +PACKAGECONFIG[udev] = "--enable-udev,--disable-udev,,udev lvm2-udevrules" PACKAGECONFIG[kernel_crypto] = "--enable-kernel_crypto,--disable-kernel_crypto" # gcrypt-pkbdf2 requries --with-crypto_backend=gcrypt or the flag isn't # recognized. @@ -71,14 +67,6 @@ PACKAGECONFIG[kernel] = "--with-crypto_backend=kernel" PACKAGECONFIG[nettle] = "--with-crypto_backend=nettle,,nettle" PACKAGECONFIG[luks2] = "--with-default-luks-format=LUKS2,--with-default-luks-format=LUKS1" -RRECOMMENDS_${PN} = "kernel-module-aes-generic \ - kernel-module-dm-crypt \ - kernel-module-md5 \ - kernel-module-cbc \ - kernel-module-sha256-generic \ - kernel-module-xts \ -" - EXTRA_OECONF = "--enable-static" # Building without largefile is not supported by upstream EXTRA_OECONF += "--enable-largefile" @@ -87,6 +75,19 @@ EXTRA_OECONF += "--disable-static-cryptsetup" # There's no recipe for libargon2 yet EXTRA_OECONF += "--disable-libargon2" -FILES_${PN} += "${@bb.utils.contains('DISTRO_FEATURES','systemd','${exec_prefix}/lib/tmpfiles.d/cryptsetup.conf', '', d)}" +FILES:${PN} += "${@bb.utils.contains('DISTRO_FEATURES','systemd','${exec_prefix}/lib/tmpfiles.d/cryptsetup.conf', '', d)}" + +RDEPENDS_${PN} = " \ + libdevmapper \ +" + +RRECOMMENDS_${PN}:class-target = " \ + kernel-module-aes-generic \ + kernel-module-dm-crypt \ + kernel-module-md5 \ + kernel-module-cbc \ + kernel-module-sha256-generic \ + kernel-module-xts \ +" BBCLASSEXTEND = "native nativesdk" diff --git a/meta-citadel/recipes-support/libblockdev/libblockdev_2.25.bb b/meta-citadel/recipes-support/libblockdev/libblockdev_2.26.bb similarity index 95% rename from meta-citadel/recipes-support/libblockdev/libblockdev_2.25.bb rename to meta-citadel/recipes-support/libblockdev/libblockdev_2.26.bb index 2c8fdc7..41c70e1 100644 --- a/meta-citadel/recipes-support/libblockdev/libblockdev_2.25.bb +++ b/meta-citadel/recipes-support/libblockdev/libblockdev_2.26.bb @@ -8,10 +8,10 @@ SECTION = "devel/lib" LIC_FILES_CHKSUM = "file://LICENSE;md5=c07cb499d259452f324bb90c3067d85c" -inherit autotools gobject-introspection +inherit autotools gobject-introspection pkgconfig SRC_URI = "git://github.com/storaged-project/libblockdev;branch=2.x-branch" -SRCREV = "c50869272b54bf4b4bc3825e8c3332a54678b43f" +SRCREV = "47ff12242c89e36a33259d18b7068b26c3bb1c64" S = "${WORKDIR}/git" FILES_${PN} += "${libdir}/python2.7/dist-packages ${libdir}/python3.*/site-packages" diff --git a/meta-citadel/recipes-support/libbytesize/libbytesize_1.4.bb b/meta-citadel/recipes-support/libbytesize/libbytesize_2.6.bb similarity index 71% rename from meta-citadel/recipes-support/libbytesize/libbytesize_1.4.bb rename to meta-citadel/recipes-support/libbytesize/libbytesize_2.6.bb index 863ce42..3617fe6 100644 --- a/meta-citadel/recipes-support/libbytesize/libbytesize_1.4.bb +++ b/meta-citadel/recipes-support/libbytesize/libbytesize_2.6.bb @@ -9,25 +9,22 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=c07cb499d259452f324bb90c3067d85c" S = "${WORKDIR}/git" B = "${S}" -SRCREV = "ebbda2217d177d2a17f917d7a3e3d132a26db791" -SRC_URI = "git://github.com/rhinstaller/libbytesize;branch=master \ -" +SRCREV = "c9864f4dd03736839f40d225da494cb1eb64e654" +SRC_URI = "git://github.com/rhinstaller/libbytesize;branch=master" -inherit gettext autotools python3native +inherit gettext autotools pkgconfig python3native DEPENDS += " \ - libpcre \ + libpcre2 \ gmp \ mpfr \ + gettext-native \ " FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}/bytesize" PACKAGECONFIG ??= "python3" -PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3" -PACKAGECONFIG[python2] = "--with-python2, --without-python2,,python2" -PACKAGECONFIG[doc] = "--with-gtk-doc, --without-gtk-doc, gtk-doc-native" +PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3-core" +EXTRA_OECONF = "--without-gtk-doc" EXTRA_OEMAKE = "py3libdir=${PYTHON_SITEPACKAGES_DIR}" - - diff --git a/meta-citadel/recipes-support/nano/nano_5.6.bb b/meta-citadel/recipes-support/nano/nano_5.8.bb similarity index 81% rename from meta-citadel/recipes-support/nano/nano_5.6.bb rename to meta-citadel/recipes-support/nano/nano_5.8.bb index 1ce08dd..8ba4ca1 100644 --- a/meta-citadel/recipes-support/nano/nano_5.6.bb +++ b/meta-citadel/recipes-support/nano/nano_5.8.bb @@ -1,3 +1,4 @@ +SUMMARY = "Small and friendly console text editor" DESCRIPTION = "GNU nano (Nano's ANOther editor, or \ Not ANOther editor) is an enhanced clone of the \ Pico text editor." @@ -12,7 +13,7 @@ RDEPENDS_${PN} = "ncurses-terminfo-base" PV_MAJOR = "${@d.getVar('PV').split('.')[0]}" SRC_URI = "https://nano-editor.org/dist/v${PV_MAJOR}/nano-${PV}.tar.xz" -SRC_URI[sha256sum] = "fce183e4a7034d07d219c79aa2f579005d1fd49f156db6e50f53543a87637a32" +SRC_URI[sha256sum] = "e43b63db2f78336e2aa123e8d015dbabc1720a15361714bfd4b1bb4e5e87768c" UPSTREAM_CHECK_URI = "https://ftp.gnu.org/gnu/nano" diff --git a/meta-citadel/recipes-support/udisks/udisks2_2.9.2.bb b/meta-citadel/recipes-support/udisks/udisks2_2.9.3.bb similarity index 90% rename from meta-citadel/recipes-support/udisks/udisks2_2.9.2.bb rename to meta-citadel/recipes-support/udisks/udisks2_2.9.3.bb index f9e1274..edd097f 100644 --- a/meta-citadel/recipes-support/udisks/udisks2_2.9.2.bb +++ b/meta-citadel/recipes-support/udisks/udisks2_2.9.3.bb @@ -17,8 +17,8 @@ DEPENDS += "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" RDEPENDS_${PN} = "acl" -SRC_URI = "git://github.com/storaged-project/udisks.git;branch=master" -SRCREV = "da6d9480fefeb0ffdf8a84626b5096827d8d7030" +SRC_URI = "git://github.com/storaged-project/udisks.git;branch=2.9.x-branch" +SRCREV = "c430dd9a27e158693cc783e9ee91bf6e5b2a8819" S = "${WORKDIR}/git" CVE_PRODUCT = "udisks" diff --git a/meta-gnome/recipes-connectivity/iwd/iwd/0001-build-Use-abs_top_srcdir-instead-of-abs_srcdir-for-e.patch b/meta-gnome/recipes-connectivity/iwd/iwd/0001-build-Use-abs_top_srcdir-instead-of-abs_srcdir-for-e.patch index 63d617f..9ed7310 100644 --- a/meta-gnome/recipes-connectivity/iwd/iwd/0001-build-Use-abs_top_srcdir-instead-of-abs_srcdir-for-e.patch +++ b/meta-gnome/recipes-connectivity/iwd/iwd/0001-build-Use-abs_top_srcdir-instead-of-abs_srcdir-for-e.patch @@ -1,6 +1,6 @@ -From 0532cddcec9c3abff1f3bc22d2fa50df03d55d17 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 5 Apr 2021 14:11:40 -0700 +From b0b51d762f45ff9d320b96bd0acb89313148a446 Mon Sep 17 00:00:00 2001 +From: Zang Ruochen +Date: Wed, 12 May 2021 14:28:24 +0900 Subject: [PATCH] build: Use abs_top_srcdir instead of abs_srcdir for ell sources this makes it build when build dir is outside of sources dir @@ -10,13 +10,12 @@ Upstream-Status: Submitted [https://lists.01.org/hyperkitty/list/iwd@lists.01.or Makefile.am | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) +diff --git a/Makefile.am b/Makefile.am +index 68035e4..e3f7990 100644 --- a/Makefile.am +++ b/Makefile.am -@@ -625,9 +625,10 @@ unit/tls-settings.8021x: unit/cert-ca.pe - BUILT_SOURCES = $(ell_built_sources) src/builtin.h - - ell/shared: Makefile -+ $(AM_V_at)$(MKDIR_P) ell +@@ -628,7 +628,7 @@ ell/shared: Makefile + $(AM_V_at)$(MKDIR_P) ell $(AM_V_GEN)for f in $(ell_shared) ; do \ if [ ! -f $$f ] ; then \ - $(LN_S) -t ell -f $(abs_srcdir)/../ell/$$f ; \ @@ -24,7 +23,7 @@ Upstream-Status: Submitted [https://lists.01.org/hyperkitty/list/iwd@lists.01.or fi \ done > $@ -@@ -635,7 +636,7 @@ ell/internal: Makefile +@@ -636,7 +636,7 @@ ell/internal: Makefile $(AM_V_at)$(MKDIR_P) ell $(AM_V_GEN)for f in $(ell_headers) $(ell_sources) ; do \ if [ ! -f $$f ] ; then \ @@ -33,3 +32,6 @@ Upstream-Status: Submitted [https://lists.01.org/hyperkitty/list/iwd@lists.01.or fi \ done > $@ +-- +2.25.1 + diff --git a/meta-gnome/recipes-connectivity/iwd/iwd_1.13.bb b/meta-gnome/recipes-connectivity/iwd/iwd_1.17.bb similarity index 94% rename from meta-gnome/recipes-connectivity/iwd/iwd_1.13.bb rename to meta-gnome/recipes-connectivity/iwd/iwd_1.17.bb index 19d3a50..11b8c88 100644 --- a/meta-gnome/recipes-connectivity/iwd/iwd_1.13.bb +++ b/meta-gnome/recipes-connectivity/iwd/iwd_1.17.bb @@ -8,7 +8,7 @@ DEPENDS = "ell" SRC_URI = "https://www.kernel.org/pub/linux/network/wireless/${BP}.tar.xz \ file://0001-build-Use-abs_top_srcdir-instead-of-abs_srcdir-for-e.patch \ " -SRC_URI[sha256sum] = "b005f7ed0f0a96a2c6181c44560fc868533a18e7034bd4cb43ea0d40c21b4e7a" +SRC_URI[sha256sum] = "6f946f823b0dc3205e4e72becf8ad1915448d194f5b10d8003e4c8c5a18e4ef7" inherit autotools manpages pkgconfig python3native systemd diff --git a/meta-gnome/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb b/meta-gnome/recipes-connectivity/modemmanager/modemmanager_1.16.8.bb similarity index 73% rename from meta-gnome/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb rename to meta-gnome/recipes-connectivity/modemmanager/modemmanager_1.16.8.bb index f8e074a..acfa113 100644 --- a/meta-gnome/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb +++ b/meta-gnome/recipes-connectivity/modemmanager/modemmanager_1.16.8.bb @@ -9,22 +9,17 @@ LIC_FILES_CHKSUM = " \ inherit gnomebase gettext systemd vala gobject-introspection bash-completion -DEPENDS = "glib-2.0 libgudev dbus-glib intltool-native" - -SRC_URI = "http://www.freedesktop.org/software/ModemManager/ModemManager-${PV}.tar.xz \ - file://0001-Do-not-set-Wno-unused-but-set-variable.patch \ - file://0001-Do-not-pass-null-string-to-s-printf-formatted-string.patch \ - " - -SRC_URI[md5sum] = "a49c9f73e46c7b89e5efedda250d22c0" -SRC_URI[sha256sum] = "96f2a5f0ed15532b4c4c185b756fdc0326e7c2027cea26a1264f91e098260f80" +DEPENDS = "glib-2.0 libgudev intltool-native libxslt-native" +SRC_URI = "http://www.freedesktop.org/software/ModemManager/ModemManager-${PV}.tar.xz" +SRC_URI[sha256sum] = "21fdfaf94171261ad9d99771894f5ade4bc39ef3d1ff1d421054d14713e97880" S = "${WORKDIR}/ModemManager-${PV}" -PACKAGECONFIG ??= "mbim qmi polkit \ - ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \ +PACKAGECONFIG ??= "mbim qmi \ + ${@bb.utils.filter('DISTRO_FEATURES', 'systemd polkit', d)} \ " +PACKAGECONFIG[at] = "--with-at-command-via-dbus" PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,," PACKAGECONFIG[polkit] = "--with-polkit=yes,--with-polkit=no,polkit" # Support WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol. @@ -35,12 +30,12 @@ PACKAGECONFIG[qmi] = "--with-qmi,--without-qmi,libqmi" EXTRA_OECONF = " \ --with-udev-base-dir=${nonarch_base_libdir}/udev \ " -CFLAGS_append_toolchain-gcc = " -Wno-unused-but-set-variable" FILES_${PN} += " \ ${datadir}/icons \ ${datadir}/polkit-1 \ ${datadir}/dbus-1 \ + ${datadir}/ModemManager \ ${libdir}/ModemManager \ ${systemd_unitdir}/system \ " diff --git a/meta-gnome/recipes-connectivity/networkmanager/networkmanager/0002-Do-not-create-settings-settings-property-documentati.patch b/meta-gnome/recipes-connectivity/networkmanager/networkmanager/0002-Do-not-create-settings-settings-property-documentati.patch index 0a86aba..86e8eaa 100644 --- a/meta-gnome/recipes-connectivity/networkmanager/networkmanager/0002-Do-not-create-settings-settings-property-documentati.patch +++ b/meta-gnome/recipes-connectivity/networkmanager/networkmanager/0002-Do-not-create-settings-settings-property-documentati.patch @@ -1,6 +1,6 @@ From d0dead0478a070b96f37bd3b310443eaa8c93a25 Mon Sep 17 00:00:00 2001 -From: Vinicius Aquino -Date: Thu, 1 Apr 2021 14:13:07 -0300 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= +Date: Mon, 5 Jul 2021 00:42:23 +0200 Subject: [PATCH] Do not create settings settings/property documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 @@ -15,34 +15,35 @@ Upstream-Status: Inappropriate [OE specific] Signed-off-by: Andreas Müller Signed-off-by: Vinicius Aquino --- - Makefile.am | 4 ---- + Makefile.am | 5 ----- configure.ac | 5 ----- - 2 files changed, 9 deletions(-) + 2 files changed, 10 deletions(-) diff --git a/Makefile.am b/Makefile.am -index 9279672c1..2e52acbb2 100644 +index 5a62070..3d0ebcd 100644 --- a/Makefile.am +++ b/Makefile.am -@@ -1686,14 +1686,10 @@ libnm/libnm.typelib: libnm/libnm.gir - INTROSPECTION_GIRS += libnm/NM-1.0.gir +@@ -1860,15 +1860,10 @@ src/libnm-client-impl/libnm.typelib: src/libnm-client-impl/libnm.gir + INTROSPECTION_GIRS += src/libnm-client-impl/NM-1.0.gir libnm_noinst_data = \ -- clients/cli/generate-docs-nm-settings-nmcli.xml \ - libnm/nm-property-infos-dbus.xml \ - libnm/nm-property-infos-ifcfg-rh.xml \ - libnm/nm-property-infos-keyfile.xml \ - libnm/nm-property-infos-nmcli.xml \ -- libnm/nm-settings-docs-gir.xml \ +- src/nmcli/generate-docs-nm-settings-nmcli.xml \ - man/nm-settings-docs-dbus.xml \ - man/nm-settings-docs-nmcli.xml \ + src/libnm-client-impl/nm-property-infos-dbus.xml \ + src/libnm-client-impl/nm-property-infos-ifcfg-rh.xml \ + src/libnm-client-impl/nm-property-infos-keyfile.xml \ + src/libnm-client-impl/nm-property-infos-nmcli.xml \ +- src/libnm-client-impl/nm-settings-docs-gir.xml \ +- src/libnmc-setting/settings-docs-input.xml \ $(NULL) noinst_DATA += $(libnm_noinst_data) diff --git a/configure.ac b/configure.ac -index 784ac4695..681e6cb32 100644 +index 8fe23de..dc24850 100644 --- a/configure.ac +++ b/configure.ac -@@ -1241,11 +1241,6 @@ GTK_DOC_CHECK(1.0) +@@ -1258,11 +1258,6 @@ GTK_DOC_CHECK(1.0) # check if we can build setting property documentation build_docs=no if test -n "$INTROSPECTION_MAKEFILE"; then @@ -55,5 +56,5 @@ index 784ac4695..681e6cb32 100644 if test -z "$PERL"; then AC_MSG_ERROR([--enable-introspection requires perl]) -- -2.20.1 +2.31.1 diff --git a/meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0001-Fix-build-with-musl-systemd-specific.patch b/meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0001-Fix-build-with-musl-systemd-specific.patch deleted file mode 100644 index 692f1ff..0000000 --- a/meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0001-Fix-build-with-musl-systemd-specific.patch +++ /dev/null @@ -1,154 +0,0 @@ -From 44884c7e7655b889f41cb02ffc8ab72a29b52ebf Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andreas=20M=C3=BCller?= -Date: Tue, 2 Apr 2019 01:34:35 +0200 -Subject: [PATCH 1/2] Fix build with musl - systemd specific -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Networkmanager imported some code from systemd. This requires some adjustments -for musl. - -Upstream-Status: Pending - -Signed-off-by: Andreas Müller -Signed-off-by: Vinicius Aquino ---- - shared/systemd/src/basic/in-addr-util.c | 1 + - shared/systemd/src/basic/process-util.c | 9 +++++++++ - shared/systemd/src/basic/socket-util.h | 6 ++++++ - shared/systemd/src/basic/sort-util.h | 13 ++++--------- - shared/systemd/src/basic/stdio-util.h | 2 ++ - shared/systemd/src/basic/string-util.h | 5 +++++ - 6 files changed, 27 insertions(+), 9 deletions(-) - -diff --git a/shared/systemd/src/basic/in-addr-util.c b/shared/systemd/src/basic/in-addr-util.c -index c315dcbb8..5b7e04eb7 100644 ---- a/shared/systemd/src/basic/in-addr-util.c -+++ b/shared/systemd/src/basic/in-addr-util.c -@@ -15,6 +15,7 @@ - #include "in-addr-util.h" - #include "macro.h" - #include "parse-util.h" -+#include "string-util.h" - #include "random-util.h" - #include "string-util.h" - #include "strxcpyx.h" -diff --git a/shared/systemd/src/basic/process-util.c b/shared/systemd/src/basic/process-util.c -index 0e25b0200..ea2c0fbb4 100644 ---- a/shared/systemd/src/basic/process-util.c -+++ b/shared/systemd/src/basic/process-util.c -@@ -17,6 +17,9 @@ - #include - #include - #include -+#ifndef __GLIBC__ -+#include -+#endif - #if 0 /* NM_IGNORED */ - #if HAVE_VALGRIND_VALGRIND_H - #include -@@ -1152,11 +1155,13 @@ void reset_cached_pid(void) { - cached_pid = CACHED_PID_UNSET; - } - -+#ifdef __GLIBC__ - /* We use glibc __register_atfork() + __dso_handle directly here, as they are not included in the glibc - * headers. __register_atfork() is mostly equivalent to pthread_atfork(), but doesn't require us to link against - * libpthread, as it is part of glibc anyway. */ - extern int __register_atfork(void (*prepare) (void), void (*parent) (void), void (*child) (void), void *dso_handle); - extern void* __dso_handle _weak_; -+#endif - - pid_t getpid_cached(void) { - static bool installed = false; -@@ -1185,7 +1190,11 @@ pid_t getpid_cached(void) { - * only half-documented (glibc doesn't document it but LSB does — though only superficially) - * we'll check for errors only in the most generic fashion possible. */ - -+#ifdef __GLIBC__ - if (__register_atfork(NULL, NULL, reset_cached_pid, __dso_handle) != 0) { -+#else -+ if (pthread_atfork(NULL, NULL, reset_cached_pid) != 0) { -+#endif - /* OOM? Let's try again later */ - cached_pid = CACHED_PID_UNSET; - return new_pid; -diff --git a/shared/systemd/src/basic/socket-util.h b/shared/systemd/src/basic/socket-util.h -index 1de069476..f6834fbd2 100644 ---- a/shared/systemd/src/basic/socket-util.h -+++ b/shared/systemd/src/basic/socket-util.h -@@ -14,6 +14,12 @@ - #include - #include - -+#if !defined(__GLIBC__) -+/* SIOCGSTAMPNS from linux/asm-generic.h -+ * for src/systemd/src/libsystemd-network/sd-lldp.c */ -+#include -+#endif -+ - #include "macro.h" - #include "missing_network.h" - #include "missing_socket.h" -diff --git a/shared/systemd/src/basic/sort-util.h b/shared/systemd/src/basic/sort-util.h -index a8984fc16..5fb90f8c5 100644 ---- a/shared/systemd/src/basic/sort-util.h -+++ b/shared/systemd/src/basic/sort-util.h -@@ -5,15 +5,10 @@ - - #include "macro.h" - --void *xbsearch_r(const void *key, const void *base, size_t nmemb, size_t size, -- __compar_d_fn_t compar, void *arg); -- --#define typesafe_bsearch_r(k, b, n, func, userdata) \ -- ({ \ -- const typeof(b[0]) *_k = k; \ -- int (*_func_)(const typeof(b[0])*, const typeof(b[0])*, typeof(userdata)) = func; \ -- xbsearch_r((const void*) _k, (b), (n), sizeof((b)[0]), (__compar_d_fn_t) _func_, userdata); \ -- }) -+#if !defined(__GLIBC__) -+typedef int (*__compar_fn_t) (const void*, const void*); -+typedef __compar_fn_t comparison_fn_t; -+#endif - - /** - * Normal bsearch requires base to be nonnull. Here were require -diff --git a/shared/systemd/src/basic/stdio-util.h b/shared/systemd/src/basic/stdio-util.h -index d45d3c1a6..fee1a57ca 100644 ---- a/shared/systemd/src/basic/stdio-util.h -+++ b/shared/systemd/src/basic/stdio-util.h -@@ -2,7 +2,9 @@ - #pragma once - - #if 0 /* NM_IGNORED */ -+#if defined(__GLIBC__) - #include -+#endif - #endif /* NM_IGNORED */ - #include - #include -diff --git a/shared/systemd/src/basic/string-util.h b/shared/systemd/src/basic/string-util.h -index 593cf04ae..541c393f6 100644 ---- a/shared/systemd/src/basic/string-util.h -+++ b/shared/systemd/src/basic/string-util.h -@@ -26,6 +26,11 @@ - #define strcaseeq(a,b) (strcasecmp((a),(b)) == 0) - #define strncaseeq(a, b, n) (strncasecmp((a), (b), (n)) == 0) - -+/* musl does not know strndupa */ -+#if !defined(__GLIBC__) -+#define strndupa(x,s) strncpy(alloca(strlen(x)+1),x,s) -+#endif -+ - int strcmp_ptr(const char *a, const char *b) _pure_; - int strcasecmp_ptr(const char *a, const char *b) _pure_; - --- -2.20.1 - diff --git a/meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0002-Fix-build-with-musl-systemd-specific.patch b/meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0002-Fix-build-with-musl-systemd-specific.patch deleted file mode 100644 index d83efd3..0000000 --- a/meta-gnome/recipes-connectivity/networkmanager/networkmanager/musl/0002-Fix-build-with-musl-systemd-specific.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 7d9a11a17da425d106791ada7100d7a6559e6065 Mon Sep 17 00:00:00 2001 -From: Adrian Freihofer -Date: Sat, 7 Mar 2020 14:24:01 +0100 -Subject: [PATCH 2/2] Fix build with musl - systemd specific - ---- - src/core/systemd/src/libsystemd-network/sd-dhcp6-client.c | 2 ++ - 1 file changed, 2 insertions(+) - -diff --git a/src/core/systemd/src/libsystemd-network/sd-dhcp6-client.c b/src/core/systemd/src/libsystemd-network/sd-dhcp6-client.c -index 3fafd3c0e..79d6096c2 100644 ---- a/src/core/systemd/src/libsystemd-network/sd-dhcp6-client.c -+++ b/src/core/systemd/src/libsystemd-network/sd-dhcp6-client.c -@@ -8,7 +8,9 @@ - #include - #include - #if 0 /* NM_IGNORED */ -+#ifdef __GLIBC__ /* musl supplies full set of userspace headers */ - #include -+#endif - #else /* NM_IGNORED */ - #include - #endif /* NM_IGNORED */ --- -2.20.1 - diff --git a/meta-gnome/recipes-connectivity/networkmanager/networkmanager_1.30.2.bb b/meta-gnome/recipes-connectivity/networkmanager/networkmanager_1.32.10.bb similarity index 94% rename from meta-gnome/recipes-connectivity/networkmanager/networkmanager_1.30.2.bb rename to meta-gnome/recipes-connectivity/networkmanager/networkmanager_1.32.10.bb index ec3bdd2..cc4293b 100644 --- a/meta-gnome/recipes-connectivity/networkmanager/networkmanager_1.30.2.bb +++ b/meta-gnome/recipes-connectivity/networkmanager/networkmanager_1.32.10.bb @@ -27,11 +27,7 @@ SRC_URI = " \ file://0002-Do-not-create-settings-settings-property-documentati.patch \ file://0003-install-firewalld-to-var-libdir-rather-than-hardcod-.patch \ " -SRC_URI_append_libc-musl = " \ - file://musl/0001-Fix-build-with-musl-systemd-specific.patch \ - file://musl/0002-Fix-build-with-musl-systemd-specific.patch \ -" -SRC_URI[sha256sum] = "0c8e80e77877860e4a4e6ab4a0f7cdc1186e356b65b042a751897188b88944d2" +SRC_URI[sha256sum] = "3e5ccc66805659e3f11a718e3a599f9726b79a01d6ff14814be6ad8bc5da8bb8" S = "${WORKDIR}/NetworkManager-${PV}" @@ -56,13 +52,14 @@ CFLAGS_append_libc-musl = " \ " do_compile_prepend() { - export GIR_EXTRA_LIBS_PATH="${B}/libnm/.libs:${B}/libnm-glib/.libs:${B}/libnm-util/.libs" + export GIR_EXTRA_LIBS_PATH="${B}/src/libnm-client-impl/.libs" } PACKAGECONFIG ??= "nss ifupdown dnsmasq nmcli \ ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', bb.utils.contains('DISTRO_FEATURES', 'x11', 'consolekit', '', d), d)} \ ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez5', '', d)} \ ${@bb.utils.filter('DISTRO_FEATURES', 'wifi polkit', d)} \ + ${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'selinux audit', '', d)} \ " inherit ${@bb.utils.contains('PACKAGECONFIG', 'nmcli', 'bash-completion', '', d)} @@ -87,6 +84,8 @@ PACKAGECONFIG[qt4-x11-free] = "--enable-qt,--disable-qt,qt4-x11-free" PACKAGECONFIG[cloud-setup] = "--with-nm-cloud-setup=yes,--with-nm-cloud-setup=no" PACKAGECONFIG[nmcli] = "--with-nmcli=yes,--with-nmcli=no,readline" PACKAGECONFIG[ovs] = "--enable-ovs,--disable-ovs,jansson" +PACKAGECONFIG[audit] = "--with-libaudit,--without-libaudit,audit" +PACKAGECONFIG[selinux] = "--with-selinux,--without-selinux,libselinux" PACKAGES =+ " \ ${PN}-nmcli ${PN}-nmcli-doc \ diff --git a/meta-gnome/recipes-freedesktop/colord/colord-native/0001-Move-the-function-cd_icc_create_from_edid-to-avoid-u.patch b/meta-gnome/recipes-freedesktop/colord/colord-native/0001-Move-the-function-cd_icc_create_from_edid-to-avoid-u.patch index bc4729a..aae2be8 100644 --- a/meta-gnome/recipes-freedesktop/colord/colord-native/0001-Move-the-function-cd_icc_create_from_edid-to-avoid-u.patch +++ b/meta-gnome/recipes-freedesktop/colord/colord-native/0001-Move-the-function-cd_icc_create_from_edid-to-avoid-u.patch @@ -1,12 +1,7 @@ -From e11dedcf3dc5514f4116e861a19d321dd802c0cd Mon Sep 17 00:00:00 2001 +From cbb8f5c05fce1d56ae2e5fa9f57fc49c47bed5ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20M=C3=BCller?= Date: Sun, 12 May 2019 21:58:02 +0200 Subject: [PATCH] Move the function cd_icc_create_from_edid to avoid udev -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -From: =?UTF-8?q?Andreas=20M=C3=BCller?= dependeny MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 @@ -17,7 +12,6 @@ We do not have udev-native so it is a dependeny we cannot satisfy Upstream-Status: Inappropriate [OE specific] Signed-off-by: Andreas Müller - --- lib/colord/cd-edid.c | 63 ++++++++++++++++++++++++++++++++++++++++++++ lib/colord/cd-icc.c | 62 ------------------------------------------- @@ -167,3 +161,6 @@ index 8beec43..398ff7a 100644 /** * cd_icc_create_from_edid: * @icc: A valid #CdIcc +-- +2.20.1 + diff --git a/meta-gnome/recipes-freedesktop/colord/colord.bb b/meta-gnome/recipes-freedesktop/colord/colord.bb index 214338e..f514c0b 100644 --- a/meta-gnome/recipes-freedesktop/colord/colord.bb +++ b/meta-gnome/recipes-freedesktop/colord/colord.bb @@ -1,8 +1,9 @@ require ${BPN}.inc -inherit meson gobject-introspection gsettings gettext bash-completion systemd useradd +inherit meson gobject-introspection gsettings gettext bash-completion systemd features_check useradd # polkit and gobject-introspection are mandatory and cannot be configured +REQUIRED_DISTRO_FEATURES = "polkit gobject-introspection-data" UNKNOWN_CONFIGURE_WHITELIST_append = " introspection" DEPENDS += " \ @@ -35,7 +36,7 @@ FILES_${PN} += " \ ${datadir}/glib-2.0 \ ${datadir}/color \ ${systemd_user_unitdir} \ - ${libdir}/tmpfiles.d \ + ${nonarch_libdir}/tmpfiles.d \ ${libdir}/colord-plugins \ ${libdir}/colord-sensors \ " diff --git a/meta-gnome/recipes-freedesktop/colord/colord.inc b/meta-gnome/recipes-freedesktop/colord/colord.inc index 1191aec..09e600c 100644 --- a/meta-gnome/recipes-freedesktop/colord/colord.inc +++ b/meta-gnome/recipes-freedesktop/colord/colord.inc @@ -8,6 +8,5 @@ LIC_FILES_CHKSUM = " \ PV = "1.4.5" SRC_URI = "https://www.freedesktop.org/software/colord/releases/${BPN}-${PV}.tar.xz" -SRC_URI[md5sum] = "adc4501b54fb8667ee99f64cff87e12d" SRC_URI[sha256sum] = "b774ea443d239f4a2ee1853bd678426e669ddeda413dcb71cea1638c4d6c5e17" diff --git a/meta-gnome/recipes-freedesktop/libgusb/libgusb_0.2.11.bb b/meta-gnome/recipes-freedesktop/libgusb/libgusb_0.2.11.bb deleted file mode 100644 index c81a8f3..0000000 --- a/meta-gnome/recipes-freedesktop/libgusb/libgusb_0.2.11.bb +++ /dev/null @@ -1,14 +0,0 @@ -SUMMARY = "GObject wrapper for libusb1" -LICENSE = "LGPLv2.1" -LIC_FILES_CHKSUM = "file://COPYING;md5=2d5025d4aa3495befef8f17206a5b0a1" - -SRC_URI = "https://people.freedesktop.org/~hughsient/releases/libgusb-${PV}.tar.xz" -SRC_URI[md5sum] = "fa2b41b828c749f9190edf888948a77b" -SRC_URI[sha256sum] = "9cb143493fab1dc3d0d0fdba2114b1d8ec8c5b6fad05bfd0f7700e4e4ff8f7de" - -DEPENDS = "glib-2.0 libusb1" - -inherit pkgconfig autotools gobject-introspection - -EXTRA_OECONF = "--disable-static --disable-gtk-doc" -BBCLASSEXTEND="native" diff --git a/meta-gnome/recipes-freedesktop/libgusb/libgusb_0.3.7.bb b/meta-gnome/recipes-freedesktop/libgusb/libgusb_0.3.7.bb new file mode 100644 index 0000000..c737fec --- /dev/null +++ b/meta-gnome/recipes-freedesktop/libgusb/libgusb_0.3.7.bb @@ -0,0 +1,11 @@ +SUMMARY = "GUsb is a GObject wrapper for libusb1" +LICENSE = "LGPLv2.1" +LIC_FILES_CHKSUM = "file://COPYING;md5=2d5025d4aa3495befef8f17206a5b0a1" + +DEPENDS = "glib-2.0 libusb1" + +inherit meson gobject-introspection gtk-doc gettext vala + +SRC_URI = "git://github.com/hughsie/libgusb.git" +SRCREV = "ff9c606d9d72c7dd369ad220d92729556faaaf0c" +S = "${WORKDIR}/git" diff --git a/meta-gnome/recipes-freedesktop/plymouth/plymouth.bb b/meta-gnome/recipes-freedesktop/plymouth/plymouth.bb index bb3cb47..952f994 100644 --- a/meta-gnome/recipes-freedesktop/plymouth/plymouth.bb +++ b/meta-gnome/recipes-freedesktop/plymouth/plymouth.bb @@ -19,7 +19,7 @@ RPROVIDES_${PN} = "virtual-psplash virtual-psplash-support" SRCREV = "e55447500fa95a0cc59c741296030ed91a2986dc" SRC_URI = " \ - git://gitlab.freedesktop.org/plymouth/plymouth.git;branch=master;protocol=https \ + git://gitlab.freedesktop.org/plymouth/plymouth.git;branch=main;protocol=https \ file://0001-Make-full-path-to-systemd-tty-ask-password-agent-con.patch \ " S = "${WORKDIR}/git" diff --git a/meta-gnome/recipes-freedesktop/upower/upower_0.99.11.bb b/meta-gnome/recipes-freedesktop/upower/upower_0.99.13.bb similarity index 74% rename from meta-gnome/recipes-freedesktop/upower/upower_0.99.11.bb rename to meta-gnome/recipes-freedesktop/upower/upower_0.99.13.bb index d6c89a6..da0ef82 100644 --- a/meta-gnome/recipes-freedesktop/upower/upower_0.99.11.bb +++ b/meta-gnome/recipes-freedesktop/upower/upower_0.99.13.bb @@ -4,13 +4,16 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=0de8fbf1d97a140d1d93b9f14dcfbf08" DEPENDS = "intltool-native libusb1 libgudev glib-2.0 dbus-glib" +# Version 0.99.13 +SRCREV = "0f6cc0a10be22d7ddd684e1cd851e4364a440494" SRC_URI = " \ - http://upower.freedesktop.org/releases/${BPN}-${PV}.tar.xz \ + git://gitlab.freedesktop.org/upower/upower.git;branch=master;protocol=https \ " -SRC_URI[md5sum] = "abe6acb617f11f2e8dbd9846fcf86e24" -SRC_URI[sha256sum] = "64b5ffbfccd5bdb15d925777979a4dbee1a957f9eaeb158dc76175267eddbdef" -inherit autotools pkgconfig gettext gobject-introspection systemd +S = "${WORKDIR}/git" + + +inherit autotools pkgconfig gettext gobject-introspection systemd gtk-doc PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" PACKAGECONFIG[idevice] = "--with-idevice,--without-idevice,libimobiledevice libplist" @@ -24,8 +27,12 @@ SYSTEMD_SERVICE_${PN} = "upower.service" SYSTEMD_AUTO_ENABLE = "disable" do_configure_prepend() { - sed -i -e s:-nonet:\:g ${S}/doc/man/Makefile.am - sed -i -e 's: doc : :g' ${S}/Makefile.am + touch ${S}/ABOUT-NLS + mkdir -p ${S}/build-aux + touch ${S}/build-aux/config.rpath + + #sed -i -e s:-nonet:\:g ${S}/doc/man/Makefile.am + #sed -i -e 's: doc : :g' ${S}/Makefile.am } RDEPENDS_${PN} += "dbus" diff --git a/meta-gnome/recipes-gnome/gdm/gdm_40.0.bb b/meta-gnome/recipes-gnome/gdm/gdm_41.0.bb similarity index 94% rename from meta-gnome/recipes-gnome/gdm/gdm_40.0.bb rename to meta-gnome/recipes-gnome/gdm/gdm_41.0.bb index 3dbef78..552855d 100644 --- a/meta-gnome/recipes-gnome/gdm/gdm_40.0.bb +++ b/meta-gnome/recipes-gnome/gdm/gdm_41.0.bb @@ -24,7 +24,7 @@ def gnome_verdir(v): SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive" -SRC_URI[archive.sha256sum] = "5ed74b739d3a232ffb1e4a132bcf965bdfe955d995b528773588775b02f2950e" +SRC_URI[archive.sha256sum] = "5738c4293a9f5a80d4a6e9e06f4d0df3e9f313ca7b61bfb4d8afaba983e200dc" SRC_URI += "file://gdm.conf" diff --git a/meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch b/meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch index f418333..58ebe67 100644 --- a/meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch +++ b/meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch @@ -1,17 +1,17 @@ -From 462ed3afdfc6988daf79448558f5433ea773e64c Mon Sep 17 00:00:00 2001 -From: David McKinney -Date: Thu, 2 Jul 2020 14:52:35 +0000 +From a8011c5037a8807bb592b5d9e7e9f73be1e185e6 Mon Sep 17 00:00:00 2001 +From: Bruce Leidl +Date: Tue, 5 Oct 2021 12:37:53 +0000 Subject: [PATCH] Fix tests that cannot run --- - meson.build | 36 ++++++++++++++++++------------------ - 1 file changed, 18 insertions(+), 18 deletions(-) + meson.build | 28 ---------------------------- + 1 file changed, 28 deletions(-) diff --git a/meson.build b/meson.build -index 9ab29475..3dbadcf1 100644 +index 6ded66c..3753b9f 100644 --- a/meson.build +++ b/meson.build -@@ -233,27 +233,6 @@ release builds of SpiderMonkey. Try configuring SpiderMonkey with +@@ -234,27 +234,6 @@ release builds of SpiderMonkey. Try configuring SpiderMonkey with --disable-debug.''') endif @@ -39,14 +39,17 @@ index 9ab29475..3dbadcf1 100644 have_printf_alternative_int = cc.compiles(''' #include int main(void) { -@@ -628,8 +607,6 @@ if not get_option('skip_gtk_tests') +@@ -656,13 +635,6 @@ if not get_option('skip_gtk_tests') have_gtk4 = dependency('gtk4', required: false).found() endif -subdir('installed-tests') - +-# Note: The test program in test/ needs to be ported +-# to Windows before we can build it on Windows. +-if host_machine.system() != 'windows' +- subdir('test') +-endif + valgrind_environment = environment() valgrind_environment.set('G_SLICE', 'always-malloc,debug-blocks') - valgrind_environment.set('G_DEBUG', - - diff --git a/meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch.bak b/meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch.bak new file mode 100644 index 0000000..2de0c4e --- /dev/null +++ b/meta-gnome/recipes-gnome/gjs/gjs/0001-Fix-tests-that-cannot-run.patch.bak @@ -0,0 +1,50 @@ +From cb34a340e47a2c85830346aa3ebeb7e2c278c6c4 Mon Sep 17 00:00:00 2001 +From: Bruce Leidl +Date: Tue, 5 Oct 2021 11:58:42 +0000 +Subject: [PATCH] Fix tests that cannot run + +--- + meson.build | 23 ----------------------- + 1 file changed, 23 deletions(-) + +diff --git a/meson.build b/meson.build +index 6ded66c..3bd6142 100644 +--- a/meson.build ++++ b/meson.build +@@ -234,27 +234,6 @@ release builds of SpiderMonkey. Try configuring SpiderMonkey with + --disable-debug.''') + endif + +-# 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. +-minimal_program = cxx.run(''' +-#include +-int main(void) { +- if (!JS_Init()) return 1; +- JS_ShutDown(); +- return 0; +-} +-''', +- args: debug_arg, dependencies: spidermonkey, +- name: 'SpiderMonkey sanity check') +- +-if not minimal_program.compiled() or minimal_program.returncode() != 0 +- error('''A minimal SpiderMonkey program +-could not be compiled, linked, or run. Most likely you should build it with a +-different configuration. Check the recommended configuration: +-https://github.com/spidermonkey-embedders/spidermonkey-embedding-examples/blob/esr78/docs/Building%20SpiderMonkey.md''') +-endif +- + have_printf_alternative_int = cc.compiles(''' + #include + int main(void) { +@@ -656,8 +635,6 @@ if not get_option('skip_gtk_tests') + have_gtk4 = dependency('gtk4', required: false).found() + endif + +-subdir('installed-tests') +- + # Note: The test program in test/ needs to be ported + # to Windows before we can build it on Windows. + if host_machine.system() != 'windows' diff --git a/meta-gnome/recipes-gnome/gjs/gjs_1.68.0.bb b/meta-gnome/recipes-gnome/gjs/gjs_1.70.0.bb similarity index 71% rename from meta-gnome/recipes-gnome/gjs/gjs_1.68.0.bb rename to meta-gnome/recipes-gnome/gjs/gjs_1.70.0.bb index 677a478..4f8aa6e 100644 --- a/meta-gnome/recipes-gnome/gjs/gjs_1.68.0.bb +++ b/meta-gnome/recipes-gnome/gjs/gjs_1.70.0.bb @@ -6,17 +6,15 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=8dcea832f6acf45d856abfeb2d51ec48" inherit gnomebase gettext gobject-introspection meson -ERROR_QA_remove = "unknown-configure-option" - -export GIDATADIR="${STAGING_DATADIR_NATIVE}/gobject-introspection-1.0" +UNKNOWN_CONFIGURE_WHITELIST_append = " introspection" DEPENDS = "glib-2.0 gobject-introspection gobject-introspection-native cairo gtk+3 mozjs78 glib-2.0-native" -EXTRA_OEMESON = " -Dskip_dbus_tests=true -Dskip_gtk_tests=true -Dinstalled_tests=false -Dpkgconfig-sysroot-path=${GIDATADIR}" +EXTRA_OEMESON = " -Dskip_dbus_tests=true -Dskip_gtk_tests=true -Dinstalled_tests=false" CFLAGS_append = " -include ${STAGING_INCDIR}/mozjs-78/js/RequiredDefines.h" SRC_URI += " file://0001-Fix-tests-that-cannot-run.patch" -SRC_URI[archive.sha256sum] = "f00e74a00e81ab61bb92669e0f1c8bb613cc019586097f06aed0572efcaf1aef" +SRC_URI[archive.sha256sum] = "4b0629341a318a02374e113ab97f9a9f3325423269fc1e0b043a5ffb01861c5f" RDEPENDS_${PN} += "libmozjs-78" diff --git a/meta-gnome/recipes-gnome/glib-2.0/glib-2.0_2.68.0.bb b/meta-gnome/recipes-gnome/glib-2.0/glib-2.0_2.70.0.bb similarity index 93% rename from meta-gnome/recipes-gnome/glib-2.0/glib-2.0_2.68.0.bb rename to meta-gnome/recipes-gnome/glib-2.0/glib-2.0_2.70.0.bb index 94d2431..4010f29 100644 --- a/meta-gnome/recipes-gnome/glib-2.0/glib-2.0_2.68.0.bb +++ b/meta-gnome/recipes-gnome/glib-2.0/glib-2.0_2.70.0.bb @@ -7,7 +7,6 @@ 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://Enable-more-tests-while-cross-compiling.patch \ file://0001-Remove-the-warning-about-deprecated-paths-in-schemas.patch \ file://0001-Install-gio-querymodules-as-libexec_PROGRAM.patch \ file://0001-Do-not-ignore-return-value-of-write.patch \ @@ -20,7 +19,7 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \ " SRC_URI_append_class-native = " file://relocate-modules.patch" -SRC_URI[sha256sum] = "67734f584f3a05a2872f57e9a8db38f3b06c7087fb531c5a839d9171968103ea" +SRC_URI[sha256sum] = "200d7df811c5ba634afbf109f14bb40ba7fde670e89389885da14e27c0840742" # Find any meson cross files in FILESPATH that are relevant for the current # build (using siteinfo) and add them to EXTRA_OEMESON. diff --git a/meta-gnome/recipes-gnome/glib-2.0/glib.inc b/meta-gnome/recipes-gnome/glib-2.0/glib.inc index 71777bc..10d5938 100644 --- a/meta-gnome/recipes-gnome/glib-2.0/glib.inc +++ b/meta-gnome/recipes-gnome/glib-2.0/glib.inc @@ -2,14 +2,12 @@ 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 = "LGPLv2.1+ & BSD & PD" LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c \ file://glib/glib.h;beginline=4;endline=17;md5=b88abb7f3ad09607e71cb9d530155906 \ file://gmodule/COPYING;md5=4fbd65380cdd255951079008b364516c \ file://gmodule/gmodule.h;beginline=4;endline=17;md5=b88abb7f3ad09607e71cb9d530155906 \ - file://glib/pcre/pcre.h;beginline=8;endline=36;md5=3e2977dae4ad05217f58c446237298fc \ file://docs/reference/COPYING;md5=f51a5100c17af6bae00735cd791e1fcc" BUGTRACKER = "http://bugzilla.gnome.org" SECTION = "libs" @@ -22,6 +20,7 @@ DEPENDS = "glib-2.0-native \ virtual/libintl \ virtual/libiconv \ libffi \ + libpcre \ zlib" PACKAGES += "${PN}-codegen ${PN}-utils" @@ -36,10 +35,8 @@ GTKDOC_MESON_OPTION = "gtk_doc" S = "${WORKDIR}/glib-${PV}" -PACKAGECONFIG ??= "system-pcre libmount \ +PACKAGECONFIG ??= "libmount \ ${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)}" -# To use the system pcre it must be configured with --enable-unicode-properties -PACKAGECONFIG[system-pcre] = "-Dinternal_pcre=false,-Dinternal_pcre=true,libpcre" PACKAGECONFIG[libmount] = "-Dlibmount=enabled,-Dlibmount=disabled,util-linux" PACKAGECONFIG[manpages] = "-Dman=true, -Dman=false, libxslt-native xmlto-native" # libelf is auto-detected without a configuration option diff --git a/meta-gnome/recipes-gnome/gnome-backgrounds/gnome-backgrounds_40.0.bb b/meta-gnome/recipes-gnome/gnome-backgrounds/gnome-backgrounds_41.0.bb similarity index 83% rename from meta-gnome/recipes-gnome/gnome-backgrounds/gnome-backgrounds_40.0.bb rename to meta-gnome/recipes-gnome/gnome-backgrounds/gnome-backgrounds_41.0.bb index bb85442..c482944 100644 --- a/meta-gnome/recipes-gnome/gnome-backgrounds/gnome-backgrounds_40.0.bb +++ b/meta-gnome/recipes-gnome/gnome-backgrounds/gnome-backgrounds_41.0.bb @@ -11,7 +11,7 @@ def gnome_verdir(v): SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive" -SRC_URI[archive.sha256sum] = "46c3133a5ed7180347ae396962bf8827085f0f3b7cd9385452d623c4a167a2f6" +SRC_URI[archive.sha256sum] = "1da1ac0d261bedf0fcd2c85b480bc65505e23cf51f1143126c0d37717e693145" FILES_${PN} += "\ ${datadir}/backgrounds/gnome \ diff --git a/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch b/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch index 8d12d87..f131d3c 100644 --- a/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch +++ b/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch @@ -1,21 +1,20 @@ -From 379b93699b428ccb49f0d48ed1366a67f9ab5ffc Mon Sep 17 00:00:00 2001 +From 408e0ab8df0b7e98b642228a91ac1072196df36b Mon Sep 17 00:00:00 2001 From: Bruce Leidl -Date: Tue, 27 Oct 2020 16:43:34 -0400 +Date: Wed, 6 Oct 2021 14:28:02 -0400 Subject: [PATCH] Add options for Citadel and disabling GOA/CUPS --- - meson.build | 14 +++++++++++++ - meson_options.txt | 5 +++++ - panels/background/bg-pictures-source.c | 21 ++++++++++++++++--- - panels/background/meson.build | 15 ++++++++++---- - panels/meson.build | 23 ++++++++++++++------- - shell/cc-panel-list.c | 15 +++++++++++++- - shell/cc-panel-loader.c | 28 ++++++++++++++++++++++++++ - tests/meson.build | 2 +- - 8 files changed, 107 insertions(+), 16 deletions(-) + meson.build | 14 ++++++++++++++ + meson_options.txt | 5 +++++ + panels/background/meson.build | 4 +++- + panels/meson.build | 23 ++++++++++++++++------- + shell/cc-panel-list.c | 14 ++++++++++++++ + shell/cc-panel-loader.c | 28 ++++++++++++++++++++++++++++ + tests/meson.build | 2 +- + 7 files changed, 81 insertions(+), 9 deletions(-) diff --git a/meson.build b/meson.build -index 9002169..a2106f6 100644 +index 1ee69c5..a5a5243 100644 --- a/meson.build +++ b/meson.build @@ -114,6 +114,15 @@ if not libhandy_dep.found() @@ -35,13 +34,13 @@ index 9002169..a2106f6 100644 pulse_req_version = '>= 2.0' @@ -124,7 +133,9 @@ gio_dep = dependency('gio-2.0') - glib_dep = dependency('glib-2.0', version: '>= 2.56.0') + glib_dep = dependency('glib-2.0', version: '>= 2.68.0') gnome_desktop_dep = dependency('gnome-desktop-3.0', version: '>= 3.33.4') gnome_settings_dep = dependency('gnome-settings-daemon', version: '>= 3.27.90') +if enable_goa goa_dep = dependency('goa-1.0', version: goa_req_version) +endif - gsettings_desktop_dep = dependency('gsettings-desktop-schemas', version: '>= 3.37.1') + gsettings_desktop_dep = dependency('gsettings-desktop-schemas', version: '>= 40.alpha') libxml_dep = dependency('libxml-2.0') polkit_gobject_dep = dependency('polkit-gobject-1', version: '>= 0.114') @@ -149,6 +160,8 @@ common_deps = [ @@ -74,124 +73,8 @@ index 1b7b548..8dd1b33 100644 +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/background/bg-pictures-source.c b/panels/background/bg-pictures-source.c -index 3a3027b..a973b78 100644 ---- a/panels/background/bg-pictures-source.c -+++ b/panels/background/bg-pictures-source.c -@@ -29,7 +29,9 @@ - #include - #include - #include -+#ifdef WITH_GOA - #include -+#endif - #include - #include - -@@ -43,8 +45,9 @@ struct _BgPicturesSource - - GCancellable *cancellable; - -+#ifdef WITH_GOA - CcBackgroundGriloMiner *grl_miner; -- -+#endif - GFileMonitor *picture_dir_monitor; - GFileMonitor *cache_dir_monitor; - -@@ -83,8 +86,9 @@ bg_pictures_source_dispose (GObject *object) - g_clear_object (&source->cancellable); - } - -+#ifdef WITH_GOA - g_clear_object (&source->grl_miner); -- -+#endif - G_OBJECT_CLASS (bg_pictures_source_parent_class)->dispose (object); - } - -@@ -392,7 +396,9 @@ add_single_file (BgPicturesSource *bg_source, - const gchar *pictures_path; - g_autoptr(GFile) pictures_dir = NULL; - g_autoptr(GFile) cache_dir = NULL; -+#ifdef WITH_GOA - GrlMedia *media; -+#endif - - /* find png and jpeg files */ - if (!content_type) -@@ -432,13 +438,16 @@ add_single_file (BgPicturesSource *bg_source, - "source-url", source_uri, - NULL); - -+#ifdef WITH_GOA - media = g_object_get_data (G_OBJECT (file), "grl-media"); - if (media == NULL) - { -+#endif - g_object_set_data_full (G_OBJECT (file), "item", g_object_ref (item), g_object_unref); - g_file_read_async (file, G_PRIORITY_DEFAULT, - bg_source->cancellable, - picture_opened_for_read, bg_source); -+#ifdef WITH_GOA - } - else - { -@@ -476,7 +485,7 @@ add_single_file (BgPicturesSource *bg_source, - picture_copied_for_read, - bg_source); - } -- -+#endif - retval = TRUE; - - out: -@@ -496,6 +505,7 @@ add_single_file_from_info (BgPicturesSource *bg_source, - return add_single_file (bg_source, file, content_type, mtime); - } - -+#ifdef WITH_GOA - static gboolean - add_single_file_from_media (BgPicturesSource *bg_source, - GFile *file, -@@ -520,6 +530,7 @@ add_single_file_from_media (BgPicturesSource *bg_source, - - return add_single_file (bg_source, file, content_type, (guint64) mtime_unix); - } -+#endif - - gboolean - bg_pictures_source_add (BgPicturesSource *bg_source, -@@ -804,6 +815,7 @@ monitor_path (BgPicturesSource *self, - return monitor; - } - -+#ifdef WITH_GOA - static void - media_found_cb (BgPicturesSource *self, GrlMedia *media) - { -@@ -815,6 +827,7 @@ media_found_cb (BgPicturesSource *self, GrlMedia *media) - g_object_set_data_full (G_OBJECT (file), "grl-media", g_object_ref (media), g_object_unref); - add_single_file_from_media (self, file, media); - } -+#endif - - static void - bg_pictures_source_init (BgPicturesSource *self) -@@ -837,9 +850,11 @@ bg_pictures_source_init (BgPicturesSource *self) - cache_path = bg_pictures_source_get_cache_path (); - self->cache_dir_monitor = monitor_path (self, cache_path); - -+#ifdef WITH_GOA - self->grl_miner = cc_background_grilo_miner_new (); - g_signal_connect_object (self->grl_miner, "media-found", G_CALLBACK (media_found_cb), self, G_CONNECT_SWAPPED); - cc_background_grilo_miner_start (self->grl_miner); -+#endif - } - - BgPicturesSource * diff --git a/panels/background/meson.build b/panels/background/meson.build -index e9fa398..534b999 100644 +index eb5e9ec..ee52d12 100644 --- a/panels/background/meson.build +++ b/panels/background/meson.build @@ -34,9 +34,11 @@ install_data( @@ -207,39 +90,8 @@ index e9fa398..534b999 100644 'cc-background-item.h' ) -@@ -81,22 +83,27 @@ sources = common_sources + files( - 'bg-source.c', - 'bg-wallpapers-source.c', - 'cc-background-chooser.c', -- 'cc-background-grilo-miner.c', - 'cc-background-item.c', - 'cc-background-panel.c', - 'cc-background-preview.c', - 'cc-background-xml.c', - ) - -+if enable_goa -+sources += files('cc-background-grilo-miner.c') -+endif -+ - deps = common_deps + [ - gdk_pixbuf_dep, - gnome_desktop_dep, -- goa_dep, - libxml_dep, - dependency('cairo-gobject'), -- dependency('grilo-0.3', version: '>= 0.3.0') - ] - -+if enable_goa -+deps += [ goa_dep, dependency('grilo-0.3', version: '>= 0.3.0') ] -+endif -+ - cflags += [ - '-DDATADIR="@0@"'.format(control_center_datadir), - '-DGNOME_DESKTOP_USE_UNSTABLE_API' diff --git a/panels/meson.build b/panels/meson.build -index 2f4fdc5..82f54bd 100644 +index f603db9..943210f 100644 --- a/panels/meson.build +++ b/panels/meson.build @@ -1,12 +1,10 @@ @@ -255,9 +107,9 @@ index 2f4fdc5..82f54bd 100644 'diagnostics', 'display', 'info-overview', -@@ -16,17 +14,12 @@ panels = [ - 'microphone', +@@ -17,17 +15,12 @@ panels = [ 'mouse', + 'multitasking', 'notifications', - 'online-accounts', 'power', @@ -269,11 +121,11 @@ index 2f4fdc5..82f54bd 100644 'sound', 'universal-access', 'usage', -- 'user-accounts' +- 'user-accounts', + 'wwan', ] - if host_is_linux -@@ -41,6 +34,22 @@ if host_is_linux_not_s390 +@@ -43,6 +36,22 @@ if host_is_linux_not_s390 ] endif @@ -297,13 +149,13 @@ index 2f4fdc5..82f54bd 100644 panels_libs = [] foreach cappletname: panels diff --git a/shell/cc-panel-list.c b/shell/cc-panel-list.c -index e23da0b..b6aacfb 100644 +index c5532ba..75be10d 100644 --- a/shell/cc-panel-list.c +++ b/shell/cc-panel-list.c -@@ -386,11 +386,16 @@ static const gchar * const panel_order[] = { - "background", +@@ -388,10 +388,16 @@ static const gchar * const panel_order[] = { "notifications", "search", + "multitasking", +#ifndef CITADEL "applications", +#endif @@ -313,12 +165,11 @@ index e23da0b..b6aacfb 100644 +#endif +#ifndef CITADEL "sharing", -- +#endif + /* Privacy page */ "location", - "camera", -@@ -406,16 +411,24 @@ static const gchar * const panel_order[] = { +@@ -408,16 +414,24 @@ static const gchar * const panel_order[] = { "display", "mouse", "keyboard", @@ -344,7 +195,7 @@ index e23da0b..b6aacfb 100644 "datetime", "info-overview", diff --git a/shell/cc-panel-loader.c b/shell/cc-panel-loader.c -index f203843..cad01f5 100644 +index 67f3f1b..4b595af 100644 --- a/shell/cc-panel-loader.c +++ b/shell/cc-panel-loader.c @@ -31,14 +31,18 @@ @@ -366,7 +217,7 @@ index f203843..cad01f5 100644 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); -@@ -48,19 +52,29 @@ extern GType cc_network_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); @@ -396,7 +247,7 @@ index f203843..cad01f5 100644 #ifdef BUILD_WACOM extern GType cc_wacom_panel_get_type (void); #endif /* BUILD_WACOM */ -@@ -90,7 +104,9 @@ extern void cc_wacom_panel_static_init_func (void); +@@ -97,7 +111,9 @@ extern void cc_wwan_panel_static_init_func (void); static CcPanelLoaderVtable default_panels[] = { @@ -406,7 +257,7 @@ index f203843..cad01f5 100644 PANEL_TYPE("background", cc_background_panel_get_type, NULL), #ifdef BUILD_BLUETOOTH PANEL_TYPE("bluetooth", cc_bluetooth_panel_get_type, NULL), -@@ -98,7 +114,9 @@ static CcPanelLoaderVtable default_panels[] = +@@ -105,7 +121,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), @@ -416,7 +267,7 @@ index f203843..cad01f5 100644 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), -@@ -112,20 +130,30 @@ static CcPanelLoaderVtable default_panels[] = +@@ -120,20 +138,30 @@ 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), diff --git a/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch.blah b/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch.blah new file mode 100644 index 0000000..e50a484 --- /dev/null +++ b/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center/0001-Add-options-for-Citadel-and-disabling-GOA-CUPS.patch.blah @@ -0,0 +1,293 @@ +From d7283acccea0a26c1236e757a186221cf9177cff Mon Sep 17 00:00:00 2001 +From: Bruce Leidl +Date: Wed, 6 Oct 2021 14:19:27 -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 1ee69c5..a5a5243 100644 +--- a/meson.build ++++ b/meson.build +@@ -114,6 +114,15 @@ if not libhandy_dep.found() + libhandy_dep = libhandy.get_variable('libhandy_dep') + endif + ++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' + +@@ -124,7 +133,9 @@ gio_dep = dependency('gio-2.0') + glib_dep = dependency('glib-2.0', version: '>= 2.68.0') + gnome_desktop_dep = dependency('gnome-desktop-3.0', version: '>= 3.33.4') + gnome_settings_dep = dependency('gnome-settings-daemon', version: '>= 3.27.90') ++if enable_goa + goa_dep = dependency('goa-1.0', version: goa_req_version) ++endif + gsettings_desktop_dep = dependency('gsettings-desktop-schemas', version: '>= 40.alpha') + libxml_dep = dependency('libxml-2.0') + polkit_gobject_dep = dependency('polkit-gobject-1', version: '>= 0.114') +@@ -149,6 +160,8 @@ common_deps = [ + ] + + # 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') + +@@ -171,6 +184,7 @@ endforeach + config_h.set10('HAVE_CUPS_HTTPCONNECT2', + cc.has_function('httpConnect2', dependencies: cups_dep), + description: 'Define if httpConnect2() is available in CUPS') ++endif + + # Optional dependency for the user accounts panel + enable_cheese = get_option('cheese') +diff --git a/meson_options.txt b/meson_options.txt +index 1b7b548..8dd1b33 100644 +--- a/meson_options.txt ++++ b/meson_options.txt +@@ -8,3 +8,8 @@ option('tracing', type: 'boolean', value: false, description: 'add extra debuggi + option('wayland', type: 'boolean', value: true, description: 'build with Wayland support') + option('profile', type: 'combo', choices: ['default','development'], value: 'default') + option('malcontent', type: 'boolean', value: false, description: 'build with malcontent support') ++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 f603db9..943210f 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', + 'info-overview', +@@ -17,17 +15,12 @@ panels = [ + 'mouse', + 'multitasking', + 'notifications', +- 'online-accounts', + 'power', +- 'printers', + 'region', +- 'removable-media', + 'search', +- 'sharing', + 'sound', + 'universal-access', + 'usage', +- 'user-accounts', + 'wwan', + ] + +@@ -43,6 +36,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 c5532ba..75be10d 100644 +--- a/shell/cc-panel-list.c ++++ b/shell/cc-panel-list.c +@@ -388,10 +388,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", +@@ -408,16 +414,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 67f3f1b..4b595af 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_goa_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 */ +@@ -97,7 +111,9 @@ extern void cc_wwan_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), +@@ -105,7 +121,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), +@@ -120,20 +138,30 @@ 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_goa_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("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 d4fe361..b879160 100644 +--- a/tests/meson.build ++++ b/tests/meson.build +@@ -6,5 +6,5 @@ endif + + subdir('interactive-panels') + +-subdir('printers') ++#subdir('printers') + subdir('info') diff --git a/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center_40.0.bb b/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center_41.0.bb similarity index 95% rename from meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center_40.0.bb rename to meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center_41.0.bb index 8a51f4d..3c6594e 100644 --- a/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center_40.0.bb +++ b/meta-gnome/recipes-gnome/gnome-control-center/gnome-control-center_41.0.bb @@ -37,7 +37,7 @@ def gnome_verdir(v): SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive" -SRC_URI[archive.sha256sum] = "ccc9a5736517385109ae5a59906c258244dd879b7503ad5984cf41655cb302f1" +SRC_URI[archive.sha256sum] = "a5696222ad353fcf9a07c406e287ecc9138e250645cb2a5941a88ff0685658c1" # diff --git a/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop_40.0.bb b/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop_41.0.bb similarity index 92% rename from meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop_40.0.bb rename to meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop_41.0.bb index 89f850e..fff8f51 100644 --- a/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop_40.0.bb +++ b/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop_41.0.bb @@ -15,7 +15,7 @@ def gnome_verdir(v): SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive" SRC_URI += "file://0001-needs-stdint-include.patch" -SRC_URI[archive.sha256sum] = "20abfd3f831e4e8092b55839311661dc73b2bf13fc9bef71c4a5a4475da9ee04" +SRC_URI[archive.sha256sum] = "69cb1d3d9a10700eb66348ef1c0e66a855fc5a97ae62902df97a499da11562d2" DEPENDS += "itstool-native gsettings-desktop-schemas gconf virtual/libx11 gtk+3 glib-2.0 startup-notification xkeyboard-config iso-codes udev libseccomp" diff --git a/meta-gnome/recipes-gnome/gnome-disk-utility/gnome-disk-utility_40.1.bb b/meta-gnome/recipes-gnome/gnome-disk-utility/gnome-disk-utility_41.0.bb similarity index 91% rename from meta-gnome/recipes-gnome/gnome-disk-utility/gnome-disk-utility_40.1.bb rename to meta-gnome/recipes-gnome/gnome-disk-utility/gnome-disk-utility_41.0.bb index 82476da..df27017 100644 --- a/meta-gnome/recipes-gnome/gnome-disk-utility/gnome-disk-utility_40.1.bb +++ b/meta-gnome/recipes-gnome/gnome-disk-utility/gnome-disk-utility_41.0.bb @@ -33,7 +33,7 @@ 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] = "2a4b99ac11ca23394b28c5584b9e96284e8c5a4da65cf06207de54f42b1ff141" +SRC_URI[archive.sha256sum] = "8743c98fd656062ef862933efe30c5be4c6b322ec02eee154ec70d08ed0895df" FILES_${PN} += " \ ${datadir}/metainfo \ diff --git a/meta-gnome/recipes-gnome/gnome-settings-daemon/gnome-settings-daemon_40.0.1.bb b/meta-gnome/recipes-gnome/gnome-settings-daemon/gnome-settings-daemon_41.0.bb similarity index 90% rename from meta-gnome/recipes-gnome/gnome-settings-daemon/gnome-settings-daemon_40.0.1.bb rename to meta-gnome/recipes-gnome/gnome-settings-daemon/gnome-settings-daemon_41.0.bb index c0a0214..0b20539 100644 --- a/meta-gnome/recipes-gnome/gnome-settings-daemon/gnome-settings-daemon_40.0.1.bb +++ b/meta-gnome/recipes-gnome/gnome-settings-daemon/gnome-settings-daemon_41.0.bb @@ -9,7 +9,7 @@ DEPENDS = "pango gnome-desktop xorgproto libnotify fontconfig libgudev libxext w FILES_${PN} += "\ ${systemd_user_unitdir} \ - ${libdir}/gnome-settings-daemon-40 \ + ${libdir}/gnome-settings-daemon-41 \ " FILES_${PN}-staticdev += "${libdir}/gnome-settings-daemon-3.0/libgsd.a" @@ -26,7 +26,7 @@ def gnome_verdir(v): SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive" -SRC_URI[archive.sha256sum] = "37dfac1b69a53e2e499228420259d6e134c1c06b74530af88fa855bda1187b21" +SRC_URI[archive.sha256sum] = "e6ca6361fbd1deab2de1a1e390d4f14167cf47b1c547dbb8b65a5d89e9663884" SRC_URI += "file://0001-disable-power-tests-and-sharing.patch" EXTRA_OEMESON += "\ diff --git a/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Citadel-Gnome-Shell-changes.patch b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Citadel-Gnome-Shell-changes.patch.old similarity index 100% rename from meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Citadel-Gnome-Shell-changes.patch rename to meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Citadel-Gnome-Shell-changes.patch.old diff --git a/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch index 0e0b87d..fc422c4 100644 --- a/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch +++ b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch @@ -1,22 +1,22 @@ -From a2ea7fac46ea2b6599df0095223627b17181f390 Mon Sep 17 00:00:00 2001 -From: xSmurf -Date: Wed, 14 Nov 2018 01:47:43 -0500 -Subject: [PATCH] Disabled calendar events from user session... +From 724ea2e98f186456ea984fe9250f8650ed025a9c Mon Sep 17 00:00:00 2001 +From: Bruce Leidl +Date: Tue, 5 Oct 2021 11:17:47 +0000 +Subject: [PATCH] Disabled calendar events from user session --- js/ui/sessionMode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/ui/sessionMode.js b/js/ui/sessionMode.js -index 2136e94..3f35ab2 100644 +index afcd67c..b686efb 100644 --- a/js/ui/sessionMode.js +++ b/js/ui/sessionMode.js -@@ -69,7 +69,7 @@ const _modes = { +@@ -71,7 +71,7 @@ const _modes = { 'user': { hasOverview: true, - showCalendarEvents: true, + showCalendarEvents: false, + showWelcomeDialog: true, allowSettings: true, allowExtensions: true, - allowScreencast: true, diff --git a/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch.old b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch.old new file mode 100644 index 0000000..0e0b87d --- /dev/null +++ b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0001-Disabled-calendar-events-from-user-session.patch.old @@ -0,0 +1,22 @@ +From a2ea7fac46ea2b6599df0095223627b17181f390 Mon Sep 17 00:00:00 2001 +From: xSmurf +Date: Wed, 14 Nov 2018 01:47:43 -0500 +Subject: [PATCH] Disabled calendar events from user session... + +--- + js/ui/sessionMode.js | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/js/ui/sessionMode.js b/js/ui/sessionMode.js +index 2136e94..3f35ab2 100644 +--- a/js/ui/sessionMode.js ++++ b/js/ui/sessionMode.js +@@ -69,7 +69,7 @@ const _modes = { + + 'user': { + hasOverview: true, +- showCalendarEvents: true, ++ showCalendarEvents: false, + allowSettings: true, + allowExtensions: true, + allowScreencast: true, diff --git a/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0002-Citadel-Gnome-Shell-changes.patch b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0002-Citadel-Gnome-Shell-changes.patch new file mode 100644 index 0000000..17bdd54 --- /dev/null +++ b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell/0002-Citadel-Gnome-Shell-changes.patch @@ -0,0 +1,3352 @@ +From 86c760b9e5e4358aab9a6bef4ffdedd7d7c2dd3f Mon Sep 17 00:00:00 2001 +From: Bruce Leidl +Date: Tue, 5 Oct 2021 11:34:09 +0000 +Subject: [PATCH] Citadel Gnome Shell changes + +--- + data/org.gnome.shell.gschema.xml.in | 8 + + data/theme/gnome-shell-sass/_widgets.scss | 2 + + .../gnome-shell-sass/widgets/_realms.scss | 17 + + data/theme/meson.build | 1 + + js/js-resources.gresource.xml | 7 + + js/ui/main.js | 4 + + js/ui/overview.js | 2 +- + js/ui/overviewControls.js | 3 + + js/ui/realms/realmIndicator.js | 37 ++ + js/ui/realms/realmManager.js | 54 +++ + js/ui/realms/realmSearchProvider.js | 326 +++++++++++++ + js/ui/realms/realmSwitcher.js | 325 +++++++++++++ + js/ui/realms/realmWindowFrame.js | 371 +++++++++++++++ + js/ui/realms/realmWindowMenu.js | 113 +++++ + js/ui/windowManager.js | 41 +- + js/ui/windowMenu.js | 15 +- + js/ui/workspacesView.js | 12 + + src/meson.build | 7 + + src/shell-app-cache.c | 2 +- + src/shell-app-system.c | 179 ++++++- + src/shell-app-system.h | 6 +- + src/shell-global.c | 3 + + src/shell-realm-item.c | 392 ++++++++++++++++ + src/shell-realm-item.h | 35 ++ + src/shell-realm-tracker.c | 297 ++++++++++++ + src/shell-realm-tracker.h | 14 + + src/shell-realms-private.h | 21 + + src/shell-realms.c | 442 ++++++++++++++++++ + src/shell-realms.h | 23 + + src/shell-window-tracker.c | 43 +- + 30 files changed, 2779 insertions(+), 23 deletions(-) + create mode 100644 data/theme/gnome-shell-sass/widgets/_realms.scss + create mode 100644 js/ui/realms/realmIndicator.js + create mode 100644 js/ui/realms/realmManager.js + create mode 100644 js/ui/realms/realmSearchProvider.js + create mode 100644 js/ui/realms/realmSwitcher.js + create mode 100644 js/ui/realms/realmWindowFrame.js + create mode 100644 js/ui/realms/realmWindowMenu.js + create mode 100644 src/shell-realm-item.c + create mode 100644 src/shell-realm-item.h + create mode 100644 src/shell-realm-tracker.c + create mode 100644 src/shell-realm-tracker.h + create mode 100644 src/shell-realms-private.h + create mode 100644 src/shell-realms.c + create mode 100644 src/shell-realms.h + +diff --git a/data/org.gnome.shell.gschema.xml.in b/data/org.gnome.shell.gschema.xml.in +index a805d52..edc03b9 100644 +--- a/data/org.gnome.shell.gschema.xml.in ++++ b/data/org.gnome.shell.gschema.xml.in +@@ -230,6 +230,14 @@ + ["<Super>9"] + Switch to application 9 + ++ ++ ["<Primary>Tab"] ++ Open Realm Switcher ++ ++ ++ ["<Shift><Primary>Tab"] ++ Open Realm Switcher Backwards ++ + + + ui/status/remoteAccess.js + ui/status/system.js + ui/status/thunderbolt.js ++ ++ ui/realms/realmIndicator.js ++ ui/realms/realmManager.js ++ ui/realms/realmSearchProvider.js ++ ui/realms/realmSwitcher.js ++ ui/realms/realmWindowFrame.js ++ ui/realms/realmWindowMenu.js + + +diff --git a/js/ui/main.js b/js/ui/main.js +index c7bac11..e032b14 100644 +--- a/js/ui/main.js ++++ b/js/ui/main.js +@@ -49,6 +49,7 @@ const PointerA11yTimeout = imports.ui.pointerA11yTimeout; + const ParentalControlsManager = imports.misc.parentalControlsManager; + const Config = imports.misc.config; + const Util = imports.misc.util; ++const RealmManager = imports.ui.realms.realmManager; + + const WELCOME_DIALOG_LAST_SHOWN_VERSION = 'welcome-dialog-last-shown-version'; + // Make sure to mention the point release, otherwise it will show every time +@@ -91,6 +92,7 @@ var kbdA11yDialog = null; + var inputMethod = null; + var introspectService = null; + var locatePointer = null; ++var realmManager = null; + let _startDate; + let _defaultCssStylesheet = null; + let _cssStylesheet = null; +@@ -264,6 +266,8 @@ function _initializeUI() { + extensionManager = new ExtensionSystem.ExtensionManager(); + extensionManager.init(); + ++ realmManager = new RealmManager.RealmManager(); ++ + if (sessionMode.isGreeter && screenShield) { + layoutManager.connect('startup-prepared', () => { + screenShield.showDialog(); +diff --git a/js/ui/overview.js b/js/ui/overview.js +index 87bf835..12054e1 100644 +--- a/js/ui/overview.js ++++ b/js/ui/overview.js +@@ -251,7 +251,7 @@ var Overview = class { + DND.addDragMonitor(this._dragMonitor); + // Remember the workspace we started from + let workspaceManager = global.workspace_manager; +- this._lastActiveWorkspaceIndex = workspaceManager.get_active_workspace_index(); ++ this._lastActiveWorkspaceIndex = workspaceManager.get_active_workspace_id(); + } + + _onDragEnd(time) { +diff --git a/js/ui/overviewControls.js b/js/ui/overviewControls.js +index 6cbaa22..97780e9 100644 +--- a/js/ui/overviewControls.js ++++ b/js/ui/overviewControls.js +@@ -342,6 +342,8 @@ class ControlsManager extends St.Widget { + workspaceManager.connect('notify::n-workspaces', + this._updateAdjustment.bind(this)); + ++ this._contextSwitchedId = workspaceManager.connect('context-switched', this._updateAdjustment.bind(this)); ++ + this._searchController = new SearchController.SearchController( + this._searchEntry, + this.dash.showAppsButton); +@@ -653,6 +655,7 @@ class ControlsManager extends St.Widget { + + _onDestroy() { + global.workspace_manager.disconnect(this._nWorkspacesNotifyId); ++ global.workspace_manager.disconnect(this._contextSwitchedId); + } + + _updateAdjustment() { +diff --git a/js/ui/realms/realmIndicator.js b/js/ui/realms/realmIndicator.js +new file mode 100644 +index 0000000..d71e346 +--- /dev/null ++++ b/js/ui/realms/realmIndicator.js +@@ -0,0 +1,37 @@ ++const { Clutter, GObject, Shell, St } = imports.gi; ++const PanelMenu = imports.ui.panelMenu; ++ ++var RealmPanelIndicator = GObject.registerClass( ++class RealmPanelIndicator extends PanelMenu.Button { ++ _init() { ++ super._init(0.5, "Current Realm"); ++ ++ this._label = new St.Label({ ++ style_class: 'current-realm-label', ++ y_align: Clutter.ActorAlign.CENTER ++ }); ++ this.add_child(this._label); ++ ++ this.update(); ++ } ++ ++ clear() { ++ this._label.set_text(''); ++ } ++ ++ update() { ++ let realm_name = ''; ++ const realms = Shell.Realms.get_default(); ++ let current = realms.current_realm; ++ if (current) { ++ realm_name = current.realm_name; ++ this._label.set_text(`realm-${realm_name}`); ++ } ++ ++ if (realm_name.length > 0) { ++ this._label.set_text(`realm-${realm_name}`); ++ } else { ++ this._label.set_text(''); ++ } ++ } ++ }); +diff --git a/js/ui/realms/realmManager.js b/js/ui/realms/realmManager.js +new file mode 100644 +index 0000000..0432190 +--- /dev/null ++++ b/js/ui/realms/realmManager.js +@@ -0,0 +1,54 @@ ++const { Clutter, Gio, Meta, Shell, St } = imports.gi; ++ ++const Main = imports.ui.main; ++const RealmIndicator = imports.ui.realms.realmIndicator; ++const RealmSwitcher = imports.ui.realms.realmSwitcher; ++const Lightbox = imports.ui.lightbox; ++const RealmSearchProvider = imports.ui.realms.realmSearchProvider; ++const RealmWindowFrame = imports.ui.realms.realmWindowFrame; ++ ++var RealmManager = class { ++ constructor() { ++ ++ this._realmIndicator = new RealmIndicator.RealmPanelIndicator(); ++ Main.panel.addToStatusArea('RealmIndicator', this._realmIndicator); ++ ++ this._switchAction = Main.wm.addKeybinding('switch-realm', ++ new Gio.Settings({ schema_id: "org.gnome.shell.keybindings"}), ++ Meta.KeyBindingFlags.NONE, ++ Shell.ActionMode.NORMAL, ++ this._switchRealms.bind(this)); ++ ++ this._switchActionBackward = Main.wm.addKeybinding('switch-realm-backward', ++ new Gio.Settings({ schema_id: "org.gnome.shell.keybindings"}), ++ Meta.KeyBindingFlags.IS_REVERSED, ++ Shell.ActionMode.NORMAL, ++ this._switchRealms.bind(this)); ++ ++ const realms = Shell.Realms.get_default(); ++ realms.connect('realm-context-switched', () => { ++ Main.overview.dash._queueRedisplay(); ++ }); ++ ++ this._switchAnimation = new RealmSwitcher.ContextSwitchAnimationController(this._realmIndicator); ++ ++ this._searchResults = Main.overview._overview.controls._searchController._searchResults; ++ this._searchProvider = new RealmSearchProvider.RealmSearchProvider(); ++ this._searchProvider.createResultDisplay(this._searchResults); ++ this._searchResults._registerProvider(this._searchProvider); ++ ++ this._frameManager = new RealmWindowFrame.WindowFrameManager(); ++ } ++ ++ animateSwitch(from, to, onComplete) { ++ this._switchAnimation.animateSwitch(from, to, onComplete); ++ } ++ ++ _switchRealms(display, window, binding) { ++ let popup = new RealmSwitcher.SwitchRealmPopup(this._switchAction, this._switchActionBackward); ++ if (!popup.show(binding.is_reversed(), binding.get_name(), binding.get_mask())) ++ popup.fadeAndDestroy(); ++ } ++ ++}; ++ +diff --git a/js/ui/realms/realmSearchProvider.js b/js/ui/realms/realmSearchProvider.js +new file mode 100644 +index 0000000..00ad04d +--- /dev/null ++++ b/js/ui/realms/realmSearchProvider.js +@@ -0,0 +1,326 @@ ++const { Clutter, GObject, Pango, Shell, St } = imports.gi; ++ ++const Search = imports.ui.search; ++const Main = imports.ui.main; ++const Util = imports.misc.util; ++ ++// Based on ProviderInfo in search.js ++var RealmProviderInfo = GObject.registerClass( ++class RealmProviderInfo extends St.Button { ++ _init() { ++ super._init({ ++ style_class: 'search-provider-icon', ++ reactive: false, ++ can_focus: false, ++ accessible_name: "Realms", ++ track_hover: false, ++ y_align: Clutter.ActorAlign.START, ++ }); ++ ++ this._content = new St.BoxLayout({ vertical: false, ++ style_class: 'list-search-provider-content' }); ++ this.set_child(this._content); ++ ++ let icon = new St.Icon({ icon_size: this.PROVIDER_ICON_SIZE, ++ icon_name: 'computer' }); ++ ++ let detailsBox = new St.BoxLayout({ style_class: 'list-search-provider-details', ++ vertical: true, ++ x_expand: true }); ++ ++ let nameLabel = new St.Label({ ++ text: "Realms", ++ x_align: Clutter.ActorAlign.START ++ }); ++ ++ this._moreLabel = new St.Label({ x_align: Clutter.ActorAlign.START }); ++ ++ detailsBox.add_actor(nameLabel); ++ detailsBox.add_actor(this._moreLabel); ++ ++ ++ this._content.add_actor(icon); ++ this._content.add_actor(detailsBox); ++ } ++ ++ get PROVIDER_ICON_SIZE() { ++ return 48; ++ } ++ ++ setMoreCount(count) { ++ this._moreLabel.text = ngettext("%d more", "%d more", count).format(count); ++ this._moreLabel.visible = count > 0; ++ } ++}); ++ ++var MAX_LIST_SEARCH_RESULTS_ROWS = 10; ++ ++// Based on ListSearchResult in search.js ++var RealmSearchResult = GObject.registerClass( ++class ListSearchResult extends Search.SearchResult { ++ _init(provider, metaInfo, resultsView) { ++ super._init(provider, metaInfo, resultsView); ++ ++ this.style_class = 'list-search-result'; ++ ++ let content = new St.BoxLayout({ ++ style_class: 'list-search-result-content', ++ vertical: false, ++ x_align: Clutter.ActorAlign.FILL, ++ x_expand: true, ++ y_expand: true, ++ }); ++ this.set_child(content); ++ ++ this._termsChangedId = 0; ++ ++ let titleBox = new St.BoxLayout({ ++ style_class: 'list-search-result-title', ++ y_align: Clutter.ActorAlign.CENTER, ++ }); ++ ++ content.add_child(titleBox); ++ ++ // An icon for, or thumbnail of, content ++ let icon = this.metaInfo['createIcon'](this.ICON_SIZE); ++ if (icon) ++ titleBox.add(icon); ++ ++ let title = new St.Label({ ++ text: this.metaInfo['name'], ++ y_align: Clutter.ActorAlign.CENTER, ++ }); ++ titleBox.add_child(title); ++ ++ this.label_actor = title; ++ ++ if (this.metaInfo['description']) { ++ this._descriptionLabel = new St.Label({ ++ style_class: 'list-search-result-description', ++ x_expand: true, ++ x_align: Clutter.ActorAlign.START, ++ y_align: Clutter.ActorAlign.CENTER, ++ }); ++ this._descriptionLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE; ++ content.add_child(this._descriptionLabel); ++ ++ this._termsChangedId = ++ this._resultsView.connect('terms-changed', ++ this._highlightTerms.bind(this)); ++ ++ this._highlightTerms(); ++ } ++ ++ let id = this.metaInfo['id']; ++ ++ if (id != ':new:') { ++ this.configButton = new St.Button({ ++ style_class: 'button', ++ track_hover: true, ++ can_focus: true, ++ child: new St.Icon({ ++ style_class: 'realm-config-icon', ++ icon_name: 'emblem-system-symbolic', ++ icon_size: 24, ++ }), ++ }); ++ ++ this.configButton.connect('clicked', () => { ++ Main.overview.toggle(); ++ Util.spawn(['/usr/libexec/realm-config-ui', id]); ++ }); ++ content.add_child(this.configButton); ++ } ++ ++ this.connect('destroy', this._onDestroy.bind(this)); ++ } ++ ++ get ICON_SIZE() { ++ return 24; ++ } ++ ++ _highlightTerms() { ++ let markup = this._resultsView.highlightTerms(this.metaInfo['description'].split('\n')[0]); ++ this._descriptionLabel.clutter_text.set_markup(markup); ++ } ++ ++ _onDestroy() { ++ if (this._termsChangedId) ++ this._resultsView.disconnect(this._termsChangedId); ++ this._termsChangedId = 0; ++ } ++}); ++ ++// Based on ListSearchResults in search.js ++var RealmSearchResults = GObject.registerClass( ++class RealmSearchResults extends Search.SearchResultsBase { ++ _init(provider, resultsView) { ++ super._init(provider, resultsView); ++ ++ this._container = new St.BoxLayout({ style_class: 'search-section-content' }); ++ this.providerInfo = new RealmProviderInfo(); ++ this.providerInfo.connect('key-focus-in', this._keyFocusIn.bind(this)); ++ this.providerInfo.connect('clicked', () => { ++ Main.overview.toggle(); ++ }); ++ ++ this._container.add_child(this.providerInfo); ++ ++ this._content = new St.BoxLayout({ ++ style_class: 'list-search-results', ++ vertical: true, ++ x_expand: true, ++ }); ++ this._container.add_child(this._content); ++ ++ this._resultDisplayBin.set_child(this._container); ++ } ++ ++ _setMoreCount(count) { ++ this.providerInfo.setMoreCount(count); ++ } ++ ++ _getMaxDisplayedResults() { ++ return MAX_LIST_SEARCH_RESULTS_ROWS; ++ } ++ ++ _clearResultDisplay() { ++ this._content.remove_all_children(); ++ } ++ ++ _createResultDisplay(meta) { ++ return super._createResultDisplay(meta) || ++ new RealmSearchResult(this.provider, meta, this._resultsView); ++ } ++ ++ _addItem(display) { ++ this._content.add_actor(display); ++ } ++ ++ getFirstResult() { ++ if (this._content.get_n_children() > 0) ++ return this._content.get_child_at_index(0); ++ else ++ return null; ++ } ++ ++}); ++ ++var RealmSearchProvider = class RealmSearchProvider { ++ constructor() { ++ this._shellRealms = Shell.Realms.get_default(); ++ this.id = 'realms'; ++ this.isRemoteProvider = false; ++ this.canLaunchSearch = false; ++ this.display = null; ++ } ++ ++ createResultDisplay(resultsView) { ++ this.display = new RealmSearchResults(this, resultsView); ++ this.display.connect('notify::focus-child', resultsView._focusChildChanged.bind(resultsView)); ++ this.display.hide(); ++ resultsView._content.add(this.display); ++ } ++ ++ createIcon(size, realm) { ++ if (realm.is_running()) { ++ return new St.Icon({ icon_name: 'emblem-synchronizing', icon_size: size }); ++ } else { ++ return new St.Icon({ icon_name: 'exaile', icon_size: size }); ++ } ++ } ++ ++ createRealmMeta(realm) { ++ let id = realm.get_realm_name(); ++ let description = ''; ++ if (realm.is_running()) { ++ description = `Set realm-${id} as current realm`; ++ } else { ++ description = `Start realm-${id}`; ++ } ++ ++ return { ++ id: id, ++ name: `realm-${id}`, ++ description: description, ++ createIcon: size => { ++ return this.createIcon(size, realm); ++ }, ++ }; ++ } ++ ++ createNewRealmMeta() { ++ return { ++ id: ':new:', ++ name: 'New Realm', ++ description: 'Create a new realm', ++ createIcon: size => { ++ return new St.Icon({ ++ icon_name: 'computer', ++ icon_size: size, ++ }); ++ } ++ } ++ } ++ ++ getResultMetas (ids, callback) { ++ let metas = []; ++ ++ for (let id of ids) { ++ if (id == ":new:") { ++ metas.push(this.createNewRealmMeta()); ++ } else { ++ let realm = this._shellRealms.realm_by_name(id); ++ if (realm && !realm.is_current()) { ++ metas.push(this.createRealmMeta(realm)); ++ } else { ++ log(`No realm found for ${id}`); ++ } ++ } ++ } ++ callback(metas); ++ } ++ ++ activateResult (resultId, _terms) { ++ ++ if (resultId == ':new:') { ++ Main.overview.toggle(); ++ Util.spawn(['/usr/libexec/realm-config-ui', '--new']); ++ return; ++ } ++ ++ let realm = this._shellRealms.realm_by_name(resultId); ++ if (realm) { ++ realm.set_current(); ++ } else { ++ log(`No realm found for ${resultId}`); ++ } ++ } ++ ++ filterResults(results, maxNumber) { ++ return results.slice(0, maxNumber) ++ } ++ ++ getInitialResultSet(terms, callback, _cancellable) { ++ let realms = this._shellRealms.get_all_realms(); ++ let matches = []; ++ ++ if (terms.length == 1 && "new".startsWith(terms[0])) { ++ matches.push(":new:"); ++ } ++ ++ for (let realm of realms) { ++ if (!realm.is_current()) { ++ let name = realm.get_realm_name(); ++ if (terms.every(t => name.indexOf(t) != -1)) { ++ matches.push(name); ++ } ++ } ++ } ++ callback(matches); ++ } ++ ++ getSubsearchResultSet(previousResults, terms, callback, cancellable) { ++ this.getInitialResultSet(terms, callback, cancellable) ++ } ++} +diff --git a/js/ui/realms/realmSwitcher.js b/js/ui/realms/realmSwitcher.js +new file mode 100644 +index 0000000..507df00 +--- /dev/null ++++ b/js/ui/realms/realmSwitcher.js +@@ -0,0 +1,325 @@ ++ ++const { Clutter, GObject, Meta, Shell, St } = imports.gi; ++ ++const Background = imports.ui.background; ++const SwitcherPopup = imports.ui.switcherPopup; ++const Layout = imports.ui.layout; ++const Main = imports.ui.main; ++ ++const WINDOW_ANIMATION_TIME = 2000; ++var APP_ICON_SIZE = 96; ++ ++var RealmItem = GObject.registerClass( ++class RealmItem extends St.BoxLayout { ++ _init(realm, workspace_group) { ++ super._init({ vertical: true }); ++ this.realm = realm; ++ ++ this.add_child(workspace_group); ++ ++ this.label = new St.Label({ ++ text: `realm-${this.realm.realm_name}`, ++ x_align: Clutter.ActorAlign.CENTER, ++ }); ++ ++ this.add_child(this.label); ++ } ++ ++ activate() { ++ this.realm.set_current(); ++ } ++ ++}); ++ ++function getRealmItems() { ++ const monitor = Main.layoutManager.primaryMonitor; ++ const realms = Shell.Realms.get_default(); ++ let realm_list = realms.get_running_realms(); ++ let items = []; ++ realm_list.forEach(realm => { ++ let ws = realm.get_active_workspace(); ++ if (ws) { ++ let size = 256; // default thumbnail size ++ let scale = Math.min(1.0, size / monitor.width, size / monitor.height); ++ let wsgroup = new WorkspaceGroup(ws, monitor, scale); ++ items.push(new RealmItem(realm, wsgroup)); ++ } ++ }); ++ return items; ++} ++ ++var SwitchRealmList = GObject.registerClass( ++class SwitchRealmList extends SwitcherPopup.SwitcherList { ++ _init(items) { ++ super._init(false); ++ ++ items.forEach(item => { ++ this.addItem(item, item.label); ++ }); ++ } ++}); ++ ++var SwitchRealmPopup = GObject.registerClass( ++class SwitchRealmPopup extends SwitcherPopup.SwitcherPopup { ++ _init(action, actionBackward) { ++ super._init(); ++ this._action = action; ++ this._actionBackward = actionBackward; ++ this._items = getRealmItems(); ++ this._switcherList = new SwitchRealmList(this._items); ++ } ++ ++ _keyPressHandler(keysym, action) { ++ if (action == this._action) ++ this._select(this._next()); ++ else if (action == this._actionBackward) ++ this._select(this._previous()); ++ else if (keysym == Clutter.KEY_Left) ++ this._select(this._previous()); ++ else if (keysym == Clutter.KEY_Right) ++ this._select(this._next()); ++ else ++ return Clutter.EVENT_PROPAGATE; ++ ++ return Clutter.EVENT_STOP; ++ } ++ ++ _finish() { ++ super._finish(); ++ this._items[this._selectedIndex].activate(); ++ } ++ ++}); ++ ++const WorkspaceGroup = GObject.registerClass( ++class WorkspaceGroup extends Clutter.Actor { ++ _init(workspace, monitor, scale = 1.0) { ++ super._init(); ++ this._workspace = workspace; ++ this._monitor = monitor; ++ this._scale = scale; ++ this._windowRecords = []; ++ this.width = monitor.width * scale; ++ this.height = monitor.height * scale; ++ this._background = new Meta.BackgroundGroup({ ++ width: this.width * this._scale, ++ height: this.height * this._scale, ++ }); ++ this.add_actor(this._background); ++ this._bgManager = new Background.BackgroundManager({ ++ container: this._background, ++ monitorIndex: this._monitor.index, ++ controlPosition: false, ++ }); ++ this.clip_to_allocation = true; ++ ++ this._createWindows(); ++ this.connect('destroy', this._onDestroy.bind(this)); ++ this._restackedId = global.display.connect('restacked', this._syncStacking.bind(this)); ++ } ++ ++ get workspace() { ++ return this._workspace; ++ } ++ ++ _shouldShowWindow(window) { ++ if (!window.showing_on_its_workspace()) ++ return false; ++ ++ const geometry = global.display.get_monitor_geometry(this._monitor.index); ++ const [intersects] = window.get_frame_rect().intersect(geometry); ++ if (!intersects) ++ return false; ++ ++ const isSticky = window.is_on_all_workspaces(); ++ ++ return !isSticky && window.located_on_workspace(this._workspace); ++ } ++ ++ _syncStacking() { ++ const windowActors = global.get_window_actors().filter(w => ++ this._shouldShowWindow(w.meta_window)); ++ ++ let lastRecord; ++ ++ for (const windowActor of windowActors) { ++ const record = this._windowRecords.find(r => r.windowActor === windowActor); ++ this.set_child_above_sibling(record.clone, lastRecord ? lastRecord.clone : this._background); ++ lastRecord = record; ++ } ++ } ++ ++ _createWindows() { ++ const windowActors = global.get_window_actors().filter(w => ++ this._shouldShowWindow(w.meta_window)); ++ for (const windowActor of windowActors) { ++ let [width,height] = windowActor.get_size(); ++ const clone = new Clutter.Clone({ ++ source: windowActor, ++ width: width * this._scale, ++ height: height * this._scale, ++ x: (windowActor.x - this._monitor.x) * this._scale, ++ y: (windowActor.y - this._monitor.y) * this._scale, ++ }); ++ this.add_child(clone); ++ const record = {windowActor, clone }; ++ record.windowDestroyId = windowActor.connect('destroy', () => { ++ clone.destroy(); ++ this._windowRecords.splice(this._windowRecords.indexOf(record), 1); ++ }); ++ this._windowRecords.push(record); ++ } ++ } ++ ++ _removeWindows() { ++ for (const record of this._windowRecords) { ++ record.windowActor.disconnect(record.windowDestroyId); ++ record.clone.destroy(); ++ } ++ this._windowRecords = []; ++ } ++ ++ _onDestroy() { ++ global.display.disconnect(this._restackedId); ++ this._removeWindows(); ++ this._bgManager.destroy(); ++ } ++ ++}); ++ ++const MonitorGroup = GObject.registerClass({ ++ Properties: { ++ 'progress': GObject.ParamSpec.double( ++ 'progress', 'progress', 'progress', ++ GObject.ParamFlags.READWRITE, ++ -Infinity, Infinity, 0), ++ }, ++}, class MonitorGroup extends St.Widget { ++ _init(monitor, fromIndex, toIndex) { ++ super._init({ ++ clip_to_allocation: true, ++ style_class: 'workspace-animation', ++ }); ++ this._monitor = monitor; ++ const constraint = new Layout.MonitorConstraint({ index: monitor.index }); ++ this.add_constraint(constraint); ++ ++ this._container = new Clutter.Actor(); ++ this.add_child(this._container); ++ ++ this._progress = 0; ++ this._fadeOut = true; ++ ++ this._workspaceGroups = []; ++ this._blackBackground = new Clutter.Actor(); ++ this._blackBackground.width = monitor.width; ++ this._blackBackground.height = monitor.height; ++ let [_res, color] = Clutter.Color.from_string("#000000ff"); ++ this._blackBackground.background_color = color; ++ ++ ++ ++ this.addWorkspaceByIndex(toIndex, monitor); ++ // add opaque black actor ++ this._container.add_child(this._blackBackground); ++ this.addWorkspaceByIndex(fromIndex, monitor); ++ ++ // tween 'from' WorkspaceGroup opacity from 255 to 0 fading workspace to black background ++ // tween 'block' actor opacity from 255 to 0 revealing 'to' WorkspaceGroup ++ } ++ ++ addWorkspaceByIndex(idx, monitor) { ++ const workspaceManager = global.workspace_manager; ++ const ws = workspaceManager.get_workspace_by_index(idx); ++ if (ws) { ++ const fullscreen = ws.list_windows().some(w => w.get_monitor() === monitor.index && w.is_fullscreen()); ++ const group = new WorkspaceGroup(ws, monitor); ++ this._workspaceGroups.push(group); ++ this._container.add_child(group); ++ } ++ } ++ ++ get progress() { ++ return this._progress; ++ } ++ ++ // Interpolate opacity from 0 (full opaque) to 50 (full transparent) ++ calculateOpacity(progress) { ++ return 255 - (255 * (progress / 50.0)); ++ } ++ ++ set progress(p) { ++ const fromGroup = this._workspaceGroups[this._workspaceGroups.length - 1]; ++ this._progress = p; ++ // 0 - 50 ++ if (p < 50) { ++ this._blackBackground.opacity = 255; ++ fromGroup.opacity = this.calculateOpacity(p); ++ } else if (p < 100) { ++ if (this._fadeOut) { ++ this._fadeOut = false; ++ } ++ fromGroup.opacity = 0; ++ this._blackBackground.opacity = this.calculateOpacity(p - 50); ++ } else { ++ fromGroup.opacity = 0; ++ this._blackBackground.opacity = 0; ++ } ++ } ++}); ++ ++var ContextSwitchAnimationController = class { ++ constructor(indicator) { ++ this._switchData = null; ++ this._indicator = indicator; ++ } ++ ++ _prepareContextSwitch(fromIdx, toIdx) { ++ if (this._switchData) { ++ this._switchData.monitors[0].remove_all_transitions(); ++ this._finishContextSwitch(this._switchData); ++ } ++ ++ const switchData = {}; ++ this._switchData = switchData; ++ switchData.monitors = []; ++ switchData.inProgress = false; ++ ++ const monitor = Main.layoutManager.primaryMonitor; ++ ++ const group = new MonitorGroup(monitor, fromIdx, toIdx); ++ ++ Main.uiGroup.insert_child_above(group, global.window_group); ++ ++ switchData.monitors.push(group); ++ ++ Meta.disable_unredirect_for_display(global.display); ++ } ++ ++ _finishContextSwitch(switchData) { ++ Meta.enable_unredirect_for_display(global.display); ++ this._indicator.update(); ++ this._switchData = null; ++ switchData.monitors.forEach(m => m.destroy()); ++ if (switchData.onComplete) { ++ switchData.onComplete(); ++ } ++ } ++ ++ animateSwitch(fromIdx, toIdx, onComplete) { ++ ++ this._prepareContextSwitch(fromIdx, toIdx); ++ this._switchData.inProgress = true; ++ this._switchData.onComplete = onComplete; ++ ++ const params = { ++ duration: WINDOW_ANIMATION_TIME, ++ mode: Clutter.AnimationMode.EASE_IN_OUT_QUAD, ++ }; ++ params.onComplete = () => { ++ this._finishContextSwitch(this._switchData); ++ }; ++ this._indicator.clear(); ++ this._switchData.monitors[0].ease_property('progress', 100, params); ++ } ++} +diff --git a/js/ui/realms/realmWindowFrame.js b/js/ui/realms/realmWindowFrame.js +new file mode 100644 +index 0000000..0a36179 +--- /dev/null ++++ b/js/ui/realms/realmWindowFrame.js +@@ -0,0 +1,371 @@ ++const { Clutter, Cogl, GObject, Meta, Shell, St } = imports.gi; ++ ++const Main = imports.ui.main; ++ ++var pastelColors = {}; ++ ++function pastelColorsFromName(name) { ++ var hash = 0; ++ ++ if (name in pastelColors) { ++ return pastelColors[name]; ++ } ++ if (name === undefined || name === null || name === "") { ++ hash = Math.random() * 0xffffff; ++ } else { ++ for (let i = 0, ii = name.length; i < ii; i++) { ++ hash = name.charCodeAt(i) + ((hash << 5) - hash); ++ } ++ } ++ ++ let baseline = 127; ++ let multiplier = 64 + ((hash>>24)&0xff); ++ let ok = false; ++ let i = 0; ++ while (!ok && i++ < 10) { ++ var r = ( Math.round( (hash&0xff) * multiplier ) + baseline ) & 0xff; ++ var g = ( Math.round( ((hash>>8)&0xff) * multiplier ) + baseline ) & 0xff; ++ var b = ( Math.round( ((hash>>16)&0xff) * multiplier ) + baseline ) & 0xff; ++ multiplier += 10; ++ let d = Math.sqrt( Math.pow((r-0xff), 2) + Math.pow(g, 2) + Math.pow(b, 2) ); ++ let p = Math.round( ( d / Math.sqrt( Math.pow(255, 2) * 3 ) ) * 100 ); ++ if (p <= 35) { ++ continue; ++ } ++ ok = true; ++ } ++ ++ pastelColors[name] = [r,g,b]; ++ return pastelColors[name]; ++} ++ ++let IgnoredWindowTypes = [ ++ Meta.WindowType.TOOLTIP ++ , Meta.WindowType.MENU ++ , Meta.WindowType.DROPDOWN_MENU ++ , Meta.WindowType.POPUP_MENU ++]; ++ ++var WindowFrameManager = class WindowFrameManager { ++ constructor() { ++ this._windowMapId = ++ global.window_manager.connect('map', this._handleWindowMap.bind(this)); ++ this._contextWindowMovedId = ++ global.workspace_manager.connect('context-window-moved', this._onContextWindowMoved.bind(this)); ++ ++ this._realms = Shell.Realms.get_default(); ++ this._labelOnTop = true; ++ this._workspaces = []; ++ this.trackWindows(); ++ } ++ ++ _onContextWindowMoved(workspaceManager, window) { ++ let actor = window.get_compositor_private(); ++ if (actor) { ++ this.handleWindow(actor); ++ } ++ return Clutter.EVENT_PROPAGATE; ++ } ++ ++ _handleWindowMap(shellwm, actor) { ++ this.handleWindow(actor); ++ return Clutter.EVENT_PROPAGATE; ++ } ++ ++ windowRealmName(win) { ++ if (this._realms.is_citadel_window(win)) { ++ return "Citadel"; ++ } else { ++ let realm = this._realms.realm_by_window(win); ++ if (realm) { ++ return realm.realm_name; ++ } ++ } ++ return ""; ++ } ++ ++ handleWindow(actor) { ++ let win = actor.metaWindow; ++ ++ if (win.is_on_foreign_workspace_context()) { ++ let realm_name = this.windowRealmName(win); ++ this._applyBorder(actor, win, realm_name); ++ } else { ++ this._removeBorder(actor); ++ } ++ } ++ ++ trackWindows() { ++ var actors = global.get_window_actors(); ++ actors.forEach(a => this.handleWindow(a)); ++ } ++ ++ _removeLabel(actor) { ++ var children = actor.get_children(); ++ for (const child of children) { ++ if (child.get_name() == 'realm-label') { ++ actor.remove_child(child); ++ } ++ } ++ } ++ ++ _removeBorder(actor) { ++ actor.remove_effect_by_name('foreign'); ++ this._removeLabel(actor); ++ } ++ ++ _applyLabel(actor, win, realm_name, r, g, b) { ++ let _lot = this._labelOnTop; ++ //let geom = actor.get_allocation_geometry(); ++ let box = actor.get_allocation_box(); ++ if ((box.y <= 30) || // Top bar XXX: Calculate/obtain from somewhere ++ win.is_fullscreen() === true || // Fullscreen ++ [Meta.MaximizeFlags.BOTH, Meta.MaximizeFlags.VERTICAL].includes(win.get_maximized())) { // Maximized ++ _lot = false; ++ } ++ this._removeLabel(actor); ++ ++ let label = new St.Label({ ++ style_class: 'realm-frame-label', ++ z_position: 1.0, ++ }) ++ let clutter_text = label.get_clutter_text(); ++ let alpha = 64; ++ if (_lot === true) { ++ alpha *= 2; ++ } ++ let color_text = new Clutter.Color({ ++ red: 0, ++ green: 0, ++ blue: 0, ++ alpha: alpha * 1.5 ++ }); ++ let color_background = new Clutter.Color({ ++ red: r, ++ green: g, ++ blue: b, ++ alpha: alpha ++ }); ++ clutter_text.set_color(color_text); ++ clutter_text.set_background_color(color_background); ++ clutter_text.set_name('realm-label'); ++ label.set_text(' '+realm_name+' '); ++ ++ let orect = win.get_frame_rect(); ++ let irect = win.get_buffer_rect(); ++ let borderX = orect.x - irect.x; ++ let borderY = orect.y - irect.y; ++ let margins = { ++ top: borderY + 1 ++ , left: borderX + 2 ++ }; ++ margins.top -= 3; ++ margins.left -= 3; ++ ++ if (_lot === true) { ++ margins.top -= label.get_height(); ++ margins.left -= 2; ++ } ++ if (win.is_fullscreen() === true || win.get_maximized() === Meta.MaximizeFlags.BOTH) { ++ margins.top = 0; ++ margins.left = 0; ++ } ++ label.x = margins.left; ++ label.y = margins.top; ++ actor.add_child(label); ++ } ++ ++ _applyBorder(actor, win, realm_name) { ++ if (IgnoredWindowTypes.includes(win.get_window_type())) { ++ return; ++ } ++ let e = new RealmFrameEffect(); ++ e.setRGB(realm_name, win); ++ ++ if (win.get_window_type() === Meta.WindowType.NORMAL) { ++ this._applyLabel(actor, win, realm_name, e.r, e.g, e.b); ++ } ++ ++ if (!actor.get_effect('foreign')) { ++ actor.add_effect_with_name('foreign', e); ++ } ++ } ++ ++} ++ ++var RealmFrameEffect = GObject.registerClass( ++ class RealmFrameEffect extends Clutter.Effect { ++ _init() { ++ super._init(); ++ this._pipeline = null; ++ } ++ setRGB(name, win) { ++ this._win = win; ++ var r = 0, g = 0, b = 0; ++ if (name == 'Citadel') { ++ r = 0xff; ++ } else { ++ [r,g,b] = pastelColorsFromName(name); ++ } ++ this.r = r; ++ this.g = g; ++ this.b = b; ++ } ++ ++ adjust_actor_box(box, win) { ++ let frame_rect = win.get_frame_rect(); ++ let buffer_rect = win.get_buffer_rect(); ++ let borderX = frame_rect.x - buffer_rect.x; ++ let borderY = frame_rect.y - buffer_rect.y; ++ ++ let margins = { ++ top: borderY - 3, ++ bottom: borderY - 1, ++ left: borderX - 3, ++ right: borderX - 3, ++ }; ++ ++ let wayland = win.get_client_type() == Meta.WindowClientType.WAYLAND; ++ ++ if (wayland) { ++ margins.bottom += 4; ++ } ++ ++ let width = 2; ++ ++ switch (win.get_maximized()) { ++ case Meta.MaximizeFlags.BOTH: ++ margins.top += width; ++ margins.right += width; ++ margins.bottom += width - (wayland ? 5 : 0); ++ margins.left += width; ++ break; ++ case Meta.MaximizeFlags.HORIZONTAL: ++ margins.right += width; ++ margins.left += width; ++ break; ++ case Meta.MaximizeFlags.VERTICAL: ++ margins.top += width; ++ margins.bottom += width; ++ break; ++ } ++ ++ if (win.is_fullscreen()) { ++ margins.top += 3; ++ margins.right += 2; ++ margins.bottom -= (wayland ? 3 : 0); ++ margins.left += 3; ++ } ++ ++ if (!wayland && !win.decorated && !win.is_fullscreen() && (win.get_maximized() !== Meta.MaximizeFlags.BOTH)) { ++ margins.bottom += 4; ++ } ++ ++ } ++ ++ draw_rect(node, x, y, width, height) { ++ const box = new Clutter.ActorBox(); ++ box.set_origin(x, y); ++ box.set_size(width, height); ++ node.add_rectangle(box); ++ } ++ ++ draw_hline(node, x, y, size, line_width = 2) { ++ this.draw_rect(node, x, y, size, line_width); ++ } ++ ++ draw_vline(node, x, y, size, line_width = 2) { ++ this.draw_rect(node, x, y, line_width, size); ++ } ++ ++ vfunc_paint_node(node, ctx) { ++ let actor = this.get_actor(); ++ ++ const actorNode = new Clutter.ActorNode(actor, -1); ++ node.add_child(actorNode); ++ ++ if (!this._pipeline) { ++ let framebuffer = ctx.get_framebuffer(); ++ let coglContext = framebuffer.get_context(); ++ let color = new Cogl.Color(); ++ color.init_from_4ub(this.r, this.g, this.b, 0xc4); ++ this._pipeline = new Cogl.Pipeline(coglContext); ++ this._pipeline.set_color(color); ++ } ++ ++ let win = actor.get_meta_window(); ++ let frame_rect = win.get_frame_rect(); ++ let buffer_rect = win.get_buffer_rect(); ++ let borderX = frame_rect.x - buffer_rect.x; ++ let borderY = frame_rect.y - buffer_rect.y; ++ ++ let margins = { ++ top: borderY - 3, ++ bottom: borderY - 1, ++ left: borderX - 3, ++ right: borderX - 3, ++ }; ++ ++ let wayland = win.get_client_type() == Meta.WindowClientType.WAYLAND; ++ ++ if (wayland) { ++ margins.bottom += 4; ++ } ++ ++ let width = 2; ++ ++ switch (win.get_maximized()) { ++ case Meta.MaximizeFlags.BOTH: ++ margins.top += width; ++ margins.right += width; ++ margins.bottom += width - (wayland ? 5 : 0); ++ margins.left += width; ++ break; ++ case Meta.MaximizeFlags.HORIZONTAL: ++ margins.right += width; ++ margins.left += width; ++ break; ++ case Meta.MaximizeFlags.VERTICAL: ++ margins.top += width; ++ margins.bottom += width; ++ break; ++ } ++ ++ if (win.is_fullscreen()) { ++ margins.top += 3; ++ margins.right += 2; ++ margins.bottom -= (wayland ? 3 : 0); ++ margins.left += 3; ++ } ++ ++ if (!wayland && !win.decorated && !win.is_fullscreen() && (win.get_maximized() !== Meta.MaximizeFlags.BOTH)) { ++ margins.bottom += 4; ++ } ++ ++ const pipelineNode = new Clutter.PipelineNode(this._pipeline); ++ pipelineNode.set_name('Realm Frame'); ++ node.add_child(pipelineNode); ++ ++ const render_box = new Clutter.ActorBox(); ++ ++ let alloc = actor.get_allocation_box(); ++ ++ let w = alloc.get_width() - (margins.right + margins.left); ++ let h = alloc.get_height() - (margins.bottom + margins.top + width); ++ ++ // Clockwise starting at top ++ ++ // Top ++ ++ this.draw_hline(pipelineNode, margins.left, margins.top + width, w, width * 2); ++ ++ // Right ++ this.draw_vline(pipelineNode, alloc.get_width() - width - margins.right, width + margins.top, h); ++ ++ // Bottom ++ this.draw_hline(pipelineNode, margins.left, alloc.get_height() - width - margins.bottom, w); ++ ++ // Left ++ this.draw_vline(pipelineNode, margins.left, margins.top + width, h); ++ } ++ }); +diff --git a/js/ui/realms/realmWindowMenu.js b/js/ui/realms/realmWindowMenu.js +new file mode 100644 +index 0000000..1aef4d0 +--- /dev/null ++++ b/js/ui/realms/realmWindowMenu.js +@@ -0,0 +1,113 @@ ++ ++const { Shell, GObject } = imports.gi; ++ ++const PopupMenu = imports.ui.popupMenu; ++ ++function _windowAppId(window) { ++ const tracker = Shell.WindowTracker.get_default(); ++ const app = tracker.get_window_app(window); ++ if (app) { ++ return app.get_id(); ++ } else { ++ log(`No app found for window ${window.get_description()}`) ++ return null; ++ } ++} ++ ++function windowMenuDebugString(window) { ++ const id = _windowAppId(window); ++ const realm_name = windowRealmName(window); ++ ++ if (!realm_name) { ++ return id; ++ } else if (window.is_on_foreign_workspace_context()) { ++ return `${id} [${realm_name}]`; ++ } else { ++ return `${id} (${realm_name})`; ++ } ++} ++ ++function _createMoveWindowItem(label, realm_name, window) { ++ let item = new PopupMenu.PopupMenuItem(label); ++ item.connect('activate', () => { ++ let realms = Shell.Realms.get_default(); ++ let realm = realms.realm_by_name(realm_name); ++ ++ if (realm) { ++ realm.move_window_to_context(window); ++ } ++ }); ++ return item; ++} ++ ++// Return name of the realm the application this window belongs to is running in. ++function windowRealmName(window) { ++ const realms = Shell.Realms.get_default(); ++ ++ if (realms.is_citadel_window(window)) { ++ return "Citadel" ++ } ++ ++ let realm = realms.realm_by_window(window); ++ ++ if (realm) { ++ return realm.realm_name; ++ } else { ++ return null; ++ } ++} ++ ++// Return name of realm the context this window is currently located on belongs to ++function windowContextRealmName(window) { ++ if (window.on_all_workspaces) { ++ return windowRealmName(window); ++ } ++ ++ let ws = window.get_workspace(); ++ ++ if (!ws) { ++ return null; ++ } ++ const realms = Shell.Realms.get_default(); ++ let realm = realms.realm_by_context_id(ws.get_context_id()); ++ ++ if (realm) { ++ return realm.realm_name; ++ } else { ++ return null; ++ } ++} ++ ++function realmWindowMenu(window) { ++ ++ const realm_name = windowContextRealmName(window); ++ ++ if (!realm_name) { ++ return null; ++ } ++ ++ const realms = Shell.Realms.get_default(); ++ let other_realms = []; ++ ++ let running_realms = realms.get_running_realms(); ++ running_realms.forEach(realm => { ++ if (realm.realm_name != realm_name) { ++ other_realms.push(realm.realm_name); ++ } ++ }); ++ ++ if (other_realms.length == 0) { ++ return null; ++ } else if (other_realms.length == 1) { ++ let name = other_realms[0]; ++ return _createMoveWindowItem(`Move to realm-${name}`, name, window); ++ } ++ ++ let subMenu = new PopupMenu.PopupSubMenuMenuItem('Move to Realm...', true); ++ ++ other_realms.forEach(name => { ++ let item = _createMoveWindowItem(`realm-${name}`, name, window); ++ subMenu.menu.addMenuItem(item); ++ }); ++ return subMenu; ++} +\ No newline at end of file +diff --git a/js/ui/windowManager.js b/js/ui/windowManager.js +index caaecec..a8ff7f9 100644 +--- a/js/ui/windowManager.js ++++ b/js/ui/windowManager.js +@@ -198,6 +198,8 @@ var WorkspaceTracker = class { + workspaceManager.connect('workspaces-reordered', () => { + this._workspaces.sort((a, b) => a.index() - b.index()); + }); ++ workspaceManager.connect('context-switched', ++ this._workspaceContextSwitched.bind(this)); + global.window_manager.connect('switch-workspace', + this._queueCheckWorkspaces.bind(this)); + +@@ -253,6 +255,8 @@ var WorkspaceTracker = class { + emptyWorkspaces[index] = false; + } + ++ let current_context_id = workspaceManager.active_context_id(); ++ + let windows = global.get_window_actors(); + for (i = 0; i < windows.length; i++) { + let actor = windows[i]; +@@ -261,7 +265,12 @@ var WorkspaceTracker = class { + if (win.is_on_all_workspaces()) + continue; + +- let workspaceIndex = win.get_workspace().index(); ++ let workspace = win.get_workspace(); ++ ++ if (workspace.get_context_id() != current_context_id) ++ continue; ++ ++ let workspaceIndex = workspace.index(); + emptyWorkspaces[workspaceIndex] = false; + } + +@@ -339,6 +348,28 @@ var WorkspaceTracker = class { + this._checkWorkspacesId = Meta.later_add(Meta.LaterType.BEFORE_REDRAW, this._checkWorkspaces.bind(this)); + } + ++ ++ _workspaceContextSwitched() { ++ let workspaceManager = global.workspace_manager; ++ let numWorkspaces = workspaceManager.n_workspaces; ++ ++ this._workspaces.forEach(workspace => { ++ workspace.disconnect(workspace._windowAddedId); ++ workspace.disconnect(workspace._windowRemovedId); ++ }); ++ ++ this._workspaces = []; ++ ++ for (let w = 0; w < numWorkspaces; w++) { ++ let workspace = workspaceManager.get_workspace_by_index(w); ++ workspace._windowAddedId = workspace.connect('window-added', this._queueCheckWorkspaces.bind(this)); ++ workspace._windowRemovedId = workspace.connect('window-removed', this._windowRemoved.bind(this)); ++ this._workspaces[w] = workspace; ++ } ++ this._queueCheckWorkspaces(); ++ return false; ++ } ++ + _nWorkspacesChanged() { + let workspaceManager = global.workspace_manager; + let oldNumWorkspaces = this._workspaces.length; +@@ -1641,6 +1672,14 @@ var WindowManager = class { + + this._switchInProgress = true; + ++ if (direction == Meta.MotionDirection.CONTEXT_SWITCH) { ++ Main.realmManager.animateSwitch(from, to, () => { ++ this._shellwm.completed_switch_workspace(); ++ this._switchInProgress = false; ++ }); ++ return; ++ } ++ + this._workspaceAnimation.animateSwitch(from, to, direction, () => { + this._shellwm.completed_switch_workspace(); + this._switchInProgress = false; +diff --git a/js/ui/windowMenu.js b/js/ui/windowMenu.js +index 27cecda..b238b86 100644 +--- a/js/ui/windowMenu.js ++++ b/js/ui/windowMenu.js +@@ -1,11 +1,12 @@ + // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -* + /* exported WindowMenuManager */ + +-const { GLib, Meta, St } = imports.gi; ++const { GLib, Meta, Shell, St } = imports.gi; + + const BoxPointer = imports.ui.boxpointer; + const Main = imports.ui.main; + const PopupMenu = imports.ui.popupMenu; ++const RealmWindowMenu = imports.ui.realms.realmWindowMenu; + + var WindowMenu = class extends PopupMenu.PopupMenu { + constructor(window, sourceActor) { +@@ -24,6 +25,18 @@ var WindowMenu = class extends PopupMenu.PopupMenu { + + let item; + ++ let s = RealmWindowMenu.windowMenuDebugString(window); ++ ++ this.addMenuItem(new PopupMenu.PopupSeparatorMenuItem(s)); ++ ++ if (!window.is_on_all_workspaces()) { ++ let realmSubmenu = RealmWindowMenu.realmWindowMenu(window); ++ if (realmSubmenu) { ++ this.addMenuItem(realmSubmenu); ++ } ++ } ++ this.addMenuItem(new PopupMenu.PopupSeparatorMenuItem()); ++ + item = this.addAction(_('Hide'), () => { + window.minimize(); + }); +diff --git a/js/ui/workspacesView.js b/js/ui/workspacesView.js +index 3761881..b662d05 100644 +--- a/js/ui/workspacesView.js ++++ b/js/ui/workspacesView.js +@@ -122,6 +122,10 @@ class WorkspacesView extends WorkspacesViewBase { + this._updateWorkspacesId = + workspaceManager.connect('notify::n-workspaces', + this._updateWorkspaces.bind(this)); ++ this._contextSwitchedId = ++ workspaceManager.connect('context-switched', ++ this._refreshWorkspaces.bind(this)); ++ + this._reorderWorkspacesId = + workspaceManager.connect('workspaces-reordered', () => { + this._workspaces.sort((a, b) => { +@@ -450,6 +454,13 @@ class WorkspacesView extends WorkspacesViewBase { + } + } + ++ _refreshWorkspaces() { ++ for (let ws = this._workspaces.pop(); ws; ws = this._workspaces.pop()) { ++ ws.destroy(); ++ } ++ this._updateWorkspaces(); ++ } ++ + _updateWorkspaces() { + let workspaceManager = global.workspace_manager; + let newNumWorkspaces = workspaceManager.n_workspaces; +@@ -499,6 +510,7 @@ class WorkspacesView extends WorkspacesViewBase { + global.window_manager.disconnect(this._switchWorkspaceNotifyId); + let workspaceManager = global.workspace_manager; + workspaceManager.disconnect(this._updateWorkspacesId); ++ workspaceManager.disconnect(this._contextSwitchedId); + workspaceManager.disconnect(this._reorderWorkspacesId); + } + +diff --git a/src/meson.build b/src/meson.build +index 5fa9fdf..65c18ab 100644 +--- a/src/meson.build ++++ b/src/meson.build +@@ -125,6 +125,7 @@ libshell_private_headers = [ + 'shell-app-cache-private.h', + 'shell-app-system-private.h', + 'shell-global-private.h', ++ 'shell-realms-private.h', + 'shell-window-tracker-private.h', + 'shell-wm-private.h' + ] +@@ -147,6 +148,12 @@ libshell_sources = [ + 'shell-perf-log.c', + 'shell-polkit-authentication-agent.c', + 'shell-polkit-authentication-agent.h', ++ 'shell-realm-item.c', ++ 'shell-realm-item.h', ++ 'shell-realms.c', ++ 'shell-realms.h', ++ 'shell-realm-tracker.c', ++ 'shell-realm-tracker.h', + 'shell-screenshot.c', + 'shell-secure-text-buffer.c', + 'shell-secure-text-buffer.h', +diff --git a/src/shell-app-cache.c b/src/shell-app-cache.c +index 44fc8b0..092e83f 100644 +--- a/src/shell-app-cache.c ++++ b/src/shell-app-cache.c +@@ -23,7 +23,7 @@ + * Shell is running. + */ + +-#define DEFAULT_TIMEOUT_SECONDS 5 ++#define DEFAULT_TIMEOUT_SECONDS 2 + + struct _ShellAppCache + { +diff --git a/src/shell-app-system.c b/src/shell-app-system.c +index 828fa72..033e731 100644 +--- a/src/shell-app-system.c ++++ b/src/shell-app-system.c +@@ -12,6 +12,7 @@ + #include "shell-app-cache-private.h" + #include "shell-app-private.h" + #include "shell-window-tracker-private.h" ++#include "shell-realms.h" + #include "shell-app-system-private.h" + #include "shell-global.h" + #include "shell-util.h" +@@ -91,6 +92,110 @@ static void shell_app_system_class_init(ShellAppSystemClass *klass) + G_TYPE_NONE, 0); + } + ++/* ++ * Applications belonging to realms have a prefix added to the filenames ++ * of their desktop files indicating the name of the realm. For example ++ * in a realm called 'main' the desktop file 'org.gnome.Terminal.desktop' ++ * is renamed to 'realm-main.org.gnome.Terminal.desktop'. ++ * ++ * This has the effect of creating a separate application ID for instances ++ * of the same application in multiple realms. ++ */ ++static const char * ++realm_name_from_application_id (const char *id) ++{ ++ gchar **split = NULL; ++ const char *result = NULL; ++ ++ if (!g_str_has_prefix (id, "realm-")) { ++ return NULL; ++ } ++ ++ split = g_strsplit(id, ".", 2); ++ ++ if (split[0]) { ++ g_assert_true (g_str_has_prefix (split[0], "realm-")); ++ result = g_strdup(split[0] + 6); ++ } ++ ++ g_strfreev (split); ++ return result; ++} ++ ++ ++char * ++current_realm_name (gboolean name_only) ++{ ++ gchar *link = NULL; ++ gchar *p = NULL; ++ gchar *realm = NULL; ++ ++ link = g_file_read_link ("/run/citadel/realms/current/current.realm", NULL); ++ ++ if (link) { ++ p = g_strrstr(link, "/realm-"); ++ if (p) { ++ /* skip slash character */ ++ p++; ++ if (name_only) { ++ /* skip 'realm-' */ ++ p += 6; ++ } ++ realm = g_strdup(p); ++ } ++ g_free (link); ++ } ++ ++ return realm; ++} ++ ++static gboolean ++is_current_realm_app (const char *id, const char *current_realm) ++{ ++ ++ return !g_str_has_prefix (id, "realm-") || g_str_has_prefix (id, current_realm); ++} ++ ++static void ++refresh_installed_apps (ShellAppSystem *self) ++{ ++ const GList *l; ++ GAppInfo *app; ++ const char *app_id; ++ char *current_realm; ++ ShellAppSystemPrivate *priv = self->priv; ++ ++ g_list_free_full (g_steal_pointer (&priv->installed_apps), g_object_unref); ++ ++ l = shell_app_cache_get_all (shell_app_cache_get_default ()); ++ ++ current_realm = current_realm_name (FALSE); ++ ++ while (l) { ++ app = l->data; ++ app_id = g_app_info_get_id (app); ++ ++ if (is_current_realm_app (app_id, current_realm)) { ++ priv->installed_apps = g_list_prepend (priv->installed_apps, g_object_ref (app)); ++ } ++ l = l->next; ++ } ++ priv->installed_apps = g_list_reverse (priv->installed_apps); ++ ++ g_free (current_realm); ++} ++ ++ ++static char * ++realm_wm_class (const char *wmclass, const char *realm_name) ++{ ++ if (realm_name) { ++ return g_strdup_printf ("realm-%s.%s", realm_name, wmclass); ++ } else { ++ return g_strdup (wmclass); ++ } ++} ++ + static void + scan_startup_wm_class_to_id (ShellAppSystem *self) + { +@@ -106,6 +211,7 @@ scan_startup_wm_class_to_id (ShellAppSystem *self) + { + GAppInfo *info = l->data; + const char *startup_wm_class, *id, *old_id; ++ char *realm_wmclass; + + id = g_app_info_get_id (info); + startup_wm_class = g_desktop_app_info_get_startup_wm_class (G_DESKTOP_APP_INFO (info)); +@@ -113,12 +219,17 @@ scan_startup_wm_class_to_id (ShellAppSystem *self) + if (startup_wm_class == NULL) + continue; + ++ realm_wmclass = realm_wm_class (startup_wm_class, realm_name_from_application_id (id)); ++ + /* In case multiple .desktop files set the same StartupWMClass, prefer + * the one where ID and StartupWMClass match */ +- old_id = g_hash_table_lookup (priv->startup_wm_class_to_id, startup_wm_class); +- if (old_id == NULL || strcmp (id, startup_wm_class) == 0) ++ old_id = g_hash_table_lookup (priv->startup_wm_class_to_id, realm_wmclass); ++ if (old_id == NULL || strcmp (id, startup_wm_class) == 0) { + g_hash_table_insert (priv->startup_wm_class_to_id, +- g_strdup (startup_wm_class), g_strdup (id)); ++ g_strdup (realm_wmclass), g_strdup (id)); ++ } ++ ++ g_free (realm_wmclass); + } + } + +@@ -347,15 +458,19 @@ shell_app_system_lookup_heuristic_basename (ShellAppSystem *system, + */ + ShellApp * + shell_app_system_lookup_desktop_wmclass (ShellAppSystem *system, +- const char *wmclass) ++ const char *wmclass, ++ const char *realm_name) + { + char *canonicalized; + char *desktop_file; ++ char *classname; + ShellApp *app; + + if (wmclass == NULL) + return NULL; + ++ classname = realm_wm_class (wmclass, realm_name); ++ + /* First try without changing the case (this handles + org.example.Foo.Bar.desktop applications) + +@@ -363,14 +478,16 @@ shell_app_system_lookup_desktop_wmclass (ShellAppSystem *system, + the WM_CLASS to Org.example.Foo.Bar, but it also + sets the instance part to org.example.Foo.Bar, so we're ok + */ +- desktop_file = g_strconcat (wmclass, ".desktop", NULL); ++ desktop_file = g_strconcat (classname, ".desktop", NULL); + app = shell_app_system_lookup_heuristic_basename (system, desktop_file); + g_free (desktop_file); + +- if (app) ++ if (app) { ++ g_free (classname); + return app; ++ } + +- canonicalized = g_ascii_strdown (wmclass, -1); ++ canonicalized = g_ascii_strdown (classname, -1); + + /* This handles "Fedora Eclipse", probably others. + * Note g_strdelimit is modify-in-place. */ +@@ -382,6 +499,7 @@ shell_app_system_lookup_desktop_wmclass (ShellAppSystem *system, + + g_free (canonicalized); + g_free (desktop_file); ++ g_free (classname); + + return app; + } +@@ -398,14 +516,20 @@ shell_app_system_lookup_desktop_wmclass (ShellAppSystem *system, + */ + ShellApp * + shell_app_system_lookup_startup_wmclass (ShellAppSystem *system, +- const char *wmclass) ++ const char *wmclass, ++ const char *realm_name) + { + const char *id; ++ char *classname; + + if (wmclass == NULL) + return NULL; + +- id = g_hash_table_lookup (system->priv->startup_wm_class_to_id, wmclass); ++ classname = realm_wm_class (wmclass, realm_name); ++ ++ id = g_hash_table_lookup (system->priv->startup_wm_class_to_id, classname); ++ g_free (classname); ++ + if (id == NULL) + return NULL; + +@@ -435,6 +559,29 @@ _shell_app_system_notify_app_state_changed (ShellAppSystem *self, + g_signal_emit (self, signals[APP_STATE_CHANGED], 0, app); + } + ++static gboolean ++is_current_realm_context_app(ShellApp *app) ++{ ++ ShellRealms *realms = shell_realms_get_default(); ++ ShellRealmItem *item = shell_realms_current_realm (realms); ++ guint id = (item) ? shell_realm_item_get_context_id (item) : 0; ++ ++ GSList *iter = shell_app_get_windows (app); ++ ++ while (iter) { ++ MetaWindow *window = iter->data; ++ if (meta_window_is_on_all_workspaces (window)) { ++ return true; ++ } ++ MetaWorkspace *workspace = meta_window_get_workspace (window); ++ if (meta_workspace_get_context_id (workspace) == id) { ++ return true; ++ } ++ iter = iter->next; ++ } ++ return false; ++} ++ + /** + * shell_app_system_get_running: + * @self: A #ShellAppSystem +@@ -458,7 +605,9 @@ shell_app_system_get_running (ShellAppSystem *self) + { + ShellApp *app = key; + +- ret = g_slist_prepend (ret, app); ++ if (is_current_realm_context_app (app)) { ++ ret = g_slist_prepend (ret, app); ++ } + } + + ret = g_slist_sort (ret, (GCompareFunc)shell_app_compare); +@@ -482,12 +631,16 @@ shell_app_system_search (const char *search_string) + { + char ***results = g_desktop_app_info_search (search_string); + char ***groups, **ids; ++ char *current_realm; ++ ++ current_realm = current_realm_name (FALSE); + + for (groups = results; *groups; groups++) + for (ids = *groups; *ids; ids++) +- if (!g_utf8_validate (*ids, -1, NULL)) ++ if (!g_utf8_validate (*ids, -1, NULL) || !is_current_realm_app (*ids, current_realm)) + **ids = '\0'; + ++ g_free (current_realm); + return results; + } + +@@ -504,5 +657,7 @@ shell_app_system_search (const char *search_string) + GList * + shell_app_system_get_installed (ShellAppSystem *self) + { +- return shell_app_cache_get_all (shell_app_cache_get_default ()); ++ ShellAppSystemPrivate *priv = self->priv; ++ refresh_installed_apps (self); ++ return priv->installed_apps; + } +diff --git a/src/shell-app-system.h b/src/shell-app-system.h +index 8719dbc..6a0203e 100644 +--- a/src/shell-app-system.h ++++ b/src/shell-app-system.h +@@ -20,9 +20,11 @@ ShellApp *shell_app_system_lookup_heuristic_basename (ShellAppSystem * + const char *id); + + ShellApp *shell_app_system_lookup_startup_wmclass (ShellAppSystem *system, +- const char *wmclass); ++ const char *wmclass, ++ const char *realm_name); + ShellApp *shell_app_system_lookup_desktop_wmclass (ShellAppSystem *system, +- const char *wmclass); ++ const char *wmclass, ++ const char *realm_name); + + GSList *shell_app_system_get_running (ShellAppSystem *self); + char ***shell_app_system_search (const char *search_string); +diff --git a/src/shell-global.c b/src/shell-global.c +index e8705f5..c97510f 100644 +--- a/src/shell-global.c ++++ b/src/shell-global.c +@@ -44,6 +44,7 @@ + #include "shell-util.h" + #include "st.h" + #include "switcheroo-control.h" ++#include "shell-realm-tracker.h" + + static ShellGlobal *the_object = NULL; + +@@ -1068,6 +1069,8 @@ _shell_global_set_plugin (ShellGlobal *global, + global->focus_manager = st_focus_manager_get_for_stage (global->stage); + + update_scaling_factor (global, settings); ++ ++ shell_realm_tracker_start (); + } + + GjsContext * +diff --git a/src/shell-realm-item.c b/src/shell-realm-item.c +new file mode 100644 +index 0000000..6ea84bd +--- /dev/null ++++ b/src/shell-realm-item.c +@@ -0,0 +1,392 @@ ++#include "shell-global.h" ++#include "shell-realm-item.h" ++#include "shell-realm-tracker.h" ++#include ++#include ++ ++struct _ShellRealmItem { ++ GObject parent; ++ char *realm_name; ++ char *description; ++ char *namespace; ++ MetaWorkspaceContext *context; ++ guint8 status; ++ gboolean tagged; ++ gboolean disposed; ++}; ++ ++G_DEFINE_TYPE (ShellRealmItem, shell_realm_item, G_TYPE_OBJECT); ++ ++ ++enum { ++ PROP_0, ++ PROP_ITEM_REALM_NAME, ++ PROP_ITEM_DESCRIPTION, ++ PROP_ITEM_NAMESPACE ++}; ++ ++#define REALM_STATUS_RUNNING 1 ++#define REALM_STATUS_CURRENT 2 ++#define REALM_STATUS_SYSTEM 4 ++ ++static void ++shell_realm_item_init(ShellRealmItem *item) ++{ ++} ++ ++ShellRealmItem * ++shell_realm_item_new (const char *realm_name, const char *description, const char *namespace, guint8 status) ++{ ++ ShellRealmItem *item = g_object_new (SHELL_TYPE_REALM_ITEM, NULL); ++ item->realm_name = g_strdup (realm_name); ++ item->description = g_strdup (description); ++ item->namespace = g_strdup (namespace); ++ item->status = status; ++ item->context = NULL; ++ item->tagged = FALSE; ++ item->disposed = FALSE; ++ ++ return item; ++} ++ ++void ++shell_realm_item_acquire_context (ShellRealmItem *item) ++{ ++ if (item->context || item->disposed || shell_realm_item_is_system (item)) { ++ return; ++ } ++ ++ if (!item->namespace || !shell_realm_item_is_running (item)) { ++ g_warning ("ShellRealmItem: Cannot acquire workspace context for realm '%s' because not running or no namespace", item->realm_name); ++ return; ++ } ++ ++ MetaDisplay *display = shell_global_get_display (shell_global_get()); ++ MetaWorkspaceManager *workspace_manager = meta_display_get_workspace_manager (display); ++ item->context = meta_workspace_manager_context_for_namespace (workspace_manager, item->namespace); ++} ++ ++/** ++ * shell_realm_item_get_realm_name: ++ * @item: A #ShellRealmItem instance ++ * ++ * Returns: The name of the realm for this #ShellRealmItem ++ */ ++const char * ++shell_realm_item_get_realm_name (ShellRealmItem *item) ++{ ++ return item->realm_name; ++} ++ ++/** ++ * shell_realm_item_get_description: ++ * @item: A #ShellRealmItem instance ++ * ++ * Returns: The description field for this realm or an empty string if no description is set ++ */ ++const char * ++shell_realm_item_get_description (ShellRealmItem *item) ++{ ++ if (item->description) ++ return item->description; ++ else ++ return ""; ++} ++ ++ ++/** ++ * shell_realm_item_get_namespace: ++ * @item: A #ShellRealmItem instance ++ * ++ * Returns: The namespace field for this realm or an empty string if no namespace is set ++ */ ++const char * ++shell_realm_item_get_namespace (ShellRealmItem *item) ++{ ++ if (item->namespace) ++ return item->namespace; ++ else ++ return ""; ++} ++ ++/** ++ * shell_realm_item_get_context_id: ++ * @item: A #ShellRealmItem instance ++ * ++ * Returns: The context id for the #MetaWorkspaceContext of this realm or 0 if ++ * no context exists. ++ */ ++guint ++shell_realm_item_get_context_id (ShellRealmItem *item) ++{ ++ if (shell_realm_item_is_running (item) && !item->context) { ++ shell_realm_item_acquire_context (item); ++ } ++ ++ if (item->context) { ++ return meta_workspace_context_id (item->context); ++ } else { ++ return 0; ++ } ++} ++ ++/** ++ * shell_realm_item_get_active_workspace: ++ * @item: A #ShellRealmItem ++ * ++ * Returns: (transfer none): The current workspace for the context ++ * belonging to this item. ++ */ ++MetaWorkspace * ++shell_realm_item_get_active_workspace (ShellRealmItem *item) ++{ ++ if (shell_realm_item_is_running (item) && !item->context) { ++ shell_realm_item_acquire_context (item); ++ } ++ ++ if (item->context) { ++ return meta_workspace_context_get_active_workspace (item->context); ++ } else { ++ return NULL; ++ } ++} ++ ++/** ++ * shell_realm_item_activate_context: ++ * @item: A #ShellRealmItem instance for a running realm ++ * ++ * If a #MetaWorkspaceContext is associated with this realm ++ * set it as the active workspace context. ++ */ ++void ++shell_realm_item_activate_context (ShellRealmItem *item) ++{ ++ shell_realm_item_acquire_context (item); ++ ++ if (item->context) { ++ meta_workspace_context_activate (item->context); ++ } ++} ++ ++/** ++ * shell_realm_item_set_current: ++ * @item: A #ShellRealmItem instance for a running realm ++ * ++ * Sends a DBUS request to change the current realm to this realm. This does not immediately ++ * influence any local state in GNOME shell. Once the realms daemon has changed the current realm ++ * it will emit a signal and the processing of that signal will update the local state. ++ */ ++void ++shell_realm_item_set_current (ShellRealmItem *item) { ++ ShellRealmTracker *tracker = shell_realm_tracker_get_default(); ++ if (item && item->realm_name) { ++ shell_realm_tracker_call_set_current (tracker, item->realm_name); ++ } ++} ++ ++/** ++ * shell_realm_item_move_window_to_context: ++ * @item: A #ShellRealmItem instance for a running realm ++ * @window: A #MetaWindow for some window ++ * ++ * Move window to the currently active workspace in the #MetaWorkspaceContext for ++ * this realm. ++ */ ++void ++shell_realm_item_move_window_to_context (ShellRealmItem *item, MetaWindow *window) ++{ ++ shell_realm_item_acquire_context (item); ++ ++ if (item->context) { ++ meta_workspace_context_move_window_to_context (item->context, window); ++ } else { ++ g_warning ("ShellRealmItem: Attempted to move window to realm '%s' which has no workspace context", item->realm_name); ++ } ++} ++ ++static gboolean ++is_flag_set(guint8 status, guchar flag) ++{ ++ return ((status & flag) != 0) ? TRUE : FALSE; ++} ++ ++static gboolean ++has_status_flag (ShellRealmItem *item, guchar flag) ++{ ++ return is_flag_set (item->status, flag); ++} ++ ++static void ++set_status_flag (ShellRealmItem *item, guint8 flag, gboolean value) ++{ ++ if (value) { ++ item->status |= flag; ++ } else { ++ item->status &= ~flag; ++ } ++} ++ ++/** ++ * shell_realm_item_is_current: ++ * @item: A #ShellRealmItem instance ++ * ++ * Returns: %TRUE if this #ShellRealmItem is the current realm ++ */ ++gboolean ++shell_realm_item_is_current (ShellRealmItem *item) ++{ ++ return has_status_flag (item, REALM_STATUS_CURRENT); ++} ++ ++/** ++ * shell_realm_item_is_running: ++ * @item: A #ShellRealmItem instance ++ * ++ * Returns: %TRUE if this #ShellRealmItem is running ++ */ ++gboolean ++shell_realm_item_is_running (ShellRealmItem *item) ++{ ++ return has_status_flag (item, REALM_STATUS_RUNNING); ++} ++ ++/** ++ * shell_realm_item_is_system: ++ * @item: A #ShellRealmItem instance ++ * ++ * Returns: %TRUE if this #ShellRealmItem is a system realm ++ */ ++gboolean ++shell_realm_item_is_system (ShellRealmItem *item) ++{ ++ return has_status_flag (item, REALM_STATUS_SYSTEM); ++} ++ ++ ++void shell_realm_item_set_current_flag (ShellRealmItem *item, gboolean value) ++{ ++ set_status_flag (item, REALM_STATUS_CURRENT, value); ++} ++ ++void shell_realm_item_set_running_flag (ShellRealmItem *item, gboolean value) ++{ ++ set_status_flag (item, REALM_STATUS_RUNNING, value); ++ ++ if (!value && item->context) { ++ g_clear_object(&item->context); ++ } ++} ++ ++ ++void shell_realm_item_update (ShellRealmItem *item, const char *realm_name, const char *namespace, guint8 status) ++{ ++ if (g_strcmp0 (item->realm_name, realm_name)) { ++ g_message ("ShellRealmItem: Realm name changed from %s to %s", item->realm_name, realm_name); ++ g_free (item->realm_name); ++ item->realm_name = g_strdup (realm_name); ++ } ++ ++ if (g_strcmp0 (item->namespace, namespace)) { ++ g_free(item->namespace); ++ item->namespace = g_strdup (namespace); ++ } ++ ++ if (item->status != status) { ++ gboolean was_running = has_status_flag (item, REALM_STATUS_RUNNING); ++ gboolean is_running = is_flag_set (status, REALM_STATUS_RUNNING); ++ gboolean stopped = was_running && !is_running; ++ ++ item->status = status; ++ ++ if (stopped) { ++ g_clear_object(&item->context); ++ } ++ } ++} ++ ++void ++shell_realm_item_set_tagged (ShellRealmItem *item, gboolean is_tagged) ++{ ++ item->tagged = is_tagged; ++} ++ ++gboolean ++shell_realm_item_is_tagged (ShellRealmItem *item) ++{ ++ return item->tagged; ++} ++ ++static void shell_realm_item_get_property (GObject *gobject, ++ guint prop_id, ++ GValue *value, ++ GParamSpec *pspec) ++{ ++ ShellRealmItem *item = SHELL_REALM_ITEM (gobject); ++ switch (prop_id) { ++ case PROP_ITEM_REALM_NAME: ++ g_value_set_string (value, shell_realm_item_get_realm_name (item)); ++ break; ++ case PROP_ITEM_DESCRIPTION: ++ g_value_set_string (value, shell_realm_item_get_description (item)); ++ break; ++ case PROP_ITEM_NAMESPACE: ++ g_value_set_string (value, shell_realm_item_get_namespace (item)); ++ break; ++ default: ++ G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec); ++ break; ++ } ++} ++ ++static void shell_realm_item_dispose (GObject *object) ++{ ++ ShellRealmItem *item = SHELL_REALM_ITEM (object); ++ g_clear_object(&item->context); ++ item->disposed = TRUE; ++ G_OBJECT_CLASS(shell_realm_item_parent_class)->dispose (object); ++} ++ ++static void ++shell_realm_item_finalize (GObject *object) ++{ ++ ShellRealmItem *item = SHELL_REALM_ITEM (object); ++ g_message("ShellRealmItem: finalize (%s)", item->realm_name); ++ g_free (item->realm_name); ++ g_free (item->description); ++ g_free (item->namespace); ++ ++ G_OBJECT_CLASS(shell_realm_item_parent_class)->finalize (object); ++} ++ ++static void ++shell_realm_item_class_init (ShellRealmItemClass *klass) ++{ ++ GObjectClass *gobject_class = G_OBJECT_CLASS (klass); ++ ++ gobject_class->get_property = shell_realm_item_get_property; ++ gobject_class->dispose = shell_realm_item_dispose; ++ gobject_class->finalize = shell_realm_item_finalize; ++ ++ g_object_class_install_property (gobject_class, ++ PROP_ITEM_NAMESPACE, ++ g_param_spec_string ("namespace", ++ "Context Namespace", ++ "PID namespace of context", ++ NULL, ++ G_PARAM_READABLE | G_PARAM_STATIC_STRINGS)); ++ g_object_class_install_property (gobject_class, ++ PROP_ITEM_REALM_NAME, ++ g_param_spec_string ("realm-name", ++ "Realm Name", ++ "Name of realm associated with this context", ++ NULL, ++ G_PARAM_READABLE | G_PARAM_STATIC_STRINGS)); ++ ++ g_object_class_install_property (gobject_class, ++ PROP_ITEM_DESCRIPTION, ++ g_param_spec_string ("description", ++ "Realm Description", ++ "Optional description of realm", ++ NULL, ++ G_PARAM_READABLE | G_PARAM_STATIC_STRINGS)); ++} +\ No newline at end of file +diff --git a/src/shell-realm-item.h b/src/shell-realm-item.h +new file mode 100644 +index 0000000..8e9d8ec +--- /dev/null ++++ b/src/shell-realm-item.h +@@ -0,0 +1,35 @@ ++#ifndef __SHELL_REALM_ITEM_H__ ++#define __SHELL_REALM_ITEM_H__ ++ ++#include ++#include ++ ++#define SHELL_TYPE_REALM_ITEM (shell_realm_item_get_type()) ++G_DECLARE_FINAL_TYPE (ShellRealmItem, shell_realm_item, SHELL, REALM_ITEM, GObject) ++ ++ShellRealmItem *shell_realm_item_new (const char *realm_name, const char *description, const char *namespace, guint8 status); ++ ++const char *shell_realm_item_get_realm_name (ShellRealmItem *item); ++const char *shell_realm_item_get_description (ShellRealmItem *item); ++const char *shell_realm_item_get_namespace (ShellRealmItem *item); ++guint shell_realm_item_get_context_id (ShellRealmItem *item); ++MetaWorkspace *shell_realm_item_get_active_workspace (ShellRealmItem *item); ++ ++void shell_realm_item_update (ShellRealmItem *item, const char *realm_name, const char *namespace, guint8 status); ++ ++ ++void shell_realm_item_set_current_flag (ShellRealmItem *item, gboolean value); ++void shell_realm_item_set_running_flag (ShellRealmItem *item, gboolean value); ++ ++void shell_realm_item_activate_context (ShellRealmItem *item); ++void shell_realm_item_set_current (ShellRealmItem *item); ++void shell_realm_item_move_window_to_context (ShellRealmItem *item, MetaWindow *window); ++gboolean shell_realm_item_is_current(ShellRealmItem *item); ++gboolean shell_realm_item_is_running(ShellRealmItem *item); ++gboolean shell_realm_item_is_system(ShellRealmItem *item); ++ ++void shell_realm_item_set_tagged (ShellRealmItem *item, gboolean is_tagged); ++gboolean shell_realm_item_is_tagged (ShellRealmItem *item); ++ ++void shell_realm_item_acquire_context (ShellRealmItem *item); ++#endif //__SHELL_REALM_ITEM_H__ +diff --git a/src/shell-realm-tracker.c b/src/shell-realm-tracker.c +new file mode 100644 +index 0000000..97cb6ed +--- /dev/null ++++ b/src/shell-realm-tracker.c +@@ -0,0 +1,297 @@ ++#include "shell-realm-tracker.h" ++#include "shell-realms-private.h" ++ ++#define NUM_BUS_SIGNAL_IDS 5 ++ ++#define REALMS_BUS_NAME "com.subgraph.realms" ++#define REALMS_OBJECT_PATH "/com/subgraph/realms" ++#define REALMS_MANAGER_INTERFACE "com.subgraph.realms.Manager" ++ ++struct _ShellRealmTracker { ++ GObject parent; ++ GDBusConnection *dbus; ++ guint realms_watch_id; ++ guint bus_signal_ids[NUM_BUS_SIGNAL_IDS]; ++ gboolean destroy_in_progress; ++}; ++ ++G_DEFINE_TYPE (ShellRealmTracker, shell_realm_tracker, G_TYPE_OBJECT); ++ ++static void ++shell_realm_tracker_init (ShellRealmTracker *tracker) ++{ ++ tracker->dbus = NULL; ++ tracker->realms_watch_id = 0; ++ tracker->destroy_in_progress = FALSE; ++} ++ ++static void ++shell_realm_tracker_class_init (ShellRealmTrackerClass *klass) ++{ ++} ++ ++static void ++on_realm_bus_signal(GDBusConnection *connection, ++ const gchar *sender_name, ++ const gchar *object_path, ++ const gchar *interface_name, ++ const gchar *signal_name, ++ GVariant *parameters, ++ gpointer user_data) ++{ ++ ShellRealms *realms = shell_realms_get_default(); ++ ++ const gchar *realm_name = NULL; ++ const gchar *description = NULL; ++ const gchar *namespace = NULL; ++ guint8 status = 0; ++ ++ g_message ("ShellRealmTracker: on_realm_bus_signal(%s)", signal_name); ++ ++ if (g_str_equal (signal_name, "RealmStarted")) { ++ ++ g_variant_get (parameters, "(&s&sy)", &realm_name, &namespace, &status); ++ shell_realms_on_realm_started (realms, realm_name, namespace, status); ++ ++ } else if (g_str_equal (signal_name, "RealmStopped")) { ++ ++ g_variant_get (parameters, "(&sy)", &realm_name, &status); ++ shell_realms_on_realm_stopped (realms, realm_name); ++ ++ } else if (g_str_equal (signal_name, "RealmRemoved")) { ++ ++ g_variant_get (parameters, "(&s)", &realm_name); ++ shell_realms_on_realm_removed (realms, realm_name); ++ ++ } else if (g_str_equal (signal_name, "RealmCurrent")) { ++ ++ g_variant_get (parameters, "(&sy)", &realm_name, &status); ++ shell_realms_on_realm_current (realms, realm_name); ++ ++ } else if (g_str_equal (signal_name, "RealmNew")) { ++ ++ g_variant_get (parameters, "(&s&sy)", &realm_name, &description, status); ++ shell_realms_on_realm_new (realms, realm_name, description, status); ++ ++ } else { ++ g_warning("Unexpected signal name '%s' received from realms manager DBUS", signal_name); ++ } ++} ++ ++static void ++realm_state_process_elements (ShellRealmTracker *self, GVariant *response) ++{ ++ ++ GVariantIter *iter = NULL; ++ const gchar *name = NULL; ++ const gchar *description = NULL; ++ const gchar *namespace = NULL; ++ guchar status = 0; ++ ++ ShellRealms *realms = shell_realms_get_default(); ++ shell_realms_untag_all (realms); ++ ++ g_variant_get(response, "(a(ssssy))", &iter); ++ ++ // (name, desc, realmfs, namespace, status) ++ while (g_variant_iter_next(iter, "(&s&ss&sy)", &name, &description, NULL, &namespace, &status)) { ++ shell_realms_update_realm (realms, name, description, namespace, status); ++ } ++ ++ shell_realms_remove_untagged (realms); ++ g_variant_iter_free(iter); ++} ++ ++static void ++request_realm_state_finish(GObject *object, GAsyncResult *result, gpointer data) ++{ ++ ShellRealmTracker *self = data; ++ ++ GError *error = NULL; ++ ++ GVariant *response = g_dbus_connection_call_finish (G_DBUS_CONNECTION(object), result, &error); ++ ++ if (!response) { ++ if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) { ++ g_warning("MetaRealmDbus: Error calling 'List' bus method: %s", error->message); ++ } ++ g_clear_error (&error); ++ return; ++ } ++ ++ if (self->destroy_in_progress) { ++ g_variant_unref (response); ++ return; ++ } ++ ++ realm_state_process_elements(self, response); ++ g_variant_unref(response); ++} ++ ++static void ++call_dbus_method (ShellRealmTracker *self, const gchar *method, GVariant *parameters, GAsyncReadyCallback callback, gpointer user_data) ++{ ++ if (!self->dbus) { ++ g_warning("ShellRealmTracker: call_dbus_method(%s) called when no bus connection present", method); ++ return; ++ } ++ ++ g_dbus_connection_call(self->dbus, ++ REALMS_BUS_NAME, ++ REALMS_OBJECT_PATH, ++ REALMS_MANAGER_INTERFACE, ++ method, ++ parameters, ++ NULL, ++ G_DBUS_CALL_FLAGS_NO_AUTO_START, ++ -1, ++ NULL, ++ callback, ++ user_data); ++} ++ ++static void ++request_realm_state(ShellRealmTracker *self) ++{ ++ call_dbus_method (self, "List", NULL, request_realm_state_finish, self); ++} ++ ++void ++shell_realm_tracker_call_set_current (ShellRealmTracker *self, const char *realm_name) ++{ ++ call_dbus_method (self, "SetCurrent", g_variant_new("(s)", realm_name), NULL, NULL); ++} ++ ++ ++static void ++unsubscribe_signals (ShellRealmTracker *self) ++{ ++ for (int i = 0; i < NUM_BUS_SIGNAL_IDS; i++) { ++ if (self->bus_signal_ids[i]) { ++ if (self->dbus) { ++ g_dbus_connection_signal_unsubscribe(self->dbus, self->bus_signal_ids[i]); ++ } ++ self->bus_signal_ids[i] = 0; ++ } ++ } ++} ++ ++static guint ++bus_signal_subscribe (ShellRealmTracker *self, const gchar *signal_name) ++{ ++ g_assert(self->dbus); ++ ++ return g_dbus_connection_signal_subscribe(self->dbus, ++ REALMS_BUS_NAME, ++ REALMS_MANAGER_INTERFACE, ++ signal_name, ++ REALMS_OBJECT_PATH, ++ NULL, ++ G_DBUS_SIGNAL_FLAGS_NONE, ++ on_realm_bus_signal, ++ self, ++ NULL); ++} ++ ++static void ++subscribe_bus_signals (ShellRealmTracker *self) ++{ ++ if (self->dbus) { ++ int idx = 0; ++ self->bus_signal_ids[idx++] = bus_signal_subscribe(self, "RealmStarted"); ++ self->bus_signal_ids[idx++] = bus_signal_subscribe(self, "RealmStopped"); ++ self->bus_signal_ids[idx++] = bus_signal_subscribe(self, "RealmCurrent"); ++ self->bus_signal_ids[idx++] = bus_signal_subscribe(self, "RealmNew"); ++ self->bus_signal_ids[idx++] = bus_signal_subscribe(self, "RealmRemoved"); ++ g_assert(idx == NUM_BUS_SIGNAL_IDS); ++ } ++} ++ ++static void ++on_realm_manager_appeared (GDBusConnection *connection, const gchar *name, const gchar *name_owner, gpointer user_data) ++{ ++ ShellRealmTracker *self = user_data; ++ ++ // Avoid processing spurious events while destroying 'self' ++ if (self->destroy_in_progress) { ++ return; ++ } ++ ++ if (!self->dbus) { ++ self->dbus = g_object_ref(connection); ++ subscribe_bus_signals (self); ++ } else { ++ g_warning("Realm tracker already has a connection in on_realm_manager_appeared()"); ++ } ++ ++ request_realm_state (self); ++} ++ ++ ++static void ++on_realm_manager_vanished (GDBusConnection *connection, const gchar *name, gpointer user_data) ++{ ++ ShellRealmTracker *self = user_data; ++ ++ // Avoid processing spurious events while destroying 'self' ++ if (self->destroy_in_progress) { ++ return; ++ } ++ ++ if (!connection) { ++ g_clear_object (&self->dbus); ++ } ++ ++ unsubscribe_signals(self); ++} ++ ++/** ++ * shell_realm_tracker_get_default: ++ * ++ * Return Value: (transfer none): The global #ShellRealmTracker singleton ++ */ ++ShellRealmTracker * ++shell_realm_tracker_get_default(void) ++{ ++ static ShellRealmTracker *instance; ++ if (instance == NULL) { ++ instance = g_object_new (SHELL_TYPE_REALM_TRACKER, NULL); ++ } ++ return instance; ++} ++ ++void shell_realm_tracker_start () ++{ ++ ShellRealmTracker *tracker = shell_realm_tracker_get_default(); ++ ++ if (tracker->realms_watch_id) { ++ g_warning ("ShellRealmTracker: shell_realm_tracker_start() called when already started"); ++ return; ++ } ++ ++ tracker->realms_watch_id = g_bus_watch_name(G_BUS_TYPE_SYSTEM, ++ REALMS_BUS_NAME, ++ G_BUS_NAME_WATCHER_FLAGS_NONE, ++ on_realm_manager_appeared, ++ on_realm_manager_vanished, ++ tracker, ++ g_free); ++ ++} ++ ++void ++shell_realm_tracker_destroy(ShellRealmTracker *self) ++{ ++ if (self->dbus) { ++ unsubscribe_signals (self); ++ g_clear_object (&self->dbus); ++ } ++ ++ // event handlers check this and will bail early in case there are ++ // any in queue. see docs for g_bus_unwatch_name() ++ self->destroy_in_progress = TRUE; ++ ++ // frees 'self' in destroy notifier ++ g_bus_unwatch_name(self->realms_watch_id); ++ ++} +diff --git a/src/shell-realm-tracker.h b/src/shell-realm-tracker.h +new file mode 100644 +index 0000000..a979f95 +--- /dev/null ++++ b/src/shell-realm-tracker.h +@@ -0,0 +1,14 @@ ++#ifndef __SHELL_REALM_TRACKER_H__ ++#define __SHELL_REALM_TRACKER_H__ ++ ++#include ++ ++#define SHELL_TYPE_REALM_TRACKER (shell_realm_tracker_get_type ()) ++G_DECLARE_FINAL_TYPE (ShellRealmTracker, shell_realm_tracker, ++ SHELL, REALM_TRACKER, GObject) ++ ++ShellRealmTracker *shell_realm_tracker_get_default(void); ++void shell_realm_tracker_call_set_current (ShellRealmTracker *self, const char *realm_name); ++void shell_realm_tracker_start (); ++ ++#endif /* __SHELL_REALM_TRACKER_H__ */ +diff --git a/src/shell-realms-private.h b/src/shell-realms-private.h +new file mode 100644 +index 0000000..16a81b2 +--- /dev/null ++++ b/src/shell-realms-private.h +@@ -0,0 +1,21 @@ ++#ifndef __SHELL_REALMS_PRIVATE_H__ ++#define __SHELL_REALMS_PRIVATE_H__ ++#include ++#include "shell-realms.h" ++ ++ ++void shell_realms_untag_all (ShellRealms *realms); ++void shell_realms_remove_untagged (ShellRealms *realms); ++void shell_realms_update_realm (ShellRealms *realms, ++ const char *realm_name, ++ const char *description, ++ const char *namespace, ++ guint8 status); ++ ++void shell_realms_on_realm_started (ShellRealms *realms, const gchar *realm_name, const gchar *namespace, guint8 status); ++void shell_realms_on_realm_current (ShellRealms *realms, const gchar *realm_name); ++void shell_realms_on_realm_stopped (ShellRealms *realms, const gchar *realm_name); ++void shell_realms_on_realm_removed (ShellRealms *realms, const gchar *realm_name); ++void shell_realms_on_realm_new (ShellRealms *realms, const gchar *realm_name, const gchar *description, guint8 status); ++ ++#endif //__SHELL_REALMS_PRIVATE_H__ +diff --git a/src/shell-realms.c b/src/shell-realms.c +new file mode 100644 +index 0000000..44ee2b7 +--- /dev/null ++++ b/src/shell-realms.c +@@ -0,0 +1,442 @@ ++ ++#include ++#include ++#include "shell-realm-item.h" ++#include "shell-realm-tracker.h" ++#include "shell-realms-private.h" ++#include "shell-global.h" ++ ++struct _ShellRealms { ++ GObject parent; ++ GHashTable *realms; ++ GList *running_realms; ++ ShellRealmItem *current_realm; ++}; ++ ++G_DEFINE_TYPE (ShellRealms, shell_realms, G_TYPE_OBJECT); ++ ++enum { ++ REALM_CONTEXT_SWITCHED, ++ LAST_SIGNAL, ++}; ++ ++enum { ++ PROP_0, ++ PROP_CURRENT_REALM, ++}; ++ ++static guint shell_realms_signals [LAST_SIGNAL] = { 0 }; ++ ++/** ++ * shell_realms_current_realm: ++ * @realms: A #ShellRealms instance ++ * ++ * Returns: (transfer none) (nullable): The current realm as a #ShellRealmItem ++ * or %NULL if no realm is current. ++ */ ++ShellRealmItem * ++shell_realms_current_realm (ShellRealms *realms) ++{ ++ return realms->current_realm; ++} ++ ++/** ++ * shell_realms_realm_by_name: ++ * @realms: a #ShellRealms instance ++ * @realm_name: The name of a realm to look up ++ * ++ * Returns: (transfer none) (nullable): A realm #ShellRealmItem or %NULL ++ * if name not found ++ */ ++ShellRealmItem * ++shell_realms_realm_by_name(ShellRealms *realms, const gchar *realm_name) ++{ ++ ShellRealmItem *item = g_hash_table_lookup (realms->realms, realm_name); ++ if (!item) { ++ g_warning("ShellRealms: No realm found for name '%s'", realm_name); ++ } ++ return item; ++} ++ ++/** ++ * shell_realms_realm_by_context_id: ++ * @realms: a #ShellRealms instance ++ * @context_id: A context id to search for. ++ * ++ * Returns: (transfer none) (nullable): The realm #ShellRealmItem for the realm ++ * with a workspace context id matching the specified value or %NULL if no such realm is found ++ */ ++ShellRealmItem * ++shell_realms_realm_by_context_id (ShellRealms *realms, guint context_id) ++{ ++ if (context_id == 0) { ++ return NULL; ++ } ++ ++ for (GList *iter = realms->running_realms; iter; iter = iter->next) { ++ ShellRealmItem *item = iter->data; ++ if (shell_realm_item_get_context_id (item) == context_id) { ++ return item; ++ } ++ } ++ return NULL; ++} ++ ++/** ++ * shell_realms_realm_by_window: ++ * @realms: a #ShellRealms instance ++ * @window: A window to find the corresponding realm for. ++ * ++ * Returns: (transfer none) (nullable): The realm #ShellRealmItem for the realm ++ * the application the window belongs to is running in or %NULL if no realm is found ++ */ ++ShellRealmItem * ++shell_realms_realm_by_window (ShellRealms *realms, MetaWindow *window) ++{ ++ const char *window_ns = meta_window_namespace (window); ++ ++ if (!window_ns) { ++ return NULL; ++ } ++ ++ for (GList *iter = realms->running_realms; iter; iter = iter->next) { ++ ShellRealmItem *item = iter->data; ++ if (g_strcmp0 (window_ns, shell_realm_item_get_namespace (item)) == 0) { ++ return item; ++ } ++ } ++ return NULL; ++} ++ ++/** ++ * shell_realms_is_citadel_window: ++ * @realms: A #ShellRealms instance ++ * @window: A #MetaWindow ++ * ++ * Return #TRUE if the window belongs to an application running inside of Citadel ++ * rather than running in a realm. ++ * ++ * Returns: If window belongs to an application running in Citadel return #True ++ */ ++gboolean ++shell_realms_is_citadel_window (ShellRealms *realms, MetaWindow *window) ++{ ++ MetaDisplay *display = shell_global_get_display (shell_global_get()); ++ MetaWorkspaceManager *workspace_manager = meta_display_get_workspace_manager (display); ++ ++ const char *mutter_ns = meta_workspace_manager_mutter_namespace (workspace_manager); ++ const char *window_ns = meta_window_namespace (window); ++ ++ return g_strcmp0 (mutter_ns, window_ns) == 0; ++} ++ ++/** ++ * shell_realms_get_running_realms: ++ * @realms: the #ShellRealms instance ++ * ++ * Returns all running realms as a list of #ShellRealmItem ++ * ++ * Returns: (transfer none) (element-type ShellRealmItem): a list of ++ * #ShellRealmItem for all running realms. ++ * ++ */ ++GList * ++shell_realms_get_running_realms (ShellRealms *realms) ++{ ++ return realms->running_realms; ++} ++ ++/** ++ * shell_realms_get_all_realms: ++ * @realms: the #ShellRealms instance ++ * ++ * Returns all realms as a list of #ShellRealmItem ++ * ++ * Returns: (transfer container) (element-type ShellRealmItem): all realms as ++ * a list of #ShellRealmItem ++ */ ++GList * ++shell_realms_get_all_realms (ShellRealms *realms) ++{ ++ return g_hash_table_get_values (realms->realms); ++} ++ ++static gboolean ++shell_realms_is_on_running_list (ShellRealms *realms, ShellRealmItem *item) ++{ ++ return (g_list_index (realms->running_realms, item) >= 0); ++} ++ ++static void ++shell_realms_remove_running_realm (ShellRealms *realms, ShellRealmItem *item) ++{ ++ ++ if (!shell_realms_is_on_running_list (realms, item)) { ++ return; ++ } ++ ++ realms->running_realms = g_list_remove(realms->running_realms, item); ++ g_object_unref (item); ++} ++ ++static void ++shell_realms_update_running_list_for_item (ShellRealms *realms, ShellRealmItem *item) ++{ ++ gboolean running = shell_realm_item_is_running (item); ++ ++ if (running) { ++ if (!shell_realms_is_on_running_list (realms, item)) { ++ realms->running_realms = g_list_append (realms->running_realms, g_object_ref (item)); ++ } ++ ++ // If realm is current realm, make sure it's at the front of the list ++ if (shell_realm_item_is_current (item) && g_list_index (realms->running_realms, item) > 0) { ++ realms->running_realms = g_list_remove (realms->running_realms, item); ++ realms->running_realms = g_list_prepend (realms->running_realms, item); ++ } ++ ++ } else { ++ shell_realms_remove_running_realm (realms, item); ++ } ++} ++ ++static void ++shell_realms_set_current_item (ShellRealms *realms, ShellRealmItem *item) ++{ ++ if (realms->current_realm == item) { ++ return; ++ } else if (realms->current_realm) { ++ shell_realm_item_set_current_flag (realms->current_realm, FALSE); ++ } ++ ++ shell_realm_item_set_current_flag (item, TRUE); ++ realms->current_realm = item; ++} ++ ++/* ++ * If a realm already exists for 'realm_name' update it with provided information, otherwise ++ * create a new ShellRealmItem and add it to hash table unless it is a system realm. Returns ++ * the existing or newly created ShellRealmItem or returns NULL if the realm is a system realm. ++ */ ++static ShellRealmItem * ++shell_realms_add_realm_item (ShellRealms *realms, ++ const char *realm_name, ++ const char *description, ++ const char *namespace, ++ guint8 status) ++{ ++ ShellRealmItem *item = g_hash_table_lookup (realms->realms, realm_name); ++ if (item) { ++ shell_realm_item_update (item, realm_name, namespace, status); ++ return item; ++ } ++ ++ item = shell_realm_item_new (realm_name, description, namespace, status); ++ ++ if (shell_realm_item_is_system (item)) { ++ g_clear_object(&item); ++ return NULL; ++ } ++ g_hash_table_insert (realms->realms, g_strdup (realm_name), item); ++ return item; ++} ++ ++void ++shell_realms_update_realm (ShellRealms *realms, ++ const char *realm_name, ++ const char *description, ++ const char *namespace, ++ guint8 status) ++{ ++ ShellRealmItem *item = shell_realms_add_realm_item (realms, realm_name, description, namespace, status); ++ ++ // Ignore system realms ++ if (!item) { ++ return; ++ } ++ ++ shell_realms_update_running_list_for_item (realms, item); ++ shell_realm_item_set_tagged (item, TRUE); ++ ++ // If realm is current, make sure it has a context. This also ensures that the ++ // first context requested is for the current realm. ++ if (shell_realm_item_is_current (item)) { ++ shell_realms_set_current_item (realms, item); ++ shell_realm_item_acquire_context (item); ++ } ++} ++ ++// When processing list of realms returned from "List" dbus method, ++// ++// 1) first all the existing realms are "untagged" ++// 2) As each realm on list is processed it is marked as "tagged" ++// 3) After processing list, realm items that are not tagged were not in list ++// returned from server so remove them. ++// ++void ++shell_realms_untag_all (ShellRealms *realms) ++{ ++ GList *item_list = g_hash_table_get_values (realms->realms); ++ ++ for (GList *iter = item_list; iter; iter = iter->next) { ++ ShellRealmItem *item = iter->data; ++ shell_realm_item_set_tagged (item, FALSE); ++ iter = iter->next; ++ } ++ g_list_free (item_list); ++} ++ ++void ++shell_realms_remove_untagged (ShellRealms *realms) ++{ ++ GHashTableIter iter; ++ gpointer value; ++ ++ g_hash_table_iter_init (&iter, realms->realms); ++ while (g_hash_table_iter_next (&iter, NULL, &value)) { ++ ShellRealmItem *item = value; ++ if (!shell_realm_item_is_tagged (item)) { ++ shell_realms_remove_running_realm (realms, item); ++ g_hash_table_iter_remove (&iter); ++ } ++ } ++} ++ ++// Signal handlers ++ ++void ++shell_realms_on_realm_started (ShellRealms *realms, const gchar *realm_name, const gchar *namespace, guint8 status) ++{ ++ ShellRealmItem *item = shell_realms_realm_by_name (realms, realm_name); ++ if (item) { ++ shell_realm_item_update (item, realm_name, namespace, status); ++ if (!shell_realm_item_is_system (item)) { ++ shell_realms_update_running_list_for_item (realms, item); ++ shell_realm_item_acquire_context (item); ++ } ++ } ++} ++ ++void ++shell_realms_on_realm_current (ShellRealms *realms, const gchar *realm_name) ++{ ++ ShellRealmItem *item = shell_realms_realm_by_name (realms, realm_name); ++ ++ if (realms->current_realm != item) { ++ shell_realms_set_current_item (realms, item); ++ shell_realms_update_running_list_for_item (realms, item); ++ shell_realm_item_activate_context (item); ++ g_signal_emit (realms, shell_realms_signals[REALM_CONTEXT_SWITCHED], 0); ++ } ++} ++ ++void ++shell_realms_on_realm_stopped (ShellRealms *realms, const gchar *realm_name) ++{ ++ ShellRealmItem *item = shell_realms_realm_by_name (realms, realm_name); ++ if (item) { ++ shell_realm_item_set_running_flag (item, FALSE); ++ shell_realms_remove_running_realm (realms, item); ++ } ++} ++ ++void ++shell_realms_on_realm_removed (ShellRealms *realms, const gchar *realm_name) ++{ ++ ShellRealmItem *item = shell_realms_realm_by_name (realms, realm_name); ++ if (item) { ++ shell_realms_remove_running_realm (realms, item); ++ g_hash_table_remove (realms->realms, realm_name); ++ } ++} ++ ++void ++shell_realms_on_realm_new (ShellRealms *realms, const gchar *realm_name, const gchar *description, guint8 status) ++{ ++ if (!g_hash_table_contains (realms->realms, realm_name)) { ++ (void) shell_realms_add_realm_item (realms, realm_name, description, NULL, status); ++ } else { ++ g_warning("ShellRealms: RealmNew signal received for realm '%s' but it already exists", realm_name); ++ } ++} ++ ++/** ++ * shell_realms_get_default: ++ * ++ * Return Value: (transfer none): The global #ShellRealms singleton ++ */ ++ShellRealms * ++shell_realms_get_default(void) ++{ ++ static ShellRealms *instance; ++ ++ if (instance == NULL) { ++ instance = g_object_new (SHELL_TYPE_REALMS, NULL); ++ } ++ return instance; ++} ++ ++static void ++shell_realms_init(ShellRealms *realms) ++{ ++ realms->realms = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref); ++ realms->running_realms = NULL; ++ realms->current_realm = NULL; ++} ++ ++static void ++shell_realms_finalize (GObject *obj) ++{ ++ ShellRealms *realms = SHELL_REALMS (obj); ++ realms->current_realm = NULL; ++ g_list_free_full (realms->running_realms, g_object_unref); ++ g_hash_table_destroy (realms->realms); ++ G_OBJECT_CLASS (shell_realms_parent_class)->finalize (obj); ++} ++ ++static void ++shell_realms_get_property (GObject *gobject, ++ guint prop_id, ++ GValue *value, ++ GParamSpec *pspec) ++{ ++ ShellRealms *realms = SHELL_REALMS (gobject); ++ ++ switch (prop_id) { ++ case PROP_CURRENT_REALM: ++ if (realms->current_realm) { ++ g_value_set_object (value, realms->current_realm); ++ } ++ break; ++ ++ default: ++ G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec); ++ break; ++ } ++} ++ ++static void ++shell_realms_class_init (ShellRealmsClass *klass) ++{ ++ ++ GObjectClass *object_class = G_OBJECT_CLASS (klass); ++ ++ object_class->get_property = shell_realms_get_property; ++ object_class->finalize = shell_realms_finalize; ++ ++ shell_realms_signals[REALM_CONTEXT_SWITCHED] = ++ g_signal_new ("realm-context-switched", ++ G_TYPE_FROM_CLASS(klass), ++ G_SIGNAL_RUN_LAST, ++ 0, ++ NULL, NULL, NULL, ++ G_TYPE_NONE, 0); ++ ++ g_object_class_install_property (object_class, ++ PROP_CURRENT_REALM, ++ g_param_spec_object ("current-realm", ++ "Current Realm", ++ "The currently active realm", ++ SHELL_TYPE_REALM_ITEM, ++ G_PARAM_READABLE | G_PARAM_STATIC_STRINGS)); ++} +diff --git a/src/shell-realms.h b/src/shell-realms.h +new file mode 100644 +index 0000000..a1a3353 +--- /dev/null ++++ b/src/shell-realms.h +@@ -0,0 +1,23 @@ ++#ifndef __SHELL_REALMS_H__ ++#define __SHELL_REALMS_H__ ++ ++#include ++#include ++#include "shell-realm-item.h" ++ ++#define SHELL_TYPE_REALMS (shell_realms_get_type()) ++G_DECLARE_FINAL_TYPE(ShellRealms, shell_realms, SHELL, REALMS, GObject) ++ ++ShellRealms *shell_realms_get_default(void); ++ ++ ++ShellRealmItem *shell_realms_current_realm (ShellRealms *realms); ++ShellRealmItem *shell_realms_realm_by_name(ShellRealms *realms, const gchar *realm_name); ++ShellRealmItem *shell_realms_realm_by_context_id (ShellRealms *realms, guint context_id); ++ShellRealmItem *shell_realms_realm_by_window (ShellRealms *realms, MetaWindow *window); ++gboolean shell_realms_is_citadel_window (ShellRealms *realms, MetaWindow *window); ++ ++GList *shell_realms_get_running_realms (ShellRealms *realms); ++GList *shell_realms_get_all_realms (ShellRealms *realms); ++ ++#endif //__SHELL_REALMS_H__ +diff --git a/src/shell-window-tracker.c b/src/shell-window-tracker.c +index 5c9d2ec..0ca7004 100644 +--- a/src/shell-window-tracker.c ++++ b/src/shell-window-tracker.c +@@ -15,6 +15,7 @@ + #include "shell-window-tracker-private.h" + #include "shell-app-private.h" + #include "shell-global.h" ++#include "shell-realms.h" + #include "st.h" + + /* This file includes modified code from +@@ -129,6 +130,22 @@ check_app_id_prefix (ShellApp *app, + return g_str_has_prefix (shell_app_get_id (app), prefix); + } + ++static const char * ++get_window_realm_name (MetaWindow *window) { ++ ++ ShellRealms *realms = shell_realms_get_default(); ++ if (shell_realms_is_citadel_window (realms, window)) { ++ return NULL; ++ } ++ ShellRealmItem *item = shell_realms_realm_by_window(realms, window); ++ ++ if (item) { ++ return shell_realm_item_get_realm_name (item); ++ } else { ++ return NULL; ++ } ++} ++ + /* + * get_app_from_window_wmclass: + * +@@ -146,6 +163,7 @@ get_app_from_window_wmclass (MetaWindow *window) + const char *wm_class; + const char *wm_instance; + const char *sandbox_id; ++ const char *realm_name; + g_autofree char *app_prefix = NULL; + + appsys = shell_app_system_get_default (); +@@ -154,6 +172,9 @@ get_app_from_window_wmclass (MetaWindow *window) + if (sandbox_id) + app_prefix = g_strdup_printf ("%s.", sandbox_id); + ++ realm_name = get_window_realm_name (window); ++ ++ g_warning ("ShellWindowTracker: get_app_from_window_wmclass() realm_name=%s", realm_name ? realm_name : "None"); + /* Notes on the heuristics used here: + much of the complexity here comes from the desire to support + Chrome apps. +@@ -191,23 +212,23 @@ get_app_from_window_wmclass (MetaWindow *window) + + /* first try a match from WM_CLASS (instance part) to StartupWMClass */ + wm_instance = meta_window_get_wm_class_instance (window); +- app = shell_app_system_lookup_startup_wmclass (appsys, wm_instance); ++ app = shell_app_system_lookup_startup_wmclass (appsys, wm_instance, realm_name); + if (app != NULL && check_app_id_prefix (app, app_prefix)) + return g_object_ref (app); + + /* then try a match from WM_CLASS to StartupWMClass */ + wm_class = meta_window_get_wm_class (window); +- app = shell_app_system_lookup_startup_wmclass (appsys, wm_class); ++ app = shell_app_system_lookup_startup_wmclass (appsys, wm_class, realm_name); + if (app != NULL && check_app_id_prefix (app, app_prefix)) + return g_object_ref (app); + + /* then try a match from WM_CLASS (instance part) to .desktop */ +- app = shell_app_system_lookup_desktop_wmclass (appsys, wm_instance); ++ app = shell_app_system_lookup_desktop_wmclass (appsys, wm_instance, realm_name); + if (app != NULL && check_app_id_prefix (app, app_prefix)) + return g_object_ref (app); + + /* finally, try a match from WM_CLASS to .desktop */ +- app = shell_app_system_lookup_desktop_wmclass (appsys, wm_class); ++ app = shell_app_system_lookup_desktop_wmclass (appsys, wm_class, realm_name); + if (app != NULL && check_app_id_prefix (app, app_prefix)) + return g_object_ref (app); + +@@ -236,7 +257,19 @@ get_app_from_id (MetaWindow *window, + + appsys = shell_app_system_get_default (); + +- desktop_file = g_strconcat (id, ".desktop", NULL); ++ const char *realm_name = NULL; ++ ShellRealms *realms = shell_realms_get_default(); ++ ShellRealmItem *item = shell_realms_realm_by_window (realms, window); ++ ++ if (item) { ++ realm_name = shell_realm_item_get_realm_name (item); ++ } ++ ++ if (realm_name) { ++ desktop_file = g_strconcat ("realm-", realm_name, ".", id, ".desktop", NULL); ++ } else { ++ desktop_file = g_strconcat (id, ".desktop", NULL); ++ } + app = shell_app_system_lookup_app (appsys, desktop_file); + if (app) + return g_object_ref (app); diff --git a/meta-gnome/recipes-gnome/gnome-shell/gnome-shell_40.0.bb b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell_41.0.bb similarity index 87% rename from meta-gnome/recipes-gnome/gnome-shell/gnome-shell_40.0.bb rename to meta-gnome/recipes-gnome/gnome-shell/gnome-shell_41.0.bb index da70ac0..25ebcc5 100644 --- a/meta-gnome/recipes-gnome/gnome-shell/gnome-shell_40.0.bb +++ b/meta-gnome/recipes-gnome/gnome-shell/gnome-shell_41.0.bb @@ -13,14 +13,14 @@ 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 \ - file://0001-Disabled-calendar-events-from-user-session.patch \ file://0001-do-not-use-python-path-from-build-environment.patch \ file://0001-Remove-calendar-server-fix-build.patch \ file://0001-Remove-log-out-label-from-power-off-in-status-UI.patch \ - file://0001-Citadel-Gnome-Shell-changes.patch \ + file://0001-Disabled-calendar-events-from-user-session.patch \ + file://0002-Citadel-Gnome-Shell-changes.patch \ " -SRC_URI[archive.sha256sum] = "bce71f402dfaa9c5e269bf65bf48a22343d896e6cf9a2c34669392d7fbf68478" +SRC_URI[archive.sha256sum] = "52f971e85140e5de74b9369ef6656e49ce95af1f232fc1e0df1f046129ab4f65" DEPENDS = " \ @@ -56,9 +56,13 @@ FILES_${PN}-tools += "\ /usr/bin/gnome-shell-extension-tool \ " +do_compile_prepend() { + rm -f ${B}/data/theme/*.css +} + do_configure_append () { MUTTER_DIR="/usr/lib/mutter" 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" +EXTRA_OEMESON += "-Dman=false -Dsystemd=true -Dnetworkmanager=true -Dextensions_app=false -Dtests=false" diff --git a/meta-gnome/recipes-gnome/gnome-system-monitor/gnome-system-monitor_40.1.bb b/meta-gnome/recipes-gnome/gnome-system-monitor/gnome-system-monitor_41.0.bb similarity index 89% rename from meta-gnome/recipes-gnome/gnome-system-monitor/gnome-system-monitor_40.1.bb rename to meta-gnome/recipes-gnome/gnome-system-monitor/gnome-system-monitor_41.0.bb index 7b30b6e..f8c4f11 100644 --- a/meta-gnome/recipes-gnome/gnome-system-monitor/gnome-system-monitor_40.1.bb +++ b/meta-gnome/recipes-gnome/gnome-system-monitor/gnome-system-monitor_41.0.bb @@ -22,7 +22,7 @@ def gnome_verdir(v): SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive" -SRC_URI[archive.sha256sum] = "fdb30f4367907aab86d7c2bb76a7b773ba850b765c9666a39f42abfe22691d1a" +SRC_URI[archive.sha256sum] = "c7fc44c61949b794b0289968ebbbcc0c15f8cfc3d9e45bfaa81ed45c12139e5f" PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" PACKAGECONFIG[systemd] = "-Dsystemd=true, -Dsystemd=false, systemd" diff --git a/meta-gnome/recipes-gnome/gnome-terminal/gnome-terminal_3.40.1.bb b/meta-gnome/recipes-gnome/gnome-terminal/gnome-terminal_3.41.0.bb similarity index 76% rename from meta-gnome/recipes-gnome/gnome-terminal/gnome-terminal_3.40.1.bb rename to meta-gnome/recipes-gnome/gnome-terminal/gnome-terminal_3.41.0.bb index d3f708e..63c65f3 100644 --- a/meta-gnome/recipes-gnome/gnome-terminal/gnome-terminal_3.40.1.bb +++ b/meta-gnome/recipes-gnome/gnome-terminal/gnome-terminal_3.41.0.bb @@ -16,11 +16,12 @@ DEPENDS = " \ docbook-xsl-stylesheets-native \ " +GNOMEBASEBUILDCLASS = "meson" inherit gnomebase gsettings gnome-help gettext itstool upstream-version-is-even -SRC_URI[archive.sha256sum] = "0770cc7320d737fb2eaf9e4cf5ecc6a741f120b17b192f061f683e14b869d8e4" +SRC_URI[archive.sha256sum] = "b016d89efc3fbc2a85a8ea664077a06158a462c03c222d82478ce01531d5390c" -EXTRA_OECONF = "--disable-search-provider --without-nautilus-extension" +EXTRA_OEMESON = "-Ddocs=false -Dnautilus_extension=false -Dsearch_provider=false" FILES_${PN} += "\ ${systemd_user_unitdir} \ diff --git a/meta-gnome/recipes-gnome/gsettings-desktop-schema/gsettings-desktop-schemas_40.0.bb b/meta-gnome/recipes-gnome/gsettings-desktop-schema/gsettings-desktop-schemas_41.0.bb similarity index 86% rename from meta-gnome/recipes-gnome/gsettings-desktop-schema/gsettings-desktop-schemas_40.0.bb rename to meta-gnome/recipes-gnome/gsettings-desktop-schema/gsettings-desktop-schemas_41.0.bb index 203310a..aed9f90 100644 --- a/meta-gnome/recipes-gnome/gsettings-desktop-schema/gsettings-desktop-schemas_40.0.bb +++ b/meta-gnome/recipes-gnome/gsettings-desktop-schema/gsettings-desktop-schemas_41.0.bb @@ -17,5 +17,5 @@ def gnome_verdir(v): SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive" -SRC_URI[archive.sha256sum] = "f1b83bf023c0261eacd0ed36066b76f4a520bbcb14bb69c402b7959257125685" +SRC_URI[archive.sha256sum] = "77289972e596d044583f0c056306d8f1dbd8adcf912910a50da0a663e65332ed" diff --git a/meta-gnome/recipes-gnome/gtk4/gtk4.inc b/meta-gnome/recipes-gnome/gtk4/gtk4.inc index f1bf8c7..b5331f5 100644 --- a/meta-gnome/recipes-gnome/gtk4/gtk4.inc +++ b/meta-gnome/recipes-gnome/gtk4/gtk4.inc @@ -5,7 +5,7 @@ HOMEPAGE = "http://www.gtk.org" BUGTRACKER = "https://bugzilla.gnome.org/" SECTION = "libs" -DEPENDS = "glib-2.0 cairo pango atk jpeg libpng gdk-pixbuf libepoxy graphene libxi sassc-native \ +DEPENDS = "glib-2.0 cairo pango atk jpeg libpng gdk-pixbuf libepoxy graphene libxcursor libxinerama libxi sassc-native \ gdk-pixbuf-native wayland wayland-protocols libxkbcommon virtual/egl virtual/libgles2 wayland-native" LICENSE = "LGPLv2 & LGPLv2+ & LGPLv2.1+" @@ -37,6 +37,7 @@ do_configure_prepend() { EXTRA_OEMESON += " \ -Ddemos=false \ + -Dmedia-gstreamer=disabled \ " do_compile_prepend() { diff --git a/meta-gnome/recipes-gnome/gtk4/gtk4_4.1.2.bb b/meta-gnome/recipes-gnome/gtk4/gtk4_4.4.0.bb similarity index 85% rename from meta-gnome/recipes-gnome/gtk4/gtk4_4.1.2.bb rename to meta-gnome/recipes-gnome/gtk4/gtk4_4.4.0.bb index 372d480..3343c7a 100644 --- a/meta-gnome/recipes-gnome/gtk4/gtk4_4.1.2.bb +++ b/meta-gnome/recipes-gnome/gtk4/gtk4_4.4.0.bb @@ -5,7 +5,7 @@ MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}" SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk/${MAJ_VER}/gtk-${PV}.tar.xz \ " -SRC_URI[sha256sum] = "33407da437c5e5ac09e7a463ba3bd025da3d80ba1953b8bbe2bce97dd2609677" +SRC_URI[sha256sum] = "e0a1508f441686c3a20dfec48af533b19a4b2e017c18eaee31dccdb7d292505b" S = "${WORKDIR}/gtk-${PV}" diff --git a/meta-gnome/recipes-gnome/gvfs/gvfs_1.46.1.bb b/meta-gnome/recipes-gnome/gvfs/gvfs_1.48.1.bb similarity index 93% rename from meta-gnome/recipes-gnome/gvfs/gvfs_1.46.1.bb rename to meta-gnome/recipes-gnome/gvfs/gvfs_1.48.1.bb index a8533de..1a03cc6 100644 --- a/meta-gnome/recipes-gnome/gvfs/gvfs_1.46.1.bb +++ b/meta-gnome/recipes-gnome/gvfs/gvfs_1.48.1.bb @@ -9,8 +9,7 @@ DEPENDS += "libsecret glib-2.0 gconf libgudev udisks2 polkit shadow-native libus SRC_URI = "https://download.gnome.org/sources/${BPN}/${@gnome_verdir("${PV}")}/${BPN}-${PV}.tar.xz;name=archive" -SRC_URI[archive.md5sum] = "3013dca31a373202779d0f9652118fe2" -SRC_URI[archive.sha256sum] = "621ea6c1b9a60b7ed2893938620d3190725a3d9dc65ce5af0fb6c186ee342503" +SRC_URI[archive.sha256sum] = "b2ea4f271aad2711f16b43c03151e2ec5a9874ff1a21142ef6d6406486a19dc2" EXTRA_OEMESON = " \ -Dadmin=false \ diff --git a/meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch b/meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch index e6d09d5..cb70b99 100644 --- a/meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch +++ b/meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch @@ -1,6 +1,6 @@ -From c203de9ad5f88eb48f749cda1b5a6c8896a2af15 Mon Sep 17 00:00:00 2001 +From 1b27f150bf7656cade484925da726daf9a52dd6b Mon Sep 17 00:00:00 2001 From: Bruce Leidl -Date: Mon, 4 Oct 2021 07:19:16 -0400 +Date: Mon, 4 Oct 2021 13:10:48 +0000 Subject: [PATCH] Citadel changes to Mutter --- @@ -21,10 +21,10 @@ Subject: [PATCH] Citadel changes to Mutter 14 files changed, 786 insertions(+), 85 deletions(-) diff --git a/src/compositor/compositor.c b/src/compositor/compositor.c -index 1770550..d1eb7f8 100644 +index 9cdd39c..879950a 100644 --- a/src/compositor/compositor.c +++ b/src/compositor/compositor.c -@@ -744,8 +744,13 @@ meta_compositor_switch_workspace (MetaCompositor *compositor, +@@ -747,8 +747,13 @@ meta_compositor_switch_workspace (MetaCompositor *compositor, meta_compositor_get_instance_private (compositor); gint to_indx, from_indx; @@ -684,21 +684,21 @@ index 61fbc00..d7696a7 100644 + return context->id != window->workspace->context_id; +} diff --git a/src/core/util-private.h b/src/core/util-private.h -index 0d68a72..834b3e2 100644 +index 01b6639..27d480e 100644 --- a/src/core/util-private.h +++ b/src/core/util-private.h -@@ -43,4 +43,6 @@ void meta_set_is_wayland_compositor (gboolean setting); - char * meta_generate_random_id (GRand *rand, - int length); +@@ -58,4 +58,6 @@ void meta_get_clutter_debug_flags (ClutterDebugFlag *debug_flags, + ClutterDrawDebugFlag *draw_flags, + ClutterPickDebugFlag *pick_flags); +char * meta_read_pid_namespace (pid_t pid); + #endif diff --git a/src/core/util.c b/src/core/util.c -index bbb5a24..57645e0 100644 +index 74a884c..17a13bd 100644 --- a/src/core/util.c +++ b/src/core/util.c -@@ -741,3 +741,51 @@ meta_get_debug_paint_flags (void) +@@ -794,3 +794,51 @@ meta_get_debug_paint_flags (void) { return debug_paint_flags; } @@ -751,13 +751,13 @@ index bbb5a24..57645e0 100644 + return value; +} diff --git a/src/core/window-private.h b/src/core/window-private.h -index d1730c9..6a55630 100644 +index 3bd75fe..293cc88 100644 --- a/src/core/window-private.h +++ b/src/core/window-private.h -@@ -562,6 +562,9 @@ struct _MetaWindow - guint unmanage_idle_id; +@@ -568,6 +568,9 @@ struct _MetaWindow - pid_t client_pid; + gboolean has_valid_cgroup; + GFile *cgroup_path; + + guint namespace_set: 1; + gchar *namespace; @@ -765,10 +765,10 @@ index d1730c9..6a55630 100644 struct _MetaWindowClass diff --git a/src/core/window.c b/src/core/window.c -index c843c62..c0b9e3f 100644 +index e543814..02164e0 100644 --- a/src/core/window.c +++ b/src/core/window.c -@@ -345,6 +345,7 @@ meta_window_finalize (GObject *object) +@@ -356,6 +356,7 @@ meta_window_finalize (GObject *object) g_free (window->gtk_app_menu_object_path); g_free (window->gtk_menubar_object_path); g_free (window->placement.rule); @@ -776,7 +776,7 @@ index c843c62..c0b9e3f 100644 G_OBJECT_CLASS (meta_window_parent_class)->finalize (object); } -@@ -1564,7 +1565,7 @@ meta_window_unmanage (MetaWindow *window, +@@ -1578,7 +1579,7 @@ meta_window_unmanage (MetaWindow *window, g_assert (window->workspace == NULL); #ifndef G_DISABLE_CHECKS @@ -785,7 +785,7 @@ index c843c62..c0b9e3f 100644 while (tmp != NULL) { MetaWorkspace *workspace = tmp->data; -@@ -4889,7 +4890,7 @@ set_workspace_state (MetaWindow *window, +@@ -4903,7 +4904,7 @@ set_workspace_state (MetaWindow *window, else if (window->on_all_workspaces) { GList *l; @@ -794,7 +794,7 @@ index c843c62..c0b9e3f 100644 { MetaWorkspace *ws = l->data; meta_workspace_remove_window (ws, window); -@@ -4904,7 +4905,7 @@ set_workspace_state (MetaWindow *window, +@@ -4918,7 +4919,7 @@ set_workspace_state (MetaWindow *window, else if (window->on_all_workspaces) { GList *l; @@ -803,7 +803,7 @@ index c843c62..c0b9e3f 100644 { MetaWorkspace *ws = l->data; meta_workspace_add_window (ws, window); -@@ -5203,8 +5204,10 @@ meta_window_change_workspace_by_index (MetaWindow *window, +@@ -5276,8 +5277,10 @@ meta_window_change_workspace_by_index (MetaWindow *window, workspace = meta_workspace_manager_get_workspace_by_index (workspace_manager, space_index); @@ -815,7 +815,7 @@ index c843c62..c0b9e3f 100644 if (workspace) meta_window_change_workspace (window, workspace); -@@ -5528,7 +5531,7 @@ meta_window_get_workspaces (MetaWindow *window) +@@ -5618,7 +5621,7 @@ meta_window_get_workspaces (MetaWindow *window) MetaWorkspaceManager *workspace_manager = window->display->workspace_manager; if (window->on_all_workspaces) @@ -824,7 +824,7 @@ index c843c62..c0b9e3f 100644 else if (window->workspace != NULL) return window->workspace->list_containing_self; else if (window->constructing) -@@ -8675,3 +8678,31 @@ meta_window_get_client_type (MetaWindow *window) +@@ -8822,3 +8825,31 @@ meta_window_get_client_type (MetaWindow *window) { return window->client_type; } @@ -858,7 +858,7 @@ index c843c62..c0b9e3f 100644 +} \ No newline at end of file diff --git a/src/core/workspace-private.h b/src/core/workspace-private.h -index a58b234..2e364a1 100644 +index f0d896f..38c3b4c 100644 --- a/src/core/workspace-private.h +++ b/src/core/workspace-private.h @@ -39,6 +39,7 @@ struct _MetaWorkspace @@ -879,7 +879,7 @@ index a58b234..2e364a1 100644 void meta_workspace_add_window (MetaWorkspace *workspace, MetaWindow *window); diff --git a/src/core/workspace.c b/src/core/workspace.c -index 321d3ef..633184d 100644 +index 76ba87b..3ac18b8 100644 --- a/src/core/workspace.c +++ b/src/core/workspace.c @@ -237,7 +237,7 @@ meta_workspace_init (MetaWorkspace *workspace) @@ -933,7 +933,7 @@ index 321d3ef..633184d 100644 meta_workspace_clear_logical_monitor_data (workspace); -@@ -381,8 +390,8 @@ meta_workspace_add_window (MetaWorkspace *workspace, +@@ -403,8 +412,8 @@ meta_workspace_add_window (MetaWorkspace *workspace, if (window->struts) { meta_topic (META_DEBUG_WORKAREA, @@ -944,7 +944,7 @@ index 321d3ef..633184d 100644 meta_workspace_invalidate_work_area (workspace); } -@@ -405,8 +414,8 @@ meta_workspace_remove_window (MetaWorkspace *workspace, +@@ -432,8 +441,8 @@ meta_workspace_remove_window (MetaWorkspace *workspace, if (window->struts) { meta_topic (META_DEBUG_WORKAREA, @@ -955,7 +955,7 @@ index 321d3ef..633184d 100644 meta_workspace_invalidate_work_area (workspace); } -@@ -456,6 +465,13 @@ workspace_switch_sound(MetaWorkspace *from, +@@ -486,6 +495,13 @@ workspace_switch_sound(MetaWorkspace *from, int i, nw, x, y, fi, ti; const char *e; @@ -969,7 +969,7 @@ index 321d3ef..633184d 100644 nw = meta_workspace_manager_get_n_workspaces (from->manager); fi = meta_workspace_index(from); ti = meta_workspace_index(to); -@@ -536,9 +552,15 @@ meta_workspace_activate_with_focus (MetaWorkspace *workspace, +@@ -566,9 +582,15 @@ meta_workspace_activate_with_focus (MetaWorkspace *workspace, MetaWorkspaceLayout layout1, layout2; gint num_workspaces, current_space, new_space; MetaMotionDirection direction; @@ -987,7 +987,7 @@ index 321d3ef..633184d 100644 if (workspace->manager->active_workspace == workspace) { -@@ -601,52 +623,59 @@ meta_workspace_activate_with_focus (MetaWorkspace *workspace, +@@ -631,52 +653,59 @@ meta_workspace_activate_with_focus (MetaWorkspace *workspace, comp = meta_display_get_compositor (workspace->display); direction = 0; @@ -1089,7 +1089,7 @@ index 321d3ef..633184d 100644 meta_compositor_switch_workspace (comp, old, workspace, direction); -@@ -683,14 +712,19 @@ meta_workspace_activate (MetaWorkspace *workspace, +@@ -714,14 +743,19 @@ meta_workspace_activate (MetaWorkspace *workspace, int meta_workspace_index (MetaWorkspace *workspace) { @@ -1115,7 +1115,7 @@ index 321d3ef..633184d 100644 } void -@@ -747,14 +781,14 @@ meta_workspace_invalidate_work_area (MetaWorkspace *workspace) +@@ -778,14 +812,14 @@ meta_workspace_invalidate_work_area (MetaWorkspace *workspace) if (workspace->work_areas_invalid) { meta_topic (META_DEBUG_WORKAREA, @@ -1134,7 +1134,7 @@ index 321d3ef..633184d 100644 /* If we are in the middle of a resize or move operation, we * might have cached pointers to the workspace's edges */ -@@ -925,8 +959,8 @@ ensure_work_areas_validated (MetaWorkspace *workspace) +@@ -956,8 +990,8 @@ ensure_work_areas_validated (MetaWorkspace *workspace) } workspace->work_area_screen = work_area; meta_topic (META_DEBUG_WORKAREA, @@ -1145,7 +1145,7 @@ index 321d3ef..633184d 100644 workspace->work_area_screen.x, workspace->work_area_screen.y, workspace->work_area_screen.width, -@@ -956,8 +990,8 @@ ensure_work_areas_validated (MetaWorkspace *workspace) +@@ -987,8 +1021,8 @@ ensure_work_areas_validated (MetaWorkspace *workspace) meta_topic (META_DEBUG_WORKAREA, "Computed work area for workspace %d " @@ -1156,7 +1156,7 @@ index 321d3ef..633184d 100644 logical_monitor->number, data->logical_monitor_work_area.x, data->logical_monitor_work_area.y, -@@ -1199,6 +1233,8 @@ meta_motion_direction_to_string (MetaMotionDirection direction) +@@ -1230,6 +1264,8 @@ meta_motion_direction_to_string (MetaMotionDirection direction) return "Up-Left"; case META_MOTION_DOWN_LEFT: return "Down-Left"; @@ -1255,10 +1255,10 @@ index 92cd681..d00948d 100644 + #endif /* META_WORKSPACE_MANAGER_H */ diff --git a/src/meta/types.h b/src/meta/types.h -index 49fb568..d479c19 100644 +index 403e62b..4e2f042 100644 --- a/src/meta/types.h +++ b/src/meta/types.h -@@ -42,6 +42,7 @@ typedef struct _MetaCursorTracker MetaCursorTracker; +@@ -43,6 +43,7 @@ typedef struct _MetaCursorTracker MetaCursorTracker; typedef struct _MetaDnd MetaDnd; typedef struct _MetaSettings MetaSettings; @@ -1267,10 +1267,10 @@ index 49fb568..d479c19 100644 typedef struct _MetaSelection MetaSelection; diff --git a/src/meta/window.h b/src/meta/window.h -index 3157d44..a5901ee 100644 +index 2b69269..f4aebf0 100644 --- a/src/meta/window.h +++ b/src/meta/window.h -@@ -446,4 +446,10 @@ uint64_t meta_window_get_id (MetaWindow *window); +@@ -450,4 +450,10 @@ uint64_t meta_window_get_id (MetaWindow *window); META_EXPORT MetaWindowClientType meta_window_get_client_type (MetaWindow *window); diff --git a/meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch.old b/meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch.old new file mode 100644 index 0000000..e6d09d5 --- /dev/null +++ b/meta-gnome/recipes-gnome/mutter/mutter/0001-Citadel-changes-to-Mutter.patch.old @@ -0,0 +1,1300 @@ +From c203de9ad5f88eb48f749cda1b5a6c8896a2af15 Mon Sep 17 00:00:00 2001 +From: Bruce Leidl +Date: Mon, 4 Oct 2021 07:19:16 -0400 +Subject: [PATCH] Citadel changes to Mutter + +--- + src/compositor/compositor.c | 9 +- + src/core/meta-workspace-manager-private.h | 69 ++++ + src/core/meta-workspace-manager.c | 465 +++++++++++++++++++++- + src/core/util-private.h | 2 + + src/core/util.c | 48 +++ + src/core/window-private.h | 3 + + src/core/window.c | 41 +- + src/core/workspace-private.h | 3 + + src/core/workspace.c | 170 ++++---- + src/meta/common.h | 4 +- + src/meta/meta-workspace-manager.h | 44 ++ + src/meta/types.h | 1 + + src/meta/window.h | 6 + + src/meta/workspace.h | 6 + + 14 files changed, 786 insertions(+), 85 deletions(-) + +diff --git a/src/compositor/compositor.c b/src/compositor/compositor.c +index 1770550..d1eb7f8 100644 +--- a/src/compositor/compositor.c ++++ b/src/compositor/compositor.c +@@ -744,8 +744,13 @@ meta_compositor_switch_workspace (MetaCompositor *compositor, + meta_compositor_get_instance_private (compositor); + gint to_indx, from_indx; + +- to_indx = meta_workspace_index (to); +- from_indx = meta_workspace_index (from); ++ if (direction == META_MOTION_CONTEXT_SWITCH) { ++ to_indx = meta_workspace_get_id (to); ++ from_indx = meta_workspace_get_id (from); ++ } else { ++ to_indx = meta_workspace_index (to); ++ from_indx = meta_workspace_index (from); ++ } + + priv->switch_workspace_in_progress++; + +diff --git a/src/core/meta-workspace-manager-private.h b/src/core/meta-workspace-manager-private.h +index 261c4d4..4b5d4f4 100644 +--- a/src/core/meta-workspace-manager-private.h ++++ b/src/core/meta-workspace-manager-private.h +@@ -30,6 +30,36 @@ + #include "meta/types.h" + #include "meta/meta-workspace-manager.h" + ++// ++// Stores list of MetaWorkspaces and pointer to an active MetaWorkspace. When this context becomes ++// the current context, the workspace fields are swapped into the corresponding fields in ++// MetaWorkspaceManager. ++// ++// ++struct _MetaWorkspaceContext ++{ ++ ++ GObject parent; ++ // Link back to MetaWorkspaceManager ++ MetaWorkspaceManager *manager; ++ ++ // MetaWorkspace list belonging to this context. Copied to field with same name in ++ // MetaWorkspaceManager when this context is active. Any code which changes this list ++ // must make sure this context is not currently active in which case the list in ++ // MetaWorkspaceManager must be changed instead. ++ GList *workspaces; ++ ++ // Active MetaWorkspace for this context. Also copied to workspace manager upon activation. ++ // The rule above about not writing if context is currently active also applies to this field. ++ MetaWorkspace *active_workspace; ++ ++ // PID namespace ++ gchar *namespace; ++ ++ // A unique ID value for this context. ++ guint id; ++}; ++ + struct _MetaWorkspaceManager + { + GObject parent; +@@ -37,8 +67,21 @@ struct _MetaWorkspaceManager + MetaDisplay *display; + MetaWorkspace *active_workspace; + ++ GList *all_workspaces; + GList *workspaces; + ++ // List of WorkspaceContext ++ GList *context_list; ++ ++ gchar *mutter_namespace; ++ ++ // Current active WorkspaceContext. MetaWorkspaceManager state (workspaces, active_workspace) ++ // will be saved here when a new WorkspaceContext is made active. ++ MetaWorkspaceContext *active_context; ++ ++ // The next id value to allocate when creating a new WorkspaceContext ++ guint next_context_id; ++ + int rows_of_workspaces; + int columns_of_workspaces; + MetaDisplayCorner starting_corner; +@@ -93,4 +136,30 @@ void meta_workspace_manager_update_num_workspaces (MetaWorkspaceManager *workspa + guint32 timestamp, + int new_num); + ++MetaWorkspaceContext *meta_workspace_context_new (MetaWorkspaceManager *manager, const char *namespace); ++ ++void meta_workspace_context_make_active (MetaWorkspaceContext *context); ++ ++MetaWorkspaceContext *meta_workspace_manager_lookup_context (MetaWorkspaceManager *workspace_manager, ++ guint context_id); ++ ++ ++void meta_workspace_manager_append_context_workspace (MetaWorkspaceManager *manager, ++ MetaWorkspace *workspace); ++ ++void meta_workspace_manager_remove_context_workspace (MetaWorkspaceManager *manager, ++ MetaWorkspace *workspace); ++ ++int meta_workspace_manager_context_workspace_index (MetaWorkspaceManager *workspace_manager, ++ MetaWorkspace *workspace); ++ ++int meta_workspace_manager_get_workspace_id (MetaWorkspaceManager *workspace_manager, ++ MetaWorkspace *workspace); ++MetaWorkspace * ++meta_workspace_manager_lookup_workspace_by_id (MetaWorkspaceManager *workspace_manager, int workspace_id); ++ ++gboolean ++meta_workspace_manager_is_window_on_foreign_context (MetaWorkspaceManager *workspace_manager, MetaWindow *window); ++ ++ + #endif /* META_WORKSPACE_MANAGER_PRIVATE_H */ +diff --git a/src/core/meta-workspace-manager.c b/src/core/meta-workspace-manager.c +index 61fbc00..d7696a7 100644 +--- a/src/core/meta-workspace-manager.c ++++ b/src/core/meta-workspace-manager.c +@@ -44,6 +44,8 @@ enum + WORKSPACES_REORDERED, + ACTIVE_WORKSPACE_CHANGED, + SHOWING_DESKTOP_CHANGED, ++ CONTEXT_SWITCHED, ++ CONTEXT_WINDOW_MOVED, + LAST_SIGNAL + }; + +@@ -178,6 +180,21 @@ meta_workspace_manager_class_init (MetaWorkspaceManagerClass *klass) + 0, NULL, NULL, NULL, + G_TYPE_NONE, 0); + ++ workspace_manager_signals[CONTEXT_SWITCHED] = ++ g_signal_new ("context-switched", ++ G_TYPE_FROM_CLASS (klass), ++ G_SIGNAL_RUN_LAST, ++ 0, NULL, NULL, NULL, ++ G_TYPE_NONE, 0); ++ ++ workspace_manager_signals[CONTEXT_WINDOW_MOVED] = ++ g_signal_new("context-window-moved", ++ G_TYPE_FROM_CLASS(klass), ++ G_SIGNAL_RUN_LAST, ++ 0, NULL, NULL, NULL, ++ G_TYPE_NONE, 1, ++ META_TYPE_WINDOW); ++ + g_object_class_install_property (object_class, + PROP_LAYOUT_COLUMNS, + g_param_spec_int ("layout-columns", +@@ -201,6 +218,7 @@ meta_workspace_manager_class_init (MetaWorkspaceManagerClass *klass) + "Number of workspaces", + 1, G_MAXINT, 1, + G_PARAM_READABLE)); ++ + } + + static void +@@ -213,7 +231,7 @@ meta_workspace_manager_reload_work_areas (MetaWorkspaceManager *workspace_manage + { + GList *l; + +- for (l = workspace_manager->workspaces; l; l = l->next) ++ for (l = workspace_manager->all_workspaces; l; l = l->next) + { + MetaWorkspace *workspace = l->data; + +@@ -230,12 +248,24 @@ meta_workspace_manager_new (MetaDisplay *display) + + workspace_manager->display = display; + workspace_manager->active_workspace = NULL; ++ workspace_manager->all_workspaces = NULL; + workspace_manager->workspaces = NULL; + workspace_manager->rows_of_workspaces = 1; + workspace_manager->columns_of_workspaces = -1; + workspace_manager->vertical_workspaces = FALSE; + workspace_manager->starting_corner = META_DISPLAY_TOPLEFT; + ++ workspace_manager->context_list = NULL; ++ workspace_manager->active_context = NULL; ++ workspace_manager->next_context_id = 1; ++ workspace_manager->mutter_namespace = meta_read_pid_namespace (getpid()); ++ ++ MetaWorkspaceContext *context = meta_workspace_context_new (workspace_manager, NULL); ++ ++ workspace_manager->workspaces = g_steal_pointer (&context->workspaces); ++ workspace_manager->active_workspace = g_steal_pointer (&context->active_workspace); ++ workspace_manager->active_context = context; ++ + /* This is the default layout extracted from default + * variable values in update_num_workspaces () + * This can be overridden using _NET_DESKTOP_LAYOUT in +@@ -246,11 +276,6 @@ meta_workspace_manager_new (MetaDisplay *display) + 1, + -1); + +- /* There must be at least one workspace at all times, +- * so create that required workspace. +- */ +- meta_workspace_new (workspace_manager); +- + meta_workspace_manager_init_workspaces (workspace_manager); + + meta_prefs_add_listener (prefs_changed_callback, workspace_manager); +@@ -301,6 +326,9 @@ MetaWorkspace * + meta_workspace_manager_get_workspace_by_index (MetaWorkspaceManager *workspace_manager, + int idx) + { ++ if ((idx >> 16) & 0xFFFF) { ++ return meta_workspace_manager_lookup_workspace_by_id (workspace_manager, idx); ++ } + return g_list_nth_data (workspace_manager->workspaces, idx); + } + +@@ -1001,7 +1029,7 @@ meta_workspace_manager_unshow_desktop (MetaWorkspaceManager *workspace_manager) + GList * + meta_workspace_manager_get_workspaces (MetaWorkspaceManager *workspace_manager) + { +- return workspace_manager->workspaces; ++ return workspace_manager->all_workspaces; + } + + int +@@ -1015,6 +1043,17 @@ meta_workspace_manager_get_active_workspace_index (MetaWorkspaceManager *workspa + return meta_workspace_index (active); + } + ++int ++meta_workspace_manager_get_active_workspace_id (MetaWorkspaceManager *workspace_manager) ++{ ++ MetaWorkspace *active = workspace_manager->active_workspace; ++ ++ if (!active) ++ return -1; ++ ++ return meta_workspace_get_id (active); ++} ++ + /** + * meta_workspace_manager_get_active_workspace: + * @workspace_manager: A #MetaWorkspaceManager +@@ -1033,9 +1072,15 @@ meta_workspace_manager_workspace_switched (MetaWorkspaceManager *workspace_manag + int to, + MetaMotionDirection direction) + { +- g_signal_emit (workspace_manager, +- workspace_manager_signals[WORKSPACE_SWITCHED], 0, +- from, to, direction); ++ if (direction == META_MOTION_CONTEXT_SWITCH) { ++ g_signal_emit (workspace_manager, ++ workspace_manager_signals[CONTEXT_SWITCHED], ++ 0, NULL); ++ } else { ++ g_signal_emit (workspace_manager, ++ workspace_manager_signals[WORKSPACE_SWITCHED], 0, ++ from, to, direction); ++ } + } + + static void +@@ -1058,3 +1103,403 @@ prefs_changed_callback (MetaPreference pref, + timestamp, new_num); + } + } ++ ++ ++/** ++ * meta_workspace_manager_set_builtin_struts_all: ++ * @workspace_manager: a #MetaWorkspaceManager ++ * @struts: (element-type Meta.Strut) (transfer none): list of #MetaStrut ++ * ++ * Sets a list of struts on every workspace that will be used in addition to the struts ++ * of the windows in the workspace when computing the work area of ++ * the workspace. ++ */ ++void meta_workspace_manager_set_builtin_struts_all(MetaWorkspaceManager *workspace_manager, ++ GSList *struts) ++{ ++ GList *context_iter = workspace_manager->context_list; ++ while (context_iter) { ++ MetaWorkspaceContext *context = context_iter->data; ++ for (GList *ws_iter = context->workspaces; ws_iter; ws_iter = ws_iter->next) { ++ MetaWorkspace *workspace = ws_iter->data; ++ meta_workspace_set_builtin_struts(workspace, struts); ++ } ++ context_iter = context_iter->next; ++ } ++} ++ ++ ++ ++/** ++ * meta_workspace_manager_lookup_context: ++ * @workspace_manager: a #MetaWorkspaceManager ++ * @context_id: id value of context to look up ++ * ++ * Look up WorkspaceContext by id and return it. If no context is found with ++ * the specified id the return value is %NULL. ++ * ++ * Return value: (transfer none) (nullable): the workspace context with the specified id ++ * or %NULL if no context with matching id exists. ++ */ ++MetaWorkspaceContext * ++meta_workspace_manager_lookup_context (MetaWorkspaceManager *workspace_manager, guint context_id) ++{ ++ for (GList *iter = workspace_manager->context_list; iter; iter = iter->next) { ++ MetaWorkspaceContext *context = iter->data; ++ if (context_id == context->id) { ++ return context; ++ } ++ } ++ return NULL; ++} ++ ++const char * ++meta_workspace_manager_mutter_namespace (MetaWorkspaceManager *workspace_manager) ++{ ++ if (!workspace_manager->mutter_namespace) { ++ workspace_manager->mutter_namespace = meta_read_pid_namespace (getpid()); ++ } ++ return workspace_manager->mutter_namespace; ++} ++ ++/* ++ * Return pointer to the live workspace list depending on whether or not the context is currently active. ++ * While a workspace context is active, the list must be accessed through the pointer workspace_manager->workspaces ++ */ ++GList ** ++meta_workspace_manager_workspace_list_for_context (MetaWorkspaceManager *workspace_manager, guint context_id) ++{ ++ if (workspace_manager->active_context && workspace_manager->active_context->id == context_id) { ++ return &workspace_manager->workspaces; ++ } ++ ++ MetaWorkspaceContext *context = meta_workspace_manager_lookup_context (workspace_manager, context_id); ++ ++ if (context) { ++ return &context->workspaces; ++ } else { ++ g_warning ("MetaWorkspaceManager: Failed to find context workspace list (context_id = %d)", context_id); ++ return NULL; ++ } ++} ++ ++void ++meta_workspace_manager_append_context_workspace (MetaWorkspaceManager *workspace_manager, MetaWorkspace *workspace) ++{ ++ GList **p_workspaces = meta_workspace_manager_workspace_list_for_context (workspace_manager, workspace->context_id); ++ if (p_workspaces) { ++ *p_workspaces = g_list_append (*p_workspaces, workspace); ++ } ++} ++ ++void ++meta_workspace_manager_remove_context_workspace (MetaWorkspaceManager *workspace_manager, MetaWorkspace *workspace) ++{ ++ GList **p_workspaces = meta_workspace_manager_workspace_list_for_context (workspace_manager, workspace->context_id); ++ if (p_workspaces) { ++ *p_workspaces = g_list_remove (*p_workspaces, workspace); ++ } ++ workspace_manager->all_workspaces = g_list_remove (workspace_manager->all_workspaces, workspace); ++} ++ ++static int ++workspace_index_in_context (MetaWorkspaceManager *workspace_manager, MetaWorkspace *workspace) ++{ ++ GList **p_workspaces = meta_workspace_manager_workspace_list_for_context (workspace_manager, workspace->context_id); ++ if (p_workspaces) { ++ return g_list_index (*p_workspaces, workspace); ++ } else { ++ g_warning ("MetaWorkspaceManager: Could not find context for id=%d in workspace_index_in_context()", workspace->context_id); ++ return -1; ++ } ++} ++ ++int ++meta_workspace_manager_get_workspace_id (MetaWorkspaceManager *workspace_manager, MetaWorkspace *workspace) ++{ ++ int idx = workspace_index_in_context (workspace_manager, workspace); ++ ++ if (idx >= 0) { ++ idx |= (int)(workspace->context_id << 16); ++ } else { ++ g_warning ("MetaWorkspaceManager: Workspace with context_id = %d not found in meta_workspace_manager_get_workspace_id()", workspace->context_id); ++ } ++ return idx; ++} ++ ++int ++meta_workspace_manager_context_workspace_index (MetaWorkspaceManager *workspace_manager, MetaWorkspace *workspace) ++{ ++ ++ if (!(workspace_manager->active_context && workspace_manager->active_context->id == workspace->context_id)) { ++ guint active = (workspace_manager->active_context) ? (workspace_manager->active_context->id) : 0; ++ g_warning ("MetaWorkspaceManager: context_workspace_index() called on workspace not in active context. (ws->context_id = %d, active->context_id=%d)", ++ workspace->context_id, active); ++ } ++ ++ int idx = workspace_index_in_context (workspace_manager, workspace); ++ if (idx < 0) { ++ g_warning ("MetaWorkspaceManager: Failed to find workspace with context_id=%d in context_workspace_index()", ++ workspace->context_id); ++ } ++ return idx; ++} ++ ++MetaWorkspace * ++meta_workspace_manager_lookup_workspace_by_id (MetaWorkspaceManager *workspace_manager, int workspace_id) ++{ ++ uint context_id = (workspace_id >> 16) & 0xFFFF; ++ if (context_id) { ++ GList **p_workspaces = meta_workspace_manager_workspace_list_for_context (workspace_manager, context_id); ++ int idx = workspace_id & 0xFFFF; ++ if (p_workspaces) { ++ return g_list_nth_data (*p_workspaces, idx); ++ } ++ } ++ return NULL; ++} ++ ++/** ++ * meta_workspace_manager_context_for_namespace: ++ * @workspace_manager: a #MetaWorkspaceManager ++ * @namespace: namespace of context ++ * ++ * Find an existing WorkspaceContext for the specified namespace. If no WorkspaceContext ++ * currently exists for namespace create a new one. ++ * ++ * Return value: (transfer none): the workspace context for the specified namespace ++ */ ++MetaWorkspaceContext * ++meta_workspace_manager_context_for_namespace (MetaWorkspaceManager *workspace_manager, const gchar *namespace) ++{ ++ MetaWorkspaceContext *anonymous_context = NULL; ++ ++ for (GList *iter = workspace_manager->context_list; iter; iter = iter->next) { ++ MetaWorkspaceContext *context = iter->data; ++ if (context->namespace == NULL && anonymous_context == NULL) { ++ anonymous_context = context; ++ } else if (!g_strcmp0 (context->namespace, namespace )) { ++ return context; ++ } ++ } ++ ++ if (anonymous_context) { ++ g_message ("MetaWorkspaceManager: Assigning anonymous workspace context to namespace %s", namespace); ++ anonymous_context->namespace = g_strdup (namespace); ++ return anonymous_context; ++ } ++ ++ return meta_workspace_context_new (workspace_manager, namespace); ++} ++ ++guint ++meta_workspace_manager_active_context_id (MetaWorkspaceManager *workspace_manager) ++{ ++ if (workspace_manager->active_context) { ++ return workspace_manager->active_context->id; ++ } else { ++ return 0; ++ } ++} ++ ++G_DEFINE_TYPE (MetaWorkspaceContext, meta_workspace_context, G_TYPE_OBJECT) ++ ++guint ++meta_workspace_context_id (MetaWorkspaceContext *context) ++{ ++ return context->id; ++} ++ ++void ++meta_workspace_context_remove (MetaWorkspaceContext *context) ++{ ++ if (meta_workspace_context_is_current (context)) { ++ g_warning ("MetaWorkspaceManager: attempt to remove active context ignored"); ++ return; ++ } ++ ++ context->manager->context_list = g_list_remove (context->manager->context_list, context); ++ g_object_unref (context); ++} ++ ++static void ++meta_workspace_context_destroy (MetaWorkspaceContext *context) ++{ ++ MetaWorkspaceManager *manager= context->manager; ++ ++ g_return_if_fail (manager->active_context != context); ++ ++ manager->context_list = g_list_remove(manager->context_list, context); ++ ++ for (GList *iter = context->workspaces; iter; iter = iter->next) { ++ MetaWorkspace *workspace = iter->data; ++ meta_workspace_relocate_windows (workspace, manager->active_workspace); ++ } ++ context->active_workspace = NULL; ++ g_free (context->namespace); ++ g_list_free_full (context->workspaces, (GDestroyNotify) meta_workspace_remove); ++ g_free(context); ++} ++ ++static void ++meta_workspace_context_finalize (GObject *object) ++{ ++ MetaWorkspaceContext *context = META_WORKSPACE_CONTEXT (object); ++ meta_workspace_context_destroy(context); ++ G_OBJECT_CLASS(meta_workspace_context_parent_class)->finalize(object); ++} ++ ++static void ++meta_workspace_context_class_init (MetaWorkspaceContextClass *klass) ++{ ++ GObjectClass *object_class = G_OBJECT_CLASS (klass); ++ object_class->finalize = meta_workspace_context_finalize; ++} ++ ++static void ++meta_workspace_context_init (MetaWorkspaceContext *context) ++{ ++} ++ ++MetaWorkspaceContext * ++meta_workspace_context_new (MetaWorkspaceManager *manager, const char *namespace) ++{ ++ guint context_id = manager->next_context_id++; ++ ++ MetaWorkspaceContext *context = g_object_new (META_TYPE_WORKSPACE_CONTEXT, NULL); ++ ++ context->manager = manager; ++ context->workspaces = NULL; ++ context->active_workspace = NULL; ++ context->namespace = NULL; ++ context->id = context_id; ++ ++ if (namespace) { ++ g_message ("MetaWorkspaceManager: Creating new workspace context for namespace %s (id: %d)", namespace, context_id); ++ context->namespace = g_strdup (namespace); ++ } else { ++ g_message ("MetaWorkspaceManager: Creating new anonymous workspace context (id: %d)", context_id); ++ } ++ ++ manager->context_list = g_list_append (manager->context_list, context); ++ ++ context->active_workspace = meta_workspace_new_with_context_id (manager, context_id); ++ g_object_notify (G_OBJECT (manager), "n-workspaces"); ++ ++ return context; ++} ++ ++ ++/* ++ * Synchronize the state stored in the MetaWorkspaceManager to 'context' ++ * by copying the relevant fields to the WorkspaceContext structure. ++ * ++ * The state which is saved is the list of workspaces and the active ++ * workspace pointer: ++ * ++ * workspace_manager->active_workspace ++ * workspace_manager->workspaces ++ */ ++static void ++workspace_context_sync_manager_state (MetaWorkspaceContext *context) ++{ ++ context->active_workspace = context->manager->active_workspace; ++ context->workspaces = context->manager->workspaces; ++} ++ ++gboolean ++meta_workspace_context_is_current (MetaWorkspaceContext *context) ++{ ++ return context && context->manager->active_context == context; ++} ++ ++/** ++ * meta_workspace_context_get_active_workspace: ++ * @context: A #MetaWorkspaceContext ++ * ++ * Returns: (transfer none): The current workspace for this context ++ */ ++MetaWorkspace * ++meta_workspace_context_get_active_workspace (MetaWorkspaceContext *context) ++{ ++ if (meta_workspace_context_is_current (context)) { ++ return context->manager->active_workspace; ++ } else { ++ return context->active_workspace; ++ } ++} ++ ++void ++meta_workspace_context_move_window_to_context (MetaWorkspaceContext *context, MetaWindow *window) ++{ ++ if (!context->active_workspace) { ++ g_warning ("MetaWorkspaceContext: Cannot move window to context (%d) because no workspace is active", context->id); ++ return; ++ } ++ ++ if (window->workspace->context_id != context->id) { ++ meta_window_change_workspace (window, context->active_workspace); ++ g_signal_emit (context->manager, workspace_manager_signals[CONTEXT_WINDOW_MOVED], 0, window); ++ } ++} ++ ++ ++void ++meta_workspace_context_make_active (MetaWorkspaceContext *context) { ++ ++ g_message ("MetaWorkspaceManager: Activate workspace context (id: %d, ns: %s)", context->id, context->namespace); ++ ++ MetaWorkspaceManager *manager = context->manager; ++ ++ workspace_context_sync_manager_state (manager->active_context); ++ ++ manager->active_context = context; ++ ++ /* ++ * Do not update manager->active_workspace because meta_workspace_activate() expects ++ * old value ++ */ ++ ++ /* steal pointer to avoid writing code elsewhere that changes this list while context is active */ ++ manager->workspaces = g_steal_pointer (&context->workspaces); ++} ++ ++/* ++ * Activate a WorkspaceContext instance by copying the context state fields ++ * into the MetaWorkspaceManager structure. ++ * ++ * If 'context' is already the current WorkspaceContext do nothing. ++ * ++ * If some other context is active, save the context fields by calling ++ * ++ * workspace_context_sync_manager_state() ++ */ ++void ++meta_workspace_context_activate (MetaWorkspaceContext *context) ++{ ++ if (meta_workspace_context_is_current (context)) { ++ return; ++ } ++ ++ meta_workspace_context_make_active (context); ++ ++ guint32 timestamp; ++ ++ timestamp = meta_display_get_current_time_roundtrip (context->manager->display); ++ ++ /* Will set manager->active_workspace from context->active_workspace */ ++ meta_workspace_activate ( g_steal_pointer (&context->active_workspace), timestamp); ++} ++ ++gboolean ++meta_workspace_manager_is_window_on_foreign_context (MetaWorkspaceManager *workspace_manager, MetaWindow *window) ++{ ++ const char *ns = meta_window_namespace (window); ++ ++ if (!ns || !g_strcmp0 (ns, workspace_manager->mutter_namespace) || !window->workspace) { ++ return FALSE; ++ } ++ ++ MetaWorkspaceContext *context = meta_workspace_manager_context_for_namespace (workspace_manager, ns); ++ return context->id != window->workspace->context_id; ++} +diff --git a/src/core/util-private.h b/src/core/util-private.h +index 0d68a72..834b3e2 100644 +--- a/src/core/util-private.h ++++ b/src/core/util-private.h +@@ -43,4 +43,6 @@ void meta_set_is_wayland_compositor (gboolean setting); + char * meta_generate_random_id (GRand *rand, + int length); + ++char * meta_read_pid_namespace (pid_t pid); ++ + #endif +diff --git a/src/core/util.c b/src/core/util.c +index bbb5a24..57645e0 100644 +--- a/src/core/util.c ++++ b/src/core/util.c +@@ -741,3 +741,51 @@ meta_get_debug_paint_flags (void) + { + return debug_paint_flags; + } ++ ++static GFileInfo * ++pid_namespace_file_info (pid_t pid) ++{ ++ char *filename = g_strdup_printf("/proc/%u/ns/pid", pid); ++ GFile *file = g_file_new_for_path(filename); ++ g_free(filename); ++ ++ GError *error = NULL; ++ ++ GFileInfo *info = g_file_query_info(file, ++ G_FILE_ATTRIBUTE_STANDARD_IS_SYMLINK "," G_FILE_ATTRIBUTE_STANDARD_SYMLINK_TARGET, ++ G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS, ++ NULL, ++ &error); ++ ++ g_object_unref(file); ++ ++ if (info == NULL) { ++ g_warning("MetaWindow: Error attempting to read /proc/%u/ns/pid symlink: %s", pid, error->message); ++ g_error_free (error); ++ return NULL; ++ } ++ ++ if (!g_file_info_get_is_symlink (info)) { ++ g_warning("MetaWindow: /proc/%u/ns/pid exists but is not a symlink?", pid); ++ g_object_unref (info); ++ return NULL; ++ } ++ ++ return info; ++ ++} ++ ++char * ++meta_read_pid_namespace (pid_t pid) ++{ ++ char *value = NULL; ++ GFileInfo *info = pid_namespace_file_info (pid); ++ const char *target = g_file_info_get_symlink_target (info); ++ ++ if (target) { ++ value = g_strdup (target); ++ } ++ g_object_unref (info); ++ ++ return value; ++} +diff --git a/src/core/window-private.h b/src/core/window-private.h +index d1730c9..6a55630 100644 +--- a/src/core/window-private.h ++++ b/src/core/window-private.h +@@ -562,6 +562,9 @@ struct _MetaWindow + guint unmanage_idle_id; + + pid_t client_pid; ++ ++ guint namespace_set: 1; ++ gchar *namespace; + }; + + struct _MetaWindowClass +diff --git a/src/core/window.c b/src/core/window.c +index c843c62..c0b9e3f 100644 +--- a/src/core/window.c ++++ b/src/core/window.c +@@ -345,6 +345,7 @@ meta_window_finalize (GObject *object) + g_free (window->gtk_app_menu_object_path); + g_free (window->gtk_menubar_object_path); + g_free (window->placement.rule); ++ g_free (window->namespace); + + G_OBJECT_CLASS (meta_window_parent_class)->finalize (object); + } +@@ -1564,7 +1565,7 @@ meta_window_unmanage (MetaWindow *window, + g_assert (window->workspace == NULL); + + #ifndef G_DISABLE_CHECKS +- tmp = workspace_manager->workspaces; ++ tmp = workspace_manager->all_workspaces; + while (tmp != NULL) + { + MetaWorkspace *workspace = tmp->data; +@@ -4889,7 +4890,7 @@ set_workspace_state (MetaWindow *window, + else if (window->on_all_workspaces) + { + GList *l; +- for (l = workspace_manager->workspaces; l != NULL; l = l->next) ++ for (l = workspace_manager->all_workspaces; l != NULL; l = l->next) + { + MetaWorkspace *ws = l->data; + meta_workspace_remove_window (ws, window); +@@ -4904,7 +4905,7 @@ set_workspace_state (MetaWindow *window, + else if (window->on_all_workspaces) + { + GList *l; +- for (l = workspace_manager->workspaces; l != NULL; l = l->next) ++ for (l = workspace_manager->all_workspaces; l != NULL; l = l->next) + { + MetaWorkspace *ws = l->data; + meta_workspace_add_window (ws, window); +@@ -5203,8 +5204,10 @@ meta_window_change_workspace_by_index (MetaWindow *window, + workspace = + meta_workspace_manager_get_workspace_by_index (workspace_manager, space_index); + +- if (!workspace && append) ++ if (!workspace && append) { + workspace = meta_workspace_manager_append_new_workspace (workspace_manager, FALSE, META_CURRENT_TIME); ++ } ++ + + if (workspace) + meta_window_change_workspace (window, workspace); +@@ -5528,7 +5531,7 @@ meta_window_get_workspaces (MetaWindow *window) + MetaWorkspaceManager *workspace_manager = window->display->workspace_manager; + + if (window->on_all_workspaces) +- return workspace_manager->workspaces; ++ return workspace_manager->all_workspaces; + else if (window->workspace != NULL) + return window->workspace->list_containing_self; + else if (window->constructing) +@@ -8675,3 +8678,31 @@ meta_window_get_client_type (MetaWindow *window) + { + return window->client_type; + } ++ ++/** ++ * meta_window_namespace: ++ * @window: a #MetaWindow ++ * ++ * Returns string identifying PID namespace this window belongs to ++ * if known ++ * ++ * Return value: (transfer none): the pid namespace string, or %NULL ++ */ ++const char * ++meta_window_namespace (MetaWindow *window) ++{ ++ if (!window->namespace_set) { ++ window->namespace_set = TRUE; ++ pid_t pid = meta_window_get_pid (window); ++ if (pid) { ++ window->namespace = meta_read_pid_namespace (pid); ++ } ++ } ++ return window->namespace; ++} ++ ++gboolean ++meta_window_is_on_foreign_workspace_context (MetaWindow *window) ++{ ++ return meta_workspace_manager_is_window_on_foreign_context (window->display->workspace_manager, window); ++} +\ No newline at end of file +diff --git a/src/core/workspace-private.h b/src/core/workspace-private.h +index a58b234..2e364a1 100644 +--- a/src/core/workspace-private.h ++++ b/src/core/workspace-private.h +@@ -39,6 +39,7 @@ struct _MetaWorkspace + GObject parent_instance; + MetaDisplay *display; + MetaWorkspaceManager *manager; ++ guint context_id; + + GList *windows; + +@@ -74,6 +75,8 @@ struct _MetaWorkspaceClass + }; + + MetaWorkspace* meta_workspace_new (MetaWorkspaceManager *workspace_manager); ++MetaWorkspace* meta_workspace_new_with_context_id (MetaWorkspaceManager *workspace_manager, ++ guint context_id); + void meta_workspace_remove (MetaWorkspace *workspace); + void meta_workspace_add_window (MetaWorkspace *workspace, + MetaWindow *window); +diff --git a/src/core/workspace.c b/src/core/workspace.c +index 321d3ef..633184d 100644 +--- a/src/core/workspace.c ++++ b/src/core/workspace.c +@@ -237,7 +237,7 @@ meta_workspace_init (MetaWorkspace *workspace) + } + + MetaWorkspace * +-meta_workspace_new (MetaWorkspaceManager *workspace_manager) ++meta_workspace_new_with_context_id (MetaWorkspaceManager *workspace_manager, guint context_id) + { + MetaDisplay *display = workspace_manager->display; + MetaWorkspace *workspace; +@@ -247,9 +247,11 @@ meta_workspace_new (MetaWorkspaceManager *workspace_manager) + + workspace->display = display; + workspace->manager = workspace_manager; ++ workspace->context_id = context_id; ++ ++ workspace_manager->all_workspaces = ++ g_list_append (workspace_manager->all_workspaces, workspace); + +- workspace_manager->workspaces = +- g_list_append (workspace_manager->workspaces, workspace); + workspace->windows = NULL; + workspace->mru_list = NULL; + +@@ -276,9 +278,17 @@ meta_workspace_new (MetaWorkspaceManager *workspace_manager) + meta_workspace_add_window (workspace, l->data); + g_slist_free (windows); + ++ meta_workspace_manager_append_context_workspace (workspace_manager, workspace); ++ + return workspace; + } + ++MetaWorkspace * ++meta_workspace_new (MetaWorkspaceManager *workspace_manager) ++{ ++ return meta_workspace_new_with_context_id (workspace_manager, workspace_manager->active_context->id); ++} ++ + /** + * workspace_free_all_struts: + * @workspace: The workspace. +@@ -333,8 +343,7 @@ meta_workspace_remove (MetaWorkspace *workspace) + + assert_workspace_empty (workspace); + +- manager->workspaces = +- g_list_remove (manager->workspaces, workspace); ++ meta_workspace_manager_remove_context_workspace (manager, workspace); + + meta_workspace_clear_logical_monitor_data (workspace); + +@@ -381,8 +390,8 @@ meta_workspace_add_window (MetaWorkspace *workspace, + if (window->struts) + { + meta_topic (META_DEBUG_WORKAREA, +- "Invalidating work area of workspace %d since we're adding window %s to it", +- meta_workspace_index (workspace), window->desc); ++ "Invalidating work area of workspace %08x since we're adding window %s to it", ++ meta_workspace_get_id (workspace), window->desc); + meta_workspace_invalidate_work_area (workspace); + } + +@@ -405,8 +414,8 @@ meta_workspace_remove_window (MetaWorkspace *workspace, + if (window->struts) + { + meta_topic (META_DEBUG_WORKAREA, +- "Invalidating work area of workspace %d since we're removing window %s from it", +- meta_workspace_index (workspace), window->desc); ++ "Invalidating work area of workspace %08x since we're removing window %s from it", ++ meta_workspace_get_id (workspace), window->desc); + meta_workspace_invalidate_work_area (workspace); + } + +@@ -456,6 +465,13 @@ workspace_switch_sound(MetaWorkspace *from, + int i, nw, x, y, fi, ti; + const char *e; + ++ g_message ("MetaWorkspace: workspace_switch_sound(from: %08x, to: %08x)", from->context_id, to->context_id); ++ if (from->context_id != to->context_id) { ++ /* XXX: There is no sound for context switches, but there should be (?) */ ++ return; ++ } ++ g_message ("MetaWorkspace: workspace_switch_sound(), calling meta_workspace_index() on from and to"); ++ + nw = meta_workspace_manager_get_n_workspaces (from->manager); + fi = meta_workspace_index(from); + ti = meta_workspace_index(to); +@@ -536,9 +552,15 @@ meta_workspace_activate_with_focus (MetaWorkspace *workspace, + MetaWorkspaceLayout layout1, layout2; + gint num_workspaces, current_space, new_space; + MetaMotionDirection direction; ++ MetaWorkspaceContext *context; ++ ++ meta_verbose ("Activating workspace %08x", ++ meta_workspace_get_id (workspace)); + +- meta_verbose ("Activating workspace %d", +- meta_workspace_index (workspace)); ++ context = meta_workspace_manager_lookup_context (workspace->manager, workspace->context_id); ++ if(context && !meta_workspace_context_is_current (context)) { ++ meta_workspace_context_make_active (context); ++ } + + if (workspace->manager->active_workspace == workspace) + { +@@ -601,52 +623,59 @@ meta_workspace_activate_with_focus (MetaWorkspace *workspace, + comp = meta_display_get_compositor (workspace->display); + direction = 0; + +- current_space = meta_workspace_index (old); +- new_space = meta_workspace_index (workspace); +- num_workspaces = meta_workspace_manager_get_n_workspaces (workspace->manager); +- meta_workspace_manager_calc_workspace_layout (workspace->manager, num_workspaces, +- current_space, &layout1); + +- meta_workspace_manager_calc_workspace_layout (workspace->manager, num_workspaces, ++ if (workspace->context_id != old->context_id) { ++ direction = META_MOTION_CONTEXT_SWITCH; ++ current_space = meta_workspace_get_id (old); ++ new_space = meta_workspace_get_id (workspace); ++ } else { ++ current_space = meta_workspace_index (old); ++ new_space = meta_workspace_index (workspace); ++ num_workspaces = meta_workspace_manager_get_n_workspaces (workspace->manager); ++ meta_workspace_manager_calc_workspace_layout (workspace->manager, num_workspaces, ++ current_space, &layout1); ++ ++ meta_workspace_manager_calc_workspace_layout (workspace->manager, num_workspaces, + new_space, &layout2); + +- if (meta_get_locale_direction () == META_LOCALE_DIRECTION_RTL) +- { +- if (layout1.current_col > layout2.current_col) +- direction = META_MOTION_RIGHT; +- else if (layout1.current_col < layout2.current_col) +- direction = META_MOTION_LEFT; +- } +- else +- { +- if (layout1.current_col < layout2.current_col) +- direction = META_MOTION_RIGHT; +- else if (layout1.current_col > layout2.current_col) +- direction = META_MOTION_LEFT; +- } ++ if (meta_get_locale_direction () == META_LOCALE_DIRECTION_RTL) ++ { ++ if (layout1.current_col > layout2.current_col) ++ direction = META_MOTION_RIGHT; ++ else if (layout1.current_col < layout2.current_col) ++ direction = META_MOTION_LEFT; ++ } ++ else ++ { ++ if (layout1.current_col < layout2.current_col) ++ direction = META_MOTION_RIGHT; ++ else if (layout1.current_col > layout2.current_col) ++ direction = META_MOTION_LEFT; ++ } + +- if (layout1.current_row < layout2.current_row) +- { +- if (!direction) +- direction = META_MOTION_DOWN; +- else if (direction == META_MOTION_RIGHT) +- direction = META_MOTION_DOWN_RIGHT; +- else +- direction = META_MOTION_DOWN_LEFT; +- } +- +- if (layout1.current_row > layout2.current_row) +- { +- if (!direction) +- direction = META_MOTION_UP; +- else if (direction == META_MOTION_RIGHT) +- direction = META_MOTION_UP_RIGHT; +- else +- direction = META_MOTION_UP_LEFT; +- } +- +- meta_workspace_manager_free_workspace_layout (&layout1); +- meta_workspace_manager_free_workspace_layout (&layout2); ++ if (layout1.current_row < layout2.current_row) ++ { ++ if (!direction) ++ direction = META_MOTION_DOWN; ++ else if (direction == META_MOTION_RIGHT) ++ direction = META_MOTION_DOWN_RIGHT; ++ else ++ direction = META_MOTION_DOWN_LEFT; ++ } ++ ++ if (layout1.current_row > layout2.current_row) ++ { ++ if (!direction) ++ direction = META_MOTION_UP; ++ else if (direction == META_MOTION_RIGHT) ++ direction = META_MOTION_UP_RIGHT; ++ else ++ direction = META_MOTION_UP_LEFT; ++ } ++ ++ meta_workspace_manager_free_workspace_layout (&layout1); ++ meta_workspace_manager_free_workspace_layout (&layout2); ++ } + + meta_compositor_switch_workspace (comp, old, workspace, direction); + +@@ -683,14 +712,19 @@ meta_workspace_activate (MetaWorkspace *workspace, + int + meta_workspace_index (MetaWorkspace *workspace) + { +- int ret; +- +- ret = g_list_index (workspace->manager->workspaces, workspace); ++ return meta_workspace_manager_context_workspace_index (workspace->manager, workspace); ++} + +- if (ret < 0) +- meta_bug ("Workspace does not exist to index!"); ++int ++meta_workspace_get_id (MetaWorkspace *workspace) ++{ ++ return meta_workspace_manager_get_workspace_id (workspace->manager, workspace); ++} + +- return ret; ++guint ++meta_workspace_get_context_id (MetaWorkspace *workspace) ++{ ++ return workspace->context_id; + } + + void +@@ -747,14 +781,14 @@ meta_workspace_invalidate_work_area (MetaWorkspace *workspace) + if (workspace->work_areas_invalid) + { + meta_topic (META_DEBUG_WORKAREA, +- "Work area for workspace %d is already invalid", +- meta_workspace_index (workspace)); ++ "Work area for workspace %08x is already invalid", ++ meta_workspace_get_id (workspace)); + return; + } + + meta_topic (META_DEBUG_WORKAREA, +- "Invalidating work area for workspace %d", +- meta_workspace_index (workspace)); ++ "Invalidating work area for workspace %08x", ++ meta_workspace_get_id (workspace)); + + /* If we are in the middle of a resize or move operation, we + * might have cached pointers to the workspace's edges */ +@@ -925,8 +959,8 @@ ensure_work_areas_validated (MetaWorkspace *workspace) + } + workspace->work_area_screen = work_area; + meta_topic (META_DEBUG_WORKAREA, +- "Computed work area for workspace %d: %d,%d %d x %d", +- meta_workspace_index (workspace), ++ "Computed work area for workspace %08x: %d,%d %d x %d", ++ meta_workspace_get_id (workspace), + workspace->work_area_screen.x, + workspace->work_area_screen.y, + workspace->work_area_screen.width, +@@ -956,8 +990,8 @@ ensure_work_areas_validated (MetaWorkspace *workspace) + + meta_topic (META_DEBUG_WORKAREA, + "Computed work area for workspace %d " +- "monitor %d: %d,%d %d x %d", +- meta_workspace_index (workspace), ++ "monitor %08x: %d,%d %d x %d", ++ meta_workspace_get_id (workspace), + logical_monitor->number, + data->logical_monitor_work_area.x, + data->logical_monitor_work_area.y, +@@ -1199,6 +1233,8 @@ meta_motion_direction_to_string (MetaMotionDirection direction) + return "Up-Left"; + case META_MOTION_DOWN_LEFT: + return "Down-Left"; ++ case META_MOTION_CONTEXT_SWITCH: ++ return "Switch-Context"; + } + + return "Unknown"; +diff --git a/src/meta/common.h b/src/meta/common.h +index ab93080..32b6912 100644 +--- a/src/meta/common.h ++++ b/src/meta/common.h +@@ -328,6 +328,7 @@ typedef enum + * @META_MOTION_UP_RIGHT: Motion up and to the right + * @META_MOTION_DOWN_LEFT: Motion down and to the left + * @META_MOTION_DOWN_RIGHT: Motion down and to the right ++ * @META_MOTION_REALM_SWITCH: Workspace switch is a change of current realm + */ + + /* Negative to avoid conflicting with real workspace +@@ -343,7 +344,8 @@ typedef enum + META_MOTION_UP_LEFT = -5, + META_MOTION_UP_RIGHT = -6, + META_MOTION_DOWN_LEFT = -7, +- META_MOTION_DOWN_RIGHT = -8 ++ META_MOTION_DOWN_RIGHT = -8, ++ META_MOTION_CONTEXT_SWITCH = -9 + } MetaMotionDirection; + + /** +diff --git a/src/meta/meta-workspace-manager.h b/src/meta/meta-workspace-manager.h +index 92cd681..d00948d 100644 +--- a/src/meta/meta-workspace-manager.h ++++ b/src/meta/meta-workspace-manager.h +@@ -30,6 +30,14 @@ + #include + #include + ++#define META_TYPE_WORKSPACE_CONTEXT (meta_workspace_context_get_type ()) ++ ++META_EXPORT ++G_DECLARE_FINAL_TYPE (MetaWorkspaceContext, ++ meta_workspace_context, ++ META, WORKSPACE_CONTEXT, ++ GObject) ++ + #define META_TYPE_WORKSPACE_MANAGER (meta_workspace_manager_get_type ()) + + META_EXPORT +@@ -66,6 +74,9 @@ void meta_workspace_manager_reorder_workspace (MetaWorkspaceManager *workspace_m + META_EXPORT + int meta_workspace_manager_get_active_workspace_index (MetaWorkspaceManager *workspace_manager); + ++META_EXPORT ++int meta_workspace_manager_get_active_workspace_id (MetaWorkspaceManager *workspace_manager); ++ + META_EXPORT + MetaWorkspace *meta_workspace_manager_get_active_workspace (MetaWorkspaceManager *workspace_manager); + +@@ -75,4 +86,37 @@ void meta_workspace_manager_override_workspace_layout (MetaWorkspaceManager *wor + gboolean vertical_layout, + int n_rows, + int n_columns); ++META_EXPORT ++guint meta_workspace_manager_active_context_id (MetaWorkspaceManager *workspace_manager); ++ ++META_EXPORT ++void meta_workspace_manager_set_builtin_struts_all(MetaWorkspaceManager *workspace_manager, ++ GSList *struts); ++ ++META_EXPORT ++MetaWorkspaceContext *meta_workspace_manager_context_for_namespace (MetaWorkspaceManager *workspace_manager, ++ const gchar *namespace); ++ ++META_EXPORT ++const char *meta_workspace_manager_mutter_namespace (MetaWorkspaceManager *workspace_manager); ++ ++META_EXPORT ++void meta_workspace_context_activate (MetaWorkspaceContext *context); ++ ++META_EXPORT ++void meta_workspace_context_remove (MetaWorkspaceContext *context); ++ ++META_EXPORT ++gboolean meta_workspace_context_is_current (MetaWorkspaceContext *context); ++ ++META_EXPORT ++MetaWorkspace * ++meta_workspace_context_get_active_workspace (MetaWorkspaceContext *context); ++ ++META_EXPORT ++guint meta_workspace_context_id (MetaWorkspaceContext *context); ++ ++META_EXPORT ++void meta_workspace_context_move_window_to_context (MetaWorkspaceContext *context, MetaWindow *window); ++ + #endif /* META_WORKSPACE_MANAGER_H */ +diff --git a/src/meta/types.h b/src/meta/types.h +index 49fb568..d479c19 100644 +--- a/src/meta/types.h ++++ b/src/meta/types.h +@@ -42,6 +42,7 @@ typedef struct _MetaCursorTracker MetaCursorTracker; + typedef struct _MetaDnd MetaDnd; + typedef struct _MetaSettings MetaSettings; + ++typedef struct _MetaWorkspaceContext MetaWorkspaceContext; + typedef struct _MetaWorkspaceManager MetaWorkspaceManager; + typedef struct _MetaSelection MetaSelection; + +diff --git a/src/meta/window.h b/src/meta/window.h +index 3157d44..a5901ee 100644 +--- a/src/meta/window.h ++++ b/src/meta/window.h +@@ -446,4 +446,10 @@ uint64_t meta_window_get_id (MetaWindow *window); + META_EXPORT + MetaWindowClientType meta_window_get_client_type (MetaWindow *window); + ++META_EXPORT ++const char *meta_window_namespace (MetaWindow *window); ++ ++META_EXPORT ++gboolean meta_window_is_on_foreign_workspace_context (MetaWindow *window); ++ + #endif +diff --git a/src/meta/workspace.h b/src/meta/workspace.h +index 99aebee..4b94cff 100644 +--- a/src/meta/workspace.h ++++ b/src/meta/workspace.h +@@ -39,6 +39,12 @@ GType meta_workspace_get_type (void); + META_EXPORT + int meta_workspace_index (MetaWorkspace *workspace); + ++META_EXPORT ++int meta_workspace_get_id (MetaWorkspace *workspace); ++ ++META_EXPORT ++guint meta_workspace_get_context_id (MetaWorkspace *workspace); ++ + META_EXPORT + MetaDisplay *meta_workspace_get_display (MetaWorkspace *workspace); + diff --git a/meta-gnome/recipes-gnome/mutter/mutter_40.0.bb b/meta-gnome/recipes-gnome/mutter/mutter_41.0.bb similarity index 95% rename from meta-gnome/recipes-gnome/mutter/mutter_40.0.bb rename to meta-gnome/recipes-gnome/mutter/mutter_41.0.bb index 74547ae..6730eee 100644 --- a/meta-gnome/recipes-gnome/mutter/mutter_40.0.bb +++ b/meta-gnome/recipes-gnome/mutter/mutter_41.0.bb @@ -49,7 +49,7 @@ SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV} file://0001-Citadel-changes-to-Mutter.patch \ " -SRC_URI[archive.sha256sum] = "7a71b312e5a667c5374895188a506a3f6b671768bcb362b68efdc562773d198e" +SRC_URI[archive.sha256sum] = "fa80a1a744044d88ebfd677ff03203d67705ed2cd624ea06cbb8b58948cdf89e" # x11 is still mandatory - see meson.build REQUIRED_DISTRO_FEATURES = "x11 systemd" @@ -70,7 +70,7 @@ EXTRA_OEMESON += " \ -Dgles2_libname=libGLESv2.so.2 \ " -MUTTER_API_NAME = "mutter-8" +MUTTER_API_NAME = "mutter-9" do_install_append() { # Add gir links in standard paths. That makes dependents life much easier diff --git a/meta-gnome/recipes-support/ell/ell_0.39.bb b/meta-gnome/recipes-support/ell/ell_0.44.bb similarity index 90% rename from meta-gnome/recipes-support/ell/ell_0.39.bb rename to meta-gnome/recipes-support/ell/ell_0.44.bb index 68ec4cb..35d177c 100644 --- a/meta-gnome/recipes-support/ell/ell_0.39.bb +++ b/meta-gnome/recipes-support/ell/ell_0.44.bb @@ -17,7 +17,7 @@ inherit autotools pkgconfig SRC_URI = "https://mirrors.edge.kernel.org/pub/linux/libs/${BPN}/${BPN}-${PV}.tar.xz \ file://0001-pem.c-do-not-use-rawmemchr.patch \ " -SRC_URI[sha256sum] = "653e2e139e23ed31e03c56c05f15321a9e818e2dca00a315c18d2c7b72f15d08" +SRC_URI[sha256sum] = "41a6f8fa4d285b52cb7a5a87bda3e7370ecaac02d94aaa7ec1a23f0480b8bc3f" do_configure_prepend () { mkdir -p ${S}/build-aux diff --git a/meta-gnome/recipes-support/libgudev/libgudev_237.bb b/meta-gnome/recipes-support/libgudev/libgudev_237.bb new file mode 100644 index 0000000..808e966 --- /dev/null +++ b/meta-gnome/recipes-support/libgudev/libgudev_237.bb @@ -0,0 +1,26 @@ +SUMMARY = "GObject wrapper for libudev" +DESCRIPTION = "This library makes it much simpler to use libudev from programs \ +already using GObject. It also makes it possible to easily use libudev from \ +other programming languages, such as Javascript, because of GObject \ +introspection support." +HOMEPAGE = "https://wiki.gnome.org/Projects/libgudev" +BUGTRACKER = "https://gitlab.gnome.org/GNOME/libgudev/issues" +SRC_URI[archive.sha256sum] = "0d06b21170d20c93e4f0534dbb9b0a8b4f1119ffb00b4031aaeb5b9148b686aa" + +DEPENDS = "glib-2.0 udev" + +RCONFLICTS_${PN} = "systemd (<= 220)" + +LICENSE = "LGPLv2.1" +LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c" + +GIR_MESON_ENABLE_FLAG = 'enabled' +GIR_MESON_DISABLE_FLAG = 'disabled' + +GTKDOC_MESON_OPTION = 'gtk_doc' + +GNOMEBASEBUILDCLASS = "meson" +inherit gnomebase gobject-introspection gtk-doc + +UPSTREAM_CHECK_URI = "http://ftp.gnome.org/pub/GNOME/sources/libgudev/" +UPSTREAM_CHECK_REGEX = "(?P(\d+))" diff --git a/meta-gnome/recipes-support/libxfixes/libxfixes_6.0.0.bb b/meta-gnome/recipes-support/libxfixes/libxfixes_6.0.0.bb new file mode 100644 index 0000000..af7426f --- /dev/null +++ b/meta-gnome/recipes-support/libxfixes/libxfixes_6.0.0.bb @@ -0,0 +1,20 @@ +SUMMARY = "XFixes: X Fixes extension library" + +DESCRIPTION = "X applications have often needed to work around various \ +shortcomings in the core X window system. This extension is designed to \ +provide the minimal server-side support necessary to eliminate problems \ +caused by these workarounds." + +require xorg-lib-common.inc +SRC_URI[sha256sum] = "a7c1a24da53e0b46cac5aea79094b4b2257321c621b258729bc3139149245b4c" + +LICENSE = "MIT-style" +LIC_FILES_CHKSUM = "file://COPYING;md5=3c1ce42c334a6f5cccb0277556a053e0" + +DEPENDS += "virtual/libx11 xorgproto" + +PE = "1" + +XORG_PN = "libXfixes" + +BBCLASSEXTEND = "native nativesdk" diff --git a/meta-gnome/recipes-support/libxfixes/xorg-lib-common.inc b/meta-gnome/recipes-support/libxfixes/xorg-lib-common.inc new file mode 100644 index 0000000..a566eaa --- /dev/null +++ b/meta-gnome/recipes-support/libxfixes/xorg-lib-common.inc @@ -0,0 +1,26 @@ +HOMEPAGE = "http://www.x.org" +BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=xorg" + +SECTION = "x11/libs" +LICENSE = "MIT-X" +DEPENDS = "util-macros" + +XORG_PN = "${BPN}" + +SRC_URI = "${XORG_MIRROR}/individual/lib/${XORG_PN}-${PV}.tar.bz2" + +S = "${WORKDIR}/${XORG_PN}-${PV}" + +inherit autotools features_check pkgconfig + +EXTRA_OECONF = "--disable-specs --without-groff --without-ps2pdf --without-fop" + +PACKAGECONFIG ??= "" +PACKAGECONFIG[xmlto] = "--with-xmlto, --without-xmlto, xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native" + +UNKNOWN_CONFIGURE_WHITELIST += "--enable-malloc0returnsnull --disable-malloc0returnsnull \ + --disable-specs --without-groff --without-ps2pdf --without-fop \ + --without-xmlto --with-xmlto \ +" + +REQUIRED_DISTRO_FEATURES ?= "x11" diff --git a/meta-gnome/recipes-support/libxfixes/xorgproto_2021.4.99.2.bb b/meta-gnome/recipes-support/libxfixes/xorgproto_2021.4.99.2.bb new file mode 100644 index 0000000..8db3e6d --- /dev/null +++ b/meta-gnome/recipes-support/libxfixes/xorgproto_2021.4.99.2.bb @@ -0,0 +1,25 @@ +SUMMARY = "X Window System unified protocol definitions" +DESCRIPTION = "This package provides the headers and specification documents defining \ +the core protocol and (many) extensions for the X Window System" +HOMEPAGE = "http://www.x.org" +BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=xorg" + +SECTION = "x11/libs" +LICENSE = "MIT-style" +LIC_FILES_CHKSUM = "file://COPYING-x11proto;md5=dfc4bd2b0568b31725b85b0604e69b56" + +SRC_URI = "${XORG_MIRROR}/individual/proto/${BP}.tar.bz2" +SRC_URI[sha256sum] = "c38878053179c6f8bc2daeeeeb4710b5fbf0e46db5b3134aee4a1977ffb06e7a" + +inherit meson + +PACKAGECONFIG ??= "" +PACKAGECONFIG[legacy] = "-Dlegacy=true,-Dlegacy=false" + +# Datadir only used to install pc files, $datadir/pkgconfig +datadir="${libdir}" +# ${PN} is empty so we need to tweak -dev and -dbg package dependencies +RDEPENDS_${PN}-dev = "" +RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})" + +BBCLASSEXTEND = "native nativesdk" diff --git a/meta-gnome/recipes-support/mozjs78/mozjs78_78.0.1.bb b/meta-gnome/recipes-support/mozjs78/mozjs78_78.11.0.bb similarity index 91% rename from meta-gnome/recipes-support/mozjs78/mozjs78_78.0.1.bb rename to meta-gnome/recipes-support/mozjs78/mozjs78_78.11.0.bb index 5d6079a..e5b661c 100644 --- a/meta-gnome/recipes-support/mozjs78/mozjs78_78.0.1.bb +++ b/meta-gnome/recipes-support/mozjs78/mozjs78_78.11.0.bb @@ -3,19 +3,18 @@ HOMEPAGE = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonk LICENSE = "MPL-2.0" LIC_FILES_CHKSUM = "file://LICENSE;md5=dc9b6ecd19a14a54a628edaaf23733bf" -# Path: /teams/releng/tarballs-needing-help/mozjs/mozjs-78.0.1gnome.tar.xz -SRC_URI = "https://download.gnome.org/teams/releng/tarballs-needing-help/mozjs/mozjs-78.0.1gnome.tar.xz;downloadfilename=mozjs78-78.0.1.tar.xz \ +# Path: /teams/releng/tarballs-needing-help/mozjs/mozjs-78.11.0.tar.xz +SRC_URI = "https://download.gnome.org/teams/releng/tarballs-needing-help/mozjs/mozjs-78.11.0.tar.bz2;downloadfilename=mozjs78-78.11.0.tar.bz2 \ file://avoid-running-autoconf2.13.patch \ file://0001-Force-the-correct-target-string-with-environment-var.patch \ file://0003-Set-rust-host-and-target-correctly.patch \ file://0004-Do-not-add-RequiredDefines.h-here-instead-add-to-gjs.patch \ file://0005-Remove-Abort-Panic-Strategy.patch \ - file://0001-Cannot-use-both-branch-and-rev.patch \ " -SRC_URI[md5sum] = "09bf510150144238dd31f7f4e1582cf8" -SRC_URI[sha256sum] = "78d762012be9eb460b5805da4f919d1a12b15f4040f126c98a42c4dddac7339e" -S = "${WORKDIR}/mozjs-78.0.1gnome" +#SRC_URI[md5sum] = "09bf510150144238dd31f7f4e1582cf8" +SRC_URI[sha256sum] = "5ad54ac2b0368b9748e08756658eb988d65e5bb088d91baf43267486bcbf1d26" +S = "${WORKDIR}/mozjs-78.11.0" inherit autotools pkgconfig perlnative python3native inherit rust diff --git a/meta-gnome/recipes-support/vte/vte_0.64.0.bb b/meta-gnome/recipes-support/vte/vte_0.64.2.bb similarity index 97% rename from meta-gnome/recipes-support/vte/vte_0.64.0.bb rename to meta-gnome/recipes-support/vte/vte_0.64.2.bb index a16dac7..8f55189 100644 --- a/meta-gnome/recipes-support/vte/vte_0.64.0.bb +++ b/meta-gnome/recipes-support/vte/vte_0.64.2.bb @@ -18,7 +18,7 @@ GIR_MESON_OPTION = 'gir' inherit gnomebase gtk-doc features_check upstream-version-is-even gobject-introspection -SRCREV = "2520d6b6785646ceb5f501f9c37a1a0307fa4486" +SRCREV = "a913a6de14047c1939b84617f2dd483d37e89194" SRC_URI = "git://gitlab.gnome.org/GNOME/vte.git;protocol=https;branch=vte-0-64" # vapigen.m4 is required when vala is not present (but the one from vala should be used normally) SRC_URI += "file://0001-Add-W_EXITCODE-macro-for-non-glibc-systems.patch" diff --git a/meta-gnome/recipes-support/wayland/libinput/determinism.patch b/meta-gnome/recipes-support/wayland/libinput/determinism.patch new file mode 100644 index 0000000..cb55403 --- /dev/null +++ b/meta-gnome/recipes-support/wayland/libinput/determinism.patch @@ -0,0 +1,21 @@ +This finds our outer git tree and that version information breaks +determinism of this recipe. Disable it. + +RP 2020/2/6 + +Upstream-Status: Pending +Signed-off-by: Richard Purdie + +Index: libinput-1.14.3/meson.build +=================================================================== +--- libinput-1.14.3.orig/meson.build ++++ libinput-1.14.3/meson.build +@@ -387,7 +387,7 @@ pkgconfig.generate( + libraries : lib_libinput + ) + +-git_version_h = vcs_tag(command : ['git', 'describe'], ++git_version_h = vcs_tag(command : ['false'], + fallback : 'unknown', + input : 'src/libinput-git-version.h.in', + output :'libinput-git-version.h') diff --git a/meta-gnome/recipes-support/wayland/libinput/run-ptest b/meta-gnome/recipes-support/wayland/libinput/run-ptest new file mode 100644 index 0000000..d11e6eb --- /dev/null +++ b/meta-gnome/recipes-support/wayland/libinput/run-ptest @@ -0,0 +1,9 @@ +#!/bin/sh + +/usr/libexec/libinput/libinput-test-suite -j1 +if [ $? -eq 0 ]; then + echo 'PASS: libinput-test-suite' +else + echo 'FAIL: libinput-test-suite' +fi + diff --git a/meta-gnome/recipes-support/wayland/libinput_1.19.1.bb b/meta-gnome/recipes-support/wayland/libinput_1.19.1.bb new file mode 100644 index 0000000..0993415 --- /dev/null +++ b/meta-gnome/recipes-support/wayland/libinput_1.19.1.bb @@ -0,0 +1,49 @@ +SUMMARY = "Library to handle input devices in Wayland compositors" +DESCRIPTION = "libinput is a library to handle input devices in Wayland \ +compositors and to provide a generic X.Org input driver. It provides \ +device detection, device handling, input device event processing and \ +abstraction so minimize the amount of custom input code compositors need to \ +provide the common set of functionality that users expect." +HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libinput/" +SECTION = "libs" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=bab4ac7dc1c10bc0fb037dc76c46ef8a" + +DEPENDS = "libevdev udev mtdev libcheck" + +SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BP}.tar.xz \ + file://run-ptest \ + file://determinism.patch \ + " +SRC_URI[sha256sum] = "0bdcf5b1783b737854b7af1ca22df67bc36a6fe7c9cfa71f01e9149f9220446d" + +UPSTREAM_CHECK_REGEX = "libinput-(?P\d+\.\d+\.(?!9\d+)\d+)" + +inherit meson pkgconfig lib_package ptest + +# Patch out build directory, otherwise it leaks into ptest binary +do_configure_append() { + sed -i -e "s,${WORKDIR},,g" config.h + if [ -e "litest-config.h" ]; then + sed -i -e "s,${WORKDIR},,g" litest-config.h + fi +} + +PACKAGECONFIG ??= "" +PACKAGECONFIG[libwacom] = "-Dlibwacom=true,-Dlibwacom=false,libwacom" +PACKAGECONFIG[gui] = "-Ddebug-gui=true,-Ddebug-gui=false,cairo gtk+3" + +UDEVDIR = "`pkg-config --variable=udevdir udev`" + +EXTRA_OEMESON += "-Dudev-dir=${UDEVDIR} \ + -Ddocumentation=false \ + ${@bb.utils.contains('PTEST_ENABLED', '1', '-Dtests=true -Dinstall-tests=true', '-Dtests=false -Dinstall-tests=false', d)} \ + -Dzshcompletiondir=no" + +# package name changed in 1.8.1 upgrade: make sure package upgrades work +RPROVIDES_${PN} = "libinput" +RREPLACES_${PN} = "libinput" +RCONFLICTS_${PN} = "libinput" + +FILES_${PN}-ptest += "${libexecdir}/libinput/libinput-test-suite" diff --git a/meta-gnome/recipes-support/wayland/wayland-protocols_1.21.bb b/meta-gnome/recipes-support/wayland/wayland-protocols_1.21.bb new file mode 100644 index 0000000..16452f8 --- /dev/null +++ b/meta-gnome/recipes-support/wayland/wayland-protocols_1.21.bb @@ -0,0 +1,21 @@ +SUMMARY = "Collection of additional Wayland protocols" +DESCRIPTION = "Wayland protocols that add functionality not \ +available in the Wayland core protocol. Such protocols either add \ +completely new functionality, or extend the functionality of some other \ +protocol either in Wayland core, or some other protocol in \ +wayland-protocols." +HOMEPAGE = "http://wayland.freedesktop.org" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=c7b12b6702da38ca028ace54aae3d484 \ + file://stable/presentation-time/presentation-time.xml;endline=26;md5=4646cd7d9edc9fa55db941f2d3a7dc53" + +SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \ + " +SRC_URI[sha256sum] = "b99945842d8be18817c26ee77dafa157883af89268e15f4a5a1a1ff3ffa4cde5" + +UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html" + +inherit allarch autotools pkgconfig + +PACKAGES = "${PN}" +FILES_${PN} += "${datadir}/pkgconfig/wayland-protocols.pc" diff --git a/poky b/poky index e1839b5..0a2ca9d 160000 --- a/poky +++ b/poky @@ -1 +1 @@ -Subproject commit e1839b58ebe05242a52fe050aa9a08140136aa0a +Subproject commit 0a2ca9d60f3851515a79d5aa9ddd8b4069b5a206