ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CMSDIST/mysql.spec
Revision: 1.8
Committed: Fri May 19 10:09:27 2006 UTC (18 years, 11 months ago) by eulisse
Branch: MAIN
Changes since 1.7: +3 -0 lines
Log Message:
removes hardcoded dependencies to /usr/local/bin/perl.

File Contents

# User Rev Content
1 eulisse 1.3 ### RPM external mysql 5.0.18
2 eulisse 1.5 ## INITENV +PATH LD_LIBRARY_PATH %i/lib/mysql
3    
4 eulisse 1.3 #Different download locations according to the version.
5    
6     %if "%(echo %v | cut -d. -f1)" == "4"
7     %define source http://downloads.mysql.com/archives/mysql-4.0/%n-%v.tar.gz
8     %else
9     %define source http://mysql.belnet.be/Downloads/MySQL-5.0/mysql-%v.tar.gz
10     %endif
11    
12     Source: %source
13 eulisse 1.6 # Let's fake the fact that we have perl (DBI) so that rpm does not complain.
14     Provides: perl(DBI)
15 argiro 1.1
16     %prep
17     %setup -n %n-%v
18     %ifos darwin
19     # There's for some reason a "-traditional-cpp", which breaks with GCC 3.3
20     # so remove it. (FIXME: check if this is solved in a newer version.)
21     perl -p -i -e 's/-traditional-cpp/-no-cpp-precomp/g' configure.in configure
22     %endif
23    
24     %build
25     CFLAGS=-O3 CXX=gcc CXXFLAGS="-O3 -felide-constructors -fno-exceptions -fno-rtti" \
26     ./configure --prefix=%i --with-extra-charsets=complex \
27     --enable-thread-safe-client --enable-local-infile
28 eulisse 1.2 make %makeprocesses
29 eulisse 1.8 %install
30     make install
31     perl -p -i -e "s|^#!.*perl|#!/usr/bin/env perl|" $(grep -r /usr/local/bin/perl . | cut -d: -f1)
32 eulisse 1.4 %post
33     %{relocateConfig}bin/msql2mysql
34     %{relocateConfig}bin/mysqlaccess
35     %{relocateConfig}bin/mysqlbug
36     %{relocateConfig}bin/mysql_config
37     %{relocateConfig}bin/mysqld_multi
38     %{relocateConfig}bin/mysqld_safe
39     %{relocateConfig}bin/mysql_fix_privilege_tables
40     %{relocateConfig}bin/mysql_install_db
41    
42