Compare commits
15 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2ec067cddb | |||
| c662852caf | |||
| 19a3ba19ad | |||
| 4e0421bc32 | |||
| ffe29e224e | |||
| 487060e496 | |||
| 92474ea81d | |||
| 482c8efb58 | |||
| eeaea8ee89 | |||
| 7175591b00 | |||
| 8f71c4fe8b | |||
| e504cf66d3 | |||
| 211fe43fd9 | |||
| 8ac36484c5 | |||
| 5d2b5e0ac0 |
5
INSTALL
5
INSTALL
@@ -1,6 +1,7 @@
|
||||
Installing prt-get
|
||||
------------------
|
||||
|
||||
Installing prt-get is just a matter of
|
||||
meson setup bld --prefix=/usr
|
||||
ninja -C bld
|
||||
ninja -C bld install
|
||||
cd bld && meson compile
|
||||
meson install
|
||||
|
||||
92
doc/FS1843.md
Normal file
92
doc/FS1843.md
Normal file
@@ -0,0 +1,92 @@
|
||||
# Flyspray 1843 notes
|
||||
## Was: Re: Please make the output of prt-get --test more common
|
||||
|
||||
teodor observed that prt-get --test gives two different styles of output.
|
||||
The output style was found to be affected by the number of packages requested
|
||||
on the command line (one versus many), and by whether dependency resolution
|
||||
was toggled (install versus depinst).
|
||||
|
||||
In the case when one package was requested for installation, an early check
|
||||
of /var/lib/pkg/db for the existence of a previous installation would alert the
|
||||
user to the malformed command. No such check of /var/lib/pkg/db was
|
||||
being performed for multiple packages passed on the command line (FS#1910), and
|
||||
so the program continued all the way through executeTransaction() and
|
||||
evaluateResult(), which produced the more verbose output that teodor noted.
|
||||
|
||||
A similar discrepancy could be observed when requesting an **update** of **one**
|
||||
package that was not previously installed, versus an update of **multiple**
|
||||
packages among which there are some not yet installed. You would have seen a
|
||||
terse warning in the first case, and a more verbose output in the second case.
|
||||
|
||||
The softdeps branch in this code base is now more consistent in performing the
|
||||
scan of /var/lib/pkg/db, no matter how many packages are passed as argument.
|
||||
But the mixed-upinst branch collapses the distinction between install and
|
||||
update, always bringing up to date all the ports passed as argument (and their
|
||||
dependencies, unless --nodeps is given), so it can postpone the scan of
|
||||
/var/lib/pkg/db until the step of customizing pkgadd flags for each target.
|
||||
Hence there is no corresponding code in the mixed-upinst branch to solve FS#1910
|
||||
by exiting early with an error message.
|
||||
|
||||
teodor's second observation is more interesting. During dependency resolution,
|
||||
the invalid arguments (ports not found in the active repos) were silently being
|
||||
dropped, rather than being kept in memory for a post-transaction report. If
|
||||
**all** ports passed to a ``depinst`` command are nowhere among the active
|
||||
repositories, then the empty set is what gets used for executeTransaction(),
|
||||
with the predictable result "no package specified for install". Why did we see
|
||||
a different result when running ``install``? Because the calculateDependencies()
|
||||
method was never called, and so executeTransaction() received the entire list
|
||||
of nowhere-to-be-found ports! Iterating through this list of nonexistent ports
|
||||
would populate the missingPackages list, which would then be displayed nicely
|
||||
during the post-transaction summary. This side-effect of toggling dependency
|
||||
resolution could be observed in both the softdeps and the mixed-upinst branch,
|
||||
prior to the commits of 2023-09-15.
|
||||
|
||||
Although we do populate a missingPackages list during calculateDependencies(),
|
||||
the contents of this list were not being included in the post-transaction
|
||||
summary. As the code was originally conceived, executeTransaction() would get
|
||||
a filtered list, with missing packages omitted. This side-effect of ``depinst``
|
||||
violates the principle of least surprise, because users like teodor might
|
||||
justifiably expect toggling dependency resolution to generate a superset of
|
||||
**their argument list** @ARGV, not just a superset of the valid ports in @ARGV.
|
||||
To be more faithful to the principle of least surprise, the softdeps branch now
|
||||
propagates into executeTransaction() even the ports that are not in the repos,
|
||||
so that the post-transaction summary can display them. The mixed-upinst branch
|
||||
does the same, but because it merges ``install`` and ``update``, any requested
|
||||
targets that are already installed and up-to-date will appear in the
|
||||
post-transaction summary under the header "Packages already installed before
|
||||
this run (ignored)".
|
||||
|
||||
With dependency resolution enabled, the list of "Packages already installed
|
||||
before this run (ignored)" often fills up the entire height of a terminal.
|
||||
If we implemented teodor's suggestion and united the list of
|
||||
"Packages not found" with this list --- already often big enough on its own ---
|
||||
then readability of the post-transaction summary would suffer.
|
||||
Two separate lists would offer greater readability in most cases, both for
|
||||
the human eye and for a shell script.
|
||||
|
||||
teodor's proposed heading for a united list, "The following ports were
|
||||
not found/already installed:", did inspire a new way for the softdeps branch
|
||||
to handle FS#1910. All arguments to ``install`` and ``depinst`` will be tested
|
||||
against /var/lib/pkg/db to ensure that they're not already installed, and if
|
||||
all the tests fail then the user is immediately alerted to the malformed
|
||||
command. This preliminary check is simply jw's original design, but extended
|
||||
from one port to many. However, if any of the requested ports is not yet
|
||||
installed, we can go ahead with initRepo() and attempt a less ambitious
|
||||
transaction (limited to a subset of the user's argument list). The program
|
||||
will reach evaluateTransaction() and display what succeeded, as well as what
|
||||
was wrong with the original command.
|
||||
|
||||
The softdeps branch has no corresponding leniency in handling an ``update``
|
||||
command, because the typical scenario for using that command is after
|
||||
running ``prt-get diff``, at which point the user can be expected to know
|
||||
what's on their system and to pass as arguments only the names of packages
|
||||
already installed. So the early exit behaviour of my previous solution to
|
||||
FS#1910 is retained for the ``update`` command. But it's easy to imagine a
|
||||
user passing invalid targets to an ``install`` command, in the absence of
|
||||
any cues from running ``prt-get listinst | grep -E
|
||||
(package1|package2|...|packageN)``, and to handle that possibility it
|
||||
makes sense to parse leniently the arguments passed to ``install``. Users
|
||||
then obtain on the first try, most of what they intended, while also getting
|
||||
an informative list of already-installed packages in the post-transaction report.
|
||||
If they really intended to force the rebuild of those already-installed
|
||||
packages, they can issue a revised command after the first command succeeds.
|
||||
@@ -1,10 +0,0 @@
|
||||
|
||||
man_MANS = prt-get.8 prt-cache.8 prt-get.conf.5
|
||||
|
||||
clean-local:
|
||||
rm -rf *.log *.aux *.toc *.dvi *.idx *.pdf api
|
||||
|
||||
apidoc:
|
||||
doxygen
|
||||
|
||||
EXTRA_DIST = $(man_MANS) coding
|
||||
492
doc/Makefile.in
492
doc/Makefile.in
@@ -1,492 +0,0 @@
|
||||
# Makefile.in generated by automake 1.12.2 from Makefile.am.
|
||||
# @configure_input@
|
||||
|
||||
# Copyright (C) 1994-2012 Free Software Foundation, Inc.
|
||||
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE.
|
||||
|
||||
@SET_MAKE@
|
||||
VPATH = @srcdir@
|
||||
am__make_dryrun = \
|
||||
{ \
|
||||
am__dry=no; \
|
||||
case $$MAKEFLAGS in \
|
||||
*\\[\ \ ]*) \
|
||||
echo 'am--echo: ; @echo "AM" OK' | $(MAKE) -f - 2>/dev/null \
|
||||
| grep '^AM OK$$' >/dev/null || am__dry=yes;; \
|
||||
*) \
|
||||
for am__flg in $$MAKEFLAGS; do \
|
||||
case $$am__flg in \
|
||||
*=*|--*) ;; \
|
||||
*n*) am__dry=yes; break;; \
|
||||
esac; \
|
||||
done;; \
|
||||
esac; \
|
||||
test $$am__dry = yes; \
|
||||
}
|
||||
pkgdatadir = $(datadir)/@PACKAGE@
|
||||
pkgincludedir = $(includedir)/@PACKAGE@
|
||||
pkglibdir = $(libdir)/@PACKAGE@
|
||||
pkglibexecdir = $(libexecdir)/@PACKAGE@
|
||||
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
|
||||
install_sh_DATA = $(install_sh) -c -m 644
|
||||
install_sh_PROGRAM = $(install_sh) -c
|
||||
install_sh_SCRIPT = $(install_sh) -c
|
||||
INSTALL_HEADER = $(INSTALL_DATA)
|
||||
transform = $(program_transform_name)
|
||||
NORMAL_INSTALL = :
|
||||
PRE_INSTALL = :
|
||||
POST_INSTALL = :
|
||||
NORMAL_UNINSTALL = :
|
||||
PRE_UNINSTALL = :
|
||||
POST_UNINSTALL = :
|
||||
subdir = doc
|
||||
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
|
||||
$(top_srcdir)/mkinstalldirs
|
||||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||
am__aclocal_m4_deps = $(top_srcdir)/configure.in
|
||||
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||
$(ACLOCAL_M4)
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
CONFIG_HEADER = $(top_builddir)/config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
CONFIG_CLEAN_VPATH_FILES =
|
||||
SOURCES =
|
||||
DIST_SOURCES =
|
||||
am__can_run_installinfo = \
|
||||
case $$AM_UPDATE_INFO_DIR in \
|
||||
n|no|NO) false;; \
|
||||
*) (install-info --version) >/dev/null 2>&1;; \
|
||||
esac
|
||||
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
|
||||
am__vpath_adj = case $$p in \
|
||||
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
|
||||
*) f=$$p;; \
|
||||
esac;
|
||||
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
|
||||
am__install_max = 40
|
||||
am__nobase_strip_setup = \
|
||||
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
|
||||
am__nobase_strip = \
|
||||
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
|
||||
am__nobase_list = $(am__nobase_strip_setup); \
|
||||
for p in $$list; do echo "$$p $$p"; done | \
|
||||
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
|
||||
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
|
||||
if (++n[$$2] == $(am__install_max)) \
|
||||
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
|
||||
END { for (dir in files) print dir, files[dir] }'
|
||||
am__base_list = \
|
||||
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
|
||||
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
|
||||
am__uninstall_files_from_dir = { \
|
||||
test -z "$$files" \
|
||||
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|
||||
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
|
||||
$(am__cd) "$$dir" && rm -f $$files; }; \
|
||||
}
|
||||
man5dir = $(mandir)/man5
|
||||
am__installdirs = "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)"
|
||||
man8dir = $(mandir)/man8
|
||||
NROFF = nroff
|
||||
MANS = $(man_MANS)
|
||||
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||
ACLOCAL = @ACLOCAL@
|
||||
AMTAR = @AMTAR@
|
||||
AUTOCONF = @AUTOCONF@
|
||||
AUTOHEADER = @AUTOHEADER@
|
||||
AUTOMAKE = @AUTOMAKE@
|
||||
AWK = @AWK@
|
||||
CC = @CC@
|
||||
CCDEPMODE = @CCDEPMODE@
|
||||
CFLAGS = @CFLAGS@
|
||||
CPP = @CPP@
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
CXX = @CXX@
|
||||
CXXDEPMODE = @CXXDEPMODE@
|
||||
CXXFLAGS = @CXXFLAGS@
|
||||
CYGPATH_W = @CYGPATH_W@
|
||||
DEFS = @DEFS@
|
||||
DEPDIR = @DEPDIR@
|
||||
ECHO_C = @ECHO_C@
|
||||
ECHO_N = @ECHO_N@
|
||||
ECHO_T = @ECHO_T@
|
||||
EGREP = @EGREP@
|
||||
EXEEXT = @EXEEXT@
|
||||
GREP = @GREP@
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
LIBOBJS = @LIBOBJS@
|
||||
LIBS = @LIBS@
|
||||
LTLIBOBJS = @LTLIBOBJS@
|
||||
MAKEINFO = @MAKEINFO@
|
||||
MKDIR_P = @MKDIR_P@
|
||||
OBJEXT = @OBJEXT@
|
||||
PACKAGE = @PACKAGE@
|
||||
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
|
||||
PACKAGE_NAME = @PACKAGE_NAME@
|
||||
PACKAGE_STRING = @PACKAGE_STRING@
|
||||
PACKAGE_TARNAME = @PACKAGE_TARNAME@
|
||||
PACKAGE_URL = @PACKAGE_URL@
|
||||
PACKAGE_VERSION = @PACKAGE_VERSION@
|
||||
PATH_SEPARATOR = @PATH_SEPARATOR@
|
||||
SET_MAKE = @SET_MAKE@
|
||||
SHELL = @SHELL@
|
||||
STRIP = @STRIP@
|
||||
VERSION = @VERSION@
|
||||
abs_builddir = @abs_builddir@
|
||||
abs_srcdir = @abs_srcdir@
|
||||
abs_top_builddir = @abs_top_builddir@
|
||||
abs_top_srcdir = @abs_top_srcdir@
|
||||
ac_ct_CC = @ac_ct_CC@
|
||||
ac_ct_CXX = @ac_ct_CXX@
|
||||
am__include = @am__include@
|
||||
am__leading_dot = @am__leading_dot@
|
||||
am__quote = @am__quote@
|
||||
am__tar = @am__tar@
|
||||
am__untar = @am__untar@
|
||||
bindir = @bindir@
|
||||
build_alias = @build_alias@
|
||||
builddir = @builddir@
|
||||
datadir = @datadir@
|
||||
datarootdir = @datarootdir@
|
||||
docdir = @docdir@
|
||||
dvidir = @dvidir@
|
||||
exec_prefix = @exec_prefix@
|
||||
host_alias = @host_alias@
|
||||
htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
localstatedir = @localstatedir@
|
||||
mandir = @mandir@
|
||||
mkdir_p = @mkdir_p@
|
||||
oldincludedir = @oldincludedir@
|
||||
pdfdir = @pdfdir@
|
||||
prefix = @prefix@
|
||||
program_transform_name = @program_transform_name@
|
||||
psdir = @psdir@
|
||||
sbindir = @sbindir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
srcdir = @srcdir@
|
||||
sysconfdir = @sysconfdir@
|
||||
target_alias = @target_alias@
|
||||
top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
man_MANS = prt-get.8 prt-cache.8 prt-get.conf.5
|
||||
EXTRA_DIST = $(man_MANS) coding
|
||||
all: all-am
|
||||
|
||||
.SUFFIXES:
|
||||
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
|
||||
@for dep in $?; do \
|
||||
case '$(am__configure_deps)' in \
|
||||
*$$dep*) \
|
||||
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
|
||||
&& { if test -f $@; then exit 0; else break; fi; }; \
|
||||
exit 1;; \
|
||||
esac; \
|
||||
done; \
|
||||
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu doc/Makefile'; \
|
||||
$(am__cd) $(top_srcdir) && \
|
||||
$(AUTOMAKE) --gnu doc/Makefile
|
||||
.PRECIOUS: Makefile
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||
@case '$?' in \
|
||||
*config.status*) \
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
|
||||
*) \
|
||||
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
|
||||
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
|
||||
esac;
|
||||
|
||||
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
|
||||
$(top_srcdir)/configure: $(am__configure_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(am__aclocal_m4_deps):
|
||||
install-man5: $(man_MANS)
|
||||
@$(NORMAL_INSTALL)
|
||||
@list1=''; \
|
||||
list2='$(man_MANS)'; \
|
||||
test -n "$(man5dir)" \
|
||||
&& test -n "`echo $$list1$$list2`" \
|
||||
|| exit 0; \
|
||||
echo " $(MKDIR_P) '$(DESTDIR)$(man5dir)'"; \
|
||||
$(MKDIR_P) "$(DESTDIR)$(man5dir)" || exit 1; \
|
||||
{ for i in $$list1; do echo "$$i"; done; \
|
||||
if test -n "$$list2"; then \
|
||||
for i in $$list2; do echo "$$i"; done \
|
||||
| sed -n '/\.5[a-z]*$$/p'; \
|
||||
fi; \
|
||||
} | while read p; do \
|
||||
if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
|
||||
echo "$$d$$p"; echo "$$p"; \
|
||||
done | \
|
||||
sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \
|
||||
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \
|
||||
sed 'N;N;s,\n, ,g' | { \
|
||||
list=; while read file base inst; do \
|
||||
if test "$$base" = "$$inst"; then list="$$list $$file"; else \
|
||||
echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man5dir)/$$inst'"; \
|
||||
$(INSTALL_DATA) "$$file" "$(DESTDIR)$(man5dir)/$$inst" || exit $$?; \
|
||||
fi; \
|
||||
done; \
|
||||
for i in $$list; do echo "$$i"; done | $(am__base_list) | \
|
||||
while read files; do \
|
||||
test -z "$$files" || { \
|
||||
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man5dir)'"; \
|
||||
$(INSTALL_DATA) $$files "$(DESTDIR)$(man5dir)" || exit $$?; }; \
|
||||
done; }
|
||||
|
||||
uninstall-man5:
|
||||
@$(NORMAL_UNINSTALL)
|
||||
@list=''; test -n "$(man5dir)" || exit 0; \
|
||||
files=`{ for i in $$list; do echo "$$i"; done; \
|
||||
l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
|
||||
sed -n '/\.5[a-z]*$$/p'; \
|
||||
} | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \
|
||||
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
|
||||
dir='$(DESTDIR)$(man5dir)'; $(am__uninstall_files_from_dir)
|
||||
install-man8: $(man_MANS)
|
||||
@$(NORMAL_INSTALL)
|
||||
@list1=''; \
|
||||
list2='$(man_MANS)'; \
|
||||
test -n "$(man8dir)" \
|
||||
&& test -n "`echo $$list1$$list2`" \
|
||||
|| exit 0; \
|
||||
echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \
|
||||
$(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \
|
||||
{ for i in $$list1; do echo "$$i"; done; \
|
||||
if test -n "$$list2"; then \
|
||||
for i in $$list2; do echo "$$i"; done \
|
||||
| sed -n '/\.8[a-z]*$$/p'; \
|
||||
fi; \
|
||||
} | while read p; do \
|
||||
if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
|
||||
echo "$$d$$p"; echo "$$p"; \
|
||||
done | \
|
||||
sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \
|
||||
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \
|
||||
sed 'N;N;s,\n, ,g' | { \
|
||||
list=; while read file base inst; do \
|
||||
if test "$$base" = "$$inst"; then list="$$list $$file"; else \
|
||||
echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \
|
||||
$(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \
|
||||
fi; \
|
||||
done; \
|
||||
for i in $$list; do echo "$$i"; done | $(am__base_list) | \
|
||||
while read files; do \
|
||||
test -z "$$files" || { \
|
||||
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \
|
||||
$(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \
|
||||
done; }
|
||||
|
||||
uninstall-man8:
|
||||
@$(NORMAL_UNINSTALL)
|
||||
@list=''; test -n "$(man8dir)" || exit 0; \
|
||||
files=`{ for i in $$list; do echo "$$i"; done; \
|
||||
l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
|
||||
sed -n '/\.8[a-z]*$$/p'; \
|
||||
} | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \
|
||||
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
|
||||
dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir)
|
||||
tags: TAGS
|
||||
TAGS:
|
||||
|
||||
ctags: CTAGS
|
||||
CTAGS:
|
||||
|
||||
cscope cscopelist:
|
||||
|
||||
|
||||
distdir: $(DISTFILES)
|
||||
@list='$(MANS)'; if test -n "$$list"; then \
|
||||
list=`for p in $$list; do \
|
||||
if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
|
||||
if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \
|
||||
if test -n "$$list" && \
|
||||
grep 'ab help2man is required to generate this page' $$list >/dev/null; then \
|
||||
echo "error: found man pages containing the 'missing help2man' replacement text:" >&2; \
|
||||
grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \
|
||||
echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \
|
||||
echo " typically 'make maintainer-clean' will remove them" >&2; \
|
||||
exit 1; \
|
||||
else :; fi; \
|
||||
else :; fi
|
||||
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
list='$(DISTFILES)'; \
|
||||
dist_files=`for file in $$list; do echo $$file; done | \
|
||||
sed -e "s|^$$srcdirstrip/||;t" \
|
||||
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
|
||||
case $$dist_files in \
|
||||
*/*) $(MKDIR_P) `echo "$$dist_files" | \
|
||||
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
|
||||
sort -u` ;; \
|
||||
esac; \
|
||||
for file in $$dist_files; do \
|
||||
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
|
||||
if test -d $$d/$$file; then \
|
||||
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
|
||||
if test -d "$(distdir)/$$file"; then \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
|
||||
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
|
||||
else \
|
||||
test -f "$(distdir)/$$file" \
|
||||
|| cp -p $$d/$$file "$(distdir)/$$file" \
|
||||
|| exit 1; \
|
||||
fi; \
|
||||
done
|
||||
check-am: all-am
|
||||
check: check-am
|
||||
all-am: Makefile $(MANS)
|
||||
installdirs:
|
||||
for dir in "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)"; do \
|
||||
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
|
||||
done
|
||||
install: install-am
|
||||
install-exec: install-exec-am
|
||||
install-data: install-data-am
|
||||
uninstall: uninstall-am
|
||||
|
||||
install-am: all-am
|
||||
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
|
||||
|
||||
installcheck: installcheck-am
|
||||
install-strip:
|
||||
if test -z '$(STRIP)'; then \
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
install; \
|
||||
else \
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
|
||||
fi
|
||||
mostlyclean-generic:
|
||||
|
||||
clean-generic:
|
||||
|
||||
distclean-generic:
|
||||
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
|
||||
|
||||
maintainer-clean-generic:
|
||||
@echo "This command is intended for maintainers to use"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
clean: clean-am
|
||||
|
||||
clean-am: clean-generic clean-local mostlyclean-am
|
||||
|
||||
distclean: distclean-am
|
||||
-rm -f Makefile
|
||||
distclean-am: clean-am distclean-generic
|
||||
|
||||
dvi: dvi-am
|
||||
|
||||
dvi-am:
|
||||
|
||||
html: html-am
|
||||
|
||||
html-am:
|
||||
|
||||
info: info-am
|
||||
|
||||
info-am:
|
||||
|
||||
install-data-am: install-man
|
||||
|
||||
install-dvi: install-dvi-am
|
||||
|
||||
install-dvi-am:
|
||||
|
||||
install-exec-am:
|
||||
|
||||
install-html: install-html-am
|
||||
|
||||
install-html-am:
|
||||
|
||||
install-info: install-info-am
|
||||
|
||||
install-info-am:
|
||||
|
||||
install-man: install-man5 install-man8
|
||||
|
||||
install-pdf: install-pdf-am
|
||||
|
||||
install-pdf-am:
|
||||
|
||||
install-ps: install-ps-am
|
||||
|
||||
install-ps-am:
|
||||
|
||||
installcheck-am:
|
||||
|
||||
maintainer-clean: maintainer-clean-am
|
||||
-rm -f Makefile
|
||||
maintainer-clean-am: distclean-am maintainer-clean-generic
|
||||
|
||||
mostlyclean: mostlyclean-am
|
||||
|
||||
mostlyclean-am: mostlyclean-generic
|
||||
|
||||
pdf: pdf-am
|
||||
|
||||
pdf-am:
|
||||
|
||||
ps: ps-am
|
||||
|
||||
ps-am:
|
||||
|
||||
uninstall-am: uninstall-man
|
||||
|
||||
uninstall-man: uninstall-man5 uninstall-man8
|
||||
|
||||
.MAKE: install-am install-strip
|
||||
|
||||
.PHONY: all all-am check check-am clean clean-generic clean-local \
|
||||
distclean distclean-generic distdir dvi dvi-am html html-am \
|
||||
info info-am install install-am install-data install-data-am \
|
||||
install-dvi install-dvi-am install-exec install-exec-am \
|
||||
install-html install-html-am install-info install-info-am \
|
||||
install-man install-man5 install-man8 install-pdf \
|
||||
install-pdf-am install-ps install-ps-am install-strip \
|
||||
installcheck installcheck-am installdirs maintainer-clean \
|
||||
maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
|
||||
pdf-am ps ps-am uninstall uninstall-am uninstall-man \
|
||||
uninstall-man5 uninstall-man8
|
||||
|
||||
|
||||
clean-local:
|
||||
rm -rf *.log *.aux *.toc *.dvi *.idx *.pdf api
|
||||
|
||||
apidoc:
|
||||
doxygen
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
||||
@@ -115,18 +115,6 @@ See the \fBEXAMPLES\fP section below for details.
|
||||
.B remove <package1> [<package2> ...]
|
||||
Remove packages listed in this order
|
||||
|
||||
.TP
|
||||
.B sync [\-\-install\-root=<dir>] [collection1 ... collectionN]
|
||||
Reach out to remote servers defined in \fB/etc/ports\fP (or \fB<dir>/etc/ports\fP if
|
||||
\-\-install\-root is given), and bring the local ports collections up to date. The sync
|
||||
command processes all sync files whose suffix matches an executable file in
|
||||
\fB/etc/ports/drivers\fP, unless specific collections are passed as arguments, in which case
|
||||
only those collections are synchronized. If the same collection is listed in \fB/etc/ports\fP
|
||||
with different suffixes, then the matching drivers are called in lexographic order. This
|
||||
feature allows for multi-stage processing, e.g. if you want to apply local patches and then
|
||||
update the manifests. For further details on the ports system and the format of the
|
||||
{httpup,rsync,git} files, see \fBports(8)\fB.
|
||||
|
||||
.TP
|
||||
.B sysup [\-\-softdeps] [\-\-nodeps]
|
||||
Update all installed packages which are outdated. Sorts by hard dependencies
|
||||
@@ -790,7 +778,7 @@ return many identical lines; these are suppressed by the -3 flag to
|
||||
\fBcomm(1)\fP.
|
||||
|
||||
.TP
|
||||
.B for L in /var/log/pkgbuild/*.log; do P=${L%__*}; P=${P##*/}; VR=${L##*__}; VR=${VR%.log}; if ! prt\-get isinst $P >/dev/null; then mv $L /var/log/uninstalled/; elif [ \(dq$(prt\-get current $P)\(dq != \(dq$VR\(dq ]; then mv $L /var/log/oldbuild/; fi; done
|
||||
.B for L in /var/log/pkgbuild/*.log; do P=${L%__*}; P=${P##*/}; VR=${L##*__}; VR=${VR%.log}; if ! prt\-get isinst $P >/dev/null; then mv $L /var/log/uninstalled; elif [ \(dq$(prt\-get current $P)\(dq != \(dq$VR\(dq ]; then mv $L /var/log/oldbuild/; fi; done
|
||||
(based on a feature request by samsep10l) a command you can put into a script
|
||||
called by root's crontab, in order to mimic Slackware's tidy directory listings
|
||||
(the main logdir only contains build logs of the latest installed packages;
|
||||
@@ -808,13 +796,10 @@ as the first step in keeping your personal overlay up to date.
|
||||
.B prt\-get printf \(dq%M\et%n\en\(dq | grep \-c ^Tim
|
||||
Count how many ports our most-overworked core team member claims responsibility for.
|
||||
|
||||
.TP
|
||||
.B for u in $(prt\-get printf \(dq%M:%p/%n\en\(dq | grep \-i ^unmaintained | cut \-d: \-f2); do cd ${u%/*}; printf \(dq||%s ||\(dq ${u##*/}; git log ${u##*/} | head \-n 5 | awk '/^Date/ { $0=gensub(/^Date:\es+/,"","g"); printf(\(dq %s ||\en\(dq,$0); }'; cd \- >/dev/null; done
|
||||
Generate a table of unmaintained ports and the dates of their most recent
|
||||
commit, in PmWiki syntax (left-justified port names, centered dates).
|
||||
Requires that your repositories are synchronized using the \fBgit(1)\fP driver.
|
||||
Subsequent sorting by date may be done using \fBsort(1)\fP with the flags
|
||||
-k, -M, and -n (the appropriate key defs will depend on your locale).
|
||||
.TP
|
||||
.B comm \-13 <(prt\-get depends firefox\-bin |tail \-n +2 |sort) <(prt\-get depends firefox |tail \-n +2 |sort)
|
||||
Find the build-time dependencies of firefox. Runtime dependencies would also appear in the list generated by
|
||||
the first process substitution, and \fBcomm -13\fP will suppress what the two lists have in common.
|
||||
|
||||
.TP
|
||||
.B prt\-get listinst \-\-depsort | xargs prt\-get install \-\-install\-root=/mnt
|
||||
|
||||
@@ -129,9 +129,9 @@ and %n would be
|
||||
.B gcc.
|
||||
This allows you to have separate log files per port.
|
||||
Separate log files for each version and release can be achieved
|
||||
using the placeholders %v and %r, respectively. But if you want to
|
||||
enable \fBrmlog_on_uninst\fP, it is best to avoid %p, %v, and %r
|
||||
when specifying \fBlogfile\fP (as explained below).
|
||||
using the placeholders %v and %r, respectively. But if you want to enable
|
||||
\fBrmlog_on_uninst\fP, it is best to avoid %p, %v, and %r when specifying
|
||||
\fBlogfile\fP (as explained below).
|
||||
|
||||
.B rmlog_on_uninst
|
||||
which can be set to 'yes' or 'no'; when set to yes, uninstalling a
|
||||
@@ -140,8 +140,8 @@ package will also try to delete its build log. Replacements in the template
|
||||
of installed packages, and from the active repositories. If log files exist
|
||||
with different values of %p, %v, or %r than what the database and repositories
|
||||
provide, then the pattern substitutions will fail to match the names of those
|
||||
logs, and this feature will be a no-op. For example, suppose you specify
|
||||
the logfile pattern \(dq%p/.buildlogs/%n-%v-%r.log\(dq, and you have a package
|
||||
logs, and this feature will be a no-op. For example, suppose you specify the
|
||||
logfile pattern \(dq%p/.buildlogs/%n-%v-%r.log\(dq, and you have a package
|
||||
installed on your system through many versions, or after it has been
|
||||
moved from opt to contrib. Uninstalling that package would leave behind all the
|
||||
build logs except the latest. This pattern is also fragile with respect to
|
||||
@@ -156,7 +156,7 @@ can be set to 'disabled', to suppress the notification after
|
||||
installing a port with a README file; 'compact', to collect all the READMEs
|
||||
into one post-transaction output; or 'verbose', to print separate
|
||||
information about each port with a README file. See
|
||||
.B prt-get(8)
|
||||
.B prt\-get(8)
|
||||
and especially the readme command how to read those README files using
|
||||
prt-get.
|
||||
|
||||
|
||||
@@ -1,4 +0,0 @@
|
||||
EXTRA_DIST = prt-get_complete prt-get.aliases prt-get.deplist prt-get.conf
|
||||
|
||||
sysconf_DATA = prt-get.conf
|
||||
|
||||
403
misc/Makefile.in
403
misc/Makefile.in
@@ -1,403 +0,0 @@
|
||||
# Makefile.in generated by automake 1.12.2 from Makefile.am.
|
||||
# @configure_input@
|
||||
|
||||
# Copyright (C) 1994-2012 Free Software Foundation, Inc.
|
||||
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE.
|
||||
|
||||
@SET_MAKE@
|
||||
|
||||
VPATH = @srcdir@
|
||||
am__make_dryrun = \
|
||||
{ \
|
||||
am__dry=no; \
|
||||
case $$MAKEFLAGS in \
|
||||
*\\[\ \ ]*) \
|
||||
echo 'am--echo: ; @echo "AM" OK' | $(MAKE) -f - 2>/dev/null \
|
||||
| grep '^AM OK$$' >/dev/null || am__dry=yes;; \
|
||||
*) \
|
||||
for am__flg in $$MAKEFLAGS; do \
|
||||
case $$am__flg in \
|
||||
*=*|--*) ;; \
|
||||
*n*) am__dry=yes; break;; \
|
||||
esac; \
|
||||
done;; \
|
||||
esac; \
|
||||
test $$am__dry = yes; \
|
||||
}
|
||||
pkgdatadir = $(datadir)/@PACKAGE@
|
||||
pkgincludedir = $(includedir)/@PACKAGE@
|
||||
pkglibdir = $(libdir)/@PACKAGE@
|
||||
pkglibexecdir = $(libexecdir)/@PACKAGE@
|
||||
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
|
||||
install_sh_DATA = $(install_sh) -c -m 644
|
||||
install_sh_PROGRAM = $(install_sh) -c
|
||||
install_sh_SCRIPT = $(install_sh) -c
|
||||
INSTALL_HEADER = $(INSTALL_DATA)
|
||||
transform = $(program_transform_name)
|
||||
NORMAL_INSTALL = :
|
||||
PRE_INSTALL = :
|
||||
POST_INSTALL = :
|
||||
NORMAL_UNINSTALL = :
|
||||
PRE_UNINSTALL = :
|
||||
POST_UNINSTALL = :
|
||||
subdir = misc
|
||||
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
|
||||
$(top_srcdir)/mkinstalldirs
|
||||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||
am__aclocal_m4_deps = $(top_srcdir)/configure.in
|
||||
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||
$(ACLOCAL_M4)
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
CONFIG_HEADER = $(top_builddir)/config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
CONFIG_CLEAN_VPATH_FILES =
|
||||
SOURCES =
|
||||
DIST_SOURCES =
|
||||
am__can_run_installinfo = \
|
||||
case $$AM_UPDATE_INFO_DIR in \
|
||||
n|no|NO) false;; \
|
||||
*) (install-info --version) >/dev/null 2>&1;; \
|
||||
esac
|
||||
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
|
||||
am__vpath_adj = case $$p in \
|
||||
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
|
||||
*) f=$$p;; \
|
||||
esac;
|
||||
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
|
||||
am__install_max = 40
|
||||
am__nobase_strip_setup = \
|
||||
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
|
||||
am__nobase_strip = \
|
||||
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
|
||||
am__nobase_list = $(am__nobase_strip_setup); \
|
||||
for p in $$list; do echo "$$p $$p"; done | \
|
||||
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
|
||||
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
|
||||
if (++n[$$2] == $(am__install_max)) \
|
||||
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
|
||||
END { for (dir in files) print dir, files[dir] }'
|
||||
am__base_list = \
|
||||
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
|
||||
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
|
||||
am__uninstall_files_from_dir = { \
|
||||
test -z "$$files" \
|
||||
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|
||||
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
|
||||
$(am__cd) "$$dir" && rm -f $$files; }; \
|
||||
}
|
||||
am__installdirs = "$(DESTDIR)$(sysconfdir)"
|
||||
DATA = $(sysconf_DATA)
|
||||
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||
ACLOCAL = @ACLOCAL@
|
||||
AMTAR = @AMTAR@
|
||||
AUTOCONF = @AUTOCONF@
|
||||
AUTOHEADER = @AUTOHEADER@
|
||||
AUTOMAKE = @AUTOMAKE@
|
||||
AWK = @AWK@
|
||||
CC = @CC@
|
||||
CCDEPMODE = @CCDEPMODE@
|
||||
CFLAGS = @CFLAGS@
|
||||
CPP = @CPP@
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
CXX = @CXX@
|
||||
CXXDEPMODE = @CXXDEPMODE@
|
||||
CXXFLAGS = @CXXFLAGS@
|
||||
CYGPATH_W = @CYGPATH_W@
|
||||
DEFS = @DEFS@
|
||||
DEPDIR = @DEPDIR@
|
||||
ECHO_C = @ECHO_C@
|
||||
ECHO_N = @ECHO_N@
|
||||
ECHO_T = @ECHO_T@
|
||||
EGREP = @EGREP@
|
||||
EXEEXT = @EXEEXT@
|
||||
GREP = @GREP@
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
LIBOBJS = @LIBOBJS@
|
||||
LIBS = @LIBS@
|
||||
LTLIBOBJS = @LTLIBOBJS@
|
||||
MAKEINFO = @MAKEINFO@
|
||||
MKDIR_P = @MKDIR_P@
|
||||
OBJEXT = @OBJEXT@
|
||||
PACKAGE = @PACKAGE@
|
||||
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
|
||||
PACKAGE_NAME = @PACKAGE_NAME@
|
||||
PACKAGE_STRING = @PACKAGE_STRING@
|
||||
PACKAGE_TARNAME = @PACKAGE_TARNAME@
|
||||
PACKAGE_URL = @PACKAGE_URL@
|
||||
PACKAGE_VERSION = @PACKAGE_VERSION@
|
||||
PATH_SEPARATOR = @PATH_SEPARATOR@
|
||||
SET_MAKE = @SET_MAKE@
|
||||
SHELL = @SHELL@
|
||||
STRIP = @STRIP@
|
||||
VERSION = @VERSION@
|
||||
abs_builddir = @abs_builddir@
|
||||
abs_srcdir = @abs_srcdir@
|
||||
abs_top_builddir = @abs_top_builddir@
|
||||
abs_top_srcdir = @abs_top_srcdir@
|
||||
ac_ct_CC = @ac_ct_CC@
|
||||
ac_ct_CXX = @ac_ct_CXX@
|
||||
am__include = @am__include@
|
||||
am__leading_dot = @am__leading_dot@
|
||||
am__quote = @am__quote@
|
||||
am__tar = @am__tar@
|
||||
am__untar = @am__untar@
|
||||
bindir = @bindir@
|
||||
build_alias = @build_alias@
|
||||
builddir = @builddir@
|
||||
datadir = @datadir@
|
||||
datarootdir = @datarootdir@
|
||||
docdir = @docdir@
|
||||
dvidir = @dvidir@
|
||||
exec_prefix = @exec_prefix@
|
||||
host_alias = @host_alias@
|
||||
htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
localstatedir = @localstatedir@
|
||||
mandir = @mandir@
|
||||
mkdir_p = @mkdir_p@
|
||||
oldincludedir = @oldincludedir@
|
||||
pdfdir = @pdfdir@
|
||||
prefix = @prefix@
|
||||
program_transform_name = @program_transform_name@
|
||||
psdir = @psdir@
|
||||
sbindir = @sbindir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
srcdir = @srcdir@
|
||||
sysconfdir = @sysconfdir@
|
||||
target_alias = @target_alias@
|
||||
top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
EXTRA_DIST = prt-get_complete prt-get.aliases prt-get.deplist prt-get.conf
|
||||
sysconf_DATA = prt-get.conf
|
||||
all: all-am
|
||||
|
||||
.SUFFIXES:
|
||||
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
|
||||
@for dep in $?; do \
|
||||
case '$(am__configure_deps)' in \
|
||||
*$$dep*) \
|
||||
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
|
||||
&& { if test -f $@; then exit 0; else break; fi; }; \
|
||||
exit 1;; \
|
||||
esac; \
|
||||
done; \
|
||||
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu misc/Makefile'; \
|
||||
$(am__cd) $(top_srcdir) && \
|
||||
$(AUTOMAKE) --gnu misc/Makefile
|
||||
.PRECIOUS: Makefile
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||
@case '$?' in \
|
||||
*config.status*) \
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
|
||||
*) \
|
||||
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
|
||||
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
|
||||
esac;
|
||||
|
||||
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
|
||||
$(top_srcdir)/configure: $(am__configure_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(am__aclocal_m4_deps):
|
||||
install-sysconfDATA: $(sysconf_DATA)
|
||||
@$(NORMAL_INSTALL)
|
||||
@list='$(sysconf_DATA)'; test -n "$(sysconfdir)" || list=; \
|
||||
if test -n "$$list"; then \
|
||||
echo " $(MKDIR_P) '$(DESTDIR)$(sysconfdir)'"; \
|
||||
$(MKDIR_P) "$(DESTDIR)$(sysconfdir)" || exit 1; \
|
||||
fi; \
|
||||
for p in $$list; do \
|
||||
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
|
||||
echo "$$d$$p"; \
|
||||
done | $(am__base_list) | \
|
||||
while read files; do \
|
||||
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(sysconfdir)'"; \
|
||||
$(INSTALL_DATA) $$files "$(DESTDIR)$(sysconfdir)" || exit $$?; \
|
||||
done
|
||||
|
||||
uninstall-sysconfDATA:
|
||||
@$(NORMAL_UNINSTALL)
|
||||
@list='$(sysconf_DATA)'; test -n "$(sysconfdir)" || list=; \
|
||||
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
|
||||
dir='$(DESTDIR)$(sysconfdir)'; $(am__uninstall_files_from_dir)
|
||||
tags: TAGS
|
||||
TAGS:
|
||||
|
||||
ctags: CTAGS
|
||||
CTAGS:
|
||||
|
||||
cscope cscopelist:
|
||||
|
||||
|
||||
distdir: $(DISTFILES)
|
||||
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
list='$(DISTFILES)'; \
|
||||
dist_files=`for file in $$list; do echo $$file; done | \
|
||||
sed -e "s|^$$srcdirstrip/||;t" \
|
||||
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
|
||||
case $$dist_files in \
|
||||
*/*) $(MKDIR_P) `echo "$$dist_files" | \
|
||||
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
|
||||
sort -u` ;; \
|
||||
esac; \
|
||||
for file in $$dist_files; do \
|
||||
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
|
||||
if test -d $$d/$$file; then \
|
||||
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
|
||||
if test -d "$(distdir)/$$file"; then \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
|
||||
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
|
||||
else \
|
||||
test -f "$(distdir)/$$file" \
|
||||
|| cp -p $$d/$$file "$(distdir)/$$file" \
|
||||
|| exit 1; \
|
||||
fi; \
|
||||
done
|
||||
check-am: all-am
|
||||
check: check-am
|
||||
all-am: Makefile $(DATA)
|
||||
installdirs:
|
||||
for dir in "$(DESTDIR)$(sysconfdir)"; do \
|
||||
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
|
||||
done
|
||||
install: install-am
|
||||
install-exec: install-exec-am
|
||||
install-data: install-data-am
|
||||
uninstall: uninstall-am
|
||||
|
||||
install-am: all-am
|
||||
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
|
||||
|
||||
installcheck: installcheck-am
|
||||
install-strip:
|
||||
if test -z '$(STRIP)'; then \
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
install; \
|
||||
else \
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
|
||||
fi
|
||||
mostlyclean-generic:
|
||||
|
||||
clean-generic:
|
||||
|
||||
distclean-generic:
|
||||
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
|
||||
|
||||
maintainer-clean-generic:
|
||||
@echo "This command is intended for maintainers to use"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
clean: clean-am
|
||||
|
||||
clean-am: clean-generic mostlyclean-am
|
||||
|
||||
distclean: distclean-am
|
||||
-rm -f Makefile
|
||||
distclean-am: clean-am distclean-generic
|
||||
|
||||
dvi: dvi-am
|
||||
|
||||
dvi-am:
|
||||
|
||||
html: html-am
|
||||
|
||||
html-am:
|
||||
|
||||
info: info-am
|
||||
|
||||
info-am:
|
||||
|
||||
install-data-am:
|
||||
|
||||
install-dvi: install-dvi-am
|
||||
|
||||
install-dvi-am:
|
||||
|
||||
install-exec-am: install-sysconfDATA
|
||||
|
||||
install-html: install-html-am
|
||||
|
||||
install-html-am:
|
||||
|
||||
install-info: install-info-am
|
||||
|
||||
install-info-am:
|
||||
|
||||
install-man:
|
||||
|
||||
install-pdf: install-pdf-am
|
||||
|
||||
install-pdf-am:
|
||||
|
||||
install-ps: install-ps-am
|
||||
|
||||
install-ps-am:
|
||||
|
||||
installcheck-am:
|
||||
|
||||
maintainer-clean: maintainer-clean-am
|
||||
-rm -f Makefile
|
||||
maintainer-clean-am: distclean-am maintainer-clean-generic
|
||||
|
||||
mostlyclean: mostlyclean-am
|
||||
|
||||
mostlyclean-am: mostlyclean-generic
|
||||
|
||||
pdf: pdf-am
|
||||
|
||||
pdf-am:
|
||||
|
||||
ps: ps-am
|
||||
|
||||
ps-am:
|
||||
|
||||
uninstall-am: uninstall-sysconfDATA
|
||||
|
||||
.MAKE: install-am install-strip
|
||||
|
||||
.PHONY: all all-am check check-am clean clean-generic distclean \
|
||||
distclean-generic distdir dvi dvi-am html html-am info info-am \
|
||||
install install-am install-data install-data-am install-dvi \
|
||||
install-dvi-am install-exec install-exec-am install-html \
|
||||
install-html-am install-info install-info-am install-man \
|
||||
install-pdf install-pdf-am install-ps install-ps-am \
|
||||
install-strip install-sysconfDATA installcheck installcheck-am \
|
||||
installdirs maintainer-clean maintainer-clean-generic \
|
||||
mostlyclean mostlyclean-generic pdf pdf-am ps ps-am uninstall \
|
||||
uninstall-am uninstall-sysconfDATA
|
||||
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
||||
@@ -20,8 +20,8 @@ prtdir /usr/ports/opt
|
||||
# rmlog_on_success no # (yes|no)
|
||||
# rmlog_on_uninst no # (yes|no)
|
||||
logfile /var/log/pkgbuild/%n.log
|
||||
# path, %p=path to port dir, %n=port name
|
||||
# %v=version, %r=release
|
||||
# %n=port name, %v=version, %r=release
|
||||
# %p=path to repository
|
||||
|
||||
### print README information:
|
||||
# readme verbose # (verbose|compact|disabled)
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
# Makefile.am for prt-get by Johannes Winkelmann
|
||||
|
||||
install-exec-local: install-binPROGRAMS
|
||||
(cd $(DESTDIR)$(bindir); ln -sf prt-get prt-cache)
|
||||
|
||||
bin_PROGRAMS=prt-get
|
||||
|
||||
prt_get_SOURCES= argparser.cpp argparser.h\
|
||||
depresolver.cpp depresolver.h \
|
||||
installtransaction.cpp installtransaction.h \
|
||||
main.cpp \
|
||||
package.cpp package.h \
|
||||
pkgdb.cpp pkgdb.h \
|
||||
prtget.cpp prtget.h \
|
||||
repository.cpp repository.h \
|
||||
stringhelper.cpp stringhelper.h \
|
||||
process.cpp process.h \
|
||||
configuration.cpp configuration.h \
|
||||
signaldispatcher.cpp signaldispatcher.h \
|
||||
lockfile.cpp lockfile.h \
|
||||
file.cpp file.h \
|
||||
locker.cpp locker.h \
|
||||
versioncomparator.cpp versioncomparator.h \
|
||||
datafileparser.cpp datafileparser.h \
|
||||
pg_regex.cpp pg_regex.h
|
||||
|
||||
|
||||
AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\" \
|
||||
-DLOCALSTATEDIR=\"$(localstatedir)\"
|
||||
552
src/Makefile.in
552
src/Makefile.in
@@ -1,552 +0,0 @@
|
||||
# Makefile.in generated by automake 1.12.2 from Makefile.am.
|
||||
# @configure_input@
|
||||
|
||||
# Copyright (C) 1994-2012 Free Software Foundation, Inc.
|
||||
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE.
|
||||
|
||||
@SET_MAKE@
|
||||
|
||||
# Makefile.am for prt-get by Johannes Winkelmann
|
||||
|
||||
VPATH = @srcdir@
|
||||
am__make_dryrun = \
|
||||
{ \
|
||||
am__dry=no; \
|
||||
case $$MAKEFLAGS in \
|
||||
*\\[\ \ ]*) \
|
||||
echo 'am--echo: ; @echo "AM" OK' | $(MAKE) -f - 2>/dev/null \
|
||||
| grep '^AM OK$$' >/dev/null || am__dry=yes;; \
|
||||
*) \
|
||||
for am__flg in $$MAKEFLAGS; do \
|
||||
case $$am__flg in \
|
||||
*=*|--*) ;; \
|
||||
*n*) am__dry=yes; break;; \
|
||||
esac; \
|
||||
done;; \
|
||||
esac; \
|
||||
test $$am__dry = yes; \
|
||||
}
|
||||
pkgdatadir = $(datadir)/@PACKAGE@
|
||||
pkgincludedir = $(includedir)/@PACKAGE@
|
||||
pkglibdir = $(libdir)/@PACKAGE@
|
||||
pkglibexecdir = $(libexecdir)/@PACKAGE@
|
||||
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
|
||||
install_sh_DATA = $(install_sh) -c -m 644
|
||||
install_sh_PROGRAM = $(install_sh) -c
|
||||
install_sh_SCRIPT = $(install_sh) -c
|
||||
INSTALL_HEADER = $(INSTALL_DATA)
|
||||
transform = $(program_transform_name)
|
||||
NORMAL_INSTALL = :
|
||||
PRE_INSTALL = :
|
||||
POST_INSTALL = :
|
||||
NORMAL_UNINSTALL = :
|
||||
PRE_UNINSTALL = :
|
||||
POST_UNINSTALL = :
|
||||
bin_PROGRAMS = prt-get$(EXEEXT)
|
||||
subdir = src
|
||||
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
|
||||
$(top_srcdir)/depcomp $(top_srcdir)/mkinstalldirs
|
||||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||
am__aclocal_m4_deps = $(top_srcdir)/configure.in
|
||||
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||
$(ACLOCAL_M4)
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
CONFIG_HEADER = $(top_builddir)/config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
CONFIG_CLEAN_VPATH_FILES =
|
||||
am__installdirs = "$(DESTDIR)$(bindir)"
|
||||
PROGRAMS = $(bin_PROGRAMS)
|
||||
am_prt_get_OBJECTS = argparser.$(OBJEXT) depresolver.$(OBJEXT) \
|
||||
installtransaction.$(OBJEXT) main.$(OBJEXT) package.$(OBJEXT) \
|
||||
pkgdb.$(OBJEXT) prtget.$(OBJEXT) repository.$(OBJEXT) \
|
||||
stringhelper.$(OBJEXT) process.$(OBJEXT) \
|
||||
configuration.$(OBJEXT) signaldispatcher.$(OBJEXT) \
|
||||
lockfile.$(OBJEXT) file.$(OBJEXT) locker.$(OBJEXT) \
|
||||
versioncomparator.$(OBJEXT) datafileparser.$(OBJEXT) \
|
||||
pg_regex.$(OBJEXT)
|
||||
prt_get_OBJECTS = $(am_prt_get_OBJECTS)
|
||||
prt_get_LDADD = $(LDADD)
|
||||
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
|
||||
depcomp = $(SHELL) $(top_srcdir)/depcomp
|
||||
am__depfiles_maybe = depfiles
|
||||
am__mv = mv -f
|
||||
CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
|
||||
CXXLD = $(CXX)
|
||||
CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
|
||||
-o $@
|
||||
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
|
||||
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||
CCLD = $(CC)
|
||||
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
|
||||
SOURCES = $(prt_get_SOURCES)
|
||||
DIST_SOURCES = $(prt_get_SOURCES)
|
||||
am__can_run_installinfo = \
|
||||
case $$AM_UPDATE_INFO_DIR in \
|
||||
n|no|NO) false;; \
|
||||
*) (install-info --version) >/dev/null 2>&1;; \
|
||||
esac
|
||||
ETAGS = etags
|
||||
CTAGS = ctags
|
||||
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||
ACLOCAL = @ACLOCAL@
|
||||
AMTAR = @AMTAR@
|
||||
AUTOCONF = @AUTOCONF@
|
||||
AUTOHEADER = @AUTOHEADER@
|
||||
AUTOMAKE = @AUTOMAKE@
|
||||
AWK = @AWK@
|
||||
CC = @CC@
|
||||
CCDEPMODE = @CCDEPMODE@
|
||||
CFLAGS = @CFLAGS@
|
||||
CPP = @CPP@
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
CXX = @CXX@
|
||||
CXXDEPMODE = @CXXDEPMODE@
|
||||
CXXFLAGS = @CXXFLAGS@
|
||||
CYGPATH_W = @CYGPATH_W@
|
||||
DEFS = @DEFS@
|
||||
DEPDIR = @DEPDIR@
|
||||
ECHO_C = @ECHO_C@
|
||||
ECHO_N = @ECHO_N@
|
||||
ECHO_T = @ECHO_T@
|
||||
EGREP = @EGREP@
|
||||
EXEEXT = @EXEEXT@
|
||||
GREP = @GREP@
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
LIBOBJS = @LIBOBJS@
|
||||
LIBS = @LIBS@
|
||||
LTLIBOBJS = @LTLIBOBJS@
|
||||
MAKEINFO = @MAKEINFO@
|
||||
MKDIR_P = @MKDIR_P@
|
||||
OBJEXT = @OBJEXT@
|
||||
PACKAGE = @PACKAGE@
|
||||
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
|
||||
PACKAGE_NAME = @PACKAGE_NAME@
|
||||
PACKAGE_STRING = @PACKAGE_STRING@
|
||||
PACKAGE_TARNAME = @PACKAGE_TARNAME@
|
||||
PACKAGE_URL = @PACKAGE_URL@
|
||||
PACKAGE_VERSION = @PACKAGE_VERSION@
|
||||
PATH_SEPARATOR = @PATH_SEPARATOR@
|
||||
SET_MAKE = @SET_MAKE@
|
||||
SHELL = @SHELL@
|
||||
STRIP = @STRIP@
|
||||
VERSION = @VERSION@
|
||||
abs_builddir = @abs_builddir@
|
||||
abs_srcdir = @abs_srcdir@
|
||||
abs_top_builddir = @abs_top_builddir@
|
||||
abs_top_srcdir = @abs_top_srcdir@
|
||||
ac_ct_CC = @ac_ct_CC@
|
||||
ac_ct_CXX = @ac_ct_CXX@
|
||||
am__include = @am__include@
|
||||
am__leading_dot = @am__leading_dot@
|
||||
am__quote = @am__quote@
|
||||
am__tar = @am__tar@
|
||||
am__untar = @am__untar@
|
||||
bindir = @bindir@
|
||||
build_alias = @build_alias@
|
||||
builddir = @builddir@
|
||||
datadir = @datadir@
|
||||
datarootdir = @datarootdir@
|
||||
docdir = @docdir@
|
||||
dvidir = @dvidir@
|
||||
exec_prefix = @exec_prefix@
|
||||
host_alias = @host_alias@
|
||||
htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
localstatedir = @localstatedir@
|
||||
mandir = @mandir@
|
||||
mkdir_p = @mkdir_p@
|
||||
oldincludedir = @oldincludedir@
|
||||
pdfdir = @pdfdir@
|
||||
prefix = @prefix@
|
||||
program_transform_name = @program_transform_name@
|
||||
psdir = @psdir@
|
||||
sbindir = @sbindir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
srcdir = @srcdir@
|
||||
sysconfdir = @sysconfdir@
|
||||
target_alias = @target_alias@
|
||||
top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
prt_get_SOURCES = argparser.cpp argparser.h\
|
||||
depresolver.cpp depresolver.h \
|
||||
installtransaction.cpp installtransaction.h \
|
||||
main.cpp \
|
||||
package.cpp package.h \
|
||||
pkgdb.cpp pkgdb.h \
|
||||
prtget.cpp prtget.h \
|
||||
repository.cpp repository.h \
|
||||
stringhelper.cpp stringhelper.h \
|
||||
process.cpp process.h \
|
||||
configuration.cpp configuration.h \
|
||||
signaldispatcher.cpp signaldispatcher.h \
|
||||
lockfile.cpp lockfile.h \
|
||||
file.cpp file.h \
|
||||
locker.cpp locker.h \
|
||||
versioncomparator.cpp versioncomparator.h \
|
||||
datafileparser.cpp datafileparser.h \
|
||||
pg_regex.cpp pg_regex.h
|
||||
|
||||
AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\" \
|
||||
-DLOCALSTATEDIR=\"$(localstatedir)\"
|
||||
|
||||
all: all-am
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .cpp .o .obj
|
||||
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
|
||||
@for dep in $?; do \
|
||||
case '$(am__configure_deps)' in \
|
||||
*$$dep*) \
|
||||
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
|
||||
&& { if test -f $@; then exit 0; else break; fi; }; \
|
||||
exit 1;; \
|
||||
esac; \
|
||||
done; \
|
||||
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \
|
||||
$(am__cd) $(top_srcdir) && \
|
||||
$(AUTOMAKE) --gnu src/Makefile
|
||||
.PRECIOUS: Makefile
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||
@case '$?' in \
|
||||
*config.status*) \
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
|
||||
*) \
|
||||
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
|
||||
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
|
||||
esac;
|
||||
|
||||
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
|
||||
$(top_srcdir)/configure: $(am__configure_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(am__aclocal_m4_deps):
|
||||
install-binPROGRAMS: $(bin_PROGRAMS)
|
||||
@$(NORMAL_INSTALL)
|
||||
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
|
||||
if test -n "$$list"; then \
|
||||
echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \
|
||||
$(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \
|
||||
fi; \
|
||||
for p in $$list; do echo "$$p $$p"; done | \
|
||||
sed 's/$(EXEEXT)$$//' | \
|
||||
while read p p1; do if test -f $$p; \
|
||||
then echo "$$p"; echo "$$p"; else :; fi; \
|
||||
done | \
|
||||
sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
|
||||
-e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
|
||||
sed 'N;N;N;s,\n, ,g' | \
|
||||
$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
|
||||
{ d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
|
||||
if ($$2 == $$4) files[d] = files[d] " " $$1; \
|
||||
else { print "f", $$3 "/" $$4, $$1; } } \
|
||||
END { for (d in files) print "f", d, files[d] }' | \
|
||||
while read type dir files; do \
|
||||
if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
|
||||
test -z "$$files" || { \
|
||||
echo " $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \
|
||||
$(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
|
||||
} \
|
||||
; done
|
||||
|
||||
uninstall-binPROGRAMS:
|
||||
@$(NORMAL_UNINSTALL)
|
||||
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
|
||||
files=`for p in $$list; do echo "$$p"; done | \
|
||||
sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
|
||||
-e 's/$$/$(EXEEXT)/' `; \
|
||||
test -n "$$list" || exit 0; \
|
||||
echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
|
||||
cd "$(DESTDIR)$(bindir)" && rm -f $$files
|
||||
|
||||
clean-binPROGRAMS:
|
||||
-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
|
||||
prt-get$(EXEEXT): $(prt_get_OBJECTS) $(prt_get_DEPENDENCIES) $(EXTRA_prt_get_DEPENDENCIES)
|
||||
@rm -f prt-get$(EXEEXT)
|
||||
$(CXXLINK) $(prt_get_OBJECTS) $(prt_get_LDADD) $(LIBS)
|
||||
|
||||
mostlyclean-compile:
|
||||
-rm -f *.$(OBJEXT)
|
||||
|
||||
distclean-compile:
|
||||
-rm -f *.tab.c
|
||||
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/argparser.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/configuration.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/datafileparser.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/depresolver.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/file.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/installtransaction.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/locker.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lockfile.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/package.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pg_regex.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pkgdb.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/process.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/prtget.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/repository.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/signaldispatcher.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stringhelper.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/versioncomparator.Po@am__quote@
|
||||
|
||||
.cpp.o:
|
||||
@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
|
||||
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||
@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ $<
|
||||
|
||||
.cpp.obj:
|
||||
@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
|
||||
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||
@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
|
||||
|
||||
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
|
||||
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
mkid -fID $$unique
|
||||
tags: TAGS
|
||||
|
||||
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||
$(TAGS_FILES) $(LISP)
|
||||
set x; \
|
||||
here=`pwd`; \
|
||||
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
shift; \
|
||||
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
|
||||
test -n "$$unique" || unique=$$empty_fix; \
|
||||
if test $$# -gt 0; then \
|
||||
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||
"$$@" $$unique; \
|
||||
else \
|
||||
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||
$$unique; \
|
||||
fi; \
|
||||
fi
|
||||
ctags: CTAGS
|
||||
CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||
$(TAGS_FILES) $(LISP)
|
||||
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
test -z "$(CTAGS_ARGS)$$unique" \
|
||||
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
|
||||
$$unique
|
||||
|
||||
GTAGS:
|
||||
here=`$(am__cd) $(top_builddir) && pwd` \
|
||||
&& $(am__cd) $(top_srcdir) \
|
||||
&& gtags -i $(GTAGS_ARGS) "$$here"
|
||||
|
||||
cscopelist: $(HEADERS) $(SOURCES) $(LISP)
|
||||
list='$(SOURCES) $(HEADERS) $(LISP)'; \
|
||||
case "$(srcdir)" in \
|
||||
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
|
||||
*) sdir=$(subdir)/$(srcdir) ;; \
|
||||
esac; \
|
||||
for i in $$list; do \
|
||||
if test -f "$$i"; then \
|
||||
echo "$(subdir)/$$i"; \
|
||||
else \
|
||||
echo "$$sdir/$$i"; \
|
||||
fi; \
|
||||
done >> $(top_builddir)/cscope.files
|
||||
|
||||
distclean-tags:
|
||||
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
|
||||
|
||||
distdir: $(DISTFILES)
|
||||
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
list='$(DISTFILES)'; \
|
||||
dist_files=`for file in $$list; do echo $$file; done | \
|
||||
sed -e "s|^$$srcdirstrip/||;t" \
|
||||
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
|
||||
case $$dist_files in \
|
||||
*/*) $(MKDIR_P) `echo "$$dist_files" | \
|
||||
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
|
||||
sort -u` ;; \
|
||||
esac; \
|
||||
for file in $$dist_files; do \
|
||||
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
|
||||
if test -d $$d/$$file; then \
|
||||
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
|
||||
if test -d "$(distdir)/$$file"; then \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
|
||||
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
|
||||
else \
|
||||
test -f "$(distdir)/$$file" \
|
||||
|| cp -p $$d/$$file "$(distdir)/$$file" \
|
||||
|| exit 1; \
|
||||
fi; \
|
||||
done
|
||||
check-am: all-am
|
||||
check: check-am
|
||||
all-am: Makefile $(PROGRAMS)
|
||||
installdirs:
|
||||
for dir in "$(DESTDIR)$(bindir)"; do \
|
||||
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
|
||||
done
|
||||
install: install-am
|
||||
install-exec: install-exec-am
|
||||
install-data: install-data-am
|
||||
uninstall: uninstall-am
|
||||
|
||||
install-am: all-am
|
||||
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
|
||||
|
||||
installcheck: installcheck-am
|
||||
install-strip:
|
||||
if test -z '$(STRIP)'; then \
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
install; \
|
||||
else \
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
|
||||
fi
|
||||
mostlyclean-generic:
|
||||
|
||||
clean-generic:
|
||||
|
||||
distclean-generic:
|
||||
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
|
||||
|
||||
maintainer-clean-generic:
|
||||
@echo "This command is intended for maintainers to use"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
clean: clean-am
|
||||
|
||||
clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
|
||||
|
||||
distclean: distclean-am
|
||||
-rm -rf ./$(DEPDIR)
|
||||
-rm -f Makefile
|
||||
distclean-am: clean-am distclean-compile distclean-generic \
|
||||
distclean-tags
|
||||
|
||||
dvi: dvi-am
|
||||
|
||||
dvi-am:
|
||||
|
||||
html: html-am
|
||||
|
||||
html-am:
|
||||
|
||||
info: info-am
|
||||
|
||||
info-am:
|
||||
|
||||
install-data-am:
|
||||
|
||||
install-dvi: install-dvi-am
|
||||
|
||||
install-dvi-am:
|
||||
|
||||
install-exec-am: install-binPROGRAMS install-exec-local
|
||||
|
||||
install-html: install-html-am
|
||||
|
||||
install-html-am:
|
||||
|
||||
install-info: install-info-am
|
||||
|
||||
install-info-am:
|
||||
|
||||
install-man:
|
||||
|
||||
install-pdf: install-pdf-am
|
||||
|
||||
install-pdf-am:
|
||||
|
||||
install-ps: install-ps-am
|
||||
|
||||
install-ps-am:
|
||||
|
||||
installcheck-am:
|
||||
|
||||
maintainer-clean: maintainer-clean-am
|
||||
-rm -rf ./$(DEPDIR)
|
||||
-rm -f Makefile
|
||||
maintainer-clean-am: distclean-am maintainer-clean-generic
|
||||
|
||||
mostlyclean: mostlyclean-am
|
||||
|
||||
mostlyclean-am: mostlyclean-compile mostlyclean-generic
|
||||
|
||||
pdf: pdf-am
|
||||
|
||||
pdf-am:
|
||||
|
||||
ps: ps-am
|
||||
|
||||
ps-am:
|
||||
|
||||
uninstall-am: uninstall-binPROGRAMS
|
||||
|
||||
.MAKE: install-am install-strip
|
||||
|
||||
.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \
|
||||
clean-generic cscopelist ctags distclean distclean-compile \
|
||||
distclean-generic distclean-tags distdir dvi dvi-am html \
|
||||
html-am info info-am install install-am install-binPROGRAMS \
|
||||
install-data install-data-am install-dvi install-dvi-am \
|
||||
install-exec install-exec-am install-exec-local install-html \
|
||||
install-html-am install-info install-info-am install-man \
|
||||
install-pdf install-pdf-am install-ps install-ps-am \
|
||||
install-strip installcheck installcheck-am installdirs \
|
||||
maintainer-clean maintainer-clean-generic mostlyclean \
|
||||
mostlyclean-compile mostlyclean-generic pdf pdf-am ps ps-am \
|
||||
tags uninstall uninstall-am uninstall-binPROGRAMS
|
||||
|
||||
|
||||
install-exec-local: install-binPROGRAMS
|
||||
(cd $(DESTDIR)$(bindir); ln -sf prt-get prt-cache)
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
||||
@@ -128,7 +128,7 @@ const string& ArgParser::alternateConfigFile() const
|
||||
*/
|
||||
bool ArgParser::parse()
|
||||
{
|
||||
const int commandCount = 35;
|
||||
const int commandCount = 34;
|
||||
string commands[commandCount] = { "list", "search", "dsearch",
|
||||
"info", "version", "cache",
|
||||
"depends", "install", "depinst",
|
||||
@@ -139,7 +139,7 @@ bool ArgParser::parse()
|
||||
"fsearch", "lock", "unlock",
|
||||
"listlocked", "cat", "ls", "edit",
|
||||
"remove", "deptree", "dumpconfig",
|
||||
"listorphans", "sync" };
|
||||
"listorphans" };
|
||||
|
||||
Type commandID[commandCount] = { LIST, SEARCH, DSEARCH, INFO,
|
||||
SHOW_VERSION, CREATE_CACHE,
|
||||
@@ -150,7 +150,7 @@ bool ArgParser::parse()
|
||||
DEPENDENT, SYSUP, CURRENT,
|
||||
FSEARCH, LOCK, UNLOCK, LISTLOCKED,
|
||||
CAT, LS, EDIT, REMOVE, DEPTREE,
|
||||
DUMPCONFIG, LISTORPHANS, SYNC };
|
||||
DUMPCONFIG, LISTORPHANS };
|
||||
if ( m_argc < 2 ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ public:
|
||||
LISTINST, PRINTF, README, DEPENDENT, SYSUP,
|
||||
CURRENT, FSEARCH, LOCK, UNLOCK, LISTLOCKED,
|
||||
CAT, LS, EDIT, REMOVE,
|
||||
DEPTREE, DUMPCONFIG, LISTORPHANS, SYNC };
|
||||
DEPTREE, DUMPCONFIG, LISTORPHANS };
|
||||
|
||||
bool isCommandGiven() const;
|
||||
bool isTest() const;
|
||||
|
||||
@@ -37,7 +37,8 @@ Configuration::Configuration( const std::string& configFile,
|
||||
m_useRegex( false ),
|
||||
m_followSoftdeps( false ),
|
||||
m_makeCommand( "" ), m_addCommand( "" ),
|
||||
m_removeCommand( "" ), m_runscriptCommand( "" )
|
||||
m_removeCommand( "" ), m_runscriptCommand( "" ),
|
||||
m_packageDir( "" ), m_compressionMode( "" )
|
||||
{
|
||||
|
||||
}
|
||||
@@ -95,6 +96,25 @@ string Configuration::logFilePattern() const
|
||||
return m_logFilePattern;
|
||||
}
|
||||
|
||||
string Configuration::packageDir() const
|
||||
{
|
||||
string value = "";
|
||||
char line[256];
|
||||
string cmd = "eval " + m_packageDir + " && echo \"$PKGMK_PACKAGE_DIR\"";
|
||||
FILE* p = popen(cmd.c_str(), "r");
|
||||
if (p) {
|
||||
fgets(line, 256, p);
|
||||
value = StringHelper::stripWhiteSpace(line);
|
||||
pclose(p);
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
string Configuration::compressionMode() const
|
||||
{
|
||||
return ( m_compressionMode == "" ) ? "gz" : m_compressionMode;
|
||||
}
|
||||
|
||||
const list< pair<string, string> >& Configuration::rootList() const
|
||||
{
|
||||
@@ -228,6 +248,32 @@ void Configuration::parseLine(const string& line, bool prepend)
|
||||
}
|
||||
}
|
||||
|
||||
bool Configuration::parsePkgmkConf(int readOrder)
|
||||
{
|
||||
string fileName = (readOrder == 1) ? "/etc/pkgmk.conf" : "/usr/bin/pkgmk";
|
||||
FILE* fp = fopen(fileName.c_str(), "r");
|
||||
if (!fp)
|
||||
return false;
|
||||
|
||||
string s;
|
||||
char line[256];
|
||||
while (fgets(line, 256, fp)) {
|
||||
s = StringHelper::stripWhiteSpace(getValueBefore(line,'#'));
|
||||
if ( StringHelper::startsWith(s, "PKGMK_COMPRESSION_MODE=") &&
|
||||
(readOrder==1 || m_compressionMode == "") ) {
|
||||
m_compressionMode = s.substr(23);
|
||||
StringHelper::replaceAll(m_compressionMode,"\"","");
|
||||
StringHelper::replaceAll(m_compressionMode,"'","");
|
||||
} else if ( StringHelper::startsWith(s, "PKGMK_PACKAGE_DIR=") &&
|
||||
(readOrder==1 || m_packageDir == "" ) ) {
|
||||
m_packageDir = s;
|
||||
}
|
||||
}
|
||||
fclose(fp);
|
||||
|
||||
return ( m_compressionMode != "" && m_packageDir != "" );
|
||||
}
|
||||
|
||||
bool Configuration::runScripts() const
|
||||
{
|
||||
return m_runScripts;
|
||||
|
||||
@@ -46,6 +46,8 @@ public:
|
||||
bool useRegex() const;
|
||||
bool followSoftdeps() const;
|
||||
|
||||
bool parsePkgmkConf(int readOrder);
|
||||
|
||||
void addConfig(const std::string& line,
|
||||
bool configSet,
|
||||
bool configPrepend);
|
||||
@@ -54,6 +56,8 @@ public:
|
||||
std::string addCommand() const;
|
||||
std::string removeCommand() const;
|
||||
std::string runscriptCommand() const;
|
||||
std::string packageDir() const;
|
||||
std::string compressionMode() const;
|
||||
|
||||
private:
|
||||
std::string m_configFile;
|
||||
@@ -82,6 +86,8 @@ private:
|
||||
std::string m_removeCommand;
|
||||
std::string m_runscriptCommand;
|
||||
|
||||
std::string m_packageDir;
|
||||
std::string m_compressionMode;
|
||||
|
||||
void parseLine(const std::string& line, bool prepend=false);
|
||||
};
|
||||
|
||||
@@ -185,17 +185,17 @@ InstallTransaction::install( const ArgParser* parser,
|
||||
InstallTransaction::InstallResult result;
|
||||
InstallInfo info( package->hasReadme() );
|
||||
if ( parser->isTest() ) {
|
||||
info.preState = ( package->hasPreInstall() &&
|
||||
(parser->execPreInstall() || m_config->runScripts())
|
||||
) ? DEFERRED : NONEXISTENT;
|
||||
info.postState = ( package->hasPostInstall() &&
|
||||
(parser->execPostInstall() || m_config->runScripts())
|
||||
) ? DEFERRED : NONEXISTENT;
|
||||
m_installedPackages.push_back( make_pair( package->path()
|
||||
+ "/" + package->name(), info));
|
||||
continue;
|
||||
}
|
||||
|
||||
info.preState = ( package->hasPreInstall() &&
|
||||
(parser->execPreInstall() || m_config->runScripts())
|
||||
) ? DEFERRED : NONEXISTENT;
|
||||
info.postState = ( package->hasPostInstall() &&
|
||||
(parser->execPostInstall() || m_config->runScripts())
|
||||
) ? DEFERRED : NONEXISTENT;
|
||||
m_installedPackages.push_back( make_pair(package->path()
|
||||
+ "/" + package->name(), info) );
|
||||
continue;
|
||||
}
|
||||
|
||||
if ((result = installPackage( package, parser, update, info )) == SUCCESS) {
|
||||
|
||||
m_installedPackages.push_back( make_pair( package->path()
|
||||
@@ -252,7 +252,7 @@ InstallTransaction::installPackage( const Package* package,
|
||||
commandName = "prt-cache";
|
||||
}
|
||||
|
||||
// - initial information about the package to be build
|
||||
// - initial information about the package to be built
|
||||
string message;
|
||||
message = commandName + ": ";
|
||||
if (update) {
|
||||
@@ -324,10 +324,9 @@ InstallTransaction::installPackage( const Package* package,
|
||||
// -- pre-install
|
||||
struct stat statData;
|
||||
if ((parser->execPreInstall() || m_config->runScripts()) &&
|
||||
stat((parser->installRoot() + pkgdir + "/" + "pre-install").c_str(), &statData) == 0) {
|
||||
Process preProc( runscriptCommand,
|
||||
pkgdir + "/" + "pre-install",
|
||||
fdlog );
|
||||
stat((parser->installRoot() + pkgdir + "/" + "pre-install").c_str(),
|
||||
&statData) == 0) {
|
||||
Process preProc( runscriptCommand, pkgdir + "/" + "pre-install", fdlog );
|
||||
if (preProc.executeShell()) {
|
||||
info.preState = FAILED;
|
||||
} else {
|
||||
@@ -342,12 +341,18 @@ InstallTransaction::installPackage( const Package* package,
|
||||
}
|
||||
|
||||
string args = "-d " + parser->pkgmkArgs();
|
||||
// do not force a rebuild unless the port was given on the command line
|
||||
if ( parser->pkgmkArgs().find(" -f")!=string::npos &&
|
||||
find(parser->otherArgs().begin(), parser->otherArgs().end(),
|
||||
package->name()) == parser->otherArgs().end() ) {
|
||||
StringHelper::replaceAll(args," -f", "");
|
||||
}
|
||||
Process makeProc( cmd, args, fdlog );
|
||||
if ( makeProc.executeShell() ) {
|
||||
result = PKGMK_FAILURE;
|
||||
} else {
|
||||
// -- update
|
||||
string pkgdest = getPkgmkPackageDir();
|
||||
string pkgdest = m_config->packageDir();
|
||||
if ( pkgdest != "" ) {
|
||||
// TODO: don't manipulate pkgdir
|
||||
pkgdir = pkgdest;
|
||||
@@ -385,7 +390,7 @@ InstallTransaction::installPackage( const Package* package,
|
||||
args +=
|
||||
package->name() + "#" +
|
||||
package->version() + "-" +
|
||||
package->release() + ".pkg.tar." + getPkgmkCompressionMode();
|
||||
package->release() + ".pkg.tar." + m_config->compressionMode();
|
||||
|
||||
|
||||
// - inform the user about what's happening
|
||||
@@ -432,14 +437,12 @@ InstallTransaction::installPackage( const Package* package,
|
||||
} else {
|
||||
// exec post install
|
||||
if ((parser->execPostInstall() || m_config->runScripts() ) &&
|
||||
stat((parser->installRoot() + package->path()
|
||||
+ "/" + package->name() + "/" + "post-install").c_str(),
|
||||
&statData) == 0) {
|
||||
stat((parser->installRoot() + "/" + package->path() + "/"
|
||||
+ package->name() + "/" + "post-install").c_str(),
|
||||
&statData) == 0) {
|
||||
// Work around the pkgdir variable change
|
||||
Process postProc( runscriptCommand,
|
||||
package->path() + "/" + package->name()+
|
||||
"/" + "post-install",
|
||||
fdlog );
|
||||
Process postProc( runscriptCommand, package->path() + "/"
|
||||
+ package->name() + "/post-install", fdlog );
|
||||
if (postProc.executeShell()) {
|
||||
info.postState = FAILED;
|
||||
} else {
|
||||
@@ -572,7 +575,7 @@ void InstallTransaction::checkDependencies( bool greedy,
|
||||
for ( ; it != optionals.end(); ++it ) {
|
||||
string softdep = *it;
|
||||
if ( softdep.empty() ) { continue; }
|
||||
if ( isRequired(softdep) ) {
|
||||
if ( isRequired(softdep) ) {
|
||||
const Package* p = m_repo->getPackage( softdep );
|
||||
if ( p ) {
|
||||
checkDependencies( true, p, index );
|
||||
@@ -670,7 +673,7 @@ InstallTransaction::calcDependencies( )
|
||||
}
|
||||
}
|
||||
if ( !validPackages ) {
|
||||
return PACKAGE_NOT_FOUND;
|
||||
return NO_PACKAGE_GIVEN;
|
||||
}
|
||||
|
||||
if ( !calculateDependencies() ) {
|
||||
@@ -680,64 +683,7 @@ InstallTransaction::calcDependencies( )
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* getPkgDest assumes that you're in the build directory already
|
||||
*/
|
||||
string InstallTransaction::getPkgmkSetting(const string& setting)
|
||||
{
|
||||
string value = "";
|
||||
value = getPkgmkSettingFromFile(setting, "/etc/pkgmk.conf");
|
||||
if (value.size() == 0) {
|
||||
value = getPkgmkSettingFromFile(setting, "/usr/bin/pkgmk");
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
string InstallTransaction::getPkgmkSettingFromFile(const string& setting, const string& fileName)
|
||||
{
|
||||
FILE* fp = fopen(fileName.c_str(), "r");
|
||||
if (!fp)
|
||||
return "";
|
||||
|
||||
string candidate;
|
||||
string s;
|
||||
char line[256];
|
||||
while (fgets(line, 256, fp)) {
|
||||
s = StringHelper::stripWhiteSpace(line);
|
||||
if (StringHelper::startsWith(s, setting + "=")) {
|
||||
candidate = s;
|
||||
}
|
||||
}
|
||||
fclose(fp);
|
||||
|
||||
string value = "";
|
||||
if (candidate.length() > 0) {
|
||||
string cmd = "eval " + candidate + " && echo $" + setting;
|
||||
FILE* p = popen(cmd.c_str(), "r");
|
||||
if (p) {
|
||||
fgets(line, 256, p);
|
||||
value = StringHelper::stripWhiteSpace(line);
|
||||
pclose(p);
|
||||
}
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
const list<string>& InstallTransaction::ignoredPackages() const
|
||||
{
|
||||
return m_ignoredPackages;
|
||||
}
|
||||
|
||||
string InstallTransaction::getPkgmkPackageDir()
|
||||
{
|
||||
return getPkgmkSetting("PKGMK_PACKAGE_DIR");
|
||||
}
|
||||
|
||||
string InstallTransaction::getPkgmkCompressionMode()
|
||||
{
|
||||
string value = getPkgmkSetting("PKGMK_COMPRESSION_MODE");
|
||||
|
||||
return value.size() ? value : "gz";
|
||||
}
|
||||
|
||||
@@ -67,9 +67,9 @@ public:
|
||||
};
|
||||
|
||||
enum State {
|
||||
DEFERRED,
|
||||
EXEC_SUCCESS,
|
||||
FAILED,
|
||||
DEFERRED,
|
||||
NONEXISTENT
|
||||
};
|
||||
struct InstallInfo {
|
||||
@@ -96,9 +96,6 @@ public:
|
||||
const list< pair<string,string> >& missing() const;
|
||||
const list< pair<string, InstallInfo> >& installError() const;
|
||||
|
||||
static string getPkgmkPackageDir();
|
||||
static string getPkgmkCompressionMode();
|
||||
|
||||
private:
|
||||
bool calculateDependencies();
|
||||
void checkDependencies( bool greedy, const Package* package, int depends=-1 );
|
||||
@@ -109,10 +106,6 @@ private:
|
||||
InstallInfo& info ) const;
|
||||
bool isRequired(const string &pname);
|
||||
|
||||
static string getPkgmkSetting(const string& setting);
|
||||
static string getPkgmkSettingFromFile(const string& setting,
|
||||
const string& fileName);
|
||||
|
||||
PkgDB* m_pkgDB;
|
||||
DepResolver m_resolver;
|
||||
const Repository* m_repo;
|
||||
|
||||
@@ -161,9 +161,6 @@ int main( int argc, char** argv )
|
||||
case ArgParser::LISTORPHANS:
|
||||
prtGet.listOrphans();
|
||||
break;
|
||||
case ArgParser::SYNC:
|
||||
prtGet.syncPorts();
|
||||
break;
|
||||
default:
|
||||
cerr << "unknown command" << endl;
|
||||
break;
|
||||
|
||||
@@ -213,50 +213,17 @@ void Package::load() const
|
||||
|
||||
StringHelper::replaceAll( softdeps, " ", "," );
|
||||
StringHelper::replaceAll( softdeps, ",,", "," );
|
||||
StringHelper::replaceAll( softdeps, "(", "" );
|
||||
StringHelper::replaceAll( softdeps, ")", "" );
|
||||
|
||||
// TODO: decide which one to use
|
||||
#if 0
|
||||
// remove commented out packages
|
||||
list<string> softDepList = StringHelper::split( softdeps, ',' );
|
||||
list<string>::iterator it = deps.begin();
|
||||
for ( ; it != softDepList.end(); ++it ) {
|
||||
if ( (*it)[0] == '#' ) {
|
||||
cerr << "Commented dep: " << *it << endl;
|
||||
} else {
|
||||
if ( it != softDepsList.begin() ) {
|
||||
m_data->optionals += ",";
|
||||
}
|
||||
m_data->optionals += *it;
|
||||
}
|
||||
}
|
||||
#else
|
||||
m_data->optionals = softdeps;
|
||||
#endif
|
||||
} else if ( startsWithNoCase( line, "dep" ) ) {
|
||||
string depends = stripWhiteSpace( getValue( line, ':' ) );
|
||||
|
||||
StringHelper::replaceAll( depends, " ", "," );
|
||||
StringHelper::replaceAll( depends, ",,", "," );
|
||||
|
||||
// TODO: decide which one to use
|
||||
#if 0
|
||||
// remove commented out packages
|
||||
list<string> deps = StringHelper::split( depends, ',' );
|
||||
list<string>::iterator it = deps.begin();
|
||||
for ( ; it != deps.end(); ++it ) {
|
||||
if ( (*it)[0] == '#' ) {
|
||||
cerr << "Commented dep: " << *it << endl;
|
||||
} else {
|
||||
if ( it != deps.begin() ) {
|
||||
m_data->depends += ",";
|
||||
}
|
||||
m_data->depends += *it;
|
||||
}
|
||||
}
|
||||
#else
|
||||
m_data->depends = depends;
|
||||
#endif
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
224
src/prtget.cpp
224
src/prtget.cpp
@@ -271,7 +271,7 @@ void PrtGet::listShadowed()
|
||||
if (m_parser->otherArgs().size() > 0)
|
||||
format = *(m_parser->otherArgs().begin());
|
||||
else if (m_parser->verbose() > 0)
|
||||
format = "* %n\n %p1 %v1 precedes over \n %p2 %v2\n";
|
||||
format = "* %n\n %p1 %v1 preceeds over \n %p2 %v2\n";
|
||||
|
||||
string output;
|
||||
Package* p1;
|
||||
@@ -614,23 +614,29 @@ void PrtGet::install( bool update, bool dependencies )
|
||||
}
|
||||
} else {
|
||||
for ( ; it != args.end(); ++it ) {
|
||||
string s = *it;
|
||||
string s = *it;
|
||||
if ( m_pkgDB->isInstalled( s ) ) {
|
||||
// pkgadd will fail on these, since it won't be given the -u flag
|
||||
invalidArgs.push_back( s );
|
||||
// pkgadd will fail on these, since it won't be given the -u flag
|
||||
invalidArgs.push_back( s );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ( invalidArgs.size() > 0 ) {
|
||||
string attemptedOp = ( update ) ? "update" : "install";
|
||||
attemptedOp += " the following packages ";
|
||||
attemptedOp += ( update ) ? "(not yet installed)" : "(already installed)";
|
||||
cout << "cannot "<< attemptedOp <<endl;
|
||||
if ( (invalidArgs.size() > 0 && update) ||
|
||||
(invalidArgs.size() == args.size() && !update) ) {
|
||||
string invalidHeader = "-- Packages installed before this run (ignored)";
|
||||
if (update) { invalidHeader = "-- Cannot update the following (not yet installed)"; }
|
||||
if (m_parser->isTest()) {
|
||||
cout << "*** prt-get: test mode" << endl << endl;
|
||||
}
|
||||
cout << invalidHeader << endl;
|
||||
list<string>::const_iterator it = invalidArgs.begin();
|
||||
for ( ; it != invalidArgs.end(); ++it ) {
|
||||
cout << *it << endl;
|
||||
}
|
||||
if (m_parser->isTest()) {
|
||||
cout << "*** prt-get: test mode end" << endl;
|
||||
}
|
||||
m_returnValue = PG_GENERAL_ERROR ;
|
||||
return;
|
||||
}
|
||||
@@ -649,18 +655,17 @@ void PrtGet::install( bool update, bool dependencies )
|
||||
cerr << "prt-get: cyclic dependencies found" << endl;
|
||||
m_returnValue = PG_GENERAL_ERROR;
|
||||
return;
|
||||
} else if ( result == InstallTransaction::PACKAGE_NOT_FOUND ) {
|
||||
warnPackageNotFound(depTransaction);
|
||||
m_returnValue = PG_GENERAL_ERROR;
|
||||
return;
|
||||
}
|
||||
const list<string>& depRef = depTransaction.dependencies();
|
||||
list<string>::const_iterator it = depRef.begin();
|
||||
list<string> deps = depTransaction.dependencies();
|
||||
const list< pair<string, string> >& depMissing = depTransaction.missing();
|
||||
list< pair<string,string> >::const_iterator it = depMissing.begin();
|
||||
|
||||
list<string> deps;
|
||||
for (; it != depRef.end(); ++it) {
|
||||
if (!m_pkgDB->isInstalled(*it)) {
|
||||
deps.push_back(*it);
|
||||
// ensure that missing ports are retained for the post-transaction
|
||||
// summary (FS#1843). Exempt any ports that were installed manually
|
||||
// or from a repo that has since been deactivated.
|
||||
for (; it != depMissing.end(); ++it) {
|
||||
if (! m_pkgDB->isInstalled(it->first)) {
|
||||
deps.push_back(it->first);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -706,7 +711,7 @@ void PrtGet::executeTransaction( InstallTransaction& transaction,
|
||||
break;
|
||||
case InstallTransaction::PKGDEST_ERROR:
|
||||
cout << m_appName << ": error changing to PKGDEST directory "
|
||||
<< transaction.getPkgmkPackageDir() << endl;
|
||||
<< m_config->packageDir() << endl;
|
||||
failed = true;
|
||||
break;
|
||||
case InstallTransaction::PKGADD_FAILURE:
|
||||
@@ -853,6 +858,10 @@ void PrtGet::readConfig()
|
||||
}
|
||||
}
|
||||
|
||||
if (!m_config->parsePkgmkConf(1)) {
|
||||
m_config->parsePkgmkConf(0);
|
||||
}
|
||||
|
||||
const list< pair<char*, ArgParser::ConfigArgType> >& configData =
|
||||
m_parser->configData();
|
||||
list< pair<char*, ArgParser::ConfigArgType> >::const_iterator it =
|
||||
@@ -1173,7 +1182,7 @@ void PrtGet::evaluateResult( InstallTransaction& transaction,
|
||||
|
||||
cout << endl;
|
||||
|
||||
if ( errors == 0 && !interrupted ) {
|
||||
if ( inst.size() && errors == 0 && !interrupted ) {
|
||||
cout << "prt-get: " << command[1] << " successfully" << endl;
|
||||
} else {
|
||||
m_returnValue = PG_PARTIAL_INSTALL_ERROR;
|
||||
@@ -1182,16 +1191,18 @@ void PrtGet::evaluateResult( InstallTransaction& transaction,
|
||||
|
||||
void PrtGet::reportPrePost(const InstallTransaction::InstallInfo& info) {
|
||||
if (info.preState != InstallTransaction::NONEXISTENT) {
|
||||
string preString = (info.preState == InstallTransaction::FAILED) ? "failed" : "ok";
|
||||
if (info.preState == InstallTransaction::DEFERRED){
|
||||
preString = "deferred";
|
||||
string preString =
|
||||
(info.preState == InstallTransaction::FAILED) ? "failed" : "ok";
|
||||
if (info.preState == InstallTransaction::DEFERRED) {
|
||||
preString = "deferred";
|
||||
}
|
||||
cout << " [pre: " << preString << "]";
|
||||
}
|
||||
if ( info.postState != InstallTransaction::NONEXISTENT) {
|
||||
string postString = (info.postState == InstallTransaction::FAILED) ? "failed" : "ok";
|
||||
if (info.postState == InstallTransaction::DEFERRED){
|
||||
postString = "deferred";
|
||||
string postString =
|
||||
(info.postState == InstallTransaction::FAILED) ? "failed" : "ok";
|
||||
if (info.postState == InstallTransaction::DEFERRED) {
|
||||
postString = "deferred";
|
||||
}
|
||||
cout << " [post: " << postString << "]";
|
||||
}
|
||||
@@ -1928,10 +1939,10 @@ void PrtGet::remove()
|
||||
|
||||
if ( m_parser->isTest() ) {
|
||||
cout << "*** " << m_appName << ": test mode" << endl;
|
||||
} else if ( m_config->removeLogOnUninst()
|
||||
&& m_config->logFilePattern().find("%p") != string::npos ) {
|
||||
needRepo = true;
|
||||
initRepo();
|
||||
} else if ( m_config->removeLogOnUninst()
|
||||
&& m_config->logFilePattern().find("%p") != string::npos ) {
|
||||
needRepo = true;
|
||||
initRepo();
|
||||
}
|
||||
|
||||
string command = InstallTransaction::PKGRM_DEFAULT_COMMAND;
|
||||
@@ -1943,8 +1954,10 @@ void PrtGet::remove()
|
||||
list<char*>::const_iterator it = args.begin();
|
||||
for ( ; it != args.end(); ++it ) {
|
||||
if (m_pkgDB->isInstalled(*it)) {
|
||||
string rm_args = (m_parser->installRoot() == "") ? "" :
|
||||
"-r " + m_parser->installRoot() + " ";
|
||||
string rm_args = "";
|
||||
if (m_parser->installRoot() != "") {
|
||||
rm_args = "-r " + m_parser->installRoot() + " ";
|
||||
}
|
||||
rm_args += (m_parser->pkgrmArgs() + " " + *it);
|
||||
|
||||
Process proc(command, rm_args);
|
||||
@@ -1954,35 +1967,35 @@ void PrtGet::remove()
|
||||
m_locker.unlock(*it);
|
||||
m_locker.store();
|
||||
}
|
||||
if (m_config->removeLogOnUninst() && !m_parser->isTest()) {
|
||||
string rm_logFile = m_config->logFilePattern();
|
||||
bool doneSubs=false;
|
||||
const string pkgname = *it;
|
||||
StringHelper::replaceAll( rm_logFile, "%n", pkgname );
|
||||
const string rm_ver = m_pkgDB->getPackageVersion( pkgname );
|
||||
size_t pos = rm_ver.find_last_of('-');
|
||||
if (pos != string::npos) {
|
||||
const string rm_v = rm_ver.substr(0,pos);
|
||||
const string rm_r = rm_ver.substr(pos+1);
|
||||
StringHelper::replaceAll( rm_logFile, "%v", rm_v );
|
||||
StringHelper::replaceAll( rm_logFile, "%r", rm_r );
|
||||
}
|
||||
if (! needRepo) {
|
||||
doneSubs=true;
|
||||
} else if (m_repo->getPackage( pkgname )) {
|
||||
StringHelper::replaceAll( rm_logFile, "%p",
|
||||
m_repo->getPackage( pkgname )->path() );
|
||||
doneSubs=true;
|
||||
} else {
|
||||
cout << "Warning: unable to determine the logfile for "
|
||||
+ pkgname + "; log removal aborted." << endl;
|
||||
}
|
||||
struct stat slF;
|
||||
if ( doneSubs && stat(rm_logFile.c_str(), &slF)==0
|
||||
&& (slF.st_mode & S_IFMT)==S_IFREG ) {
|
||||
unlink( rm_logFile.c_str() );
|
||||
}
|
||||
}
|
||||
if (m_config->removeLogOnUninst() && !m_parser->isTest()) {
|
||||
string rm_logFile = m_config->logFilePattern();
|
||||
bool doneSubs=false;
|
||||
const string pkgname = *it;
|
||||
StringHelper::replaceAll( rm_logFile, "%n", pkgname );
|
||||
const string rm_ver = m_pkgDB->getPackageVersion( pkgname );
|
||||
size_t pos = rm_ver.find_last_of('-');
|
||||
if (pos != string::npos) {
|
||||
const string rm_v = rm_ver.substr(0,pos);
|
||||
const string rm_r = rm_ver.substr(pos+1);
|
||||
StringHelper::replaceAll( rm_logFile, "%v", rm_v );
|
||||
StringHelper::replaceAll( rm_logFile, "%r", rm_r );
|
||||
}
|
||||
if (! needRepo) {
|
||||
doneSubs=true;
|
||||
} else if (m_repo->getPackage( pkgname )) {
|
||||
StringHelper::replaceAll( rm_logFile, "%p",
|
||||
m_repo->getPackage( pkgname )->path() );
|
||||
doneSubs=true;
|
||||
} else {
|
||||
cout << "Warning: unable to determine the logfile for "
|
||||
+ pkgname + "; log removal aborted." << endl;
|
||||
}
|
||||
struct stat slF;
|
||||
if ( doneSubs && stat(rm_logFile.c_str(), &slF)==0
|
||||
&& (slF.st_mode & S_IFMT)==S_IFREG ) {
|
||||
unlink( rm_logFile.c_str() );
|
||||
}
|
||||
}
|
||||
} else {
|
||||
failed.push_back(*it);
|
||||
}
|
||||
@@ -2266,18 +2279,17 @@ void PrtGet::dumpConfig()
|
||||
cout.setf( ios::left, ios::adjustfield );
|
||||
cout.width( 20 );
|
||||
cout.fill( ' ' );
|
||||
cout << "Pkgmk settings: " << m_config->logFilePattern() << endl;
|
||||
cout << "Pkgmk settings: " << endl;
|
||||
cout.setf( ios::left, ios::adjustfield );
|
||||
cout.width( 20 );
|
||||
cout.fill( ' ' );
|
||||
cout << " Package dir: " << InstallTransaction::getPkgmkPackageDir()
|
||||
cout << " Package dir: " << m_config->packageDir()
|
||||
<< endl;
|
||||
|
||||
cout.setf( ios::left, ios::adjustfield );
|
||||
cout.width( 20 );
|
||||
cout.fill( ' ' );
|
||||
cout << " Compression mode: "
|
||||
<< InstallTransaction::getPkgmkCompressionMode() << endl;
|
||||
cout << " Compression mode: " << m_config->compressionMode() << endl;
|
||||
|
||||
|
||||
cout << endl;
|
||||
@@ -2294,81 +2306,3 @@ void PrtGet::dumpConfig()
|
||||
cout << endl;
|
||||
}
|
||||
}
|
||||
|
||||
void PrtGet::syncPorts()
|
||||
{
|
||||
const string sup_path = m_parser->installRoot() + "/etc/ports";
|
||||
const string driver_path = sup_path + "/drivers";
|
||||
DIR* d = opendir(driver_path.c_str());
|
||||
if (d == NULL) {
|
||||
cerr << "Ports drivers directory " << driver_path.c_str()
|
||||
<< " not found. Aborting sync." << endl;
|
||||
m_returnValue = PG_GENERAL_ERROR;
|
||||
return;
|
||||
}
|
||||
struct dirent* de;
|
||||
struct stat buf;
|
||||
list<string> drivers;
|
||||
while ( (de = readdir(d)) ) {
|
||||
string drvName = de->d_name;
|
||||
if (drvName != "." && drvName != ".." && stat((driver_path + "/" + drvName).c_str(), &buf) == 0
|
||||
&& buf.st_mode & S_IXUSR ) {
|
||||
drivers.push_back(drvName);
|
||||
}
|
||||
}
|
||||
closedir(d);
|
||||
|
||||
if (drivers.size() == 0) {
|
||||
cerr << "No valid ports drivers. Aborting sync." << endl;
|
||||
m_returnValue = PG_GENERAL_ERROR;
|
||||
return;
|
||||
}
|
||||
|
||||
if (m_parser->otherArgs().size()) { // sync selected repositories, with
|
||||
drivers.sort(); // multi-stage processing done predictably
|
||||
bool repo_active;
|
||||
list<char*>::const_iterator itc = m_parser->otherArgs().begin();
|
||||
list<string>::const_iterator itd;
|
||||
for (; itc != m_parser->otherArgs().end(); ++itc) {
|
||||
repo_active = false;
|
||||
for (itd = drivers.begin(); itd != drivers.end(); ++itd) {
|
||||
if (stat((sup_path + "/" + *itc + "." + *itd).c_str(),&buf) == 0) {
|
||||
repo_active = true;
|
||||
Process syncProc( driver_path + "/" + *itd,
|
||||
sup_path + "/" + *itc + "." + *itd, -1 );
|
||||
if (syncProc.execute()) {
|
||||
m_returnValue = PG_GENERAL_ERROR;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (! repo_active) {
|
||||
cerr << *itc << ": not a valid port collection" << endl;
|
||||
}
|
||||
}
|
||||
} else { // sync all active repositories
|
||||
list<string> activeRepos;
|
||||
size_t pos;
|
||||
d = opendir(sup_path.c_str());
|
||||
while ( (de = readdir(d)) ) {
|
||||
string rName = de->d_name;
|
||||
pos = rName.find_last_of(".");
|
||||
if ( pos != string::npos && find(drivers.begin(), drivers.end(),
|
||||
rName.substr(pos+1)) != drivers.end() ) {
|
||||
activeRepos.push_back(rName);
|
||||
}
|
||||
}
|
||||
closedir(d);
|
||||
|
||||
activeRepos.sort();
|
||||
list<string>::const_iterator ite = activeRepos.begin();
|
||||
for ( ; ite != activeRepos.end(); ++ite) {
|
||||
pos = (*ite).find_last_of(".");
|
||||
Process syncProc( driver_path + "/" + (*ite).substr(pos+1),
|
||||
sup_path + "/" + *ite, -1 );
|
||||
if (syncProc.execute()) {
|
||||
m_returnValue = PG_GENERAL_ERROR;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -71,7 +71,6 @@ public:
|
||||
void printDiff();
|
||||
void printQuickDiff();
|
||||
void listOrphans();
|
||||
void syncPorts();
|
||||
|
||||
void createCache();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user