Bug 50915

Summary: [MAINTAINER] security/logcheck: do not overwrite existing config
Product: Ports & Packages Reporter: Sergei Kolobov <sergei>
Component: Individual Port(s)Assignee: freebsd-ports-bugs (Nobody) <ports-bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
logcheck-1.1.1.patch none

Description Sergei Kolobov 2003-04-13 22:50:12 UTC
- Do not overwrite the existing config files when installing as a port or 
  as a package
- Bump PORTREVISION

Reported by:	Forrest Aldrich <forrie@forrie.com>
Comment 1 Yen-Ming Lee freebsd_committer freebsd_triage 2003-04-14 05:06:26 UTC
State Changed
From-To: open->analyzed

cmp always fail. You can't cmp a file which is deleted already.
Comment 2 Sergei Kolobov 2003-04-14 15:28:35 UTC
On 2003-04-13 at 21:15 -0700, Yen-Ming Lee wrote:
> cmp always fail. You can't cmp a file which is deleted already.

Yes, of course it will always fail. Pass me the pointy hat, please.

Let's get rid of those @unexec's completely. 
Uninstalling the port can leave the configs in place.

Please use the following diff (against what's in CVS now)

Index: pkg-plist
===================================================================
RCS file: /home/ncvs/ports/security/logcheck/pkg-plist,v
retrieving revision 1.5
diff -u -r1.5 pkg-plist
--- pkg-plist	2003/04/09 05:41:27	1.5
+++ pkg-plist	2003/04/14 14:18:55
@@ -1,13 +1,13 @@
 bin/logtail
 etc/logcheck.sh
-etc/logcheck.hacking
-etc/logcheck.ignore
-etc/logcheck.violations
-etc/logcheck.violations.ignore
 %%EXAMPLESDIR%%/logcheck.hacking
+@exec test -f %D/etc/%f || cp %D/%f %D/etc
 %%EXAMPLESDIR%%/logcheck.ignore
+@exec test -f %D/etc/%f || cp %D/%f %D/etc
 %%EXAMPLESDIR%%/logcheck.violations.ignore
+@exec test -f %D/etc/%f || cp %D/%f %D/etc
 %%EXAMPLESDIR%%/logcheck.violations
+@exec test -f %D/etc/%f || cp %D/%f %D/etc
 @dirrm %%EXAMPLESDIR%%
 %%PORTDOCS%%%%DOCSDIR%%/CREDITS
 %%PORTDOCS%%%%DOCSDIR%%/INSTALL
Comment 3 Yen-Ming Lee freebsd_committer freebsd_triage 2003-04-14 16:25:39 UTC
State Changed
From-To: analyzed->closed

Committed, thanks.