From owner-freebsd-ports@freebsd.org Wed Jul 12 02:38:38 2017 Return-Path: Delivered-To: freebsd-ports@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 8EDB7DB1038 for ; Wed, 12 Jul 2017 02:38:38 +0000 (UTC) (envelope-from gurenchan@gmail.com) Received: from mail-pf0-x22c.google.com (mail-pf0-x22c.google.com [IPv6:2607:f8b0:400e:c00::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 627B575014 for ; Wed, 12 Jul 2017 02:38:38 +0000 (UTC) (envelope-from gurenchan@gmail.com) Received: by mail-pf0-x22c.google.com with SMTP id q86so5296206pfl.3 for ; Tue, 11 Jul 2017 19:38:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=ELacpgr9sbDYxu33aTkYjmBQoH/P4Jtv1mz6LsnXYrI=; b=tcRV7BwhN/yhx5mjOYvnGfLO/HQNMM525TiP4JjQjZQ4OilSUtpUwrm31EDEPGxIQD +ApGKTcIbBQmRtJ4G3MgHLUk/v5wJhmG2exmz/iwn6qrCsSLSnHbUloDNntEE/MhfqM/ Y6nf50WT71/n2bzWLuZO/RoWXCQ4iXUAYNmuZc++BPRDksWuOoSJ5txh3c4ES3w7l5sb h0zPYIoG9pf8G8AWdUhO9SJZdqTiaM+1lZZFCkdNlGxMX4zywaKA2GZ3uSThkQ2JPXQt PKXbBpASrIPI6TDtr6Wd7m3gGgiF5L7vRZz+pkdOIUrXDkpK66tUiwPvtVQLaTPl/v6H 9M4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=ELacpgr9sbDYxu33aTkYjmBQoH/P4Jtv1mz6LsnXYrI=; b=drEhWNQJ52biL5Iq9nCR1wwbU7NzE0jwAI7ZwA7nzE98cOyFdH8xJ5z5p0utMawROU 5muZZZ3tmB8z3PPpoX5zZjZi/8pCENKFbx9+xA2CqE4UL+1zi91xqE1+j/O+3cprJwQM pKjf/RlREoP5dOrzEQyM4INRWOahlaCGJPeMLUgIGSGMnwuGkOU6z1oetkR29aPET0/R 92xuU46gl3Sr3uJLBVglLD8s3Ar5R8U3mdWYj2axuM/JL5snd9SCWtQscbtZWGRxdG8r 9FHxy57kBHXaq4hzR76GVEGSDHpoVNrU5nGzutuf38rWFw3KlgWwBpu/DISXeOanty7u UK5g== X-Gm-Message-State: AIVw1139ETAiq028NPwnqyARIsSv8McVz72/pERQI6fFZQXeTaI/7QJ0 TmRIXMEj8Bp9v30oJZTsA63m7vn69T5C X-Received: by 10.99.120.193 with SMTP id t184mr1543189pgc.35.1499827117711; Tue, 11 Jul 2017 19:38:37 -0700 (PDT) MIME-Version: 1.0 Received: by 10.100.165.137 with HTTP; Tue, 11 Jul 2017 19:38:37 -0700 (PDT) From: blubee blubeeme Date: Wed, 12 Jul 2017 10:38:37 +0800 Message-ID: Subject: Writing a port make deinstall To: freebsd-ports@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Jul 2017 02:38:38 -0000 Hello FreeBSD ports team I am writing a Makefile to install a port I've written this much so far PORTNAME= epson-inkjet-printer-201401w PORTVERSION= 201401w PORTREVISION= 1 PORTEPOCH= 0 CATEGORIES= print MASTER_SITES= https://download3.ebz.epson.net/dsc/f/03/00/03/45/41/d95c03482376873661d7a8d4c165b385cd082cf3/:amd64 \ https://download3.ebz.epson.net/dsc/f/03/00/03/45/41/0c527f1eef727e350302db951a45d31319ee501b/:i386 DISTFILES_amd64= epson-inkjet-printer-201401w-1.0.0-1lsb3.2.x86_64.rpm:amd64 DISTFILES_i386= epson-inkjet-printer-201401w-1.0.0-1lsb3.2.i486.rpm:i386 LICENSE= GPLv2 DIST_SUBDIR= ${PORTNAME}/${PORTVERSION} COMMENT= CUPS filter for Seiko Epson Color Ink Jet Printers RESTRICTED= GNU Lesser General Public License version 2.1. \ This program links the following object codes \ which are distributed under the conditions of \ SEIKO EPSON CORPORATION SOFTWARE LICENSE AGREEMENT. \ *libEpson_201401w.so.1.0.0 \ *libEpson_201401w.MT.so.1.0.0 NO_BUILD= yes NO_WRKSUBDIR= yes PLIST_SUB= LINUXBASE=${LINUXBASE} USES= linux USE_LINUX= cups-libs jpeg do-install: (gunzip ${WRKSRC}/opt/${PORTNAME}/ppds/Epson/*) (find ${WRKSRC}/opt/${PORTNAME}/ppds/Epson -type f -exec sed -i "" 's/\/opt\/epson/\/compat\/linux\/opt\/epson/g' {} \;) (cp -r ${WRKSRC}/opt/${PORTNAME} /compat/linux/opt/) (ln -s /compat/linux/opt/${PORTNAME}/ppds/Epson /usr/local/share/cups/model/) #cleanup? # rm -r /usr/local/share/cups/model/Epson # rm -r /compat/linux/opt/epson-inkjet-printer-201401w/ # rm -r ${WRKSRC} .include I don't know how to make the cleanup work. This Makefile passes works for installing the drivers and they work but doing make deinstall clean doesn't remove the files that I placed, the symlinks, etc. How do I properly write this Makefile so deinstall works as expected? Best, Owen