Solved

diff files

Posted on 1998-11-27
4
247 Views
Last Modified: 2013-11-13
How can I 'install' a diff file with a lot of patches inside.
Say, redhat.diff
I keep getting rejected
0
Comment
Question by:bod_1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 1

Accepted Solution

by:
terrycj earned 50 total points
ID: 1638628
> I keep getting rejected.

i guess this means you are using patch?

try the -p# argument to patch, where # is the number
of leading slashes to ignore in filenames in the diff
file. it's important.

e.g., if you're sitting in a directory with a file
called prog.c but your diff file was made by someone
with the command diff /usr/src/prog.c /usr/src/prog.c.orig,
then the diff file is going to mention /usr/src/prog.c
instead of simply prog.c. So you tell patch to ignore
the /usr/src/ part of the diff output via:

patch -p3 < diff-file

Terry.

0
 

Author Comment

by:bod_1
ID: 1638629
There's a patch that I got with RedHat's libc rpm.  It has the BSD ioctl's so I'm trying to patch sgtty.h with it.  I tried
   patch -p[3 4 5] < /.../redhat.diff
from /usr/include but patch keeps saying all of the hunks fail.?
0
 

Author Comment

by:bod_1
ID: 1638630
Guess it's a bad patch or something.?
0
 

Author Comment

by:bod_1
ID: 1638631
just did it by hand, it works
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Among others, I monitor the Windows Installer zone and Installer zone. I find that many of the questions could be answered much more quickly if a Windows Installer verbose log were submitted with the question.   However, I do not always have t…
SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question