2019-09-30 10:33:11 -04:00
|
|
|
%define api_ver 0.6.7
|
|
|
|
|
|
|
|
|
|
%{!?tcl_version: %global tcl_version %(echo 'puts $tcl_version' | tclsh)}
|
|
|
|
|
%{!?tcl_sitearch: %global tcl_sitearch %{_prefix}/%{_lib}/tcl%{tcl_version}}
|
|
|
|
|
|
2019-11-06 19:03:39 +08:00
|
|
|
%bcond_with espeak
|
|
|
|
|
%bcond_with speech
|
2019-09-30 10:33:11 -04:00
|
|
|
|
|
|
|
|
Name: brltty
|
|
|
|
|
Version: 5.6
|
2019-12-30 11:18:02 +08:00
|
|
|
Release: 32
|
2019-09-30 10:33:11 -04:00
|
|
|
Summary: Braille display driver for Linux/Unix
|
|
|
|
|
License: LGPLv2+
|
|
|
|
|
URL: http://brltty.app/
|
|
|
|
|
Source0: http://brltty.app/archive/%{name}-%{version}.tar.xz
|
|
|
|
|
|
|
|
|
|
Source1: brltty.service
|
|
|
|
|
|
|
|
|
|
#patch0~2 from fedora
|
|
|
|
|
Patch0: brltty-loadLibrary.patch
|
2019-11-06 19:03:39 +08:00
|
|
|
|
|
|
|
|
%if %{with speech}
|
2019-09-30 10:33:11 -04:00
|
|
|
Patch1: brltty-5.0-libspeechd.patch
|
2019-11-06 19:03:39 +08:00
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with espeak}
|
2019-09-30 10:33:11 -04:00
|
|
|
Patch2: 0001-Add-support-for-eSpeak-NG.patch
|
2019-11-06 19:03:39 +08:00
|
|
|
%endif
|
|
|
|
|
|
2019-09-30 10:33:11 -04:00
|
|
|
#patch3~4 from upstream
|
|
|
|
|
Patch3: brltty-5.6-libs-add-ldflags.patch
|
|
|
|
|
Patch4: brltty-5.6-libs-add-ldflags2.patch
|
|
|
|
|
|
|
|
|
|
|
2019-11-06 19:03:39 +08:00
|
|
|
BuildRequires: byacc glibc-kernheaders bluez-libs-devel systemd gettext
|
|
|
|
|
BuildRequires: python3-devel autoconf at-spi2-core-devel alsa-lib-devel
|
|
|
|
|
|
|
|
|
|
%if %{with espeak}
|
|
|
|
|
BuildRequires: espeak-ng-devel
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with speech}
|
|
|
|
|
BuildRequires: speech-dispatcher-devel
|
|
|
|
|
%endif
|
2019-09-30 10:33:11 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
Requires(pre): glibc-common, shadow-utils
|
|
|
|
|
Requires(post): coreutils systemd coreutils, util-linux
|
|
|
|
|
Requires(preun): systemd
|
|
|
|
|
Requires(postun): systemd
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Provides: brlapi
|
|
|
|
|
Obsoletes: brlapi
|
|
|
|
|
|
2019-11-06 19:03:39 +08:00
|
|
|
%if %{without espeak}
|
2019-09-30 10:33:11 -04:00
|
|
|
Obsoletes: brltty-espeak <= 5.6-5
|
2019-11-06 19:03:39 +08:00
|
|
|
%endif
|
2019-09-30 10:33:11 -04:00
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
BRLTTY is a background process (daemon) which provides
|
|
|
|
|
access to the Linux/Unix console (when in text mode)
|
|
|
|
|
for a blind person using a refreshable braille display.
|
|
|
|
|
It drives the braille display and provides complete
|
|
|
|
|
screen review functionality.
|
|
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
|
Summary: Headers, static archive, and documentation for Brltty
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
Provides: brlapi-devel = %{api_ver}-%{release}
|
2019-12-30 11:18:02 +08:00
|
|
|
Obsoletes: brlapi-devel < %{api_ver}-%{release}
|
2019-09-30 10:33:11 -04:00
|
|
|
|
|
|
|
|
%description devel
|
|
|
|
|
This package provides the header files, static archive, shared object
|
|
|
|
|
linker reference, and reference documentation for Brltty (the
|
|
|
|
|
Application Programming Interface to BRLTTY).
|
|
|
|
|
|
|
|
|
|
%package docs
|
|
|
|
|
Summary: Documentation for BRLTTY
|
|
|
|
|
|
|
|
|
|
%description docs
|
|
|
|
|
This package provides the documentation for BRLTTY.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package -n tcl-%{name}
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
BuildRequires: tcl-devel
|
|
|
|
|
Summary: Tcl bpi for brltty
|
|
|
|
|
%description -n tcl-brltty
|
|
|
|
|
This package provides the Tcl api for Brltty.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package -n python3-%{name}
|
|
|
|
|
%{?python_provide:%python_provide python3-%{name}}
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
BuildRequires: python3-Cython python3-devel
|
2019-12-03 20:01:17 +08:00
|
|
|
Provides: python3-brlapi = %{version}-%{release}
|
2019-12-03 20:10:55 +08:00
|
|
|
Obsoletes: python3-brlapi < %{version}-%{release}
|
2019-09-30 10:33:11 -04:00
|
|
|
Obsoletes: python2-%{name} python-%{name}
|
|
|
|
|
Summary: Python 3 api for Brltty
|
|
|
|
|
%description -n python3-%{name}
|
|
|
|
|
This package provides the Python 3 api for Brltty.
|
|
|
|
|
|
|
|
|
|
%package -n brltty-java
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
BuildRequires: jpackage-utils java-devel
|
|
|
|
|
Summary: Java api for Brltty
|
|
|
|
|
%description -n brltty-java
|
|
|
|
|
This package provides the Java api for Brltty.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package -n ocaml-brlapi
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
BuildRequires: ocaml
|
|
|
|
|
Summary: OCaml api for Brltty
|
|
|
|
|
%description -n ocaml-brlapi
|
|
|
|
|
This package provides the OCaml api for Brltty.
|
|
|
|
|
|
|
|
|
|
%package xw
|
|
|
|
|
Summary: XWindow driver for BRLTTY
|
|
|
|
|
License: LGPLv2+
|
|
|
|
|
BuildRequires: libSM-devel libICE-devel libX11-devel libXaw-devel libXext-devel libXt-devel libXtst-devel
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
Requires: xorg-x11-fonts-misc, ucs-miscfixed-fonts
|
|
|
|
|
%description xw
|
|
|
|
|
The XWindow driver for BRLTTY.
|
|
|
|
|
|
|
|
|
|
%package at-spi2
|
|
|
|
|
Summary: AtSpi2 driver for BRLTTY
|
|
|
|
|
License: LGPLv2+
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
%description at-spi2
|
|
|
|
|
The AtSpi2 driver for BRLTTY.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%autosetup -n %{name}-%{version} -p1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
export PYTHONCOERCECLOCALE=0
|
|
|
|
|
PYTHONS=
|
|
|
|
|
./autogen
|
|
|
|
|
|
|
|
|
|
%configure --disable-relocatable-install --with-install-root="${RPM_BUILD_ROOT}" --disable-stripping --without-curses \
|
2019-11-06 19:03:39 +08:00
|
|
|
JAVA_JAR_DIR=%{_jnidir} JAVA_JNI_DIR=%{_libdir}/brltty JAVA_JNI=yes \
|
|
|
|
|
CYTHON=%{_bindir}/cython PYTHON=%{__python3} \
|
|
|
|
|
%if %{without espeak}
|
|
|
|
|
--without-espeak
|
|
|
|
|
%endif
|
|
|
|
|
|
2019-09-30 10:33:11 -04:00
|
|
|
%make_build
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
find . \( -path ./doc -o -path ./Documents \) -prune -o \
|
|
|
|
|
\( -name 'README*' -o -name '*.txt' -o -name '*.html' -o \
|
|
|
|
|
-name '*.sgml' -o -name '*.patch' -o \
|
|
|
|
|
\( -path './Bootdisks/*' -type f -perm /ugo=x \) \) -print |
|
|
|
|
|
while read file; do
|
|
|
|
|
mkdir -p ./doc/${file%/*} && cp -rp $file ./doc/$file || exit 1
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_libdir}/ocaml/stublibs
|
|
|
|
|
%make_install JAVA_JAR_DIR=%{_jnidir} JAVA_JNI_DIR=%{_libdir}/brltty JAVA_JNI=yes
|
|
|
|
|
install -m 0644 Documents/brltty.conf ${RPM_BUILD_ROOT}%{_sysconfdir}
|
|
|
|
|
install -D -p -m 0644 %{SOURCE1} $RPM_BUILD_ROOT%{_unitdir}/brltty.service
|
|
|
|
|
chmod 755 ${RPM_BUILD_ROOT}%{_bindir}/brltty-config
|
|
|
|
|
|
|
|
|
|
rm -rf $RPM_BUILD_ROOT/%{_libdir}/libbrlapi.a
|
|
|
|
|
|
|
|
|
|
%find_lang %{name}
|
|
|
|
|
cp -p %{name}.lang ../
|
|
|
|
|
|
|
|
|
|
/usr/bin/2to3 -wn ${RPM_BUILD_ROOT}/etc/brltty/Contraction/latex-access.ctb
|
|
|
|
|
sed -i 's|/usr/bin/python|/usr/bin/python3|g' ${RPM_BUILD_ROOT}/etc/brltty/Contraction/latex-access.ctb
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
|
|
|
|
|
%pre
|
|
|
|
|
if ! getent group brlapi > /dev/null ; then
|
|
|
|
|
groupadd -r brlapi > /dev/null
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%preun
|
|
|
|
|
%systemd_preun brltty.service
|
|
|
|
|
|
|
|
|
|
%post
|
|
|
|
|
if [ ! -e %{_sysconfdir}/brlapi.key ]; then
|
|
|
|
|
mcookie > %{_sysconfdir}/brlapi.key
|
|
|
|
|
chgrp brlapi %{_sysconfdir}/brlapi.key
|
|
|
|
|
chmod 0640 %{_sysconfdir}/brlapi.key
|
|
|
|
|
fi
|
|
|
|
|
/sbin/ldconfig
|
|
|
|
|
%systemd_post brltty.service
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%postun
|
|
|
|
|
/sbin/ldconfig
|
|
|
|
|
%systemd_postun_with_restart brltty.service
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files -f %{name}.lang
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%license LICENSE-*
|
|
|
|
|
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/brltty.conf
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%{_bindir}/brltty
|
|
|
|
|
%{_bindir}/brltty-*
|
|
|
|
|
%{_bindir}/vstp
|
|
|
|
|
%{_bindir}/eutp
|
|
|
|
|
%{_bindir}/xbrlapi
|
|
|
|
|
|
|
|
|
|
%{_libdir}/brltty/
|
|
|
|
|
%{_libdir}/libbrlapi.so.*
|
|
|
|
|
%exclude %{_libdir}/brltty/libbrlttyssd.so
|
|
|
|
|
%exclude %{_libdir}/brltty/libbrlttybxw.so
|
|
|
|
|
%exclude %{_libdir}/brltty/libbrlttyxa2.so
|
|
|
|
|
%exclude %{_libdir}/brltty/libbrlttysen.so
|
|
|
|
|
%exclude %{_libdir}/brltty/libbrlapi_java.so
|
|
|
|
|
|
|
|
|
|
%{_sysconfdir}/brltty/
|
|
|
|
|
%{_sysconfdir}/X11/Xsession.d/60xbrlapi
|
|
|
|
|
|
|
|
|
|
%{_datadir}/polkit-1/actions/org.a11y.brlapi.policy
|
|
|
|
|
%exclude %{_datadir}/gdm/greeter/autostart/xbrlapi.desktop
|
|
|
|
|
|
|
|
|
|
%{_unitdir}/brltty.service
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
|
%{_libdir}/libbrlapi.so
|
|
|
|
|
%{_includedir}/brltty
|
|
|
|
|
%{_includedir}/brlapi*.h
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files docs
|
|
|
|
|
%defattr(644,root,root)
|
|
|
|
|
%doc doc/*
|
|
|
|
|
#%doc Drivers/Speech/SpeechDispatcher/README
|
|
|
|
|
#%doc Drivers/Braille/XWindow/README
|
|
|
|
|
%doc Documents/*
|
|
|
|
|
%doc %{_mandir}/man[15]/brltty.*
|
|
|
|
|
%doc %{_mandir}/man1/xbrlapi.*
|
|
|
|
|
%doc %{_mandir}/man1/vstp.*
|
|
|
|
|
%doc %{_mandir}/man1/eutp.*
|
|
|
|
|
%doc %{_mandir}/man3/brlapi_*.3*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files -n tcl-%{name}
|
|
|
|
|
%{tcl_sitearch}/brlapi-%{api_ver}
|
|
|
|
|
|
|
|
|
|
%files -n python3-%{name}
|
|
|
|
|
%{python3_sitearch}/brlapi.cpython-*.so
|
|
|
|
|
%{python3_sitearch}/Brlapi-%{api_ver}-*.egg-info
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files -n brltty-java
|
|
|
|
|
%{_libdir}/brltty/libbrlapi_java.so
|
|
|
|
|
%{_jnidir}/brlapi.jar
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files -n ocaml-brlapi
|
|
|
|
|
%{_libdir}/ocaml/brlapi/
|
|
|
|
|
%{_libdir}/ocaml/stublibs
|
|
|
|
|
|
|
|
|
|
%files xw
|
|
|
|
|
%doc Drivers/Braille/XWindow/README
|
|
|
|
|
%{_libdir}/brltty/libbrlttybxw.so
|
|
|
|
|
|
|
|
|
|
%files at-spi2
|
|
|
|
|
%{_libdir}/brltty/libbrlttyxa2.so
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
2019-12-30 11:18:02 +08:00
|
|
|
* Fri Dec 27 2019 openEuler Buildteam <buildteam@openeuler.org> - 5.6-32
|
|
|
|
|
- Type:bugfix
|
|
|
|
|
- Id:NA
|
|
|
|
|
- SUG:NA
|
|
|
|
|
- DESC:fix update problem
|
|
|
|
|
|
2019-12-13 15:07:21 +08:00
|
|
|
* Wed Dec 04 2019 openEuler Buildteam <buildteam@openeuler.org> - 5.6-31
|
|
|
|
|
- Type:bugfix
|
|
|
|
|
- Id:NA
|
2019-12-04 17:33:30 +08:00
|
|
|
- SUG:NA
|
2019-12-13 15:07:21 +08:00
|
|
|
- DESC: add the release
|
2019-12-04 17:33:30 +08:00
|
|
|
|
2019-11-06 19:03:39 +08:00
|
|
|
* Wed Oct 30 2019 caomeng <caomeng5@huawei.com> - 5.6-30
|
|
|
|
|
- Type:NA
|
|
|
|
|
- ID:NA
|
|
|
|
|
- SUG:NA
|
|
|
|
|
- DESC:add bcondwith espeak and speech
|
|
|
|
|
|
2019-09-30 10:33:11 -04:00
|
|
|
* Wed Sep 18 2019 openEuler Buildteam <buildteam@openeuler.org> - 5.6-29
|
|
|
|
|
- Type:bugfix
|
|
|
|
|
- Id:NA
|
|
|
|
|
- SUG:NA
|
|
|
|
|
- DESC: Adjust the position of ldconfig in the post stage
|
|
|
|
|
|
|
|
|
|
* Thu Sep 12 2019 hufeng <solar.hu@huawei.com> - 5.6-28
|
|
|
|
|
- Init spec
|