]> git.pld-linux.org Git - packages/codeblocks.git/blame - codeblocks.spec
- re-added -pwd.patch
[packages/codeblocks.git] / codeblocks.spec
CommitLineData
9bcbe72a 1#TODO
2# - snap build from svn
12d3c9b7 3#
9bcbe72a 4
b2a2c8d3 5%bcond_with snap # build snap instead of release
6
7%if %{with snap}
8%define _svn svn5082
9%define _snap 20080531
10%endif
11
f2e658c8 12Summary: An open source, cross platform, free C++ IDE
b4d5defa 13Summary(pl.UTF-8): Wieloplatformowe, darmowe IDE do C++ o otwartych źródłach
f2e658c8 14Name: codeblocks
b2a2c8d3 15%if %{with snap}
16Version: 1.0
17Release: %{_snap}%{_svn}
18%else
9bcbe72a 19Version: 8.02
12d3c9b7 20Release: 1
b2a2c8d3 21%endif
12d3c9b7
MB
22License: GPL v3
23Group: X11/Development/Tools
b2a2c8d3 24%if %{with snap}
25Source0: %{name}-%{_snap}.tar.gz
26%else
9bcbe72a 27Source0: http://dl.sourceforge.net/codeblocks/%{name}-%{version}-src.tar.bz2
28# Source0-md5: ac15b4b3de50d7650c2f7a8dbcb30f88
b2a2c8d3 29%endif
9bcbe72a 30Patch0: %{name}-FHS-plugins.patch
12d3c9b7
MB
31Patch1: %{name}-desktop.patch
32Patch2: %{name}-ac.patch
326d573e 33Patch3: %{name}-pwd.patch
f2e658c8 34URL: http://www.codeblocks.org/
12d3c9b7 35BuildRequires: autoconf >= 2.50
f2e658c8 36BuildRequires: automake
12d3c9b7 37BuildRequires: bzip2-devel
f2e658c8
PS
38BuildRequires: dos2unix
39BuildRequires: libtool
12d3c9b7
MB
40BuildRequires: pkgconfig
41BuildRequires: sed >= 4.0
26999fff 42BuildRequires: unixODBC-devel
9bcbe72a 43BuildRequires: wxGTK2-unicode-devel >= 2.8.0
f2e658c8 44BuildRequires: zip
12d3c9b7
MB
45BuildRequires: zlib-devel
46Requires(post,postun): desktop-file-utils
47Requires(post,postun): gtk+2
48Requires(post,postun): shared-mime-info
f2e658c8
PS
49BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
50
74a27b01 51%define _pluginsdir %{_libdir}/%{name}/plugins
9a4b0780 52
f2e658c8
PS
53%description
54Code::Blocks is a free C++ IDE built specifically to meet the most
55demanding needs of its users. It was designed, right from the start,
56to be extensible and configurable. Built around a plugin framework,
57Code::Blocks can be extended with plugin DLLs. It includes a plugin
58wizard so you can compile your own plugins!
59
f2e658c8 60Highlights:
12d3c9b7 61 - Open Source! GPL 3, no hidden costs
42743d1b 62 - Cross-platform; runs on Linux or Windows (uses wxWidgets)
64571bfc 63 - Made in GNU C++; no interpreted languages or proprietary libs needed
42743d1b 64 - Extensible thru plugins
f2e658c8
PS
65
66Compiler-related features:
42743d1b
JB
67 - Multiple compiler support: GCC (MingW / Linux), MSVC++, Digital
68 Mars, Borland C++ 5.5, Open Watcom
69 - Compiles directly or with makefiles
70 - Predefined project templates
71 - Custom template support
72 - Uses XML format for project files
73 - Multi-target projects
74 - Workspaces support
75 - Imports MSVC projects and workspaces (NOTE: assembly code and
76 inter-project dependencies not supported yet)
77 - Imports Dev-C++ projects
78 - Integrates with GDB for debugging
f2e658c8
PS
79
80Interface Features:
42743d1b
JB
81 - Syntax highlighting, customizable and extensible
82 - Code folding for C++ and XML files
83 - Tabbed interface
84 - Code completion plugin
85 - Class Browser
86 - Smart indent
87 - One-key swap between .h and .c/.cpp files
88 - Open files list for quick switching between files (optional)
89 - External customizable "Tools"
90 - To-do list management with different users
91
95d73c87 92%description -l pl.UTF-8
42743d1b 93Code::Blocks to darmowe IDE dla C++ tworzone specjalnie w celu
95d73c87
JR
94zaspokojenia największych potrzeb swoich użytkowników. Zostało
95zaprojektowane od początku aby było rozszerzalne i konfigurowalne.
96Code::Blocks, jako zbudowane w oparciu o szkielet wtyczek, można
97rozszerzać. Zawiera czarodzieja dla wtyczek, więc można kompilować
98własne.
99
100Główne cechy:
12d3c9b7 101 - otwarte źródła na licencji GPL 3, bez ukrytych kosztów
95d73c87 102 - wieloplatformowość - działa na Linuksie i Windows (przy użyciu
42743d1b 103 wxWidgets)
95d73c87
JR
104 - stworzone w GNU C++, nie wymaga języków interpretowanych ani
105 własnościowych bibliotek
42743d1b
JB
106 - rozszerzalne poprzez wtyczki
107
95d73c87
JR
108Cechy związane z kompilatorami:
109 - obsługa wielu kompilatorów: GCC (MingW / Linux), MSVC++, Digital
42743d1b 110 Mars, Borland C++ 5.5, Open Watcom
95d73c87
JR
111 - kompiluje bezpośrednio lub z użyciem plików Makefile
112 - predefiniowane szablony projektów
113 - obsługa własnych szablonów
114 - używa formatu XML dla plików projektów
42743d1b 115 - projekty z wieloma celami
95d73c87
JR
116 - obsługa przestrzeni zadań (workspace)
117 - import projektów i przestrzeni zadań MSVC (uwaga: kdo w asemblerze i
118 zależności między projektami nie są jeszcze obsługiwane)
119 - import projektów Dev-C++
42743d1b 120 - integracja z GDB do odpluskwiania
f2e658c8 121
42743d1b 122Cechy interfejsu:
95d73c87 123 - podświetlanie składni - konfigurowalne i rozszerzalne
42743d1b 124 - zwijanie kodu w plikach C++ i XML
95d73c87
JR
125 - interfejs z zakładkami
126 - wtyczka dopełniania kodu
127 - przeglądarka klas
128 - inteligentne wcięcia
129 - przełączanie jednym klawiszem między plikami .h i .c/.cpp
130 - lista otwartych plików do szybkiego przełączania między nimi (opcja)
131 - zewnętrzne, konfigurowalne "narzędzia"
132 - zarządzanie listą rzeczy do zrobienia ("To-do") przez różnych
133 użytkowników
f2e658c8 134
d9b53836
AG
135%package devel
136Summary: Development files for Code::Blocks
b4d5defa 137Summary(pl.UTF-8): Pliki nagłówkowe Code::Blocks
12d3c9b7 138Group: X11/Development/Libraries
74a27b01 139Requires: %{name} = %{version}-%{release}
d9b53836
AG
140
141%description devel
142This package provides development files for Code::Blocks. Install this
143package only if you plan to write plugins for Code::Blocks.
144
95d73c87
JR
145%description devel -l pl.UTF-8
146Ten pakiet dostarcza plików nagłówkowych Code::Blocks. Należy
147instalować ten pakiet tylko w celu pisania wtyczek do Code::Blocks.
d9b53836 148
f2e658c8 149%prep
b2a2c8d3 150%if %{with snap}
151%setup -q -n %{name}-%{_snap}
152%else
12d3c9b7 153%setup -q
b2a2c8d3 154%endif
f2e658c8 155find . -type f -and -not -name "*.cpp" -and -not -name "*.h" -and -not -name "*.png" -and -not -name "*.bmp" -and -not -name "*.c" -and -not -name "*.cxx" -and -not -name "*.ico" | sed "s/.*/\"\\0\"/" | xargs dos2unix
b2a2c8d3 156
9bcbe72a 157%patch0 -p1
12d3c9b7
MB
158%patch1 -p1
159%patch2 -p1
326d573e 160%patch3 -p1
9bcbe72a 161
162# fix the dir, where plugins are installed
163for p in astyle autosave classwizard codecompletion compilergcc debuggergdb \
164defaultmimehandler openfileslist projectsimporter scriptedwizard todo xpmanifest
165do
166 sed -i 's|$(pkgdatadir)/plugins|@libdir@/@PACKAGE@/plugins|' src/plugins/$p/Makefile.*
167done
168
169for p in AutoVersioning BrowseTracker ThreadSearch byogames cb_koders \
170codesnippets codestat dragscroll envvars help_plugin keybinder lib_finder \
171profiler regex_testbed source_exporter symtab wxSmith wxSmithContribItems
172do
173 sed -i 's|$(pkgdatadir)/plugins|@libdir@/@PACKAGE@/plugins|' src/plugins/contrib/$p/Makefile.*
174done
175
176sed -i 's|$(pkgdatadir)/plugins|@libdir@/@PACKAGE@/plugins|' src/plugins/contrib/wxSmith/plugin/Makefile.*
177
12d3c9b7 178#hardcode libdir, continue of patch0
9bcbe72a 179sed -i 's|@libdir@|%{_libdir}|' src/sdk/configmanager.cpp
180
181# remove execute bits from source files
182find src/plugins/contrib/regex_testbed -type f -exec chmod a-x {} ';'
183find src/plugins/compilergcc -type f -exec chmod a-x {} ';'
184
185# fix version inside the configure script
12d3c9b7 186sed -i 's/1\.0svn/%{version}/g' revision.m4
26999fff 187
12d3c9b7 188%build
b2a2c8d3 189%if %{with snap}
190chmod a+x update_revision.sh
191./update_revision.sh
12d3c9b7 192%endif
f2e658c8
PS
193%{__libtoolize}
194%{__aclocal}
195%{__autoconf}
196%{__autoheader}
197%{__automake}
198%configure \
9bcbe72a 199 --with-wx-config=wx-gtk2-unicode-config \
200 --with-contrib-plugins=all
201
f2e658c8 202%{__make}
12d3c9b7 203
f2e658c8
PS
204%install
205rm -rf $RPM_BUILD_ROOT
206
207%{__make} install \
12d3c9b7
MB
208 DESTDIR=$RPM_BUILD_ROOT \
209 mimeicondir=%{_iconsdir}/hicolor/48x48/mimetypes
9bcbe72a 210
211rm -f $RPM_BUILD_ROOT%{_pluginsdir}/*.la
f2e658c8
PS
212
213%clean
214rm -rf $RPM_BUILD_ROOT
215
12d3c9b7
MB
216%post
217/sbin/ldconfig
218%update_icon_cache hicolor
219%update_desktop_database_post
220%update_mime_database
221
222%postun
223/sbin/ldconfig
224%update_icon_cache hicolor
225%update_desktop_database_postun
226%update_mime_database
f2e658c8
PS
227
228%files
229%defattr(644,root,root,755)
a06a8703 230%doc AUTHORS BUGS COMPILERS README TODO ChangeLog
9bcbe72a 231%attr(755,root,root) %{_bindir}/cb_share_config
f2e658c8 232%attr(755,root,root) %{_bindir}/codeblocks
9bcbe72a 233%attr(755,root,root) %{_bindir}/codesnippets
bbe47d95 234%attr(755,root,root) %{_bindir}/cb_console_runner
12d3c9b7
MB
235%attr(755,root,root) %{_libdir}/libwxsmithlib.so.*.*.*
236%attr(755,root,root) %ghost %{_libdir}/libwxsmithlib.so.0
237%attr(755,root,root) %{_libdir}/libcodeblocks.so.*.*.*
238%attr(755,root,root) %ghost %{_libdir}/libcodeblocks.so.0
239%{_desktopdir}/codeblocks.desktop
a06a8703 240%{_pixmapsdir}/*.png
12d3c9b7 241%{_iconsdir}/hicolor/48x48/mimetypes/*.png
bbe47d95 242%{_datadir}/mime/packages/codeblocks.xml
7b226dae 243%dir %{_datadir}/%{name}
bbe47d95 244%dir %{_datadir}/%{name}/scripts
9bcbe72a 245%{_datadir}/%{name}/scripts/*
7b226dae
PS
246%{_datadir}/%{name}/*.zip
247%{_datadir}/%{name}/*.txt
248%{_datadir}/%{name}/icons
249%{_datadir}/%{name}/images
250%{_datadir}/%{name}/lexers
12d3c9b7 251%{_datadir}/%{name}/lib_finder
7b226dae 252%{_datadir}/%{name}/templates
12d3c9b7 253%dir %{_libdir}/%{name}
9bcbe72a 254%dir %{_pluginsdir}
255%attr(755,root,root) %{_pluginsdir}/*.so
12d3c9b7 256%{_mandir}/man1/*.1*
d9b53836
AG
257
258%files devel
259%defattr(644,root,root,755)
12d3c9b7
MB
260%attr(755,root,root) %{_libdir}/libcodeblocks.so
261%attr(755,root,root) %{_libdir}/libwxsmithlib.so
262%{_libdir}/libcodeblocks.la
263%{_libdir}/libwxsmithlib.la
9bcbe72a 264%{_pkgconfigdir}/codeblocks.pc
d9b53836 265%{_includedir}/codeblocks
This page took 0.164582 seconds and 4 git commands to generate.