Bug 197588 - [MAINTAINER] www/MT,russian/MT: update 5.2.12
Summary: [MAINTAINER] www/MT,russian/MT: update 5.2.12
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: freebsd-ports-bugs (Nobody)
URL:
Keywords: needs-qa, patch
Depends on:
Blocks:
 
Reported: 2015-02-13 05:13 UTC by takefu
Modified: 2015-04-03 16:16 UTC (History)
3 users (show)

See Also:


Attachments
www-MT.patch (1.22 KB, patch)
2015-02-13 05:13 UTC, takefu
no flags Details | Diff
russian-MT.patch (13.82 KB, patch)
2015-02-13 05:13 UTC, takefu
no flags Details | Diff
www-MT.patch2 (1.36 KB, patch)
2015-02-18 02:55 UTC, takefu
no flags Details | Diff
russian-MT.patch2 (430 bytes, patch)
2015-02-18 02:56 UTC, takefu
no flags Details | Diff
www-MT.patch3 (1.72 KB, patch)
2015-03-30 08:52 UTC, takefu
no flags Details | Diff
marino's attempt (8.84 KB, patch)
2015-03-30 15:24 UTC, John Marino
no flags Details | Diff
www-MT.patch4 (13.10 KB, patch)
2015-03-31 07:38 UTC, takefu
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description takefu 2015-02-13 05:13:29 UTC
Created attachment 152931 [details]
www-MT.patch

update 5.2.12
Comment 1 takefu 2015-02-13 05:13:59 UTC
Created attachment 152932 [details]
russian-MT.patch
Comment 2 takefu 2015-02-18 02:55:41 UTC
Created attachment 153133 [details]
www-MT.patch2

add russian distfile
Comment 3 takefu 2015-02-18 02:56:32 UTC
Created attachment 153134 [details]
russian-MT.patch2

del russian patchfiles
Comment 4 John Marino freebsd_committer freebsd_triage 2015-03-05 13:22:53 UTC
This still needs QA (e.g. poudriere logs)
Comment 5 Bartek Rutkowski freebsd_committer freebsd_triage 2015-03-14 08:50:00 UTC
The patch fails to build currently:

http://pd.valinor.palantiri.org/data/84amd64-default/2015-03-14_09h34m23s/logs/errors/MT-5.2.12,1.log
Comment 6 John Marino freebsd_committer freebsd_triage 2015-03-27 16:10:21 UTC
he's asking for a new (tested) patch.  Without it the PR will be closed.
Comment 7 takefu 2015-03-30 05:05:09 UTC
(In reply to John Marino from comment #6)

will certainly have problem in ports-Mgmt/poudriere
Problem does not occur with real environment and the directory is deleted.

I ports-Mgmt/poudriere doubt?
Comment 8 John Marino freebsd_committer freebsd_triage 2015-03-30 07:04:25 UTC
I am not sure it is a poudriere fake error.

It seems that a dependency (mysql?) is bringing in /var/db/mysql and MT is deleting it.

It might work if you just remove the %%MYSQL%%@dir /var/db/mysql line from pkg-plist.


Find out if mysql is installing /var/db/mysql and if so, don't let MT delete it.
Comment 9 takefu 2015-03-30 08:52:20 UTC
Created attachment 154987 [details]
www-MT.patch3

Roger. :-)
Comment 10 Bartek Rutkowski freebsd_committer freebsd_triage 2015-03-30 10:22:17 UTC
Latest patch fails as well: 

http://pd.valinor.palantiri.org/data/84amd64-default/2015-03-30_12h09m53s/logs/errors/MT-5.2.12,1.log

I really highly recommend you to build poudriere and test your patches there, you'd make our life much easier.
Comment 11 John Marino freebsd_committer freebsd_triage 2015-03-30 10:30:47 UTC
true, but that being said, this is tricky.

When he had "@dir ...", it failed because directory was missing.
When he deletes "@dir ...", it fails because the directory is orphaned.

Something weird is going on here.  Some other port seems to be interfering.
Comment 12 John Marino freebsd_committer freebsd_triage 2015-03-30 10:34:47 UTC
The fix might be to remove "/var/db/mysql" from stagedir in post-install target...
Comment 13 John Marino freebsd_committer freebsd_triage 2015-03-30 10:51:42 UTC
ugh, entire do-install target is masked with "@".  That needs changing.  I will test my theory and report back.
Comment 14 John Marino freebsd_committer freebsd_triage 2015-03-30 10:54:11 UTC
hmm, obviously we can't "mkdir /var/db/mysql/WEBLOG_DATABASEDIR" and then "rmdir /var/db/mysql" ....
Comment 15 John Marino freebsd_committer freebsd_triage 2015-03-30 10:55:15 UTC
i see something else I don't like: post-install echo messages instead of using pkg-message or pkg-message.in ...

That's wrong in my opinion.
Comment 16 John Marino freebsd_committer freebsd_triage 2015-03-30 10:56:58 UTC
installation has been done with "${CP} -R" rather than ${COPYSHARE_ ...

This port is not withstanding scrutiny, there are a lot of things it is doing that it should not be doing.
Comment 17 John Marino freebsd_committer freebsd_triage 2015-03-30 11:40:32 UTC
I think the main problem is that sometimes DB_DIR is in ${STAGEDIR} and sometimes it isn't.  yuck.
Comment 18 John Marino freebsd_committer freebsd_triage 2015-03-30 12:28:18 UTC
I think this is a shortcoming in the ports framework.

I'm not sure how to make this work, honestly.  The framework is getting confused by overlapping /var/db/mysql values.
Comment 19 John Marino freebsd_committer freebsd_triage 2015-03-30 12:35:11 UTC
I'm starting to think this is a problem with mysql, not MT.  I don't think the mysql ports are setting /var/db/mysql in pkg-plist.
Comment 20 John Marino freebsd_committer freebsd_triage 2015-03-30 13:42:43 UTC
by the way, the SUB_LIST stuff is completely broken.
Nothing after ".include <bsd" is included.
Comment 21 John Marino freebsd_committer freebsd_triage 2015-03-30 15:24:35 UTC
Created attachment 154998 [details]
marino's attempt

takefu, 
Please review my attempt at this.
There were numerous problems as I commented previously.

Mostly this gets it to work as intended, but there is one major change you need to be aware of and approve.

I removed the "MT.conf" file.  It was getting added as part of a post-install message and I doubt it was even correct.  After many attempts, I finally got pkg-messages correct and showing, but MT.conf got lost along the way.  I only figured it out when I was testing apache option.    Is this okay?  was MT.conf actually doing anything before, especially considering it may not have been populated correctly?  it's presence didn't match the instructions on pkg-message.

robak -- I think we need to ignore the error seen in check-plist when mysql option is set.  I think it's an issue with most mysql ports.
Comment 22 John Marino freebsd_committer freebsd_triage 2015-03-30 16:58:01 UTC
takefu: by the way, i've been assuming that the DB_DIR has to be at /var/db/mysql.  If it could be something else, e.g. /var/db/mt/WEBLOG ... then we wouldn't have this check-plist failure.

Can you comment if this DB_DIR is required to be what it is currently?
Comment 23 takefu 2015-03-31 07:38:03 UTC
Created attachment 155050 [details]
www-MT.patch4

Lots of fixes, thank you.

I tried to fix OptionsNG.
Comment 24 John Marino freebsd_committer freebsd_triage 2015-03-31 07:40:18 UTC
can we do that as a separate PR?  Or at least as a post-commit patch?

I literally spent hours on this and I don't want to start over again.
If the "marino's attempt" patch is okay with you, I propose to commit that, and then you can fix options with a clean patch.
Comment 25 takefu 2015-03-31 07:47:06 UTC
(In reply to John Marino from comment #24)
I made for OptionsNG from the patch I made.
Comment 26 John Marino freebsd_committer freebsd_triage 2015-03-31 07:52:00 UTC
robak, I don't have anytime time today.
takefu basically took my patch and cleaned up the options.  The /var/db/mysql... line is still going to fail (it's expected)

If you want to run this "patch4" through poudriere and visually check it over, feel free to commit.  Otherwise I will probably come back to it in a few days.
Comment 27 Bartek Rutkowski freebsd_committer freebsd_triage 2015-03-31 11:50:34 UTC
The 'www-MT.patch4' patch is still failing for me:

http://pd.valinor.palantiri.org/data/latest-per-pkg/MT/5.2.12%2c1/84amd64-default.log
Comment 28 John Marino freebsd_committer freebsd_triage 2015-03-31 12:12:11 UTC
as expected, see comment 26 and entire backlog
Comment 29 John Marino freebsd_committer freebsd_triage 2015-04-03 15:29:54 UTC
takefu, you made several what we call "gratuitous" changes -- changes that don't affect functionality, but screw up diff checks.

For example, 
line 1 \
line 2

changed to 
line 1\
line 2


First, there's no different functionally
second, the first example is preferred.  We want spaces before continuity lines, even if it means "-V" shows two spaces between items
third, like I said, it's showing a diff which makes review more complex.

Please be careful about this.
I'm reverting some unnecessary changes to make my review easier.

Also, there was a change where you made the "mkdir" of the DBDIR invisible.  I had it visible for a reason, but fine, we make it invisible.  However, then you should have added it to the previous @${MKDIR} instead of keeping it as second command.
Comment 30 commit-hook freebsd_committer freebsd_triage 2015-04-03 16:12:20 UTC
A commit references this bug:

Author: marino
Date: Fri Apr  3 16:11:41 UTC 2015
New revision: 383142
URL: https://svnweb.freebsd.org/changeset/ports/383142

Log:
  www/MT,russian/MT: Upgrade version 5.2.11 => 5.2.12

  The port needed an overhaul, there were many issues with it.  After the
  initial fix, the maintainer also made it optionsNG compliant.

  Note that when the default MYSQL option is selected, it will fail
  check-plist as a result of the mysql ports not handling /var/db/mysql
  creation correctly.  To fix the check, the mysql ports need fixing.

  PR:		197588
  Submitted by:	takefu (airport.fm)
  overhaul by:	marino

Changes:
  head/russian/MT/Makefile
  head/www/MT/Makefile
  head/www/MT/distinfo
  head/www/MT/files/MT.conf.in
  head/www/MT/files/pm.apache.in
  head/www/MT/files/pm.default.in
  head/www/MT/pkg-plist
Comment 31 John Marino freebsd_committer freebsd_triage 2015-04-03 16:16:29 UTC
I can honestly say that I hate this PR.  Closing, it's done.