[m17n-lib/f14/master] - supply libotf cflags/libs manually, since the current libotf package does not ship with "libotf-

pnemade pnemade at fedoraproject.org
Mon Sep 13 05:32:30 UTC 2010


commit 97fa0bf3b59bfbcc99b5c34259e86e0a5dfa1ebf
Author: Parag Nemade <pnemade at redhat.com>
Date:   Mon Sep 13 11:06:28 2010 +0530

    - supply libotf cflags/libs manually, since the current libotf package
      does not ship with "libotf-config" and m17n-lib cannot detect those
      values
    - fix paths for modules used by GUI support

 m17n-lib.spec |   59 +++++++++++++++++++++++++++++----------------------------
 1 files changed, 30 insertions(+), 29 deletions(-)
---
diff --git a/m17n-lib.spec b/m17n-lib.spec
index d71b673..516444d 100644
--- a/m17n-lib.spec
+++ b/m17n-lib.spec
@@ -2,12 +2,12 @@
 
 # note this duplicates native anthy IMEs
 %bcond_without anthy
-# use --with gui to build GUI library
-%bcond_with gui
+# use --with tools to build GUI library and tools to test it.
+%bcond_without tools
 
 Name:    m17n-lib
 Version:  1.6.1
-Release:  3%{?dist}
+Release:  4%{?dist}
 Summary:  Multilingual text library
 
 Group:    System Environment/Libraries
@@ -15,15 +15,14 @@ License:  LGPLv2
 URL:    http://www.m17n.org/m17n-lib/index.html
 Source0:  http://www.m17n.org/m17n-lib-download/%{name}-%{version}.tar.gz
 Patch0:  m17n-lib-1.6.1-multilib.patch
-BuildRoot:  %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:  m17n-db-devel >= 1.6.0
 %if %{with anthy}
 BuildRequires:  anthy-devel
 %endif
-%if %{with gui}
+%if %{with tools}
 BuildRequires:  libxml2-devel, libXft-devel, fontconfig-devel
 BuildRequires:  freetype-devel >= 2.0, fribidi-devel, gd-devel >= 2.0, libXaw-devel
-# ispell seems to depend on gui
+# ispell seems to depend on tools
 BuildRequires:  aspell
 %endif
 %if %{with otf}
@@ -59,14 +58,14 @@ Requires:  %{name}-anthy = %{version}-%{release}
 Development files for %{name}.
 
 
-%if %{with gui}
-%package  gui
+%if %{with tools}
+%package  tools
 Summary:  m17n GUI Library
 Group:    System Environment/Libraries
 Requires: m17n-db-datafiles
 
-%description gui
-M17n GUI widget library.
+%description tools
+Tools to test M17n GUI widget library.
 
 
 %package  ispell
@@ -83,27 +82,23 @@ Ispell module for m17n input.
 %patch0 -p0
 
 %build
-%configure --disable-rpath --disable-static %{!?with_gui:--without-gui}
+# XXX: Supply libotf cflags/libs manually, since the current libotf
+# package does not ship with "libotf-config" and m17n-lib cannot
+# detect those values.
+CPPFLAGS=`pkg-config libotf --cflags`
+export CPPFLAGS
+LIBS=`pkg-config libotf --libs`
+export LIBS
+%configure --disable-rpath --disable-static %{!?with_tools:--without-tools}
 sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
 sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
-make
+make  %{?_smp_mflags}
 
 
 %install
-rm -rf $RPM_BUILD_ROOT
 make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
 
-# remove unneeded files
-rm $RPM_BUILD_ROOT%{_libdir}/lib*.la
-rm $RPM_BUILD_ROOT%{_libdir}/m17n/1.0/libmimx-anthy.la
-%if %{without anthy}
-rm $RPM_BUILD_ROOT%{_libdir}/m17n/1.0/libmimx-anthy*
-%endif
-
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
+find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
 
 %post -p /sbin/ldconfig
 
@@ -130,24 +125,30 @@ rm -rf $RPM_BUILD_ROOT
 %{_libdir}/lib*.so
 %{_libdir}/pkgconfig/*
 
-%if %{with gui}
-%files gui
+%if %{with tools}
+%files tools
 %defattr(-,root,root,-)
 %{_bindir}/m17n-date
 %{_bindir}/m17n-dump
 %{_bindir}/m17n-edit
 %{_bindir}/m17n-view
-%{_libdir}/libm17n-X.so.*
-%{_libdir}/libm17n-gd.so.*
+%{_libdir}/m17n/1.0/libm17n-X.so
+%{_libdir}/m17n/1.0/libm17n-gd.so
 %{_libdir}/libm17n-gui.so.*
 
 %files ispell
 %defattr(-,root,root,-)
-%{_libdir}/libmimx-ispell.so.*
+%{_libdir}/m17n/1.0/libmimx-ispell.so
 %endif
 
 
 %changelog
+* Fri Sep 10 2010 Daiki Ueno <dueno at redhat.com> - 1.6.1-4
+- supply libotf cflags/libs manually, since the current libotf package
+  does not ship with "libotf-config" and m17n-lib cannot detect those
+  values
+- fix paths for modules used by GUI support
+
 * Wed Aug 11 2010 Adam Jackson <ajax at redhat.com> 1.6.1-3
 - Fix Obsoletes: so upgrades actually work (1.5.5-3 < 1.5.5-3.fc13)
 


More information about the scm-commits mailing list