LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva
User Name
Password
Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux.

Notices



Reply
 
Search this Thread
Old 11-15-2004, 04:18 PM   #1
cbonar
Member
 
Registered: Apr 2004
Location: Paris, FRANCE
Distribution: Kubuntu + Debian
Posts: 53

Rep: Reputation: 15
Searching for util-linux sources


Hi

I want to apply a patch to 'mount'. The patch (can't post the URL because I don't have enough posts :[ ) affects 'mount/get_label_uuid.c' and 'mount/linux_fs.h' from the 'util-linux' package.

I can't find the sources for this package in my distrib (community). Where to find them ?

------
$ uname-a
Linux dhcp-1038-150 2.6.8.1-10mdksmp #1 SMP Wed Sep 8 16:41:52 CEST 2004 i686 Intel(R) Pentium(R) 4 CPU 3.00GHz unknown GNU/Linux

$ rpm -q util-linux
util-linux-2.12a-4mdk
------

++
 
Old 11-15-2004, 08:50 PM   #2
opjose
Senior Member
 
Registered: Sep 2004
Location: Outlying D.C.
Distribution: Mandriva
Posts: 2,090

Rep: Reputation: 46
These are available on the URPMI repositories in the SRC directories.

Use an FTP client to connect to one of the respositories

(See: http://www.zebulon.org.uk/urpmi_en.html)

Then climb the tree until you find the respective SRC directory which has all of the .src.rpm files which you can use to rebuild the utils.

This has the advantage of keeping you in the Mandrake arena as well in that you will be working on exactly the same files Mandrake uses to compile their version of the utils.
 
Old 11-17-2004, 03:58 PM   #3
cbonar
Member
 
Registered: Apr 2004
Location: Paris, FRANCE
Distribution: Kubuntu + Debian
Posts: 53

Original Poster
Rep: Reputation: 15
Thank you, now I'm sure I've done the right thing (found this package on one of those servers).
But now, I've got many files under "/usr/src/RPM/SOURCES" matching "util-linux*".
Most of them are patches, and one seems to be the main archive : "util-linux-2.12a.tar.bz2".
When I untar this package and do a configure/make, I got compiling errors.
Should I apply all those patches in order to have a good version ?

------
$ ls /usr/src/RPM/SOURCES/util-linux*
util-linux-2.10r-clock-1.1-ppc.patch.bz2
util-linux-2.10s-clock-syntax-ppc.patch.bz2
util-linux-2.10s-s390x.patch.bz2
util-linux-2.11a-gecossize.patch.bz2
util-linux-2.11b-s390x.patch.bz2
util-linux-2.11f-rawman.patch.bz2
util-linux-2.11h-fix-compilation.patch.bz2
util-linux-2.11m-2gb.patch.bz2
util-linux-2.11m-cmos-alpha.patch.bz2
util-linux-2.11m-fdisk-fixes.patch.bz2
util-linux-2.11m-kudzu.patch.bz2
util-linux-2.11m-mcookie-urandom.patch.bz2
util-linux-2.11m-nolock-docs.patch.bz2
util-linux-2.11o-chfn-lsb-usergroups.patch.bz2
util-linux-2.11o-nochkdupexe.patch.bz2
util-linux-2.11r-miscfixes.patch.bz2
util-linux-2.11t-alpha-buildfix.patch.bz2
util-linux-2.11t-dumboctal.patch.bz2
util-linux-2.11t-mkfsman.patch.bz2
util-linux-2.11t-moretc.patch.bz2
util-linux-2.11t-swapoff.patch.bz2
util-linux-2.11x-procpartitions-37436.patch.bz2
util-linux-2.11x-set-as-encrypted.patch.bz2
util-linux-2.11x-swapon.patch.bz2
util-linux-2.11y-nfsmount.patch.bz2
util-linux-2.11y-retryudp.patch.bz2
util-linux-2.12a-biarch-utmp.patch.bz2
util-linux-2.12a-compilation.patch.bz2
util-linux-2.12a-cryptoapi-load-module.patch.bz2
util-linux-2.12a-mdkconf.patch.bz2
util-linux-2.12a-mount-remove-silly-options-in-auto.patch.bz2
util-linux-2.12a.tar.bz2
util-linux-2.12a-users.patch.bz2
util-linux-2.12-chfn-chsh-unckecked-return-error.patch.bz2
util-linux-2.12-fix-ioctl.patch.bz2
util-linux-2.12-kbdrate-period-fix.patch.bz2
util-linux-2.12-largefile.patch.bz2
util-linux-2.12-loop-AES-v2.0e.patch.bz2
util-linux-2.12-losetup-gzloop.patch.bz2
util-linux-2.12-losetup-try-LOOP_CHANGE_FD-when-loop-already-busy.patch.bz2
util-linux-2.12-lower-LOOP_PASSWORD_MIN_LENGTH-for-AES.patch.bz2
util-linux-2.12pre-autodav.patch.bz2
util-linux-2.12-swapon-skip-encrypted.patch.bz2
util-linux-2.12-swaponsymlink-57301.patch.bz2
util-linux-2.12-user_label_umount.patch.bz2
util-linux-2.7-chfn.pamd
util-linux-2.7-chsh.pamd
util-linux-2.7-login.pamd
util-linux-2.9v-nonroot.patch.bz2
------
 
Old 11-17-2004, 06:31 PM   #4
opjose
Senior Member
 
Registered: Sep 2004
Location: Outlying D.C.
Distribution: Mandriva
Posts: 2,090

Rep: Reputation: 46
There are command line parameters that will run the rpm rebuild routines

(ala rpm --rebuild util-linux-xxx.src.rpm ) but not delete the files after they have been compiled (of course you could always stop the above manually!).

This leaves the patched source tree sitting in

/usr/src/rpm/RPMS/src or thereabouts.

Most of this is available via RPM documentation.

It will automatically leave you with a patched and ready to compile source tree with the Make, etc. configured exactly the way you need it for Mandrake.

Then you make any changes and let the script complete.

You can actually end up with a distributable RPM with your patch if you like.
 
Old 11-17-2004, 07:11 PM   #5
cbonar
Member
 
Registered: Apr 2004
Location: Paris, FRANCE
Distribution: Kubuntu + Debian
Posts: 53

Original Poster
Rep: Reputation: 15
Thumbs up

Ok, thanks a lot for the tips, RPM seems more friendly to me now

ps : I've found the exact command :
$ rpm --recompile util-linux-2.12a-5mdk.src.rpm
which leaves the sources and a prepared Makefile in the following directory : /usr/src/RPM/BUILD/util-linux-2.12a/

------
Why the hell am I always doing it the hard way...???
Oh yes... I don't read the docs.

Last edited by cbonar; 11-17-2004 at 07:25 PM.
 
Old 11-17-2004, 08:44 PM   #6
opjose
Senior Member
 
Registered: Sep 2004
Location: Outlying D.C.
Distribution: Mandriva
Posts: 2,090

Rep: Reputation: 46
RPM is great but it has many failings notably with dependacy issues.

That is where urpmi takes over from RPM.

One neat trick is to use URPMI to set up for a compilation.

You can actually pass parameters to RPM from urpmi to say compile a src.rpm file.

URPMI will notice that you do not have the proper developement packages and install EVERYTHING for you from the repositories before it attempts the compilation.

VERY nice...
 
Old 11-18-2004, 08:05 AM   #7
cbonar
Member
 
Registered: Apr 2004
Location: Paris, FRANCE
Distribution: Kubuntu + Debian
Posts: 53

Original Poster
Rep: Reputation: 15
noted.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Encrypted filesystems and util-linux thebell Linux - General 2 05-31-2004 11:16 AM
mount problem with util-linux-2.12a Fonk Linux - Software 6 05-27-2004 09:38 AM
Problem compiling util-linux buboleck Slackware 0 12-21-2003 07:41 AM
util-linux cannot find any headers emu_123 Linux From Scratch 3 11-05-2003 05:19 AM
How do I install util-linux-2.10o rdaves@earthlink.net Linux - Newbie 1 05-27-2001 10:28 AM


All times are GMT -5. The time now is 07:32 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration