Ruby
From CBLFS
| Download Source: | ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.1-p376.tar.bz2 |
|---|
Introduction to Ruby
Project Homepage: Unknown
Dependencies
Optional
Non-Multilib
Test Suite Note: You will need to install ruby for make check to succeed fully. A number of tests will fail if you run the test suite prior to installing ruby.
Compile the package:
./configure --prefix=/usr \
--enable-shared --enable-pthread \
--enable-install-doc &&
make
Install the package
make install
Multilib
32Bit
Compile the package:
CC="gcc ${BUILD32}" ./configure --prefix=/usr \
--enable-shared --enable-pthread \
--enable-install-doc --host=${CLFS_TARGET32} &&
make
Install the package
make install &&
mv -v /usr/bin/ruby{,-32} &&
ln -sfv ../i686-linux/ruby/config.h /usr/include/ruby-1.9.1/ruby/config-32.h
N32
Compile the package:
sed -i "s:/lib/ruby:/lib32/ruby:g" configure &&
CC="gcc ${BUILDN32}" ./configure --prefix=/usr \
--libdir=/usr/lib32 --enable-shared \
--enable-pthread --enable-install-doc &&
make
Install the package
make install &&
mv -v /usr/bin/ruby{,-n32} &&
ln -sfv ../i686-linux/ruby/config.h /usr/include/ruby-1.9.1/ruby/config-n32.h
64Bit
Compile the package:
sed -i "s:/lib/ruby:/lib64/ruby:g" configure &&
CC="gcc ${BUILD64}" ./configure --prefix=/usr \
--libdir=/usr/lib64 --enable-shared \
--enable-pthread --enable-install-doc &&
make
Install the package
make install &&
mv -v /usr/bin/ruby{,-64} &&
ln -sfv multiarch_wrapper /usr/bin/ruby &&
ln -sfv ../x86_64-linux/ruby/config.h /usr/include/ruby-1.9.1/ruby/config-64.h
Creating a Stub Header (Multilib Only)
Creating a Generic Stub Header
cat > /usr/include/ruby-1.9.1/ruby/config.h << "EOF"
/* config.h - Stub Header */
#ifndef __STUB__CONFIG_H__
#define __STUB__CONFIG_H__
#if defined(__x86_64__) || \
defined(__sparc64__) || \
defined(__arch64__) || \
defined(__powerpc64__) || \
defined (__s390x__)
# include "config-64.h"
#else
# include "config-32.h"
#endif
#endif /* __STUB__CONFIG_H__ */
EOF
Creating a Stub Header For Mips
cat > /usr/include/ruby-1.9.1/ruby/config.h << "EOF" /* config.h - Stub Header */ #ifndef __STUB__CONFIG_H__ #define __STUB__CONFIG_H__ #include <sgidefs.h> #if (_MIPS_SIM == _ABIO32) # include "config-32.h" #elif (_MIPS_SIM == _ABIN32) # include "config-n32.h" #elif (_MIPS_SIM == _ABI64) # include "config-64.h" #endif #endif /* __STUB__CONFIG_H__ */ EOF