Re: printing
"Richard" ([email protected] via blfs-support Mailing List) <[email protected]> Fri, 16 Jan 2026 15:01:17 -0500
| Newsgroups | gmane.linux.lfs.beyond.support |
|---|---|
| Message-ID | <[email protected]> |
On 1/16/26 2:44 PM, Bruce Dubbs ([email protected] via blfs-support Mailing List) wrote: > On 1/16/26 1:21 PM, Richard ([email protected] via blfs-support Mailing > List) wrote: >> On 1/16/26 11:59 AM, Bruce Dubbs ([email protected] via >> blfs-support Mailing List) wrote: >>> On 1/16/26 9:02 AM, Richard ([email protected] via blfs-support Mailing >>> List) wrote: >>>> On 1/15/26 10:52 AM, Bruce Dubbs ([email protected] via >>>> blfs-support Mailing >>> >>> [snip] >>> >>>>>> I am the one who is missing something, I have never made >>>>>> a patch before so I would have some learning to do. It was >>>>>> just easier for me to copy the files. >>> >>>>> Just put the original expanded tarball into a directory, say >>>>> /tmp/hplip.orig, and copy that to /tmp/hplip.new. Then copy the >>>>> modified files to /tmp/hplip.new. >>>>> >>>>> Make a patch file with: >>>>> >>>>> cd /tmp >>>>> diff -Naur /tmp/hplip.orig /tmp/hplip.new > hplip-3.??.??.patch >>> >>>> Thanks for your help! >>>> >>>> I've made a patch that I tested, and I also have written up >>>> a hint for my hplip fix. How can I submit the hint and >>>> the patch? From the documentation on linuxfromscratch.org >>>> it sounds like I am supposed to submit them first to a mailing >>>> list. >>> >>> Just reply to this email and attach the hint. > >> Here they are. > > Excellent. I added them to the hints repository. > > -- Bruce > > I noticed a couple minor errors in the hint text, could you replace the .txt file with this one? Sorry for the trouble. Richard -- http://lists.linuxfromscratch.org/sympa/info/blfs-support Unsubscribe: See the above information page
hplip-3.25.8_fix.txt
(text/plain, 4.3 KB)
AUTHOR: Richard Mains <[email protected]> DATE: 2026-01-16 LICENSE: GNU GENERAL PUBLIC LICENSE SYNOPSIS: Fixes for building hplip-3.25.8 ATTACHMENTS: https://www.linuxfromscratch.org/hints/downloads/files/ATTACHMENTS/hplip-3.25.8_fix.patch HINT: I built blfs-12.4 according to the stable book, including all the packages I thought are involved with printing. Because I have two HP printers I also needed to install hplip, which is mentioned in the blfs-12.4 book but is not supported. For hplip I also needed to install net-snmp, which is also mentioned but not supported. I installed net-snmp (from http://www.net-snmp.org/) as follows: unzip net-snmp-5.9.4.zip cd net-snmp-5.9.4 # answer questions during configure ./configure make make install At the time, the latest source code version was hplip-3.25.8.tar.gz. I was able able to run .configure (along with various options) without any problems, but "make" always ended with errors, of which there were many. (I also ran "make -d" instead of "make", which gives a lot more debugging information). I ended up finding make errors in 13 different files, but unfortunately when "make" encountered any errors in a file it would stop, so I had to first try to correct the errors in that particular file and then run "make" again to find errors in the next file. Most of the errors were due to implicit function declarations, which gcc now flags as errors, but there were some other issues as well. I am not a C expert, although I do have a lot of experience programming at a basic level. Its convoluted use of functions and pointers can sometimes make my head spin. So I can't guarantee that all of my corrections are 100% correct. In many cases the fixes were straight-forward, but for other ones I had to make my "best guess" to correct the problem. All I can say for certain is that the fixes allowed me to build the package and to use my printers (although I still haven't been able to get the scanner part of my HP7602 all-in-one printer to work in blfs). With the help of the blfs-support mailing list, I was able to upload a blfs hint and a patch file (hplip-3.25.8_fix.patch, found in the attachments to the hints) which implements the changes that I made in the hplip-3.25.8 source code. I also identified the changes with comments in each of the altered files. The comment blocs all begin with "rkm mods" and end with "end rkm mods". (Note that "end rkm mods" does not necessarily mean that there are no other modifications further along in the files, it just indicates the end of that particular bloc. Also, in one case where many lines had the same change, I didn't surround each line with comments, but rather I included the line: Replaced every instance of "SANE_Char**" with "void *" within a comment bloc). There are changes in the following files, assuming you are in the expanded hplip-3.25.8 directory: prnt/cupsext/ scan/sane/ scan/sane/ io/hpmud io/hpmud io/hpmud prnt/hpcups/ scan/sane/ scan/sane/ pcard/pcardext/ prnt/hpps/ scan/sane/ledmi.h scan/sane/orblite.c For my system, I built and installed hplip-3.25.8 using the following ./configure options: ./configure --enable-pp-build --enable-hpijs-install --enable-hpijs-only-build=no --enable-new-hpcups --enable-hpcups-install --enable-qt4=no --prefix=/usr I also tested "make" with these options that were suggested on the blfs-support mailing list, but I didn't install them: ./configure --prefix=/usr --enable-pp-build ./configure --prefix=/usr --sysconfdir=/etc --enable-cups-ppd-install Both of these also allowed "make" to build successfully. Here are the steps that I used to build and install hplip-3.25.8 on my system: cp hplip-3.25.8_fix.patch /sources cp hplip-3.25.8.tar.gz /sources cd /sources tar xvzf hplip-3.25.8.tar.gz cd hplip-3.25.8 patch -p1 < ../hplip-3.25.8_fix.patch ./configure --enable-pp-build --enable-hpijs-install --enable-hpijs-only-build=no --enable-new-hpcups --enable-hpcups-install --enable-qt4=no --prefix=/usr make (as root:) make install I was surprised that the released hplip-3.25.8 source code had so many issues, which leads me to suspect that there may be something I am missing that could avoid these problems. If anyone knows of a simpler fix I would love to know about it. I hope that this hint will be helpful for other hplip users. And I hope that future releases of hplip will not have such problems!