Changes between Initial Version and Version 1 of RebuildRpms


Ignore:
Timestamp:
05/08/06 13:34:25 (12 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • RebuildRpms

    v1 v1  
     1Many RPMs rebuild are not available for RHEL, here is a rough guide on rebuilding RPMs for RHEL. 
     2 
     3Repoview: http://fedoraproject.org/extras/3/i386/repodata/repoview/fedora-rpmdevtools-0-1.0-1.html 
     4 
     5== Nvidia and ATI drivers and kernel modules == 
     6 
     7livna.org has an excellent guide at http://rpm.livna.org/kernel-modules.html 
     8 
     9For RHEL4 use FC3 SRPMs from [http://rpm.livna.org/fedora/3/i386/SRPMS.unstable/?C=M;O=D] 
     10 
     11{{{ 
     12adduser machbuild 
     13up2date qt-devel kernel-devel kernel-hugemem-devel 
     14su - machbuild 
     15# get the driver and src 
     16mkdir driver 
     17mkdir srpm 
     18wget http://rpm.livna.org/fedora/3/i386/RPMS.unstable/ati-fglrx-8.8.25.1-0.lvn.4.3.i386.rpm 
     19mv ati-fglrx-8.8.25.1-0.lvn.4.3.i386.rpm driver/ 
     20wget http://rpm.livna.org/fedora/3/i386/SRPMS.unstable/ati-fglrx-8.8.25.1-0.lvn.4.3.src.rpm 
     21mv ati-fglrx-8.8.25.1-0.lvn.4.3.src.rpm srpm/ 
     22~/bin/ati-kernel-module.sh 
     23exit 
     24rpm -Uhv /home/machbuild/driver/*rpm 
     25rpm -Uhv /home/machbuild/latest/kernel-module*rpm 
     26}}} 
     27 
     28The `ati-kernel-module.sh` script does this: 
     29{{{ 
     30#!/bin/sh 
     31NNAME="$(date +%Y%m%d)-$(uname -r)" 
     32cd 
     33fedora-buildrpmtree 
     34rpm -ihv srpm/*rpm 
     35rpmbuild -ba rpmbuild/SPECS/ati-fglrx.spec --target $(uname -m) --without driverp 
     36mkdir $NNAME 
     37rm -f latest 
     38ln -s $NNAME latest 
     39mv rpmbuild/RPMS/i686/*rpm latest 
     40rm -Rf rpmbuild 
     41}}} 
     42 
     43Whenever you install a new kernel you should run the `ati-kernel-module.sh` script to build the new kernel module. 
     44You do not need a new driver each time. X will work without a kernel module, but you will not have DRI support. 
     45Check `/var/log/Xorg.0.log` for a "DRI initialization failed!" message. 
     46 
     47After installing the driver if X does not work check `/etc/X11/xorg.conf` for problems. 
     48I've needed to change the `DefaultDepth` and display `Modes` to something reasonable  
     49(24 and 1280x1024). 
     50 
     51 
     52 
     53== JPackage RPMs of Java software == 
     54 
     55http://jpackage.org/ 
     56 
     57Java is a popular programming language, but since running Java applications  
     58usually requires a proprietary interpreter, using Linux as a platform for  
     59developing Java applications has been difficult. The JPackage Project aims  
     60to make the process simpler.  
     61 
     62First import the JPackage RPM key: 
     63{{{ 
     64wget http://www.jpackage.org/jpackage.asc     
     65rpm --import jpackage.asc 
     66}}} 
     67Then, add the JPackage repositories to `/etc/sysconfig/rhn/sources` 
     68{{{ 
     69cat >> /etc/sysconfig/rhn/sources <<EOF 
     70yum jpackage16-generic http://mirrors.dotsrc.org/jpackage/1.6/generic/free/ 
     71yum jpackage16-rhes-4 http://mirrors.dotsrc.org/jpackage/1.6/redhat-el-4.0/free/ 
     72EOF 
     73}}} 
     74Now you can easily install packages from JPackage. But wait! Jpackage doesn't 
     75have permission to distribute Java itself or several other packages, so how do 
     76you get those? The answer is the JPackage "non-free" section which provide 
     77SRPMs and some small tips on where to get the source files. Often it takes  
     78some clicking around on a confusing Sun webpage to find the download. It can 
     79be helpful to install the SRPM and see where the build fails just to find out 
     80the name of the file you're looking for: 
     81{{{ 
     82rpmbuild -ba rpmbuild/SPECS/java3d.spec  
     83error: File /home/brainj3d/rpmbuild/SOURCES/java3d-sdk-1.3.2-linux-i386.bin: No such file or directory 
     84}}} 
     85 
     86After you find the download, install the SRPM and put the source file in  
     87`rpmbuild/SOURCES/`. Here's an example with Java3d: 
     88 
     89{{{ 
     90fedora-buildrpmtree  
     91wget http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/java3d-1.3.2-1jpp.nosrc.rpm 
     92rpm -ihv java3d-1.3.2-1jpp.nosrc.rpm 
     93less rpmbuild/SPECS/java3d.spec # find the source, click through agreements, etc. 
     94mv java3d-sdk-1.3.1-linux-i386.bin rpmbuild/SOURCES/ 
     95rpmbuild -ba --without javadoc rpmbuild/SPECS/java3d.spec  
     96}}}