20 ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
20 ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
21 ## SUCH DAMAGE. |
21 ## SUCH DAMAGE. |
22 ## |
22 ## |
23 |
23 |
24 # package versions |
24 # package versions |
25 %define V_dist 1.9.3-p286 |
25 %define V_dist 2.0.0-p0 |
26 %define V_subdir 1.9.3-p286 |
26 %define V_subdir 2.0.0-p0 |
27 %define V_opkg 1.9.3p286 |
27 %define V_opkg 2.0.0p0 |
28 |
28 |
29 # package information |
29 # package information |
30 Name: ruby |
30 Name: ruby |
31 Summary: The Ruby Scripting Language |
31 Summary: The Ruby Scripting Language |
32 URL: http://www.ruby-lang.org/ |
32 URL: http://www.ruby-lang.org/ |
61 regex = ruby-(__VER__)\.tar\.gz |
61 regex = ruby-(__VER__)\.tar\.gz |
62 } |
62 } |
63 |
63 |
64 %prep |
64 %prep |
65 %setup -q -n ruby-%{V_subdir} |
65 %setup -q -n ruby-%{V_subdir} |
|
66 l_stackprot=yes |
|
67 case "%{l_platform -t}" in |
|
68 *-sunos* ) l_stackprot=broken ;; |
|
69 esac |
|
70 %{l_shtool} subst \ |
|
71 -e 's;#!\ /bin/sh;#! %{l_bash};' \ |
|
72 -e 's;stack_protector=yes;stack_protector=$l_stackprot;g' \ |
|
73 configure |
66 |
74 |
67 %build |
75 %build |
68 CC="%{l_cc}" \ |
76 CC="%{l_cc}" \ |
69 CFLAGS="%{l_cflags -O} %{l_cppflags}" \ |
77 CFLAGS="%{l_cflags -O} %{l_cppflags}" \ |
70 GREP="grep" \ |
78 GREP="grep" \ |
71 ./configure \ |
79 ./configure \ |
72 --prefix=%{l_prefix} \ |
80 --prefix=%{l_prefix} \ |
73 --mandir=%{l_prefix}/man \ |
81 --mandir=%{l_prefix}/man \ |
74 --with-ldflags="%{l_ldflags}" \ |
82 --disable-dtrace \ |
75 --disable-shared |
83 --disable-shared |
76 %{l_make} %{l_mflags -O} |
84 %{l_make} %{l_mflags -O} V=1 |
77 |
85 |
78 %install |
86 %install |
79 %{l_shtool} mkdir -f -p -m 755 $RPM_BUILD_ROOT%{l_prefix} |
87 %{l_shtool} mkdir -f -p -m 755 $RPM_BUILD_ROOT%{l_prefix} |
80 %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT |
88 %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT |
81 strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true |
89 strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true |