1

В связи с тем, что под Mageia перестал поддерживаться wine-staging начиная со сборки 2.4 (где-то), нужна помощь в его сборке.

Вот здесь нашёл файлы отвечающие за компиляцию:
https://github.com/wine-compholio/wine- … ageia/wine

файл boot.sh

{{ __filename = __filename if package_boot else None }}
#!/bin/bash
set -e -x

urpmi --auto-update

{{
    # FIXME: Fix support for daily builds - snapshot urls are no longer available
    url = "https://dl.winehq.org/wine/source/2.x"
    download("wine.tar.xz", "%s/wine-%s.tar.xz" % (url, package_version), wine_sha)
}}

{{ if staging }}
{{
    url = "https://github.com/wine-compholio/wine-staging/archive"
    version = "master" if package_daily else "v%s" % package_version
    download("wine-staging.tar.gz", "%s/%s.tar.gz" % (url, version), staging_sha)
}}
{{ endif }}

# Generate directories for build
mkdir /home/build/wine
cd /home/build/wine
mkdir BUILD BUILDROOT RPMS SPECS SRPMS tmp

if [ "$(uname -m)" == "x86_64" ]; then
    sed -i "s/^%_lib .*$/%_lib lib64/g" /build/source/rpmmacros
fi

# Create symlinks
ln -s /build/source/rpmmacros /home/build/.rpmmacros
ln -s /build RPMS/i586
ln -s /build RPMS/x86_64
ln -s /build RPMS/noarch
ln -s /build/source SOURCES
for _f in /build/source/*.spec; do
    ln -s "$_f" "SPECS/$(basename "$_f")"
done

# Fixup permissions
chown -R build:build /home/build/wine

# Run builds
cd SPECS
for _f in *.spec; do
    urpmi --buildrequires --auto "$_f"
    su build -c "export BUILDER_TOPDIR=/home/build/wine; rpmbuild -vv -bb \"$_f\""
done

# Check for missing build requirements
cd /build
for _f in *.rpm; do
    if rpm -qpR "$_f" | grep "wine-missing-buildrequires-"; then
        echo "Missing build requirements, package would be broken!" >&2
        exit 1
    fi
done
Contact GitHub API Training Shop Blog About
© 2017 GitHub, Inc. Terms Privacy Security Status Help

файл rpmmacros

%_topdir                %(echo $BUILDER_TOPDIR)
%_tmppath               %(echo $BUILDER_TOPDIR)/tmp
%packager               "Sebastian Lackner <sebastian@fds-team.de>"
%make                   make -j3

%_prefix                /usr
%_exec_prefix           %{_prefix}
%_bindir                %{_exec_prefix}/bin
%_sbindir               %{_exec_prefix}/sbin
%_libexecdir            %{_exec_prefix}/libexec
%_datadir               %{_prefix}/share
%_sysconfdir            /etc
%_sharedstatedir        %{_prefix}/com
%_localstatedir         %{_prefix}/var
%_lib                   lib
%_libdir                %{_exec_prefix}/%{_lib}
%_includedir            %{_prefix}/include
%_infodir               %{_datadir}/info
%_mandir                %{_datadir}/man

файл wine.spec

{{ __filename = "%s.spec" % package }}
# Maintainer: Sebastian Lackner, sebastian [at] fds-team [dot] de

{{
    rel = int(package_release) if package_release != "" else 0
    if "-rc" in package_version
        version, release = package_version.split("-rc", 1)
        release = "0.rc%s.%d" % (release, rel + 1)
    else
        version = package_version
        release = "%d" % (rel + 1)
    endif
}}

%define rel             {{ =release }}
%define lib_major       1
%define lib_name        %mklibname %{name} %{lib_major}
%define lib_name_devel  %{mklibname -d %{name}}
%define _fortify_cflags %nil

Name:       {{ =package }}
Version:    {{ =version }}
Release:    %mkrel %rel
Epoch:      1
Summary:    WINE Is Not An Emulator - runs MS Windows programs
License:    LGPLv2+
Group:      Emulators
{{ if staging }}
URL:        http://www.wine-staging.com/
Source0:    wine.tar.xz
Source1:    wine-staging.tar.gz
{{ else }}
URL:        https://www.winehq.org/
Source0:    wine.tar.xz
{{ endif }}

%ifarch x86_64
%define wine    %{name}64
%define mark64  ()(64bit)
%else
%define wine    %{name}
%define mark64  %{nil}
%endif

%define _prefix {{ =prefix }}
Prefix:         {{ =prefix }}

BuildRequires:  attr-devel
BuildRequires:  autoconf
BuildRequires:  bison
BuildRequires:  chrpath
BuildRequires:  coreutils
BuildRequires:  cups-devel
BuildRequires:  dbus-devel
BuildRequires:  desktop-file-utils
BuildRequires:  docbook-dtd-sgml
BuildRequires:  docbook-utils
BuildRequires:  flex
BuildRequires:  fontconfig-devel
BuildRequires:  fontforge
BuildRequires:  freetype2-devel
BuildRequires:  gawk
BuildRequires:  gettext-devel
BuildRequires:  glibc-static-devel
BuildRequires:  gnutls-devel
BuildRequires:  gphoto2-devel
BuildRequires:  gpm-devel
BuildRequires:  gsm-devel
BuildRequires:  icoutils
BuildRequires:  imagemagick
BuildRequires:  isdn4k-utils-devel
BuildRequires:  lcms2-devel
BuildRequires:  libalsa-devel
%ifarch x86_64
BuildRequires:  lib64gstreamer1.0-devel
BuildRequires:  lib64gstreamer-plugins-base1.0-devel
%else
BuildRequires:  libgstreamer1.0-devel
BuildRequires:  libgstreamer-plugins-base1.0-devel
%endif
BuildRequires:  libmpg123-devel
BuildRequires:  libpcap-devel
BuildRequires:  librsvg
BuildRequires:  libsm-devel
BuildRequires:  libudev-devel
BuildRequires:  libv4l-devel
BuildRequires:  libx11-devel
BuildRequires:  libxcomposite-devel
BuildRequires:  libxcursor-devel
BuildRequires:  libxext-devel
BuildRequires:  libxi-devel
BuildRequires:  libxinerama-devel
BuildRequires:  libxrandr-devel
BuildRequires:  libxrender-devel
BuildRequires:  libxslt-devel
BuildRequires:  mesaglu-devel
BuildRequires:  ncurses-devel
BuildRequires:  openal-devel
BuildRequires:  opencl-devel
BuildRequires:  openldap-devel
BuildRequires:  osmesa-devel
BuildRequires:  perl-devel
BuildRequires:  png-devel
BuildRequires:  prelink
BuildRequires:  pulseaudio-devel
BuildRequires:  sane-devel
BuildRequires:  sgml-tools
BuildRequires:  tiff-devel
BuildRequires:  ungif-devel
BuildRequires:  unixODBC-devel
BuildRequires:  unzip
BuildRequires:  util-linux
BuildRequires:  valgrind-devel
BuildRequires:  xpm-devel

%ifarch x86_64
%package -n %{wine}
%endif
Summary:    WINE Is Not An Emulator - runs MS Windows programs
Group:      Emulators
%ifarch x86_64
Conflicts:  %{name}
%else
Conflicts:  %{name}64
%endif
Requires:   %{name}-common = %{epoch}:%{version}-%{release}
Provides:   %{lib_name} = %{epoch}:%{version}-%{release}
Obsoletes:  %{lib_name} <= %{epoch}:%{version}-%{release}
Provides:   %{name}-bin = %{epoch}:%{version}-%{release}

%ifarch %{ix86}
%package -n %{name}-common
Summary:    WINE Is Not An Emulator - runs MS Windows programs (32-bit common files)
Group:      Emulators
Requires:   %{name}-bin = %{epoch}:%{version}-%{release}
%endif

%define dlopenreq() %(F=/usr/%{_lib}/lib%{1}.so;[ -e $F ] && (file $F|grep -q ASCII && grep -o 'lib[^ ]*' $F|sed -e "s/\$/%{mark64}/"||objdump -p $F | grep SONAME | awk '{ print $2 "%{mark64}" }') || echo "wine-missing-buildrequires-on-%{1}")
Requires:   %dlopenreq asound
Requires:   %dlopenreq attr
Requires:   %dlopenreq crypto
Requires:   %dlopenreq cups
Requires:   %dlopenreq dbus-1
Requires:   %dlopenreq fontconfig
Requires:   %dlopenreq freetype
Requires:   %dlopenreq gnutls
Requires:   %dlopenreq gsm
Requires:   %dlopenreq jpeg
Requires:   %dlopenreq ncurses
Requires:   %dlopenreq odbc
Requires:   %dlopenreq OSMesa
Requires:   %dlopenreq png
Requires:   %dlopenreq sane
Requires:   %dlopenreq ssl
Requires:   %dlopenreq tiff
Requires:   %dlopenreq v4l1
{{ if staging }}
Requires:   %dlopenreq X11-xcb
{{ endif }}
Requires:   %dlopenreq Xcomposite
Requires:   %dlopenreq Xcursor
Requires:   %dlopenreq Xi
Requires:   %dlopenreq Xinerama
Requires:   %dlopenreq Xrandr
Requires:   %dlopenreq Xrender
Requires:   %dlopenreq xslt
Requires:   %dlopenreq Xxf86vm
Suggests:   sane-frontends
Requires(post): desktop-file-utils
Requires(postun): desktop-file-utils
Requires(post): desktop-common-data
Requires(postun): desktop-common-data
Requires(preun): rpm-helper
Requires(post): rpm-helper

%define desc Wine is a program which allows running Microsoft Windows programs \
(including DOS, Windows 3.x and Win32 executables) on Unix. It \
consists of a program loader which loads and executes a Microsoft \
Windows binary, and a library (called Winelib) that implements Windows \
API calls using their Unix or X11 equivalents.  The library may also \
be used for porting Win32 code into native Unix executables.

%description
%desc

%ifarch x86_64
%description -n %{wine}
%desc
%else
%description -n %{name}-common
Wine is a program which allows running Microsoft Windows programs
(including DOS, Windows 3.x and Win32 executables) on Unix.

This package contains the files needed to support 32-bit Windows
programs, and is used by both %{name} and %{name}64.
%endif

%package -n %{wine}-devel
Summary:    Static libraries and headers for %{name} (64-bit)
Group:      Development/C
Requires:   %{wine} = %{epoch}:%{version}-%{release}
%ifarch x86_64
Conflicts:  %{name}-devel
%else
Conflicts:  %{name}64-devel
%endif
Provides:   %{lib_name_devel} = %{epoch}:%{version}-%{release}
Obsoletes:  %{lib_name_devel} <= %{epoch}:%{version}-%{release}
%description -n %{wine}-devel
Wine is a program which allows running Microsoft Windows programs
(including DOS, Windows 3.x and Win32 executables) on Unix.

This package contains the libraries and header files needed to
develop programs which make use of wine.

%package -n {{ =compat_package }}
Summary:    WINE Is Not An Emulator - runs MS Windows programs
Group:      Emulators
Requires:   %{wine} = %{epoch}:%{version}-%{release}
Conflicts:  wine wine64
Provides:   wine-bin

%description -n {{ =compat_package }}
Wine is a program which allows running Microsoft Windows programs
(including DOS, Windows 3.x and Win32 executables) on Unix.

This compatibility package allows to use %{wine} system-wide as
the default wine version.

%prep
%setup -q -T -c -n wine-%{version}
tar -xvf "%{SOURCE0}" --strip-components 1
{{ if staging }}
tar -xvf "%{SOURCE1}" --strip-components 1
make -C "patches" DESTDIR="%{_builddir}/wine-%{version}" install
{{ endif }}

%build
%configure2_5x \
    --with-x \
{{ if stable }}
    --without-gstreamer \
{{ else }}
    --with-gstreamer \
{{ endif }}
{{ if staging }}
    --with-xattr \
    --with-xcb \
    --without-gtk3 \
{{ endif }}
%ifarch x86_64
    --enable-win64 \
%endif
    --disable-tests
%make

%install
%makeinstall_std LDCONFIG=/bin/true

# Compat symlinks for bindir
mkdir -p "%{buildroot}/usr/bin"
for _file in $(ls "%{buildroot}/%{_bindir}"); do \
    ln -s "%{_bindir}/$_file" "%{buildroot}/usr/bin/$_file"; \
done
%ifarch x86_64
for _file in wine wine-preloader; do \
    ln -s "%{_prefix}/bin/$_file" "%{buildroot}/usr/bin/$_file"; \
done
%endif

# Compat symlinks for desktop file
mkdir -p "%{buildroot}/usr/share/applications"
for _file in $(ls "%{buildroot}/%{_datadir}/applications"); do \
    ln -s "%{_datadir}/applications/$_file" "%{buildroot}/usr/share/applications/$_file"; \
done

# Compat manpages
for _dir in man1 de.UTF-8/man1 fr.UTF-8/man1 pl.UTF-8/man1; do \
    if [ -d "%{buildroot}/%{_mandir}/$_dir" ]; then \
        mkdir -p "$(dirname "%{buildroot}/usr/share/man/$_dir")"; \
        cp -pr "%{buildroot}/%{_mandir}/$_dir" "%{buildroot}/usr/share/man/$_dir"; \
    else \
        mkdir -p "%{buildroot}/usr/share/man/$_dir"; \
    fi; \
done
%ifarch x86_64
install -p -m 0644 loader/wine.man          "%{buildroot}/usr/share/man/man1/wine.1"
install -p -m 0644 loader/wine.de.UTF-8.man "%{buildroot}/usr/share/man/de.UTF-8/man1/wine.1"
install -p -m 0644 loader/wine.fr.UTF-8.man "%{buildroot}/usr/share/man/fr.UTF-8/man1/wine.1"
install -p -m 0644 loader/wine.pl.UTF-8.man "%{buildroot}/usr/share/man/pl.UTF-8/man1/wine.1"
%endif

%files -n %{wine}
%doc ANNOUNCE AUTHORS README
%ifarch x86_64
%{_bindir}/wine64
%{_bindir}/wine64-preloader
%endif
%{_bindir}/function_grep.pl
{{ ="%{_bindir}/msidb\n"                if staging else "" }}
%{_bindir}/msiexec
%{_bindir}/notepad
%{_bindir}/regedit
%{_bindir}/regsvr32
%{_bindir}/widl
%{_bindir}/wineboot
%{_bindir}/winebuild
%{_bindir}/winecfg
%{_bindir}/wineconsole*
%{_bindir}/winecpp
%{_bindir}/winedbg
%{_bindir}/winedump
%{_bindir}/winefile
%{_bindir}/wineg++
%{_bindir}/winegcc
%{_bindir}/winemaker
%{_bindir}/winemine
%{_bindir}/winepath
%{_bindir}/wineserver
%{_bindir}/wmc
%{_bindir}/wrc
%lang(de) %{_mandir}/de.UTF-8/man?/winemaker.?*
%lang(de) %{_mandir}/de.UTF-8/man?/wineserver.?*
%lang(fr) %{_mandir}/fr.UTF-8/man?/winemaker.?*
%lang(fr) %{_mandir}/fr.UTF-8/man?/wineserver.?*
%{_mandir}/man?/widl.1*
%{_mandir}/man?/winebuild.1*
%{_mandir}/man?/winecpp.1*
%{_mandir}/man?/winedbg.1*
%{_mandir}/man?/winedump.1*
%{_mandir}/man?/wineg++.1*
%{_mandir}/man?/winegcc.1*
%{_mandir}/man?/winemaker.1*
%{_mandir}/man?/wmc.1*
%{_mandir}/man?/wrc.1*
%{_mandir}/man?/msiexec.?*
%{_mandir}/man?/notepad.?*
%{_mandir}/man?/regedit.?*
%{_mandir}/man?/regsvr32.?*
%{_mandir}/man?/wineboot.?*
%{_mandir}/man?/winecfg.?*
%{_mandir}/man?/wineconsole.?*
%{_mandir}/man?/winefile.?*
%{_mandir}/man?/winemine.?*
%{_mandir}/man?/winepath.?*
%{_mandir}/man?/wineserver.?*
%dir %{_datadir}/wine
%{_datadir}/wine/wine.inf
%{_datadir}/wine/l_intl.nls
%{_datadir}/applications/*.desktop
%dir %{_datadir}/wine/fonts
%{_datadir}/wine/fonts/*

%ifarch %{ix86}
%files -n %{name}-common
%{_bindir}/wine
%{_bindir}/wine-preloader
%{_mandir}/man?/wine.?*
%lang(de) %{_mandir}/de.UTF-8/man?/wine.?*
%lang(fr) %{_mandir}/fr.UTF-8/man?/wine.?*
%lang(pl) %{_mandir}/pl.UTF-8/man?/wine.?*
%endif

%{_libdir}/libwine*.so.%{lib_major}*
%dir %{_libdir}/wine
%ifarch %{ix86}
%{_libdir}/wine/*.vxd.so
%{_libdir}/wine/*16.so
%endif
%{_libdir}/wine/*.a
%{_libdir}/wine/*.acm.so
%{_libdir}/wine/*.cpl.so
%{_libdir}/wine/*.def
%{_libdir}/wine/*.dll.so
%{_libdir}/wine/*.drv.so
%{_libdir}/wine/*.ds.so
%{_libdir}/wine/*.exe.so
%{_libdir}/wine/*.ocx.so
%{_libdir}/wine/*.sys.so
%{_libdir}/wine/*.tlb.so
%{_libdir}/wine/fakedlls
%{_libdir}/libwine*.so

%files -n %{wine}-devel
%{_includedir}/*

%files -n {{ =compat_package }}
/usr/bin/*
/usr/share/applications/*.desktop
/usr/share/man/man?/*
%lang(de) /usr/share/man/de.UTF-8/man?/*
%lang(fr) /usr/share/man/fr.UTF-8/man?/*
%lang(pl) /usr/share/man/pl.UTF-8/man?/*

согласно boot файлу нужно создать каталог /home/build/ и закинуть туда все три файла, плюс архив wine и к нему патчи staging.

Собственно дальше застопорился.
сама команда sh boot.sh сразу же вываливается с ошибкой

Консоль
line 1: {{: команда не найдена

2

Что-то совсем грустно здесь.
Неужели никто в spec файлах не разбирается?

3

Берс⇓ пишет:

Что-то совсем грустно здесь.

После ухода xblx совсем тихо стало, админ даже сертификат сайта не продляет

4

Нда, загнёмся мы потихонечку.

Собрал пакеты wine-2.10 под 32-х и 64-х битную систему, пропатченные wine-staging патчами. Если кому надо, пишите почту. Или могу в репозиторий кинуть, если доступ дадут.

5

Берс пишет:

В связи с тем, что под Mageia перестал поддерживаться wine-staging начиная со сборки 2.4 (где-то), нужна помощь в его сборке.

А смысл? Раньше, когда магея только появилась, ребята из вайна собирали бинарные пакеты под кучу дистров но НЕ под магею.
Тогда собирать пакеты wine для магеи было актуально. А сейчас, когда бинарники под магею можно установить непосредственно с сайта wine,
выполнив последовательно три команды в консоли - надобность в сборке отпала.

Mageia6, KDE, LXQt, x86_64.
Человек человеку - волк, а зомби зомби - зомби!