]> git.pld-linux.org Git - packages/dotnet-gtk-sharp.git/blob - dotnet-gtk-sharp.spec
- added bconds to build without gnome and gda
[packages/dotnet-gtk-sharp.git] / dotnet-gtk-sharp.spec
1 #
2 # Conditional build:
3 %bcond_without  gda     # don't build gda binding
4 %bcond_without  gnome   # don't build GNOME (and dependent) bindings
5 #
6 %define         gtkhtml_soversion       %(/bin/ls %{_libdir}/libgtkhtml-3.6.so.* 2>/dev/null | /usr/bin/head -n 1 | /bin/awk '{ split($1,v,"."); print v[4]; }')
7 %define         gtkhtml_version         %(if [ -e /usr/bin/pkg-config ]; then /usr/bin/pkg-config --modversion libgtkhtml-3.6 2>/dev/null || echo 0; else echo 0; fi)
8 %include        /usr/lib/rpm/macros.perl
9 Summary:        .NET language bindings for GTK+ and GNOME
10 Summary(pl):    Wi±zania GTK+ oraz GNOME dla .NET
11 Name:           dotnet-gtk-sharp
12 Version:        1.0.6
13 Release:        3
14 License:        LGPL
15 Group:          Development/Libraries
16 Source0:        http://www.go-mono.com/archive/%{version}/gtk-sharp-%{version}.tar.gz
17 # Source0-md5:  2651d14fe77174ab20b8af53d150ee11
18 Patch0:         %{name}-gtkhtml31.patch
19 Patch1:         %{name}-destdir.patch
20 Patch2:         %{name}-mint.patch
21 #Patch3:                %{name}-disable-rsvg-sample.patch
22 Patch4:         %{name}-pc-libdir.patch
23 URL:            http://gtk-sharp.sf.net/
24 BuildRequires:  autoconf
25 BuildRequires:  automake
26 BuildRequires:  gawk
27 BuildRequires:  libart_lgpl-devel >= 2.2.0
28 %{?with_gda:BuildRequires:      libgda-devel >= 1.0.0}
29 BuildRequires:  libglade2-devel >= 2.0.1
30 BuildRequires:  librsvg-devel >= 2.4.0
31 BuildRequires:  libtool
32 BuildRequires:  libxml2-devel
33 BuildRequires:  mono-csharp >= 1.0.2
34 BuildRequires:  ncurses-devel
35 BuildRequires:  pkgconfig
36 BuildRequires:  rpm-perlprov
37 %if %{with gnome}
38 BuildRequires:  gtkhtml-devel >= 3.6.1
39 BuildRequires:  libgnomecanvas-devel >= 2.4.0
40 %{?with_gda:BuildRequires:      libgnomedb-devel >= 1.0.0}
41 BuildRequires:  libgnomeprintui-devel >= 2.4.0
42 BuildRequires:  libgnomeui-devel >= 2.4.0
43 BuildRequires:  vte-devel >= 0.11.10
44 %endif
45 %{?with_gnome:Requires: gtkhtml = %{gtkhtml_version}}
46 Provides:       dotnet-gtk
47 Provides:       gtk-sharp
48 Obsoletes:      dotnet-gtk
49 Obsoletes:      gtk-sharp
50 ExcludeArch:    alpha
51 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
52
53 %description
54 This package provides bindings for .NET to GTK+2 and GNOME2 libraries.
55
56 %description -l pl
57 Pakiet ten dostarcza wi±zania dla .NET do bibliotek z GTK+2 oraz
58 GNOME2.
59
60 %package devel
61 Summary:        Development part of GTK#
62 Summary(pl):    Czê¶æ dla programistów GTK#
63 Group:          Development/Libraries
64 Requires:       %{name} = %{version}-%{release}
65 Provides:       dotnet-gtk-devel
66 Provides:       gtk-sharp-devel
67 Obsoletes:      dotnet-gtk-devel
68 Obsoletes:      gtk-sharp-devel
69
70 %description devel
71 Tools (C source parser and C# code generator) and documentation for
72 developing applications using GTK#.
73
74 %description devel -l pl
75 Narzêdzia (parser kodu C oraz generator kodu C#) i dokumentacja
76 potrzebne przy tworzeniu aplikacji korzystaj±cych z GTK#.
77
78 %package static
79 Summary:        Static gtk-sharp libraries
80 Summary(pl):    Biblioteki statyczne gtk-sharp
81 Group:          Development/Libraries
82 Requires:       %{name}-devel = %{version}-%{release}
83 Provides:       dotnet-gtk-static
84 Provides:       gtk-sharp-static
85 Obsoletes:      dotnet-gtk-static
86 Obsoletes:      gtk-sharp-static
87
88 %description static
89 Static gtk-sharp libraries.
90
91 %description static -l pl
92 Biblioteki statyczne gtk-sharp.
93
94 %prep
95 %setup -q -n gtk-sharp-%{version}
96 %patch0 -p1
97 %patch1 -p1
98 %patch2 -p1
99 #%patch3 -p1
100 %patch4 -p1
101
102 # workaround for variable name
103 echo 'm4_pattern_allow(PKG_PATH)' > acinclude.m4
104
105 %build
106 %{__libtoolize}
107 %{__aclocal}
108 %{__autoheader}
109 %{__automake}
110 %{__autoconf}
111 %configure \
112         GTKHTMLSOVERSION=%{gtkhtml_soversion}
113 %{__make}
114
115 %install
116 rm -rf $RPM_BUILD_ROOT
117 install -d $RPM_BUILD_ROOT{%{perl_vendorlib},%{_examplesdir}/%{name}-%{version}}
118
119 %{__make} install \
120         DESTDIR=$RPM_BUILD_ROOT
121
122 cp -a sample/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
123
124 %clean
125 rm -rf $RPM_BUILD_ROOT
126
127 %post   -p /sbin/ldconfig
128 %postun -p /sbin/ldconfig
129
130 %files
131 %defattr(644,root,root,755)
132 %doc README
133 %attr(755,root,root) %{_bindir}/gconfsharp-schemagen*
134 %attr(755,root,root) %{_libdir}/lib*sharpglue.so
135 %{_libdir}/lib*sharpglue.la
136 %{_libdir}/mono/gac/*
137
138 %files devel
139 %defattr(644,root,root,755)
140 %doc README.generator ChangeLog
141 %attr(755,root,root) %{_bindir}/gapi*
142 %{_datadir}/gapi
143 %{_examplesdir}/%{name}-%{version}
144 %{_pkgconfigdir}/*
145 %{_libdir}/mono/gtk-sharp
146
147 %files static
148 %defattr(644,root,root,755)
149 %{_libdir}/lib*sharpglue.a
This page took 0.085164 seconds and 4 git commands to generate.