Initial commit of 12to11.spec file

This commit is contained in:
Anders da Silva Rytter Hansen 2026-09-03 17:08:00 +02:00
commit fd1282bad0

100
12to11.spec Normal file
View file

@ -0,0 +1,100 @@
# SPDX-License-Identifier: GPLv3+
#
# 12to11 - Wayland to X11 protocol translator
# Active fork by fish4terrisa-MSDSM (original SourceForge project is unmaintained).
#
# On Fedora: libXpresent-devel is in the main repositories.
# On EL9/EL10: libXpresent-devel is NOT in the main repos. Enable the
# xlibre COPR first:
# dnf copr enable @xlibre/xlibre-xserver
# or build/install libXpresent from source (https://gitlab.freedesktop.org/xorg/lib/libxpresent).
#
# The build uses the legacy imake/xmkmf build system (provided by the
# 'imake' package, available in EPEL on EL9/EL10).
%global commit b6745cc4236415983ff9f19a03f5c83a9def7429
%global shortcommit %(c=%{commit}; echo ${c:0:7})
%global snapdate 20260824
Name: 12to11
Version: 0
Release: 0.1.%{snapdate}git%{shortcommit}%{?dist}
Summary: Wayland to X11 protocol translator
License: GPL-3.0-only
URL: https://github.com/fish4terrisa-MSDSM/12to11
Source0: %{url}/archive/%{commit}/12to11-%{commit}.tar.gz
# Build dependencies
# imake is in EPEL on EL9/EL10.
BuildRequires: make
BuildRequires: gcc
BuildRequires: imake
BuildRequires: gawk
BuildRequires: wayland-devel
BuildRequires: libX11-devel
BuildRequires: libXext-devel
BuildRequires: libxcb-devel
BuildRequires: pixman-devel
BuildRequires: libdrm-devel
BuildRequires: libXcursor-devel
BuildRequires: libxshmfence-devel
BuildRequires: libxkbfile-devel
# libXpresent-devel: in Fedora main; in the xlibre COPR on EL9/EL10.
BuildRequires: libXpresent-devel
# EGL + GLESv2 development files (libglvnd-devel provides the headers
# and .so symlinks; mesa-libEGL-devel provides Mesa-specific EGL headers).
BuildRequires: mesa-libEGL-devel
BuildRequires: libglvnd-devel
Requires: libglvnd-egl%{?_isa}
Requires: libglvnd-gles%{?_isa}
%description
12to11 is a Wayland compositor that runs as a regular X11 client,
displaying Wayland applications as normal X windows. It implements a
broad set of Wayland protocols including wl_data_device_manager (clipboard),
zwp_linux_dmabuf_v1, xdg_wm_base, zwp_text_input_manager_v3, and more.
When built with EGL support (the default in this package), it uses
OpenGL ES 2.0 for rendering, enabling YUV video format support and
hardware-accelerated compositing.
This is particularly useful for running Wayland-only applications
(such as Waydroid) under X11 without a nested compositor like Weston.
Clipboard sharing between Wayland clients and the X11 session is
handled natively, without requiring external bridge scripts.
This package tracks the actively maintained fork by
fish4terrisa-MSDSM; the original SourceForge project has been
unmaintained since 2022.
%prep
%autosetup -n 12to11-%{commit}
%build
# Generate Makefile from Imakefile using the legacy imake system.
xmkmf -a
# Build with EGL support (already enabled by default in 12to11.conf).
# The Makefile picks up HaveEglSupport from 12to11.conf.
%{make_build}
%install
%{make_install} DESTDIR=%{buildroot}
# Install the manual page manually (imake's install.man target can be
# unreliable across distros due to CppManTarget/nroff dependencies).
install -D -p -m 0644 12to11.man %{buildroot}%{_mandir}/man1/12to11.1
%files
%license COPYING
%doc README
%{_bindir}/12to11
%{_mandir}/man1/12to11.1*
%changelog
* Thu Sep 03 2026 Anders da Silva Rytter Hansen <andersrh@users.noreply.github.com> - 0-0.1.20260824gitb6745cc
- Initial RPM package for 12to11 (fish4terrisa-MSDSM fork).
- Built with EGL/GLESv2 rendering support.
- Snapshot from commit b6745cc (2026-08-24).