Sync from SUSE:SLFO:Main perl-X11-Protocol revision 3922432df6d3c803f72635a336c39c7e

This commit is contained in:
Adrian Schröter 2024-05-03 19:06:59 +02:00
commit 1375e0379f
5 changed files with 145 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

BIN
X11-Protocol-0.56.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

25
perl-X11-Protocol.changes Normal file
View File

@ -0,0 +1,25 @@
-------------------------------------------------------------------
Mon Nov 11 12:47:27 UTC 2019 - Arjen de Korte <suse+build@de-korte.org>
- Change architecture to 'noarch'
-------------------------------------------------------------------
Mon May 21 10:18:44 UTC 2012 - vargusz@fazekas.hu
- Fix issue with XAUTHLOCALHOSTNAME='localhost' (bnc#746894)
-------------------------------------------------------------------
Fri Jun 10 07:33:44 UTC 2011 - saigkill@opensuse.org
- prepared for factory
-------------------------------------------------------------------
Fri Apr 15 05:26:54 UTC 2011 - coolo@opensuse.org
- recreate with cpanspec
-------------------------------------------------------------------
Thu Apr 14 19:21:59 UTC 2011 - saigkill@opensuse.org
- made fit for d:l:p

73
perl-X11-Protocol.spec Normal file
View File

@ -0,0 +1,73 @@
#
# spec file for package perl-X11-Protocol
#
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: perl-X11-Protocol
Version: 0.56
Release: 0
# MANUAL
%define cpan_name X11-Protocol
Summary: Perl module for the X Window System Protocol, version 11
License: GPL-1.0-or-later OR Artistic-1.0
Group: Development/Libraries/Perl
Url: http://search.cpan.org/dist/X11-Protocol/
Source: http://www.cpan.org/authors/id/S/SM/SMCCAM/%{cpan_name}-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: perl(ExtUtils::MakeMaker)
BuildArch: noarch
%{perl_requires}
Patch0: xauthlocalhostname-localhost.diff
%description
X11::Protocol is a client-side interface to the X11 Protocol (see X(1) for
information about X11), allowing perl programs to display windows and
graphics on X11 servers.
A full description of the protocol is beyond the scope of this
documentation; for complete information, see the _X Window System Protocol,
X Version 11_, available as Postscript or *roff source from
'ftp://ftp.x.org', or _Volume 0: X Protocol Reference Manual_ of O'Reilly &
Associates's series of books about X (ISBN 1-56592-083-X,
'http://www.oreilly.com'), which contains most of the same information.
%prep
%setup -q -n %{cpan_name}-%{version}
%patch0 -p1
%build
%{__perl} Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
%{__make} %{?_smp_mflags}
%check
# MANUAL
# too complex %{__make} test
%install
%perl_make_install
%perl_process_packlist
%perl_gen_filelist
%clean
%{__rm} -rf %{buildroot}
%files -f %{name}.files
%defattr(-,root,root,755)
%doc Changes README Todo
%changelog

View File

@ -0,0 +1,21 @@
diff -Nru X11-Protocol-0.56/Auth.pm X11-Protocol-patched/Auth.pm
--- X11-Protocol-0.56/Auth.pm 2012-02-14 12:16:07.230868807 +0100
+++ X11-Protocol-patched/Auth.pm 2012-02-14 12:15:46.169630003 +0100
@@ -102,7 +102,7 @@
my($host, $fam, $dpy) = @_;
if ($host eq "localhost" or $host eq "127.0.0.1") {
require Sys::Hostname;
- $host = Sys::Hostname::hostname();
+ $host = $main::ENV{"XAUTHLOCALHOSTNAME"} || Sys::Hostname::hostname();
}
my($addr);
$addr = gethostbyname($host) if $fam eq "Internet";
@@ -113,7 +113,7 @@
next unless $fam eq $d->[0] or ($fam eq "Internet"
and $d->[0] eq "Local");
if ($fam eq "Internet" or $fam eq "Local") {
- if ($addr && $d->[1] eq $addr or $d->[1] eq $host) {
+ if ($addr && $d->[1] eq $addr or $d->[1] eq $host or $d->[1] eq "localhost" or $d->[1] eq "127.0.0.1") {
return ($d->[3], $d->[4]);
}
}