Ignore:
Timestamp:
Jun 17, 2016, 10:41:47 PM (9 years ago)
Author:
Yuri Dario
Message:

spec: glib2, build release 2.33.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • spec/trunk/SPECS/glib2.spec

    r645 r805  
    1 
     1#define svn_url     F:/rd/ports/glib/trunk
     2%define svn_url     http://svn.netlabs.org/repos/ports/glib/trunk
     3%define svn_rev     1604
    24
    35Name:           glib2
    46%define _name glib
    5 Version:        2.25.15
    6 Release:        5%{?dist}
     7Version:        2.33.12
     8Release:        1%{?dist}
    79License:        LGPLv2.1+
    810Summary:        A Library with Convenient Functions Written in C
     
    1012Group:          Development/Libraries/C and C++
    1113
    12 %define svn_url     http://svn.netlabs.org/repos/ports/glib/trunk
    13 %define svn_rev     508
    14 
    1514Source: %{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip
     15Source1: glib2-legacy.zip
    1616
    1717BuildRequires: gcc make subversion zip
    1818
    19 # @todo (dmik) later (see below about autogen.sh usage)
    20 #BuildRequires: autoconf automake
    21 ## @todo (dmik) We need this for the moment, see #93
    22 #BuildRequires: libtool = 2.4.2
     19BuildRequires: autoconf automake
     20BuildRequires: libtool > 2.4.5
    2321
    2422#BuildRequires:  fam-devel
     
    3836Provides:       glib2-doc = 2.19.6
    3937Obsoletes:      glib2-doc < 2.19.6
     38
    4039# YD this must be added to force dll install
    4140Requires:       libglib-2_0-0 = %{version}
     
    4342Requires:       libgthread-2_0-0 = %{version}
    4443Requires:       libgobject-2_0-0 = %{version}
    45 
    46 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
    4744
    4845%description
     
    113110to a C programmer and is used by Gtk+ and GNOME.
    114111
    115 #%package -n libgio-2_0-0
    116 #License:        LGPLv2.1+
    117 #Summary:        A Library with Convenient Functions Written in C
    118 #Group:          Development/Libraries/C and C++
    119 #
     112%package -n libgio-2_0-0
     113License:        LGPLv2.1+
     114Summary:        A Library with Convenient Functions Written in C
     115Group:          Development/Libraries/C and C++
    120116# Temporarily disable this, pending further discussion
    121117# Recommends:     gvfs
    122118
    123 #%description -n libgio-2_0-0
    124 #This library provides convenient functions, such as lists and hashes,
    125 #to a C programmer and is used by Gtk+ and GNOME.
     119%description -n libgio-2_0-0
     120This library provides convenient functions, such as lists and hashes,
     121to a C programmer and is used by Gtk+ and GNOME.
    126122
    127123#%package -n libgio-fam
     
    157153to a C programmer and is used by Gtk+ and GNOME.
    158154
     155%package legacy
     156Summary: The 2.25 glib2 library.
     157
     158%description legacy
     159The 2.25 glib2 library.
     160
     161%debug_package
     162
    159163# @todo (dmik) We don't support this macro, put language files into the main package
    160164#%lang_package
     
    164168%setup -q
    165169%else
    166 %setup -n "%{name}-%{version}" -Tc
     170%setup -n "%{name}-%{version}" -Tc -a 1
    167171svn export %{?svn_rev:-r %{svn_rev}} %{svn_url} . --force
    168172rm -f "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip"
     
    170174%endif
    171175
    172 # pick up m4 fix necessary for configure to work (remove when switched to that rev)
    173 svn export  %{svn_url}/m4macros/glib-gettext.m4@892 m4macros/glib-gettext.m4 --force
    174 # fix emxexp exports (r904), also to be removed
    175 sed -e 's/:space:/[:space:]/g' configure.ac -i
    176 
    177 # @todo (dmik) we can't use autogen.sh ATM because a newer trunk revison (2.33 with fixes) is necesary for that,
    178 # also there are some problems with libtool (see #93) so we also can't use autoreconf -fvi (because we need the
    179 # fixed ltmain.sh from SVN), and even when it finally works it will rename glib2.dll to glib200.dll so some
    180 # -legacy package is necessary...
    181 autoconf
    182 ## Generate configure and friends
    183 #export NOCONFIGURE=1
    184 #autogen.sh
     176cat > gtk-doc.make <<EOF
     177EXTRA_DIST =
     178CLEANFILES =
     179EOF
     180touch README INSTALL
     181
     182autoreconf -fi
    185183
    186184%build
    187 export CONFIG_SHELL="/@unixroot/usr/bin/sh.exe"
    188185export LDFLAGS="-Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp"
    189 export LIBS="-lurpo -lmmap -lpthread"
     186export CFLAGS="%optflags -I/@unixroot/usr/include/bind9"
     187export LIBS="-lurpo -lmmap -lpthread -llwres"
    190188%configure \
     189        --disable-modular-tests \
    191190        --enable-shared --disable-static
    192 
    193 # YD fix extra CRLF after pass_all and execute it again (libtool hack breaks sed substitutions)
    194 sed -i "s/pass_all/pass_all\'\n_os2_dummy_var=\'/" config.status
    195 config.status
    196191
    197192make OPT="$CFLAGS" %{?_smp_mflags}
     
    212207cp NEWS $RPM_BUILD_ROOT%{_datadir}/doc/%{name}-%{version}
    213208cp ChangeLog $RPM_BUILD_ROOT%{_datadir}/doc/%{name}-%{version}
    214 
    215 cp glib/.libs/*.dll $RPM_BUILD_ROOT%{_libdir}
    216 cp glib/.libs/*.lib $RPM_BUILD_ROOT%{_libdir}
    217 cp gmodule/.libs/*.dll $RPM_BUILD_ROOT%{_libdir}
    218 cp gmodule/.libs/*.lib $RPM_BUILD_ROOT%{_libdir}
    219 cp gthread/.libs/*.dll $RPM_BUILD_ROOT%{_libdir}
    220 cp gthread/.libs/*.lib $RPM_BUILD_ROOT%{_libdir}
    221 cp gobject/.libs/*.dll $RPM_BUILD_ROOT%{_libdir}
    222 cp gobject/.libs/*.lib $RPM_BUILD_ROOT%{_libdir}
    223 
    224 rm $RPM_BUILD_ROOT%{_libdir}/charset.alias
    225 rm $RPM_BUILD_ROOT%{_mandir}/man1/gdbus.1
    226 rm $RPM_BUILD_ROOT%{_mandir}/man1/gio-querymodules.1
    227 rm $RPM_BUILD_ROOT%{_mandir}/man1/gsettings.1
    228209
    229210#install -D -m0644 glib2.sh $RPM_BUILD_ROOT/etc/profile.d/zzz-glib2.sh
     
    249230rm $RPM_BUILD_ROOT%{_libdir}/*.la
    250231#%endif
     232
     233# copy legacy files
     234cp -p gio2.dll %{buildroot}%{_libdir}
     235cp -p glib2.dll %{buildroot}%{_libdir}
     236cp -p gmod2.dll %{buildroot}%{_libdir}
     237cp -p gobj2.dll %{buildroot}%{_libdir}
     238cp -p gthr2.dll %{buildroot}%{_libdir}
     239
    251240%find_lang %{_name}20
    252241#%fdupes $RPM_BUILD_ROOT
     
    262251#/etc/profile.d/zzz-glib2.*
    263252#/sbin/conf.d/SuSEconfig.glib2
    264 #%{_bindir}/gio-querymodules*
     253%{_bindir}/gio-querymodules*
     254%{_libdir}/charset.alias
     255%{_datadir}/bash-completion/completions/*
    265256
    266257#%files branding-upstream
     
    271262%defattr(-, root, root)
    272263%{_libdir}/glib*.dll
     264%exclude %{_libdir}/*2.dll
    273265
    274266%files -n libgmodule-2_0-0
    275267%defattr(-, root, root)
    276268%{_libdir}/gmod*.dll
     269%exclude %{_libdir}/*2.dll
    277270
    278271%files -n libgobject-2_0-0
    279272%defattr(-, root, root)
    280273%{_libdir}/gobj*.dll
     274%exclude %{_libdir}/*2.dll
    281275
    282276%files -n libgthread-2_0-0
    283277%defattr(-, root, root)
    284278%{_libdir}/gthr*.dll
    285 
    286 #%files -n libgio-2_0-0
    287 #%defattr(-, root, root)
    288 #%{_libdir}/libgio*.so.*
     279%exclude %{_libdir}/*2.dll
     280
     281%files -n libgio-2_0-0
     282%defattr(-, root, root)
     283%{_libdir}/gio*.dll
     284%exclude %{_libdir}/*2.dll
    289285#%dir %{_libdir}/gio
    290286#%dir %{_libdir}/gio/modules
     
    298294#%{_libdir}/gio/modules/libgiofam.so
    299295
    300 # @todo (dmik) We don't support this macro, put language files into the main package
    301 #%files lang -f %{_name}20.lang
    302 
    303296%files devel
    304297%defattr(-,root,root)
     
    306299%{_bindir}/gobject-*
    307300%{_bindir}/gtester*
    308 %doc %{_mandir}/man?/glib-*.*
    309 %doc %{_mandir}/man?/gobject-*.*
    310 %doc %{_mandir}/man?/gtester*.*
     301%{_bindir}/gresource*
     302%{_bindir}/gsettings*
     303%{_bindir}/gdbus*
     304#%doc %{_mandir}/man?/glib-*.*
     305#%doc %{_mandir}/man?/gobject-*.*
     306#%doc %{_mandir}/man?/gtester*.*
    311307%{_datadir}/aclocal/*.m4
    312308%{_datadir}/glib-2.0
    313309%{_includedir}/glib-2.0
    314 #%{_includedir}/gio-unix-2.0
     310%{_includedir}/gio-unix-2.0
    315311%{_libdir}/*.a
    316 %{_libdir}/*.lib
    317312%{_libdir}/glib-2.0
    318313%{_libdir}/pkgconfig/*.pc
    319 %{_datadir}/gtk-doc/html/gio
    320 %{_datadir}/gtk-doc/html/glib
    321 %{_datadir}/gtk-doc/html/gobject
     314%{_libdir}/gdbus-2.0/*
     315#%{_datadir}/gtk-doc/html/gio
     316#%{_datadir}/gtk-doc/html/glib
     317#%{_datadir}/gtk-doc/html/gobject
    322318#%{_datadir}/gdb/auto-load/%{_libdir}/*-gdb.py
    323319%{_datadir}/gdb/auto-load/*
    324320# Own these directories to not depend on gtk-doc while building:
    325 %dir %{_datadir}/gtk-doc
    326 %dir %{_datadir}/gtk-doc/html
     321#%dir %{_datadir}/gtk-doc
     322#%dir %{_datadir}/gtk-doc/html
    327323# Own these directories to not depend on gdb
    328324%dir %{_datadir}/gdb
     
    331327#%dir %{_datadir}/gdb/auto-load/%{_prefix}/%{_lib}
    332328
     329%files legacy
     330%defattr(-,root,root)
     331%{_libdir}/*2.dll
     332
    333333%changelog
     334* Fri Jun 17 2016 yd <yd@os2power.com> 2.33.12-1
     335- build public version.
     336- add legacy package for 2.25 compatibility.
     337
    334338* Wed Jan 27 2016 Dmitriy Kuminov <coding@dmik.org> 2.25.15-5
    335339- Remove .la files from distribution.
Note: See TracChangeset for help on using the changeset viewer.