Bug 165765 - [maintainer update] modern revamping japanese/p5-Mail-SpamAssassin
Summary: [maintainer update] modern revamping japanese/p5-Mail-SpamAssassin
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Michael Scheidell
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-06 02:30 UTC by Masaki TAGAWA
Modified: 2012-04-07 17:40 UTC (History)
1 user (show)

See Also:


Attachments
file.shar (5.02 KB, text/plain)
2012-03-06 02:30 UTC, Masaki TAGAWA
no flags Details
p5-Mail-SpamAssassin.shar (46.37 KB, application/x-shar)
2012-03-28 02:13 UTC, Masaki TAGAWA
no flags Details
ja_sa.patch (64.58 KB, patch)
2012-04-06 16:19 UTC, Masaki TAGAWA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Masaki TAGAWA 2012-03-06 02:30:14 UTC
	- Modern revamping japanese/p5-Mail-SpamAssassin to work as a slave port
		- See: p5-Mail-SpamAssassin.shar
	- To work this slave port, some assignments on mail/p5-Mail-SpamAssassin should be changed
		- See: p5-Mail-SpamAssassin.diff
		- CC'd maintainer <scheidell@FreeBSD.org>

Fix: 

--- p5-Mail-SpamAssassin.shar ends here -----6T1xSgaYLu6cpd7BAtyyU4cDqRZCgsxF9MwI9LjixkVIZvYd
Content-Type: text/plain; name="p5-Mail-SpamAssassin.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="p5-Mail-SpamAssassin.diff"

diff -ruN /tmp/p5-Mail-SpamAssassin.org/Makefile /tmp/p5-Mail-SpamAssassin/Makefile
--- /tmp/p5-Mail-SpamAssassin.org/Makefile	2012-02-08 00:17:28.000000000 +0900
+++ /tmp/p5-Mail-SpamAssassin/Makefile	2012-03-06 08:55:28.445163638 +0900
@@ -219,7 +219,7 @@
 .endif
 	@${INSTALL_DATA} ${WRKSRC}/spamc/libspamc.h ${PREFIX}/include
 
-post-install:
+post-install::
 .if defined (WITH_SPAMC)
 	@${STRIP_CMD} ${PREFIX}/bin/spamc
 .endif
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2012-03-06 02:30:32 UTC
Responsible Changed
From-To: freebsd-ports-bugs->perl

perl@ wants this port PRs (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=165765 
 
 Date: Wed, 21 Mar 2012 17:35:24 -0700
 From: Jason Helfman <jgh@FreeBSD.org>
 Sender: Jason Helfman <bsd-src@helfman.org>
 To: Michael Scheidell <scheidell@freebsd.org>
 Cc: bug-followup@freebsd.org
 Subject: Re: [PATCH] mail/p5-Mail-SpamAssassin: add support for AutoWhiteList
  (AWL)
 
  On Wed, Mar 21, 2012 at 08:28:22PM -0400, Michael Scheidell thus spake:
  >we went over this before, maybe not with you, but with others.
  >
  >I am not going to put an option knob in for something that does not
  >change the port, does not change the package, does not bring in more (or
  >less) dependencies, especially when awl is deprecated.
  >
  Where is it deprecated? Did you read the log?
  The fact that was in there originally and removed without any proof of when
  or how it was deprecated seems premature.
  
  It was me.
  
  -jgh
  
  -- 
  Jason Helfman         | FreeBSD Committer
  jgh@FreeBSD.org       | http://people.freebsd.org/~jgh
Comment 2 Michael Scheidell freebsd_committer freebsd_triage 2012-03-23 14:13:39 UTC
Responsible Changed
From-To: perl->scheidell

I'll take it.
Comment 3 Michael Scheidell freebsd_committer freebsd_triage 2012-03-23 14:14:15 UTC
State Changed
From-To: open->feedback

Masaki: 

Thanks, this is looking better, or at least the concept is. 
Normally, for a portupdate or portrevision, you should send in a patch, (diff -ruN) against olv vs new. 
The reason you normally want to do that, is that the port committer can quickly look at the diff, and see what you changed. 
(this way, they can concentrate their portsfoo on the changes made, in case their is a problem) 
In this case, the diff might be very messy, because, you, are, in effect, mostly trashing the old ja-p5-Mail-SpamAssassin, and  
this is almost a 'new port'. 

My real question is, and maybe its something I don't know or understand: (and maybe my ignorance) 

in this port, you have a patch to p5-Mail-SpamAssassin: 
diff -ruN /tmp/p5-Mail-SpamAssassin.org/Makefile /tmp/p5-Mail-SpamAssassin/Makefile 
--- /tmp/p5-Mail-SpamAssassin.org/Makefile	2012-02-08 00:17:28.000000000 +0900 
+++ /tmp/p5-Mail-SpamAssassin/Makefile	2012-03-06 08:55:28.445163638 +0900 
@@ -219,7 +219,7 @@ 
.endif 
@${INSTALL_DATA} ${WRKSRC}/spamc/libspamc.h ${PREFIX}/include 

-post-install: 
+post-install:: 
.if defined (WITH_SPAMC) 
@${STRIP_CMD} ${PREFIX}/bin/spamc 
.endif 

What does the extra: add? again, maybe my ignorance, and I don't know if I have ever seen this before. 

(note: once this slave port is committed, life will be a lot easier for you and your users.  I, as the p5-Mail-SpamAssassin  
maintainer, if I have a revision to my port that affects you, it will be automatic: 

if a portversion changes, that will automatically change the new portversion for ja-p5-Mail-SpamAssassin. 
if I make a portrevision change, I will just bump the portrevision+1 in your port and commit it.  That way your users will be  
able to see the update and take advantage of any patches or minor fixes. 

Any other questions, let me know. 

Thanks for the work.  I suppose you got thrown into the fire with this.  A slave port is one of the hardest ports to do!
Comment 4 Michael Scheidell freebsd_committer freebsd_triage 2012-03-23 14:49:35 UTC
Nevermind about the :: jgh explained it to me.

But:
please run portlint -abt before you submit anything.


the shar you uploaded seems to be a 'copy/paste' from something.  this 
does not preserve the [tab] vs [space].
FATAL: Makefile: [9]: use a tab (not space) after a variable name
FATAL: Makefile: [12]: use a tab (not space) after a variable name
FATAL: Makefile: [14]: use a tab (not space) after a variable name
FATAL: Makefile: [17]: use a tab (not space) after a variable name
FATAL: Makefile: [20]: use a tab (not space) after a variable name
FATAL: Makefile: [22]: use a tab (not space) after a variable name
WARN: Makefile: [24]: use a tab (not space) after a variable name
FATAL: Makefile: [26]: use a tab (not space) after a variable name
FATAL: Makefile: [28]: use a tab (not space) after a variable name
FATAL: Makefile: [29]: use a tab (not space) after a variable name
WARN: Makefile: [31]: use a tab (not space) after a variable name
FATAL: Makefile: [33]: use a tab (not space) after a variable name
FATAL: Makefile: [34]: use a tab (not space) after a variable name


And, this warning/and fatal:

WARN: Makefile: extra item placed in the PATCH_SITES section, for 
example, "PATCHLEVEL".
FATAL: Makefile: extra item "MASTERDIR" placed in the LICENSE section.

I can't tell from the shar if you want the rest of the files/* patches 
deleted, or left alone.
I can't tell if you need the pkg-* files you didn't touch deleted or 
left alone.

please doublecheck everything, edit the makefile and fix the above, and 
then ATTACH (don't cut paste) a diff -ruN to the pr and I can test this.

(to attach to an existing pr might be difficult, but, here is a 
'workaround' if your command line mail on your server won't attach:
#1, if you open a pr, and use cli tools, do a 'send-pr -a 
{portpatch.patchfilename}'
#2, if you use elm or mutt, (elm is -A), you also would use (for 
followup!), the subject and 'to' that you would get from clicking on 
'submit followup' on the web.

if all else fails, attach the patch and just email the patch (as an 
attachment!, not cut/paste) to me.



-- 
Michael Scheidell, CTO
 >*| * SECNAP Network Security Corporation
d: +1.561.948.2259
w: http://people.freebsd.org/~scheidell
Comment 5 dfilter service freebsd_committer freebsd_triage 2012-03-28 00:18:42 UTC
scheidell    2012-03-27 23:18:33 UTC

  FreeBSD ports repository

  Modified files:
    mail/p5-Mail-SpamAssassin Makefile 
  Log:
  - Update to support ja-p5-Mail-SpamAssassin slave port
  - No PORTREVISION BUMP
  
  PR:             ports/165765
  Submitted by:   Masaki TAGAWA <masaki@club.kyutech.ac.jp>
  Feature safe:   yes
  
  Revision  Changes    Path
  1.153     +1 -1      ports/mail/p5-Mail-SpamAssassin/Makefile
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 6 Masaki TAGAWA 2012-03-28 02:13:54 UTC
On Fri, Mar 23, 2012 at 23:24,  <scheidell@freebsd.org> wrote:
> In this case, the diff might be very messy, because, you, are, in effect, mostly trashing the old ja-p5-Mail-SpamAssassin, and
> this is almost a 'new port'.
Yes, I thought so too.
You can delete the rest of the files/* patches and pkg-* files. Files
in the shar are all for this port.

I edited some files and fixed. I sent a shar file, because I changed a
lot from first one.
I say again, (only) created files by this shar are all for this port.

Notices are below.

- Overwrite: pkg-message
 - I have to add some massages for japanese users, so that file was
overwritten on this port.
- Overwrite: post-install:: at Makefile
 - As you know, I have to install some files and docs, I made an
addition to "post-install"
  - We have to use "::" because we want to execute lines in
mail/p5-Mail-SpamAssassin, also some lines in
japanese/p5-Mail-SpamAssassin
- Add: PLIST, pre-install: at Makefile
 - The patch makes some new files. To create a packing list is
correct, I took this workaround.
- Add: files/spamassassin-3.3.2-ja-1.* files/tokenizer.pre
 - In the past, this port used PATCH_SITES, PATCHFILES and some
workaround. That's Ok, but this is more smart. LICENCE checked.

-- 
Masaki TAGAWA
Comment 7 Michael Scheidell freebsd_committer freebsd_triage 2012-03-28 21:58:46 UTC
I give up.  this shar won't unpack.
do it the hard way.
do it the right way.
do it the way the porters and maintainers manual says and don't take any 
shortcuts.
New ports use a shar (so we can see what it in it), old ports use a 
patch ( diff -ruN), so we know exactly what is changed.
the patch is uploaded as an attachment to GNATS so there is an audit 
trail.  and we know exactly what to do.
Actually, better than you giving us instructions on what to do, the 
patch will have all the info in it we need. the patch will delete files 
that are empty (-N).
This way we dont need to guess.

do this:
make a copy of what you think you want in japanese/p5-Mail-SpamAssassin:
    run portlint -abt on it, fix the errors.  test it.  Test it in 
redports. make sure it runs, and doesn't leave any files when its finished.
     then, when you are done,
     rsync -av p5-Mail-SpamAssassin/ /var/tmp/p5-Mail-SpamAssassin
     rm -rf p5-Mail-SpamAssassin/

update your portstree. (including wipeing out p5-Mail-SpamAssassin,  (I 
put the patch for :: into p5-Mail-SpamAssassin and committed it yesterday)

diff -ruN japanese/p5-Mail-SpamAssassin/ /var/tmp/p5-Mail-SpamAssassin/ 
 > ja_sa.patch

upload it to GNATS
(elm -A ja_sa.patch -s "Re: ports/165765: [maintainer update] modern 
revamping japanese/p5-Mail-SpamAssassin" bug-followup@FreeBSD.org  )

or however you want to do it.. send an ATTACHMENT to 
bug-followup@FreeBSD.org with the subject line of:

Re: ports/165765: [maintainer update] modern revamping 
japanese/p5-Mail-SpamAssassin





-- 
Michael Scheidell, CTO
 >*| * SECNAP Network Security Corporation
d: +1.561.948.2259
w: http://people.freebsd.org/~scheidell
Comment 8 Masaki TAGAWA 2012-04-06 16:19:46 UTC
Pardon my ignorance, I created the file which was wrong and contained Japanese.
I fixed it.

-- 
Masaki TAGAWA
Comment 9 Michael Scheidell freebsd_committer freebsd_triage 2012-04-07 13:19:20 UTC
State Changed
From-To: feedback->open

Maintainer has fixed.
Comment 10 Michael Scheidell freebsd_committer freebsd_triage 2012-04-07 13:59:17 UTC
> Pardon my ignorance, I created the file which was wrong and contained 
> Japanese.
> I fixed it.

I would not call it ignorance, just something you never did.  This is 
actually a brilliant piece of work, something I thought of doing, but 
dreaded it.

Getting a MASTER/SLAVE port to work, especially something this complex 
took a lot of work.

I am running this in a tinderbox now, to see what happens.

ps, one minor thing:

# $FreeBSD: ports/japanese/p5-Mail-SpamAssassin/Makefile,v 1.30 2012/03/13 16:15:08 pgollucci Exp $
+# $FreeBSD: ports/japanese/p5-Mail-SpamAssassin/Makefile,v 1.31 Exp $

Never mess with these.  they need to stay the way they are so that the CVS system can find the old files.
Once I commit the files to ports tree, CVS will make the substitutions all by itself.




-- 
Michael Scheidell, CTO
 >*| * SECNAP Network Security Corporation
d: +1.561.948.2259
w: http://people.freebsd.org/~scheidell
Comment 11 Michael Scheidell freebsd_committer freebsd_triage 2012-04-07 14:17:34 UTC
minor issue with plist.  you really should check to make sure that all 
files are removed from filesystem when there is a pkg_delete/make uninstall.
Having an account on a tinderbox, like redports will help.

for the man pages, I will do some += magic in your Makefile
and, for the tokenizer* files, I will do some @exec/@unexec magic in 
your *.plist file.

Goal I think is that if tokenizer.pre == tokenizer.pre.sample, we delete 
it.  if it was changed, we don't delete it.
on exec, we don't write tokenizer.pre if it exists.  this will preserve 
any changes OP makes.

I will work on this below for you.

=== Checking filesystem state after all packages deleted
1072     ================================================================
1073     list of extra files and directories in / (not present on clean 
system but present after everything was deinstalled)
1074     212111 8 drwxr-xr-x 3 root wheel 512 Apr 7 13:05 usr/local/etc/mail
1075     212112 8 drwxr-xr-x 2 root wheel 512 Apr 7 13:05 
usr/local/etc/mail/spamassassin
1076     212126 8 -rw-r--r-- 1 root wheel 163 Apr 7 13:05 
usr/local/etc/mail/spamassassin/tokenizer.pre.sample
1077     212127 8 -rw-r--r-- 1 root wheel 163 Apr 7 13:05 
usr/local/etc/mail/spamassassin/tokenizer.pre
1078     6442823 8 drwxr-xr-x 3 root wheel 512 Apr 7 13:06 
usr/local/lib/perl5
1079     6442840 8 drwxr-xr-x 3 root wheel 3072 Apr 7 13:06 
usr/local/lib/perl5/5.12.4
1080     202946 8 drwxr-xr-x 3 root wheel 512 Apr 7 13:04 
usr/local/lib/perl5/5.12.4/man
1081     202947 24 drwxr-xr-x 2 root wheel 9216 Apr 7 13:06 
usr/local/lib/perl5/5.12.4/man/man3
1082     212056 16 -r--r--r-- 1 root wheel 4282 Apr 7 13:05 
usr/local/lib/perl5/5.12.4/man/man3/Mail::SpamAssassin::Util::Charset.3
1083     212089 16 -r--r--r-- 1 root wheel 4204 Apr 7 13:05 
usr/local/lib/perl5/5.12.4/man/man3/Mail::SpamAssassin::Plugin::Tokenizer::MeCab.3
1084     212098 16 -r--r--r-- 1 root wheel 5170 Apr 7 13:05 
usr/local/lib/perl5/5.12.4/man/man3/Mail::SpamAssassin::Plugin::Tokenizer.3
1085     212102 16 -r--r--r-- 1 root wheel 4203 Apr 7 13:05 
usr/local/lib/perl5/5.12.4/man/man3/Mail::SpamAssassin::Plugin::Tokenizer::SimpleJA.3
-- 
Michael Scheidell, CTO
 >*| * SECNAP Network Security Corporation
d: +1.561.948.2259
w: http://people.freebsd.org/~scheidell
Comment 12 dfilter service freebsd_committer freebsd_triage 2012-04-07 14:43:37 UTC
scheidell    2012-04-07 13:43:28 UTC

  FreeBSD ports repository

  Modified files:
    mail/p5-Mail-SpamAssassin/files manpages 
  Log:
  - Update to support additional manpages in slave ports
  
  PR:             ports/165765
  Submitted by:   scheidell (me)
  Feature safe:   yes
  
  Revision  Changes    Path
  1.2       +3 -3      ports/mail/p5-Mail-SpamAssassin/files/manpages
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 13 dfilter service freebsd_committer freebsd_triage 2012-04-07 17:34:43 UTC
scheidell    2012-04-07 16:34:29 UTC

  FreeBSD ports repository

  Modified files:
    mail/p5-Mail-SpamAssassin Makefile 
  Log:
  - More updates to support slave. Define ETCDIR
  - Best practices, change ${CP} to ${INSTALL_DATA}
  
  PR:             ports/165765
  Submitted by:   scheidell (me)
  Feature safe:   yes
  
  Revision  Changes    Path
  1.155     +18 -17    ports/mail/p5-Mail-SpamAssassin/Makefile
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 14 dfilter service freebsd_committer freebsd_triage 2012-04-07 17:34:53 UTC
scheidell    2012-04-07 16:34:45 UTC

  FreeBSD ports repository

  Modified files:
    japanese/p5-Mail-SpamAssassin Makefile pkg-message 
  Added files:
    japanese/p5-Mail-SpamAssassin/files 
                                        spamassassin-3.3.2-ja-1.patch 
                                        spamassassin-3.3.2-ja-1.plist 
                                        tokenizer.pre 
  Removed files:
    japanese/p5-Mail-SpamAssassin distinfo pkg-deinstall pkg-descr 
                                  pkg-install pkg-plist 
    japanese/p5-Mail-SpamAssassin/files patch-rules-local.cf 
                                        patch-sa-learn.raw 
                                        sa-spamd.sh.in 
  Log:
  - Modern revamping japanese/p5-Mail-SpamAssassin to work as a slave port [1]
  - Bump PORTREVISION to follow mail/p5-Mail-SpamAssassin [1]
  - tweak files/*.plist to check for and optionally save tokenizer.pre [2]
  
  PR:             ports/165765 [1]
  Submitted by:   Masaki TAGAWA <masaki@club.kyutech.ac.jp> (maintainer)
  Reviewed by:    scheidell (me) [2]
  Feature safe:   yes
  
  Revision  Changes    Path
  1.31      +25 -321   ports/japanese/p5-Mail-SpamAssassin/Makefile
  1.9       +0 -8      ports/japanese/p5-Mail-SpamAssassin/distinfo (dead)
  1.3       +0 -15     ports/japanese/p5-Mail-SpamAssassin/files/patch-rules-local.cf (dead)
  1.2       +0 -27     ports/japanese/p5-Mail-SpamAssassin/files/patch-sa-learn.raw (dead)
  1.5       +0 -43     ports/japanese/p5-Mail-SpamAssassin/files/sa-spamd.sh.in (dead)
  1.1       +1148 -0   ports/japanese/p5-Mail-SpamAssassin/files/spamassassin-3.3.2-ja-1.patch (new)
  1.1       +7 -0      ports/japanese/p5-Mail-SpamAssassin/files/spamassassin-3.3.2-ja-1.plist (new)
  1.1       +8 -0      ports/japanese/p5-Mail-SpamAssassin/files/tokenizer.pre (new)
  1.4       +0 -17     ports/japanese/p5-Mail-SpamAssassin/pkg-deinstall (dead)
  1.2       +0 -14     ports/japanese/p5-Mail-SpamAssassin/pkg-descr (dead)
  1.7       +0 -66     ports/japanese/p5-Mail-SpamAssassin/pkg-install (dead)
  1.5       +2 -2      ports/japanese/p5-Mail-SpamAssassin/pkg-message
  1.10      +0 -161    ports/japanese/p5-Mail-SpamAssassin/pkg-plist (dead)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 15 Michael Scheidell freebsd_committer freebsd_triage 2012-04-07 17:36:59 UTC
State Changed
From-To: open->closed

Committed. Several changes. please review. Please check make 
install/deinstall/make package/pkg_delete. Edit tokenizer.pre, make sure 
it is still there after pkg_delete and make reinstall(pkg_delete + 
pkg_add). Open a new pr if you need to tweak.  Note2: you MUST update 
your ports tree.  As noted, a couple of changes were made to master 
port.