Reflect upstream package vendor decision to rename glib2 to glib.

Fri, 03 Aug 2012 15:15:17 +0200

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Fri, 03 Aug 2012 15:15:17 +0200
changeset 453
5ee40987cb02
parent 452
30449282a0c7
child 454
e99334bd789c

Reflect upstream package vendor decision to rename glib2 to glib.

glib/glib.patch file | annotate | diff | comparison | revisions
glib/glib.spec file | annotate | diff | comparison | revisions
glib2/glib2.patch file | annotate | diff | comparison | revisions
glib2/glib2.spec file | annotate | diff | comparison | revisions
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/glib/glib.patch	Fri Aug 03 15:15:17 2012 +0200
     1.3 @@ -0,0 +1,74 @@
     1.4 +Index: configure
     1.5 +--- configure.orig	2010-03-16 03:52:21.000000000 +0100
     1.6 ++++ configure	2010-03-17 20:07:17.000000000 +0100
     1.7 +@@ -25810,7 +25810,7 @@
     1.8 + 	      add_thread_lib="-l$thread_lib"
     1.9 + 	      IN=" in -l$thread_lib"
    1.10 + 	    fi
    1.11 +-	    LIBS="$add_thread_lib $glib_save_LIBS"
    1.12 ++	    LIBS="$add_thread_lib `echo x$glib_save_LIBS | sed -e 's;^x;;' -e 's;-lrt;;'`"
    1.13 + 
    1.14 +             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_get_priority_min$IN" >&5
    1.15 + $as_echo_n "checking for sched_get_priority_min$IN... " >&6; }
    1.16 +Index: glib-2.0.pc.in
    1.17 +--- glib-2.0.pc.in.orig	2009-04-01 01:04:20.000000000 +0200
    1.18 ++++ glib-2.0.pc.in	2010-03-17 20:07:17.000000000 +0100
    1.19 +@@ -9,6 +9,7 @@
    1.20 + 
    1.21 + Name: GLib
    1.22 + Description: C Utility Library
    1.23 ++Requires: libpcre
    1.24 + Version: @VERSION@
    1.25 + Libs: -L${libdir} -lglib-2.0 @INTLLIBS@
    1.26 + Libs.private: @ICONV_LIBS@
    1.27 +Index: gmodule/gmodule-dl.c
    1.28 +--- gmodule/gmodule-dl.c.orig	2009-04-01 01:04:20.000000000 +0200
    1.29 ++++ gmodule/gmodule-dl.c	2010-03-17 20:07:17.000000000 +0100
    1.30 +@@ -107,6 +107,7 @@
    1.31 + static gpointer
    1.32 + _g_module_self (void)
    1.33 + {
    1.34 ++#ifndef __FreeBSD__
    1.35 +   gpointer handle;
    1.36 +   
    1.37 +   /* to query symbols from the program itself, special link options
    1.38 +@@ -118,6 +119,9 @@
    1.39 +     g_module_set_error (fetch_dlerror (TRUE));
    1.40 +   
    1.41 +   return handle;
    1.42 ++#else
    1.43 ++  return RTLD_DEFAULT;
    1.44 ++#endif
    1.45 + }
    1.46 + 
    1.47 + static void
    1.48 +Index: tests/errorcheck-mutex-test.c
    1.49 +--- tests/errorcheck-mutex-test.c.orig	2009-04-01 01:04:20.000000000 +0200
    1.50 ++++ tests/errorcheck-mutex-test.c	2010-03-17 20:07:17.000000000 +0100
    1.51 +@@ -1,3 +1,5 @@
    1.52 ++#ifdef G_THREADS_ENABLED
    1.53 ++
    1.54 + #undef G_DISABLE_ASSERT
    1.55 + #undef G_LOG_DOMAIN
    1.56 + #define G_ERRORCHECK_MUTEXES
    1.57 +@@ -102,9 +104,12 @@
    1.58 +    timed_wait_on_otherwise_locked_mutex}
    1.59 + };
    1.60 + 
    1.61 ++#endif
    1.62 ++
    1.63 + int
    1.64 + main (int argc, char* argv[])
    1.65 + {
    1.66 ++#ifdef G_THREADS_ENABLED
    1.67 +   int i;
    1.68 + 
    1.69 +   if (argc == 2)
    1.70 +@@ -126,6 +131,7 @@
    1.71 +     {
    1.72 +       fprintf (stderr, "      %s\n", func_table[i].name);
    1.73 +     }
    1.74 ++#endif
    1.75 + 
    1.76 +   return 0;
    1.77 + }
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/glib/glib.spec	Fri Aug 03 15:15:17 2012 +0200
     2.3 @@ -0,0 +1,165 @@
     2.4 +##
     2.5 +##  glib2.spec -- OpenPKG RPM Package Specification
     2.6 +##  Copyright (c) 2000-2010 OpenPKG Foundation e.V. <http://openpkg.net/>
     2.7 +##
     2.8 +##  Permission to use, copy, modify, and distribute this software for
     2.9 +##  any purpose with or without fee is hereby granted, provided that
    2.10 +##  the above copyright notice and this permission notice appear in all
    2.11 +##  copies.
    2.12 +##
    2.13 +##  THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
    2.14 +##  WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
    2.15 +##  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    2.16 +##  IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
    2.17 +##  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
    2.18 +##  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
    2.19 +##  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
    2.20 +##  USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
    2.21 +##  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
    2.22 +##  OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
    2.23 +##  OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
    2.24 +##  SUCH DAMAGE.
    2.25 +##
    2.26 +
    2.27 +#   package version
    2.28 +%define       V_glib2_major  2.25
    2.29 +%define       V_glib2_minor  13
    2.30 +
    2.31 +#   package information
    2.32 +Name:         glib2
    2.33 +Summary:      The Gtk Utility Library
    2.34 +URL:          http://www.gtk.org/
    2.35 +Vendor:       The Gtk Project
    2.36 +Packager:     OpenPKG Foundation e.V.
    2.37 +Distribution: OpenPKG Community
    2.38 +Class:        BASE
    2.39 +Group:        Algorithm
    2.40 +License:      GPL
    2.41 +Version:      %{V_glib2_major}.%{V_glib2_minor}
    2.42 +Release:      20101020
    2.43 +
    2.44 +#   package options
    2.45 +%option       with_threads  yes
    2.46 +
    2.47 +#   list of sources
    2.48 +Source0:      ftp://ftp.gnome.org/pub/gnome/sources/glib/%{V_glib2_major}/glib-%{version}.tar.gz
    2.49 +Patch0:       glib2.patch
    2.50 +
    2.51 +#   build information
    2.52 +Prefix:       %{l_prefix}
    2.53 +BuildRoot:    %{l_buildroot}
    2.54 +BuildPreReq:  OpenPKG, openpkg >= 20100101, perl, make, pkgconfig
    2.55 +PreReq:       OpenPKG, openpkg >= 20100101, perl
    2.56 +BuildPreReq:  gettext, libiconv, pcre, pcre::with_utf8 = yes
    2.57 +PreReq:       gettext, libiconv, pcre, pcre::with_utf8 = yes
    2.58 +
    2.59 +%description
    2.60 +    GLib is the low-level core library that originally was split out
    2.61 +    from Gtk+. It provides data structure handling for C, portability
    2.62 +    wrappers, and interfaces for such runtime functionality as an event
    2.63 +    loop, threads, dynamic loading, and an object system.
    2.64 +
    2.65 +%track
    2.66 +    prog glib2 = {
    2.67 +        version   = %{version}
    2.68 +        url       = ftp://ftp.gnome.org/pub/gnome/sources/glib/%{V_glib2_major}/
    2.69 +        regex     = glib-(__VER__)\.tar\.(gz|bz2)
    2.70 +    }
    2.71 +
    2.72 +%prep
    2.73 +    %setup -q -n glib-%{version}
    2.74 +    %patch -p0
    2.75 +
    2.76 +%build
    2.77 +    #   configure package
    2.78 +    %{l_shtool} subst \
    2.79 +        -e 's;\$export_dynamic_flag_spec;;g' \
    2.80 +        -e 's;eval echo \\\\;eval echo ;' \
    2.81 +        configure
    2.82 +    %{l_shtool} subst \
    2.83 +        -e 's;/glib-2\.0\.pc;/glib-x.x.pc;g' \
    2.84 +        -e 's;/gobject-2\.0\.pc;/gobject-x.x.pc;g' \
    2.85 +        -e 's;/gthread-2\.0\.pc;/gthread-x.x.pc;g' \
    2.86 +        -e 's;/gmodule-2\.0\.pc;/gmodule-x.x.pc;g' \
    2.87 +        -e 's;/gio-unix-2\.0\.pc;/gio-unix-x.x.pc;g' \
    2.88 +        -e 's;/gio-2\.0\.pc;/gio-x.x.pc;g' \
    2.89 +        -e 's;/glib-2\.0;/glib2;g' \
    2.90 +        -e 's;/gobject-2\.0;/gobject2;g' \
    2.91 +        -e 's;/gthread-2\.0;/gthread2;g' \
    2.92 +        -e 's;/gmodule-2\.0;/gmodule2;g' \
    2.93 +        -e 's;/gio-unix-2\.0;/gio-unix2;g' \
    2.94 +        -e 's;/gio-2\.0;/gio2;g' \
    2.95 +        -e 's;/glib-x\.x\.pc;/glib-2.0.pc;g' \
    2.96 +        -e 's;/gobject-x\.x\.pc;/gobject-2.0.pc;g' \
    2.97 +        -e 's;/gthread-x\.x\.pc;/gthread-2.0.pc;g' \
    2.98 +        -e 's;/gmodule-x\.x\.pc;/gmodule-2.0.pc;g' \
    2.99 +        -e 's;/gio-unix-x\.x\.pc;/gio-unix-2.0.pc;g' \
   2.100 +        -e 's;/gio-x\.x\.pc;/gio-2.0.pc;g' \
   2.101 +        -e 's;lib\(g[a-z]*\)-2\.0;lib\12;g' \
   2.102 +        `find . -name Makefile.in -print` \
   2.103 +        m4macros/glib-2.0.m4
   2.104 +    %{l_shtool} subst \
   2.105 +        -e 's;/glib-2\.0;/glib2;g' \
   2.106 +        -e 's;/gobject-2\.0;/gobject2;g' \
   2.107 +        -e 's;/gthread-2\.0;/gthread2;g' \
   2.108 +        -e 's;/gmodule-2\.0;/gmodule2;g' \
   2.109 +        -e 's;/gio-unix-2\.0;/gio-unix2;g' \
   2.110 +        -e 's;/gio-2\.0;/gio2;g' \
   2.111 +        -e 's;-l\(g[a-z]*\)-2\.0;-l\12;g' \
   2.112 +        *-2.0.pc.in
   2.113 +    libs=""
   2.114 +%if "%{with_threads}" == "yes"
   2.115 +    case "%{l_platform -t}" in
   2.116 +        *-netbsd*  ) libs="-lpthread" ;;
   2.117 +    esac
   2.118 +%endif
   2.119 +    CC="%{l_cc}" \
   2.120 +    CFLAGS="%{l_cflags -O}" \
   2.121 +    CPPFLAGS="%{l_cppflags}" \
   2.122 +    LDFLAGS="%{l_ldflags}" \
   2.123 +    LIBS="$libs" \
   2.124 +    PERL="%{l_prefix}/bin/perl" \
   2.125 +    PERL_PATH="%{l_prefix}/bin/perl" \
   2.126 +    GREP="grep" \
   2.127 +    ./configure \
   2.128 +        --prefix=%{l_prefix} \
   2.129 +        --mandir=%{l_prefix}/man \
   2.130 +        --with-libiconv=gnu \
   2.131 +        --disable-debug \
   2.132 +        --disable-shared \
   2.133 +        --with-pcre=system \
   2.134 +%if "%{with_threads}" == "yes"
   2.135 +        --enable-threads \
   2.136 +%else
   2.137 +        --disable-threads \
   2.138 +%endif
   2.139 +        --disable-gtk-doc \
   2.140 +        --disable-dtrace
   2.141 +
   2.142 +    #   build package
   2.143 +    %{l_make} %{l_mflags}
   2.144 +
   2.145 +%install
   2.146 +    rm -rf $RPM_BUILD_ROOT
   2.147 +
   2.148 +    #   install package
   2.149 +    %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT
   2.150 +
   2.151 +    #   strip down installation
   2.152 +    rm -f  $RPM_BUILD_ROOT%{l_prefix}/info/dir
   2.153 +    rm -f  $RPM_BUILD_ROOT%{l_prefix}/lib/charset.alias
   2.154 +    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/locale
   2.155 +    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/glib-2.0
   2.156 +    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/gtk-doc
   2.157 +    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/gdb
   2.158 +    strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
   2.159 +    rm $RPM_BUILD_ROOT%{l_prefix}/lib/*.la
   2.160 +
   2.161 +    #   determine installation files
   2.162 +    %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
   2.163 +
   2.164 +%files -f files
   2.165 +
   2.166 +%clean
   2.167 +    rm -rf $RPM_BUILD_ROOT
   2.168 +
     3.1 --- a/glib2/glib2.patch	Thu Aug 02 23:26:26 2012 +0200
     3.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.3 @@ -1,74 +0,0 @@
     3.4 -Index: configure
     3.5 ---- configure.orig	2010-03-16 03:52:21.000000000 +0100
     3.6 -+++ configure	2010-03-17 20:07:17.000000000 +0100
     3.7 -@@ -25810,7 +25810,7 @@
     3.8 - 	      add_thread_lib="-l$thread_lib"
     3.9 - 	      IN=" in -l$thread_lib"
    3.10 - 	    fi
    3.11 --	    LIBS="$add_thread_lib $glib_save_LIBS"
    3.12 -+	    LIBS="$add_thread_lib `echo x$glib_save_LIBS | sed -e 's;^x;;' -e 's;-lrt;;'`"
    3.13 - 
    3.14 -             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_get_priority_min$IN" >&5
    3.15 - $as_echo_n "checking for sched_get_priority_min$IN... " >&6; }
    3.16 -Index: glib-2.0.pc.in
    3.17 ---- glib-2.0.pc.in.orig	2009-04-01 01:04:20.000000000 +0200
    3.18 -+++ glib-2.0.pc.in	2010-03-17 20:07:17.000000000 +0100
    3.19 -@@ -9,6 +9,7 @@
    3.20 - 
    3.21 - Name: GLib
    3.22 - Description: C Utility Library
    3.23 -+Requires: libpcre
    3.24 - Version: @VERSION@
    3.25 - Libs: -L${libdir} -lglib-2.0 @INTLLIBS@
    3.26 - Libs.private: @ICONV_LIBS@
    3.27 -Index: gmodule/gmodule-dl.c
    3.28 ---- gmodule/gmodule-dl.c.orig	2009-04-01 01:04:20.000000000 +0200
    3.29 -+++ gmodule/gmodule-dl.c	2010-03-17 20:07:17.000000000 +0100
    3.30 -@@ -107,6 +107,7 @@
    3.31 - static gpointer
    3.32 - _g_module_self (void)
    3.33 - {
    3.34 -+#ifndef __FreeBSD__
    3.35 -   gpointer handle;
    3.36 -   
    3.37 -   /* to query symbols from the program itself, special link options
    3.38 -@@ -118,6 +119,9 @@
    3.39 -     g_module_set_error (fetch_dlerror (TRUE));
    3.40 -   
    3.41 -   return handle;
    3.42 -+#else
    3.43 -+  return RTLD_DEFAULT;
    3.44 -+#endif
    3.45 - }
    3.46 - 
    3.47 - static void
    3.48 -Index: tests/errorcheck-mutex-test.c
    3.49 ---- tests/errorcheck-mutex-test.c.orig	2009-04-01 01:04:20.000000000 +0200
    3.50 -+++ tests/errorcheck-mutex-test.c	2010-03-17 20:07:17.000000000 +0100
    3.51 -@@ -1,3 +1,5 @@
    3.52 -+#ifdef G_THREADS_ENABLED
    3.53 -+
    3.54 - #undef G_DISABLE_ASSERT
    3.55 - #undef G_LOG_DOMAIN
    3.56 - #define G_ERRORCHECK_MUTEXES
    3.57 -@@ -102,9 +104,12 @@
    3.58 -    timed_wait_on_otherwise_locked_mutex}
    3.59 - };
    3.60 - 
    3.61 -+#endif
    3.62 -+
    3.63 - int
    3.64 - main (int argc, char* argv[])
    3.65 - {
    3.66 -+#ifdef G_THREADS_ENABLED
    3.67 -   int i;
    3.68 - 
    3.69 -   if (argc == 2)
    3.70 -@@ -126,6 +131,7 @@
    3.71 -     {
    3.72 -       fprintf (stderr, "      %s\n", func_table[i].name);
    3.73 -     }
    3.74 -+#endif
    3.75 - 
    3.76 -   return 0;
    3.77 - }
     4.1 --- a/glib2/glib2.spec	Thu Aug 02 23:26:26 2012 +0200
     4.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.3 @@ -1,165 +0,0 @@
     4.4 -##
     4.5 -##  glib2.spec -- OpenPKG RPM Package Specification
     4.6 -##  Copyright (c) 2000-2010 OpenPKG Foundation e.V. <http://openpkg.net/>
     4.7 -##
     4.8 -##  Permission to use, copy, modify, and distribute this software for
     4.9 -##  any purpose with or without fee is hereby granted, provided that
    4.10 -##  the above copyright notice and this permission notice appear in all
    4.11 -##  copies.
    4.12 -##
    4.13 -##  THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
    4.14 -##  WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
    4.15 -##  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    4.16 -##  IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
    4.17 -##  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
    4.18 -##  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
    4.19 -##  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
    4.20 -##  USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
    4.21 -##  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
    4.22 -##  OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
    4.23 -##  OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
    4.24 -##  SUCH DAMAGE.
    4.25 -##
    4.26 -
    4.27 -#   package version
    4.28 -%define       V_glib2_major  2.25
    4.29 -%define       V_glib2_minor  13
    4.30 -
    4.31 -#   package information
    4.32 -Name:         glib2
    4.33 -Summary:      The Gtk Utility Library
    4.34 -URL:          http://www.gtk.org/
    4.35 -Vendor:       The Gtk Project
    4.36 -Packager:     OpenPKG Foundation e.V.
    4.37 -Distribution: OpenPKG Community
    4.38 -Class:        BASE
    4.39 -Group:        Algorithm
    4.40 -License:      GPL
    4.41 -Version:      %{V_glib2_major}.%{V_glib2_minor}
    4.42 -Release:      20101020
    4.43 -
    4.44 -#   package options
    4.45 -%option       with_threads  yes
    4.46 -
    4.47 -#   list of sources
    4.48 -Source0:      ftp://ftp.gnome.org/pub/gnome/sources/glib/%{V_glib2_major}/glib-%{version}.tar.gz
    4.49 -Patch0:       glib2.patch
    4.50 -
    4.51 -#   build information
    4.52 -Prefix:       %{l_prefix}
    4.53 -BuildRoot:    %{l_buildroot}
    4.54 -BuildPreReq:  OpenPKG, openpkg >= 20100101, perl, make, pkgconfig
    4.55 -PreReq:       OpenPKG, openpkg >= 20100101, perl
    4.56 -BuildPreReq:  gettext, libiconv, pcre, pcre::with_utf8 = yes
    4.57 -PreReq:       gettext, libiconv, pcre, pcre::with_utf8 = yes
    4.58 -
    4.59 -%description
    4.60 -    GLib is the low-level core library that originally was split out
    4.61 -    from Gtk+. It provides data structure handling for C, portability
    4.62 -    wrappers, and interfaces for such runtime functionality as an event
    4.63 -    loop, threads, dynamic loading, and an object system.
    4.64 -
    4.65 -%track
    4.66 -    prog glib2 = {
    4.67 -        version   = %{version}
    4.68 -        url       = ftp://ftp.gnome.org/pub/gnome/sources/glib/%{V_glib2_major}/
    4.69 -        regex     = glib-(__VER__)\.tar\.(gz|bz2)
    4.70 -    }
    4.71 -
    4.72 -%prep
    4.73 -    %setup -q -n glib-%{version}
    4.74 -    %patch -p0
    4.75 -
    4.76 -%build
    4.77 -    #   configure package
    4.78 -    %{l_shtool} subst \
    4.79 -        -e 's;\$export_dynamic_flag_spec;;g' \
    4.80 -        -e 's;eval echo \\\\;eval echo ;' \
    4.81 -        configure
    4.82 -    %{l_shtool} subst \
    4.83 -        -e 's;/glib-2\.0\.pc;/glib-x.x.pc;g' \
    4.84 -        -e 's;/gobject-2\.0\.pc;/gobject-x.x.pc;g' \
    4.85 -        -e 's;/gthread-2\.0\.pc;/gthread-x.x.pc;g' \
    4.86 -        -e 's;/gmodule-2\.0\.pc;/gmodule-x.x.pc;g' \
    4.87 -        -e 's;/gio-unix-2\.0\.pc;/gio-unix-x.x.pc;g' \
    4.88 -        -e 's;/gio-2\.0\.pc;/gio-x.x.pc;g' \
    4.89 -        -e 's;/glib-2\.0;/glib2;g' \
    4.90 -        -e 's;/gobject-2\.0;/gobject2;g' \
    4.91 -        -e 's;/gthread-2\.0;/gthread2;g' \
    4.92 -        -e 's;/gmodule-2\.0;/gmodule2;g' \
    4.93 -        -e 's;/gio-unix-2\.0;/gio-unix2;g' \
    4.94 -        -e 's;/gio-2\.0;/gio2;g' \
    4.95 -        -e 's;/glib-x\.x\.pc;/glib-2.0.pc;g' \
    4.96 -        -e 's;/gobject-x\.x\.pc;/gobject-2.0.pc;g' \
    4.97 -        -e 's;/gthread-x\.x\.pc;/gthread-2.0.pc;g' \
    4.98 -        -e 's;/gmodule-x\.x\.pc;/gmodule-2.0.pc;g' \
    4.99 -        -e 's;/gio-unix-x\.x\.pc;/gio-unix-2.0.pc;g' \
   4.100 -        -e 's;/gio-x\.x\.pc;/gio-2.0.pc;g' \
   4.101 -        -e 's;lib\(g[a-z]*\)-2\.0;lib\12;g' \
   4.102 -        `find . -name Makefile.in -print` \
   4.103 -        m4macros/glib-2.0.m4
   4.104 -    %{l_shtool} subst \
   4.105 -        -e 's;/glib-2\.0;/glib2;g' \
   4.106 -        -e 's;/gobject-2\.0;/gobject2;g' \
   4.107 -        -e 's;/gthread-2\.0;/gthread2;g' \
   4.108 -        -e 's;/gmodule-2\.0;/gmodule2;g' \
   4.109 -        -e 's;/gio-unix-2\.0;/gio-unix2;g' \
   4.110 -        -e 's;/gio-2\.0;/gio2;g' \
   4.111 -        -e 's;-l\(g[a-z]*\)-2\.0;-l\12;g' \
   4.112 -        *-2.0.pc.in
   4.113 -    libs=""
   4.114 -%if "%{with_threads}" == "yes"
   4.115 -    case "%{l_platform -t}" in
   4.116 -        *-netbsd*  ) libs="-lpthread" ;;
   4.117 -    esac
   4.118 -%endif
   4.119 -    CC="%{l_cc}" \
   4.120 -    CFLAGS="%{l_cflags -O}" \
   4.121 -    CPPFLAGS="%{l_cppflags}" \
   4.122 -    LDFLAGS="%{l_ldflags}" \
   4.123 -    LIBS="$libs" \
   4.124 -    PERL="%{l_prefix}/bin/perl" \
   4.125 -    PERL_PATH="%{l_prefix}/bin/perl" \
   4.126 -    GREP="grep" \
   4.127 -    ./configure \
   4.128 -        --prefix=%{l_prefix} \
   4.129 -        --mandir=%{l_prefix}/man \
   4.130 -        --with-libiconv=gnu \
   4.131 -        --disable-debug \
   4.132 -        --disable-shared \
   4.133 -        --with-pcre=system \
   4.134 -%if "%{with_threads}" == "yes"
   4.135 -        --enable-threads \
   4.136 -%else
   4.137 -        --disable-threads \
   4.138 -%endif
   4.139 -        --disable-gtk-doc \
   4.140 -        --disable-dtrace
   4.141 -
   4.142 -    #   build package
   4.143 -    %{l_make} %{l_mflags}
   4.144 -
   4.145 -%install
   4.146 -    rm -rf $RPM_BUILD_ROOT
   4.147 -
   4.148 -    #   install package
   4.149 -    %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT
   4.150 -
   4.151 -    #   strip down installation
   4.152 -    rm -f  $RPM_BUILD_ROOT%{l_prefix}/info/dir
   4.153 -    rm -f  $RPM_BUILD_ROOT%{l_prefix}/lib/charset.alias
   4.154 -    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/locale
   4.155 -    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/glib-2.0
   4.156 -    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/gtk-doc
   4.157 -    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/gdb
   4.158 -    strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
   4.159 -    rm $RPM_BUILD_ROOT%{l_prefix}/lib/*.la
   4.160 -
   4.161 -    #   determine installation files
   4.162 -    %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
   4.163 -
   4.164 -%files -f files
   4.165 -
   4.166 -%clean
   4.167 -    rm -rf $RPM_BUILD_ROOT
   4.168 -

mercurial