Skip to content

Commit

Permalink
Fix PowerPC 32-bit RPM build
Browse files Browse the repository at this point in the history
  • Loading branch information
dcommander committed Sep 20, 2017
1 parent 8d403ae commit fd778bb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
4 changes: 4 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -565,6 +565,10 @@ case "$host_cpu" in
RPMARCH=`uname -m`
DEBARCH=ppc64el
;;
powerpc)
RPMARCH=ppc
DEBARCH=ppc
;;
*)
RPMARCH=`uname -m`
DEBARCH=$RPMARCH
Expand Down
15 changes: 13 additions & 2 deletions release/libjpeg-turbo.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,18 @@
# Path under which headers should be installed
%define _includedir %{__includedir}

%ifarch x86_64
%if "%{?__isa_bits:1}" == "1"
%define _bits %{__isa_bits}
%else
# RPM < 4.6
%if "%{_lib}" == "lib64"
%define _bits 64
%else
%define _bits 32
%endif
%endif

%if "%{_bits}" == "64"
%define _libdir %{_exec_prefix}/lib64
%else
%if "%{_prefix}" == "/opt/libjpeg-turbo"
Expand All @@ -35,7 +46,7 @@ Release: @BUILD@
License: BSD-style
BuildRoot: %{_blddir}/%{name}-buildroot-%{version}-%{release}
Prereq: /sbin/ldconfig
%ifarch x86_64
%if "%{_bits}" == "64"
Provides: %{name} = %{version}-%{release}, @PACKAGE_NAME@ = %{version}-%{release}, libturbojpeg.so()(64bit)
%else
Provides: %{name} = %{version}-%{release}, @PACKAGE_NAME@ = %{version}-%{release}, libturbojpeg.so
Expand Down

0 comments on commit fd778bb

Please sign in to comment.