X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f From: "Rod Pemberton" Newsgroups: comp.os.msdos.djgpp Subject: Re: HimemX patch (was Re: Rebuilding 2.04 from source) Date: Sat, 6 Jul 2013 11:56:06 -0400 Organization: Aioe.org NNTP Server Lines: 87 Message-ID: References: <713e6460-511d-4b27-a9a5-b07cc63fd02d AT googlegroups DOT com> NNTP-Posting-Host: CNsg4fVcCsvs3UaOgZtQCw.user.speranza.aioe.org X-Complaints-To: abuse AT aioe DOT org X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.2001 X-Notice: Filtered by postfilter v. 0.8.2 X-Newsreader: Microsoft Outlook Express 6.00.2800.2001 X-Priority: 3 X-MSMail-Priority: Normal Bytes: 4512 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com wrote in message news:bf73996e-8743-4bf7-a5f6-56df4a937263 AT googlegroups DOT com... > Just for completeness (at always seeing such annoying issues), > here's the deal: > > ============================================= > (Fri Jul 05, 11:09 AM) /tmp/doydoy # cat blah.sh > #!/bin/sh > md5sum [hH]imem* > sed -i~ -e '1,/BEGIN---cut-here--/d' -e '/END---cut-here--/,$d' > himem_rp.dif > unzip -qja Himem332.zip SOURCE/HIMEMX.ASM > patch -l HIMEMX.ASM himem_rp.dif -o himemx.rod > unzip -qjao himem334-unofficial-rp.zip SOURCE/HIMEMX.ASM > diff -was HIMEMX.ASM himemx.rod > > (Fri Jul 05, 11:10 AM) /tmp/doydoy # blah.sh > 7ded523745ae836452402e402f02a11b Himem332.zip > 866e5d607f18b6bda49ab54f621d2e0f himem334-unofficial-rp.zip > 22ae67d811af236c5496c53e383a9b2b himem_rp.dif > patching file HIMEMX.ASM > Files HIMEMX.ASM and himemx.rod are identical > ============================================= > Uh, okay... > I don't use patch as much as diff, hence why I wasn't > remembering the -l switch to ignore whitespace (same > as diff -w). But yes, also source and patch must > (apparently) match in line endings too. Instead of > manually running dos2unix, here I just let Info-Zip > fix that for me (-a to auto-convert). > > This seems unavoidable, however, as some files (e.g. > GNU makefiles or Python or whatever) are sensitive > to changes in whitespace and might break otherwise. Well, I tested the patch against a fresh unzip of Japheth's 3.32. Of course, that was prior to me posting the patch, which may have whitespace issues after posting... I didn't test the patch after posting. But, I don't think that's an issue or hope it's not. (?) This could be affected by your browser or editor too. The posted patch is against Japheth's 3.32 assembly file which doesn't have spaces at the end-of-line (EOL) trimmed. Using it will result in a patched version of 3.32 (to 3.34) with whitespaces untrimmed. I chose to do that because I had hoped Japheth would host 3.34 and his prior versions have untrimmed whitespaces. My source in the 3.34 zip has EOL whitespaces trimmed. IIRC, it also has one section of text realigned slightly with space padding. Anyway, you shouldn't need the -l for patch. You can use diff -w to remove the effects of whitespace, when comparing the patched source (3.32->3.34) and the source in 3.34 zip. All you should have to do is unzip Japheth's 3.32 and run patch with the diff: patch -p0 himemx.asm himemx.dif (Where, himemx.asm is from Japheth's 3.32 and himemx.dif is the posted diff without the delimiting lines.) This process was mentioned in the comp.os.msdos.programmer post: https://groups.google.com/d/msg/comp.os.msdos.programmer/jKuJKgUXRNU/6Rkm0bwB_iYJ Then, once you have the new asm file, run build.bat, which is also from Japheth's 3.32. http://www.japheth.de/Jemm.html As mentioned in the c.o.m.d. post, I used JWasm v2.10 (4/20/2013). http://www.japheth.de/JWasm.html Of course, you've got a zip now with a complete source file that's both patched and trimmed of EOL whitespace. So, I'm not sure exactly what your post is in regards to... i.e., the patch is completely unecessary now. Rod Pemberton