Bug 219388 - Fix CONFLICTS_INSTALL variables not correctly matching
Summary: Fix CONFLICTS_INSTALL variables not correctly matching
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Po-Chuan Hsieh
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-05-18 18:23 UTC by Pawel Pekala
Modified: 2017-05-27 19:43 UTC (History)
3 users (show)

See Also:
pawel: maintainer-feedback? (sunpoet)


Attachments
Fix CONFLICTS (9.06 KB, patch)
2017-05-18 18:23 UTC, Pawel Pekala
no flags Details | Diff
Fix CONFLICTS v2 (8.87 KB, patch)
2017-05-27 08:42 UTC, Pawel Pekala
pawel: maintainer-approval? (sunpoet)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Pawel Pekala freebsd_committer freebsd_triage 2017-05-18 18:23:11 UTC
Created attachment 182712 [details]
Fix CONFLICTS

This patch fixes CONFLICTS_INSTALL variables, which fail to match
conflicting packages correctly. Expression in form of ${PKGBASE}- 
don't detect conflicting installed packages:

% pkg query -g %n xapian-core-
%

Correct ones will return package name:

% pkg query -g %n xapian-core 
xapian-core
% pkg query -g %n 'xapian-core-[0-9]*'
xapian-core

With patch applied conflicts are detected correctly before build:

% echo $PWD
/home/corn/ports/databases/xapian-core12
% make

===>  xapian-core12-1.2.24,1 conflicts with installed package(s): 
      xapian-core-1.4.4,1

      They install files into the same place.
      You may want to stop build with Ctrl + C.
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2017-05-24 14:53:20 UTC
Also notify maintainers of:

/home/linimon/ports/default/databases/p5-Search-Xapian10
perl@FreeBSD.org
/home/linimon/ports/default/www/rubygem-railties4
ruby@FreeBSD.org

sunpoet@FreeBSD.org does maintain all the rest.
Comment 2 Mathieu Arnold freebsd_committer freebsd_triage 2017-05-24 15:34:59 UTC
Instead of adding [0-9]* the final - should be removed instead.
Comment 3 Pawel Pekala freebsd_committer freebsd_triage 2017-05-27 08:42:24 UTC
Created attachment 182957 [details]
Fix CONFLICTS v2

[0-9]* were added to prevent some ports conflicting with them selfs. After further testing I see this is not the case and can be removed. Version 2 removes just leading '-' and works exactly the same as version 1.
Comment 4 commit-hook freebsd_committer freebsd_triage 2017-05-27 19:42:38 UTC
A commit references this bug:

Author: sunpoet
Date: Sat May 27 19:42:15 UTC 2017
New revision: 441868
URL: https://svnweb.freebsd.org/changeset/ports/441868

Log:
  Fix CONFLICTS_INSTALL

  PR:		219388
  Submitted by:	pawel

Changes:
  head/databases/lua-xapian/Makefile
  head/databases/p5-Search-Xapian10/Makefile
  head/databases/postgis20/Makefile
  head/databases/py-sqlalchemy11/Makefile
  head/databases/py-xapian/Makefile
  head/databases/rocksdb/Makefile
  head/databases/xapian-bindings12/Makefile
  head/databases/xapian-core/Makefile
  head/databases/xapian-core10/Makefile
  head/databases/xapian-core12/Makefile
  head/net/mDNSResponder/Makefile
  head/science/libaec/Makefile
  head/science/szip/Makefile
  head/www/npm/Makefile
  head/www/npm2/Makefile
  head/www/npm3/Makefile
  head/www/rubygem-railties4/Makefile
  head/www/rubygem-railties5/Makefile
  head/www/rubygem-railties50/Makefile
  head/www/xapian-omega/Makefile
  head/www/xapian-omega12/Makefile
Comment 5 Po-Chuan Hsieh freebsd_committer freebsd_triage 2017-05-27 19:43:44 UTC
Committed. Thanks!