Index: head/ports-mgmt/pkg/Makefile =================================================================== --- head/ports-mgmt/pkg/Makefile (revision 455545) +++ head/ports-mgmt/pkg/Makefile (revision 455546) @@ -1,84 +1,81 @@ # $FreeBSD$ PORTNAME= pkg -DISTVERSION= 1.10.2 -PORTREVISION= 1 +DISTVERSION= 1.10.3 _PKG_VERSION= ${DISTVERSION} CATEGORIES= ports-mgmt MASTER_SITES= \ http://files.etoilebsd.net/${PORTNAME}/ \ LOCAL/portmgr \ http://mirror.shatow.net/freebsd/${PORTNAME}/ \ MAINTAINER= pkg@FreeBSD.org COMMENT= Package manager LICENSE= BSD2CLAUSE USE_LDCONFIG= yes USES= libtool tar:xz GNU_CONFIGURE= yes CONFIGURE_ARGS= --disable-maintainer-mode INSTALL_TARGET= install-strip PORTDOCS= NEWS PORTSCOUT= ignore:1 # Use a submake as 'deinstall install' needs to reevaluate PKG_CMD # so that pkg-static is used from the wrkdir USE_SUBMAKE= yes CFLAGS+= -Wno-error .if !exists(/usr/include/jail.h) EXTRA_PATCHES= ${FILESDIR}/extra-patch-docs_pkg.8 .endif -EXTRA_PATCHES+= ${FILESDIR}/0001-Do-not-use-the-origin-at-all-anymore-when-looking-fo.patch:-p1 \ - ${FILESDIR}/0002-Fix-finding-ports-updates-with-flavors.patch:-p1 .include .if defined(WITH_DEBUG) MAKE_ARGS+= DEBUG_FLAGS="${DEBUG_FLAGS}" .endif .if defined(WITH_PKG) .if ${WITH_PKG} == devel IGNORE= WITH_PKG is defined to 'devel', this version is the stable one .endif .if exists(${LOCALBASE}/sbin/pkg_info) || exists(/usr/sbin/pkg_info) NB_OLDPKGS!= pkg_info 2>/dev/null | wc -l .if exists(${PKG_BIN}) NB_NEWPKGS!= ${PKG_INFO} -aq | wc -l .else NB_NEWPKGS= 0 .endif # Only show the pre-everything notice if they have not already # converted any packages .if ${NB_OLDPKGS} > 0 && ${NB_NEWPKGS} == 0 && !defined(UPGRADEPKG) pre-everything:: @${ECHO_CMD} "You are about to convert your system to pkg while you have ports/packages"; \ ${ECHO_CMD} "installed with the old pkg_install tools."; \ ${ECHO_CMD} ""; \ ${ECHO_CMD} "To switch to pkg:"; \ ${ECHO_CMD} " 1) Install ports-mgmt/pkg"; \ ${ECHO_CMD} " cd ports-mgmt/pkg && make UPGRADEPKG=1 install clean"; \ ${ECHO_CMD} " 2) Convert your package database by running pkg2ng"; \ ${ECHO_CMD} ""; \ exit 1 .endif .endif .endif #define PKG_DEPENDS to nothing to avoid infinite loop looking for pkg :) PKG_DEPENDS= .undef INSTALLS_DEPENDS PKG_BIN= ${WRKSRC}/src/pkg-static post-install: @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/NEWS ${STAGEDIR}${DOCSDIR}/NEWS @${MV} ${STAGEDIR}${PREFIX}/lib/libpkg_static.a \ ${STAGEDIR}${PREFIX}/lib/libpkg.a .include Index: head/ports-mgmt/pkg/distinfo =================================================================== --- head/ports-mgmt/pkg/distinfo (revision 455545) +++ head/ports-mgmt/pkg/distinfo (revision 455546) @@ -1,3 +1,3 @@ -TIMESTAMP = 1510740067 -SHA256 (pkg-1.10.2.tar.xz) = 942e9e119f6d7f7d4684aef572d8d3310a9d60826a91b82cf912eb32e873ea4d -SIZE (pkg-1.10.2.tar.xz) = 2220904 +TIMESTAMP = 1512423062 +SHA256 (pkg-1.10.3.tar.xz) = a5db61522eccc91538b0ac19da56ddbe8eaf8c3bd94868a1753c37c8bade7715 +SIZE (pkg-1.10.3.tar.xz) = 2188196 Index: head/ports-mgmt/pkg/files/0002-Fix-finding-ports-updates-with-flavors.patch =================================================================== --- head/ports-mgmt/pkg/files/0002-Fix-finding-ports-updates-with-flavors.patch (revision 455545) +++ head/ports-mgmt/pkg/files/0002-Fix-finding-ports-updates-with-flavors.patch (nonexistent) @@ -1,64 +0,0 @@ -From ab5d49c07944d6a9f3a61de4c830a0130feccbd7 Mon Sep 17 00:00:00 2001 -From: Baptiste Daroussin -Date: Fri, 1 Dec 2017 14:53:41 +0100 -Subject: [PATCH 2/2] Fix finding ports updates with flavors - -Use the new target from flavors to list all potential packages and we -match against them ---- - src/version.c | 20 +++++++++++++++----- - 1 file changed, 15 insertions(+), 5 deletions(-) - -diff --git a/src/version.c b/src/version.c -index 75d9e922..f2a24186 100644 ---- a/src/version.c -+++ b/src/version.c -@@ -696,9 +696,10 @@ validate_origin(const char *portsdir, const char *origin) - } - - static const char * --port_version(UT_string *cmd, const char *portsdir, const char *origin) -+port_version(UT_string *cmd, const char *portsdir, const char *origin, -+ const char *pkgname) - { -- char *output; -+ char *output, *walk, *name; - char *version = NULL; - char *argv[5]; - -@@ -712,12 +713,21 @@ port_version(UT_string *cmd, const char *portsdir, const char *origin) - argv[0] = "make"; - argv[1] = "-C"; - argv[2] = utstring_body(cmd); -- argv[3] = "-VPKGVERSION"; -+ argv[3] = "flavors-package-names"; - argv[4] = NULL; - - if (exec_buf(cmd, argv) != 0) { - output = utstring_body(cmd); -- version = strsep(&output, "\n"); -+ while ((walk = strsep(&output, "\n")) != NULL) { -+ name = walk; -+ walk = strrchr(walk, '-'); -+ walk[0] = '\0'; -+ walk++; -+ if (strcmp(name, pkgname) == 0) { -+ version = walk; -+ break; -+ } -+ } - } - } - -@@ -772,7 +782,7 @@ do_source_ports(unsigned int opt, char limchar, char *pattern, match_t match, - strcmp(name, matchname) != 0) - continue; - -- version = port_version(cmd, portsdir, origin); -+ version = port_version(cmd, portsdir, origin, name); - print_version(pkg, "port", version, limchar, opt); - utstring_clear(cmd); - } --- -2.15.1 - Property changes on: head/ports-mgmt/pkg/files/0002-Fix-finding-ports-updates-with-flavors.patch ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/ports-mgmt/pkg/files/0001-Do-not-use-the-origin-at-all-anymore-when-looking-fo.patch =================================================================== --- head/ports-mgmt/pkg/files/0001-Do-not-use-the-origin-at-all-anymore-when-looking-fo.patch (revision 455545) +++ head/ports-mgmt/pkg/files/0001-Do-not-use-the-origin-at-all-anymore-when-looking-fo.patch (nonexistent) @@ -1,114 +0,0 @@ -From 7242a137ae73ad0da08d57c09901219179b19b14 Mon Sep 17 00:00:00 2001 -From: Baptiste Daroussin -Date: Fri, 1 Dec 2017 14:26:59 +0100 -Subject: [PATCH 1/2] Do not use the origin at all anymore when looking for new - version from the INDEX files, this makes finding new version of flavoured - ports working again - ---- - src/version.c | 33 +++++++++++---------------------- - 1 file changed, 11 insertions(+), 22 deletions(-) - -diff --git a/src/version.c b/src/version.c -index ee955bef..75d9e922 100644 ---- a/src/version.c -+++ b/src/version.c -@@ -56,7 +56,7 @@ - extern char **environ; - - struct index_entry { -- char *origin; -+ char *name; - char *version; - }; - -@@ -286,10 +286,10 @@ hash_indexfile(const char *indexfilename) - FILE *indexfile; - kh_index_t *index = NULL; - struct index_entry *entry; -- char *version, *origin; -- char *line = NULL, *l, *p; -+ char *version, *name; -+ char *line = NULL, *l; - size_t linecap = 0; -- int dirs, ret; -+ int ret; - khint_t k; - - -@@ -306,40 +306,30 @@ hash_indexfile(const char *indexfilename) - l = line; - - version = strsep(&l, "|"); -+ name = version; - version = strrchr(version, '-'); - version[0] = '\0'; - version++; - -- origin = strsep(&l, "|"); -- for (dirs = 0, p = l; p > origin; p--) { -- if ( p[-1] == '/' ) { -- dirs++; -- if (dirs == 2) { -- origin = p; -- break; -- } -- } -- } -- - entry = malloc(sizeof(struct index_entry)); - if (entry != NULL) { -+ entry->name = strdup(name); - entry->version = strdup(version); -- entry->origin = strdup(origin); - } - - if (entry == NULL || entry->version == NULL || -- entry->origin == NULL) -+ entry->name == NULL) - err(EX_SOFTWARE, "Out of memory while reading %s", - indexfilename); - - if (index == NULL) - index = kh_init_index(); -- k = kh_put_index(index, entry->origin, &ret); -+ k = kh_put_index(index, entry->name, &ret); - if (ret != 0) { - kh_value(index, k) = entry; - } else { -- free(entry->origin); - free(entry->version); -+ free(entry->name); - free(entry); - } - } -@@ -381,8 +371,8 @@ free_index(kh_index_t *index) - return; - - kh_foreach_value(index, entry, { -- free(entry->origin); - free(entry->version); -+ free(entry->name); - free(entry); - }); - kh_destroy_index(index); -@@ -460,7 +450,7 @@ do_source_index(unsigned int opt, char limchar, char *pattern, match_t match, - strcmp(name, matchname) != 0) - continue; - -- k = kh_get_index(index, origin); -+ k = kh_get_index(index, name); - print_version(pkg, "index", - k != kh_end(index) ? (kh_value(index, k))->version : NULL, limchar, opt); - } -@@ -751,7 +741,6 @@ do_source_ports(unsigned int opt, char limchar, char *pattern, match_t match, - return (EX_USAGE); - } - -- - if (chdir(portsdir) != 0) - err(EX_SOFTWARE, "Cannot chdir to %s\n", portsdir); - --- -2.15.1 - Property changes on: head/ports-mgmt/pkg/files/0001-Do-not-use-the-origin-at-all-anymore-when-looking-fo.patch ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property