1 Summary: 32-bit compiler for the i386 and m68k processors
2 Summary(pl): 32 bitowy kompilator dla procesorów i386 i m68k
3 Summary(ru): ó×ÏÂÏÄÎÙÊ ËÏÍÐÉÌÑÔÏÒ Pascal
4 Summary(uk): ÷¦ÌØÎÉÊ ËÏÍЦÌÑÔÏÒ Pascal
9 Group: Development/Languages
10 Vendor: Michael Van Canneyt <michael@tfdec1.fys.kuleuven.ac.be>
11 Source0: ftp://ftp.us.freepascal.org/pub/fpc/dist/source-%{version}/%{name}-%{version}-src.tar.gz
12 # Source0-md5: da2ec003500584649cb31288613c33fa
13 Source1: ftp://ftp.us.freepascal.org/pub/fpc/dist/Linux/i386/separate/binary.tar
14 # Source1-md5: 62c7ac6c21c44276b5e14bf34265d185
15 Source2: %{name}-sample.cfg
16 URL: http://www.freepascal.org/
18 BuildRequires: zlib-devel
19 Requires: gcc >= 2.95.2
20 ExclusiveArch: %{ix86} m68k
21 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24 Free Pascal is a 32-bit compiler for the i386 and m68k processors.
25 Free Pascal is designed to be, as much as possible, source compatible
26 with Turbo Pascal 7.0 and Delphi 4 (although this goal is not yet
27 attained), but it also enhances these languages with elements like
28 function overloading. And, unlike these ancestors, it supports
32 Free Pascal to 32 bitowy kompilator dla procesorów i386 oraz m86k.
33 Free Pascal zosta³ zaprojektowany by byæ (jak tylko to mo¿liwe)
34 kompatybilnym z Turbo Pascal 7.0 oraz Delphi 4. Free Pascal równie¿
35 rozszerza te jêzyki elementami takimi jak przeci±¿anie funkcji.
38 FPC -- 32-ÂÉÔÎÙÊ ËÏÍÐÉÌÑÔÏÒ Pascal, ÓÏ×ÍÅÓÔÉÍÙÊ Ó Turbo Pascal 7.0 É Delphi.
39 ðÏÓÔÁ×ÌÑÅÔÓÑ Ó RTL (ÂÉÂÌÉÏÔÅËÏÊ ×ÒÅÍÅÎÉ ÉÓÐÏÌÎÅÎÉÑ), FCL (ÂÉÂÌÉÏÔÅËÏÊ Ó×ÏÂÏÄÎÙÈ
40 ËÏÍÐÏÎÅÎÔ), ÉÎÔÅÒÆÅÊÓÁÍÉ Ë gtk, ncurses, zlib, mysql, postgres, ibase.
43 FPC -- 32-¦ÔÎÉÊ ËÏÍЦÌÑÔÏÒ Pascal, ÓÕͦÓÎÉÊ ¦Ú Turbo Pascal 7.0 ÔÁ Delphi.
44 ðÏÓÔÁÞÁ¤ÔØÓÑ ¦Ú RTL (¦Â̦ÏÔÅËÏÀ ÞÁÓÕ ×ÉËÏÎÁÎÎÑ), FCL (¦Â̦ÏÔÅËÏÀ צÌØÎÉÈ
45 ËÏÍÐÏÎÅÎÔ), ¦ÎÔÅÒÆÅÊÓÁÍÉ ÄÏ gtk, ncurses, zlib, mysql, postgres, ibase.
48 Summary: Free Pascal Compiler exaple programs
49 Summary(pl): Przyk³adowe programy do kompilatora Free Pascal
51 Requires: %{name} = %{version}
54 Free Pascal Compiler exaple programs.
56 %description examples -l pl
57 Przyk³adowe programy do kompilatora Free Pascal.
60 Summary: Free Pascal Compiler documentation
61 Summary(pl): Dokumentacja do kompilatora Free Pascal
63 Requires: %{name} = %{version}
66 Documentation for fpc in PDF format.
68 %description doc -l pl
69 Dokumentacja do fpc w formacie PDF.
74 for i in *.tar.gz ; do
78 mkdir -p src/%{name}-%{version}/doc
79 mv doc/%{name}-%{version}/* src/%{name}-%{version}/doc
80 mkdir -p src/%{name}-%{version}/man && echo ".PHONY: all install installman" > src/%{name}-%{version}/man/Makefile
82 cd src/%{name}-%{version}
86 if [ "%{_build_cpu}" = "m68k" ]; then
92 # DO NOT PUT $RPM_OPT_FLAGS IN OPT, IT DOES NOT WORK - baggins
93 case "%{_build_cpu}" in
104 PP=`pwd`/lib/fpc/%{version}/ppc386
105 NEWPP=`pwd`/src/fpc-%{version}/compiler/ppc386
106 NEWFPDOC=`pwd`/src/fpc-%{version}/utils/fpdoc/fpdoc
108 # ppc386 binary cuts PATH - sometimes before /usr/bin with needed as and ld
109 export PATH="/usr/bin:/bin"
111 %{__make} -C src/%{name}-%{version} \
114 BASEINSTALLDIR=%{_libdir}/%{name}/%{version} \
115 BININSTALLDIR=%{_bindir} \
120 %{__make} -C src/%{name}-%{version} \
123 BASEINSTALLDIR=%{_libdir}/%{name}/%{version} \
124 BININSTALLDIR=%{_bindir} \
127 rtl_clean rtl_smart packages_base_smart fcl_smart packages_extra_smart utils_all
129 %{__make} -C src/%{name}-%{version}/docs pdf FPDOC=${NEWFPDOC}
132 rm -rf $RPM_BUILD_ROOT
133 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_mandir},%{_examplesdir}/fpc}
135 install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/fpc.cfg
137 # new ppc386 cuts PATH too (how to fix it???)
138 export PATH="/usr/bin:/bin"
140 NEWPP=`pwd`/src/fpc-%{version}/compiler/ppc386
141 %{__make} -C src/%{name}-%{version} \
142 INSTALL_PREFIX=$RPM_BUILD_ROOT%{_prefix} \
143 INSTALL_BINDIR=$RPM_BUILD_ROOT%{_bindir} \
144 INSTALL_LIBDIR=$RPM_BUILD_ROOT%{_libdir} \
145 INSTALL_DOCDIR=$RPM_BUILD_ROOT%{_docdir} \
146 INSTALL_MANDIR=$RPM_BUILD_ROOT%{_mandir} \
148 compiler_distinstall \
150 packages_distinstall \
155 %{__make} -C src/%{name}-%{version}/docs pdfinstall DOCINSTALLDIR=$RPM_BUILD_ROOT%{_docdir}
157 mv -f src/%{name}-%{version}/doc/examples/* $RPM_BUILD_ROOT%{_examplesdir}/fpc
159 ln -sf ../lib/%{name}/%{version}/ppc386 $RPM_BUILD_ROOT%{_bindir}/ppc386
160 ln -sf ppc386 $RPM_BUILD_ROOT%{_bindir}/fpc
162 mv -f src/%{name}-%{version}/doc/faq.htm src/%{name}-%{version}/doc/faq.html
164 ln -sf %{_bindir}/{as,ld} $RPM_BUILD_ROOT%{_libdir}/%{name}/%{version}
167 rm -rf $RPM_BUILD_ROOT
171 GCCSPEC=`(gcc -v 2>&1)| head -n 1| awk '{ print $4 } '`
172 GCCDIR=`dirname $GCCSPEC`
173 echo "Found libgcc.a in $GCCDIR"
174 sed -e "s#\$GCCDIR#$GCCDIR#" %{_sysconfdir}/fpc.cfg > %{_sysconfdir}/fpc.cfg.new
175 sed -e "s#\$1#%{_libdir}/%{name}/%{version}#" %{_sysconfdir}/fpc.cfg.new > %{_sysconfdir}/fpc.cfg
176 rm -f %{_sysconfdir}/fpc.cfg.new
179 %defattr(644,root,root,755)
180 %attr(755,root,root) %{_bindir}/*
181 %doc src/%{name}-%{version}/doc/{copying*,*.txt}
182 %doc src/%{name}-%{version}/doc/faq.html
183 %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/fpc.cfg
184 %dir %{_libdir}/%{name}
185 %dir %{_libdir}/%{name}/%{version}
186 %dir %{_libdir}/%{name}/lexyacc
187 %{_libdir}/%{name}/%{version}/msg
188 %{_libdir}/%{name}/%{version}/units
189 %{_libdir}/%{name}/%{version}/as
190 %{_libdir}/%{name}/%{version}/ld
191 %{_libdir}/%{name}/lexyacc/*
192 %attr(755,root,root) %{_libdir}/%{name}/%{version}/ppc386
193 %attr(755,root,root) %{_libdir}/%{name}/%{version}/samplecfg
197 %defattr(644,root,root,755)
201 %defattr(644,root,root,755)
202 %doc src/%{name}-%{version}/doc/*.pdf