From owner-freebsd-questions@freebsd.org Sat Jul 15 12:50:16 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 75647AF9A58 for ; Sat, 15 Jul 2017 12:50:16 +0000 (UTC) (envelope-from tijl@freebsd.org) Received: from mailrelay101.isp.belgacom.be (mailrelay101.isp.belgacom.be [195.238.20.128]) (using TLSv1.2 with cipher RC4-SHA (128/128 bits)) (Client CN "relay.skynet.be", Issuer "GlobalSign Organization Validation CA - SHA256 - G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D77796F4FD for ; Sat, 15 Jul 2017 12:50:15 +0000 (UTC) (envelope-from tijl@freebsd.org) X-Belgacom-Dynamic: yes IronPort-PHdr: =?us-ascii?q?9a23=3AIVG5JBPDVWHQkHdpi/8l6mtUPXoX/o7sNwtQ0KIM?= =?us-ascii?q?zox0Ivr+rarrMEGX3/hxlliBBdydsKMbzbKO+4nbGkU4qa6bt34DdJEeHzQksu?= =?us-ascii?q?4x2zIaPcieFEfgJ+TrZSFpVO5LVVti4m3peRMNQJW2aFLduGC94iAPERvjKwV1?= =?us-ascii?q?Ov71GonPhMiryuy+4ZPebgFKiTanfb9+MAi9oBnMuMURnYZsMLs6xAHTontPde?= =?us-ascii?q?RWxGdoKkyWkh3h+Mq+/4Nt/jpJtf45+MFOTav1f6IjTbxFFzsmKHw65NfqtRbY?= =?us-ascii?q?UwSC4GYXX3gMnRpJBwjF6wz6Xov0vyDnuOdxxDWWMMvrRr0vRz+s87lkRwPpiC?= =?us-ascii?q?cfNj427mfXitBrjKlGpB6tvgFzz5LIbI2QMvd1Y6HTcs4ARWdZUMhfVzJPDJ6/?= =?us-ascii?q?YYQNAeoOMvpXoYbmqlsSrxayGRWgCP/zxjNWgHL9wK000/4mEQHDxAEuAdMOsH?= =?us-ascii?q?bQrN7oKqoSVue1zLLWwjXGdfxW3yz945XPfxA9oPGMX7ZwfNHRx0k1CQzKkEid?= =?us-ascii?q?p5HrMT+P0eQNqWeb4vNmWOmyhWAnrARxrSKuxscqkoTIiIMVykra+ipl3YY1Oc?= =?us-ascii?q?G4R1BhYdK+DJRQsCSaO5NtTcM4RGFopCY6xaMcuZKhYCcKz5EnyhjCYPKEa4iF?= =?us-ascii?q?+hHuWPuLLTtmi39oeKiziwuw/EWk0OHwS8u53EpMoyFYiNfDrGoN2AbW6sWfT/?= =?us-ascii?q?t9+Vqu1iiX2gDI7+FEPVg0la3GK5492rIwloQcsUDEHiLum0X5lquWdkQh+ue2?= =?us-ascii?q?8eTnZa/qpoOdN492jgHyKLghmsu4AeQjLAcOWnKU+eKn1LH5+k35WrpKguU3kq?= =?us-ascii?q?nfrp/aOdwWq62kDwNPzIou5BayAy273NkamXQLNk9JdRCbg4TxPlHBOvH4DfOx?= =?us-ascii?q?g1S2lzdrwujLPqHgApXPKnjOi7nhfaxj5EFC0wUz1s1Q64hTCrEbL/L/QlXxu8?= =?us-ascii?q?DADh8lLwy0xP7qCNtn1owAR22AGbSZP77LvV+R++IgPfKMZJMUuDb6Lfgl/OXj?= =?us-ascii?q?jXEjmVADY6amxoAXZ22iEvRhOUWZbimkvtBUW10XpREzSOiirBvKejdJe3uoFe?= =?us-ascii?q?po/DoyEp6rF6/bR4a8h7rH2z20SM54fGdDX2yNE3OgXIKDQPoJYSSJapt9kz4A?= =?us-ascii?q?fZa7RoIL7j3osxX1nek0ZtHI8zEV4MqwnON+4PfewFRrrWR5?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A2BXAwCiDmpZ/6qz9VFdGgEBAQECAQEBA?= =?us-ascii?q?QgBAQEBFQEBAQECAQEBAQgBAQEBgy9UEIEUjn6PA4FqLAGXaC6FGQKDcEQUAQE?= =?us-ascii?q?BAQEBAQEBAQFqKIIzJAGCQQEFJxMcIxALGAklDyoeBhOKMwysEhGDDzqLGgEBA?= =?us-ascii?q?QEBBQIBJYMohS6DJIMmhzgFkFaOXodKjD98gXSPTJVXNiGBClIwCIdhPjYBhjQ?= =?us-ascii?q?EgjsBAQE?= X-IPAS-Result: =?us-ascii?q?A2BXAwCiDmpZ/6qz9VFdGgEBAQECAQEBAQgBAQEBFQEBAQE?= =?us-ascii?q?CAQEBAQgBAQEBgy9UEIEUjn6PA4FqLAGXaC6FGQKDcEQUAQEBAQEBAQEBAQFqK?= =?us-ascii?q?IIzJAGCQQEFJxMcIxALGAklDyoeBhOKMwysEhGDDzqLGgEBAQEBBQIBJYMohS6?= =?us-ascii?q?DJIMmhzgFkFaOXodKjD98gXSPTJVXNiGBClIwCIdhPjYBhjQEgjsBAQE?= Received: from 170.179-245-81.adsl-dyn.isp.belgacom.be (HELO kalimero.tijl.coosemans.org) ([81.245.179.170]) by relay.skynet.be with ESMTP; 15 Jul 2017 14:49:02 +0200 Received: from kalimero.tijl.coosemans.org (kalimero.tijl.coosemans.org [127.0.0.1]) by kalimero.tijl.coosemans.org (8.15.2/8.15.2) with ESMTP id v6FCn1Ac029634; Sat, 15 Jul 2017 14:49:01 +0200 (CEST) (envelope-from tijl@FreeBSD.org) Date: Sat, 15 Jul 2017 14:49:01 +0200 From: Tijl Coosemans To: "Russell L. Carter" Cc: freebsd-questions@freebsd.org Subject: Re: cups and a Brother HL-L2340DW Message-ID: <20170715144901.1a53e2bc@kalimero.tijl.coosemans.org> In-Reply-To: <9d8aae34-8d78-5a9d-1f0d-adae7d5e7c27@pinyon.org> References: <9d8aae34-8d78-5a9d-1f0d-adae7d5e7c27@pinyon.org> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jul 2017 12:50:16 -0000 On Fri, 14 Jul 2017 18:38:05 -0700 "Russell L. Carter" wrote: > So this printer is the current wirecutter.com recommendation > for best cheap laser printer. After introducing it to dhcpd > so that the IP address is fixed, I was ready to introduce it > to cups. > > Add Printer -> Discovered Network Printers > -> select Brother HL-L2340D series... > > (next screen) Connection: lpd://BRWD80F9967A5AB/BINARY_P1 > > (hit Continue) > > Or Provide a PPD file: Browse... brother-HLL2340D-cups-en.ppd > -> Add Printer > > -> Set Default Options > > Which gives me, after some screen changes: > > Brother_HL-L2340D_series (Idle, Accepting Jobs, Not Shared) > Description: Brother HL-L2340D series > Location: > Driver: Brother HL-L2340D for CUPS (grayscale, 2-sided printing) > Connection: lpd://BRWD80F9967A5AB/BINARY_P1 > Defaults: job-sheets={job_sheets_default} media=iso_a4_210x297mm > sides=one-sided > > I hit ^P, the print dialog comes up, I select this printer, and all > looks good, except if I go look at jobs, I see: > > ID Name User Size Pages State Control > Brother_HL-L2340D_series-124 Unknown Withheld 1k Unknown > canceled at > Fri Jul 14 18:08:00 2017 > > What gives? > > I am on the verge of installing linux on a box to deal with this. I suspect you need to use the official Linux driver from Brother. It should be possible to get this working on FreeBSD using Linux emulation but it'll require some tinkering. Install emulators/linux_base-c6 and print/ghostscript9-agpl-base. Download both the LPR printer driver and CUPSwrapper printer driver here: http://support.brother.com/g/b/downloadlist.aspx?c=us&lang=en&prod=hll2340dw_us_eu_as&os=127 Unpack the rpm packages using tar(1). They contain an /opt directory that you can move to /compat/linux/opt. Inside the directory are some Perl scripts (brother_lpdwrapper_HLL2340D, paperconfigml1 and filter_HLL2340D) where you have to change /usr/bin/perl on the first line into /usr/local/bin/perl. Edit brother_lpdwrapper_HLL2340D to replace line 87 from $PRINTER =~ s/^\/opt\/.*\/Printers\///g; into $PRINTER =~ s/^.*\/Printers\///g; Then create these symbolic links: ln -s /compat/linux/opt/brother/Printers/HLL2340D/cupswrapper/brother_lpdwrapper_HLL2340D /usr/local/libexec/cups/filter/ ln -s /compat/linux/opt/brother/Printers/HLL2340D/cupswrapper/brother-HLL2340D-cups-en.ppd /usr/local/share/cups/model/ More changes may be needed, but this should get you a bit further. The scripts seem to create log files in /tmp so you may want to look there for clues. Also in /var/log/cups.