[BACK]Return to Makefile.in CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / pkgtools / pkg_install / files / delete

File: [cvs.NetBSD.org] / pkgsrc / pkgtools / pkg_install / files / delete / Makefile.in (download)

Revision 1.13, Wed Feb 25 16:29:08 2009 UTC (11 years, 3 months ago) by joerg
Branch: MAIN
CVS Tags: pkgsrc-2009Q4-base, pkgsrc-2009Q4, pkgsrc-2009Q3-base, pkgsrc-2009Q3, pkgsrc-2009Q2-base, pkgsrc-2009Q2, pkgsrc-2009Q1-base, pkgsrc-2009Q1
Changes since 1.12: +3 -3 lines

Rewrite pkg_delete to expand the list of packages to delete first and
reorder it if necessary. It will bail out if it knows in advance that it
can't remove a package. It will also fail for errors while removing one
package, unless forced. Add an option to remove automatically installed
packages that are no longer used.

The pkgviews support is kept, but untested. The error handling for
pkgviews most of all is as weak as before.

Basic review from hubertf@, man page changes by bad@.

# $NetBSD: Makefile.in,v 1.13 2009/02/25 16:29:08 joerg Exp $

srcdir=		@srcdir@

prefix=		@prefix@
exec_prefix=	@exec_prefix@
sbindir=	@sbindir@
mandir=		@mandir@
datarootdir=	@datarootdir@

man1dir=	$(mandir)/man1
cat1dir=	$(mandir)/cat1

CC=		@CC@
CCLD=		$(CC)
LIBS=		-linstall @LIBS@
CPPFLAGS=	@CPPFLAGS@ -I. -I$(srcdir) -I../lib -DBINDIR=\"$(sbindir)\"


PROG=		pkg_delete

OBJS=		pkg_delete.o

all: $(PROG)

	$(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) -c $<

$(PROG): $(OBJS)
	$(CCLD) $(LDFLAGS) -o $@ $(OBJS) $(LIBS)

	rm -f $(OBJS) $(PROG)

	$(INSTALL) -m 755 -d ${DESTDIR}$(sbindir)
	$(INSTALL) -m 755 -d ${DESTDIR}$(man1dir)
	$(INSTALL) -m 755 -d ${DESTDIR}$(cat1dir)
	$(INSTALL) $(PROG) ${DESTDIR}$(sbindir)/$(PROG)
	$(INSTALL) -m 444 $(PROG).1 ${DESTDIR}$(man1dir)/$(PROG).1
	$(INSTALL) -m 444 $(PROG).cat1 ${DESTDIR}$(cat1dir)/$(PROG).0