Opened 10 years ago

Closed 10 years ago

#45117 closed defect (fixed)

mythweb.27 @.27_1: depends on obsolete php5-mysql

Reported by: alh_ports@… Owned by: ctreleaven (Craig Treleaven)
Priority: Normal Milestone:
Component: ports Version: 2.3.1
Keywords: Cc: ryandesign (Ryan Carsten Schmidt)
Port: mythweb.27

Description

sudo port install mythweb.27
--->  Computing dependencies for mythweb.27
--->  Dependencies to be installed: php5-mysql
--->  Fetching distfiles for php5-mysql
--->  Verifying checksums for php5-mysql
--->  Extracting php5-mysql
--->  Configuring php5-mysql
Error: php5-mysql has been made obsolete by the port php53-mysql. Please install php53-mysql instead.
Error: org.macports.configure for port php5-mysql returned: obsolete port
Error: Failed to install php5-mysql
Please see the log file for port php5-mysql for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_php_php5-mysql/php5-mysql/main.log
Error: The following dependencies were not installed: php5-mysql

installing php53-mysql does not help

Change History (18)

comment:1 Changed 10 years ago by larryv (Lawrence Velázquez)

Keywords: mythweb php5-mysql removed
Owner: changed from macports-tickets@… to ctreleaven@…
Summary: mythweb.27 install fails because it wants an obsolete dependancymythweb.27 @.27_1: depends on obsolete php5-mysql

Thanks for the report. In future tickets, please Cc port maintainers (port info --maintainers mythweb.27).

comment:2 in reply to:  description Changed 10 years ago by larryv (Lawrence Velázquez)

Replying to alh_ports@…:

installing php53-mysql does not help

It doesn’t matter if you have php53-mysql installed; mythweb.27 still wants the obsolete php5-mysql. The maintainer should fix this.

comment:3 Changed 10 years ago by ctreleaven (Craig Treleaven)

After years of moving at a measured pace, the MacPorts project blazed ahead just recently rendering Myth's Perl, Python, and PHP bindings obsolete. Plus obsoleting the database. My time is pretty tightly constrained at the moment but I will try to address the issue at hand ASAP. I'm not a PHP guy; I'm not sure if differing versions of PHP in the backend v. MythWeb will cause issues. Tested patches welcome!

BTW, just curious why you didn't use the all-in-one installer from http://sourceforge.net/projects/macportsmythtvinstaller/ ? It was cut before all the above changes and is (as far as I can tell) MUCH more heavily used than building via MacPorts. OTOH, you're far enough into the process that it could be very confusing to mix the two approaches.

comment:4 Changed 10 years ago by alh_ports@…

I have been running this macports version of MythTV and MythWeb for about 1.5 years. Yesterday, I ran "sudo port self update", etc, and when all was done, myth web was broken - the website could not be found. To see if reinstalling myth web would fix it, I tried "sudo port uninstall mythweb", followed by "sudo port install myth web". At this point, the installer failed as indicated above. Mythbackend and mythfrontend both seem to be working correctly(I virtually never use mythfrontend - I use XBMC and mythweb).

I would be happy to transition to the packaged installer, but am apprehensive that doing so in the circumstances would be risky and certainly not straightforward.

comment:5 Changed 10 years ago by ctreleaven (Craig Treleaven)

Hold on a few days (you can tolerate MythFrontend that long, right?) and I'll get the MythWeb port fixed.

comment:6 Changed 10 years ago by ctreleaven (Craig Treleaven)

OK, I pushed a commit (r125712) that should update mythweb.27 to use PHP 5.4. However, certain aspects of the configuration and setup need to be changed or re-done to match. Could you please try the following steps and let me know if there are any problems:

0) Stop the Apache2 server, if running

sudo port unload apache2

1) Register PHP 5.4 with Apache In Terminal, enter:

cd /opt/local/apache2/modules
sudo /opt/local/apache2/bin/apxs -a -e -n "php5" mod_php54.so

2) Edit Apache's httpd.conf

In '/opt/local/apache2/conf/httpd.conf' verify that mod_php54.so module will be loaded. You should find the following line already added by the command in step 1) above.

LoadModule php5_module modules/mod_php54.so

If you find a line like the following, delete it or comment it out:

LoadModule php5_module modules/libphp5.so

3) Set up your PHP 5.4 configuration files We'll cheat and reuse the config file created for php5

sudo cp -np /opt/local/etc/php5/php.ini /opt/local/etc/php54/php.ini

4) Restart Apache2

sudo port load apache2

With luck, MythWeb should be back up!

If these steps work out correctly for you, I'll update the wiki page and point others to that. And update MythWeb.{25|26} in similar fashion.

BTW, I had always believed that MythWeb could be installed on a machine that did NOT have Myth installed. Turns out that is not true so I've fixed that, too.

comment:7 in reply to:  3 ; Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign@… added

Replying to ctreleaven@…:

After years of moving at a measured pace, the MacPorts project blazed ahead just recently rendering Myth's Perl, Python, and PHP bindings obsolete. Plus obsoleting the database. My time is pretty tightly constrained at the moment but I will try to address the issue at hand ASAP. I'm not a PHP guy; I'm not sure if differing versions of PHP in the backend v. MythWeb will cause issues. Tested patches welcome!

As far as I know there haven't been any major changes in the MacPorts Perl or Python ports lately (though discussions continue), however the PHP ports are mine, and I apologize for the lack of specific notification about finally replacing the old php5 ports, but note that the php53 ports which were designed to replace them have been available since May 2012 already. I got tired of maintaining duplicate sets of PHP ports for years and decided that the recent release of the absolutely last ever version of PHP 5.3.x provided a good time to finally force this switch on those who had not yet done so.

If possible (i.e. assuming mythweb does not specifically require only PHP 5.4.x), please offer variants so the user can choose whether they want to use php53, php54, php55 or php56. I would suggest the default among those should be the latest stable version, currently php56.

I see you added a dependency on the php54-apache2handler port. Is it absolutely necessary to run this under the PHP Apache module, or would the PHP CGI or FPM SAPI running under nginx or lighttpd or other web server also work (as it would for most PHP-based web sites)? If any PHP-capable web server would work, then you'll want to use the forthcoming ${php}-web metaport instead; keep an eye on #45008 for that.

comment:8 Changed 10 years ago by alh_ports@…

Thanks, but unfortunately, "safari can't connect to the server" Also,

  • Step 3 failed initially because there was no php54 directory. I installed php54-mysql, and then the cp command worked.
  • after following all of your steps (but before relaunching apache) I installed mythweb, which now installs but, as noted above, the browser still can't connect.
Last edited 10 years ago by alh_ports@… (previous) (diff)

comment:9 in reply to:  8 Changed 10 years ago by ctreleaven (Craig Treleaven)

Replying to alh_ports@…:

Thanks, but unfortunately, "safari can't connect to the server" Also,

  • Step 3 failed initially because there was no php54 directory. I installed php54-mysql, and then the cp command worked.
  • after following all of your steps (but before relaunching apache) I installed mythweb, which now installs but, as noted above, the browser still can't connect.

Sorry, I should have specified that you should do 'sudo port selfupdate' and 'sudo port upgrade mythweb.27' before starting. You should see php54-apache2handler get installed when you do that now and I hope that will get you off and running.

comment:10 in reply to:  7 Changed 10 years ago by ctreleaven (Craig Treleaven)

Replying to ryandesign@…:

As far as I know there haven't been any major changes in the MacPorts Perl or Python ports lately (though discussions continue), however the PHP ports are mine, and I apologize for the lack of specific notification about finally replacing the old php5 ports, but note that the php53 ports which were designed to replace them have been available since May 2012 already. I got tired of maintaining duplicate sets of PHP ports for years and decided that the recent release of the absolutely last ever version of PHP 5.3.x provided a good time to finally force this switch on those who had not yet done so.

Sorry Ryan, I was mainly just venting. I had to update from Perl 5.12 and Python 2.4. I had hoped to hold off on these changes until Myth 0.28 was released. The Myth release is, however, now months behind their original timetable and MacPorts is 'pushing' me to make 'busy work' changes to a functioning system. Myth is a pretty hairy beast and so lot's of people let it run for years without touching it.

If possible (i.e. assuming mythweb does not specifically require only PHP 5.4.x), please offer variants so the user can choose whether they want to use php53, php54, php55 or php56. I would suggest the default among those should be the latest stable version, currently php56.

I cannot locate any reports about MythWeb running successfully with PHP 5.6--5.4 is known to work OK. MythWeb is also going away. The project is moving to an internal web server and modern replacement for MythWeb. Myth 0.28 will include a preliminary version of the new internal server. In 0.29, MythWeb is supposed to be gone.

I _could_ offer variants for:

  • SQL: mysql51, mysql55, mariadb
  • Perl: perl5.16, perl5.20
  • Python: py26, py27
  • PHP: php53, php54

The problem is support--I can't possibly test all the permutations. I provide detailed, cookbook-style setup and configuration instructions via the Myth wiki. Even so, I get lots of reported problems that boil down to people missing a step. I haven't got the capacity to handle any more complications.

I see you added a dependency on the php54-apache2handler port. Is it absolutely necessary to run this under the PHP Apache module, or would the PHP CGI or FPM SAPI running under nginx or lighttpd or other web server also work (as it would for most PHP-based web sites)? If any PHP-capable web server would work, then you'll want to use the forthcoming ${php}-web metaport instead; keep an eye on #45008 for that.

Thanks for pointing out that ticket. I know MythWeb is reported to work with both nginx and lighthttpd but, as above, the package is going away.

If you want to continue this on the -dev or -users mailing lists, that's fine with me...

comment:11 Changed 10 years ago by alh_ports@…

Sorry, I should have specified that you should do 'sudo port selfupdate' and 'sudo port upgrade mythweb.27' before starting. You should see php54-apache2handler get installed when you do that now and I hope that will get you off and running.

I had to freshly install myth web today, because I uninstalled it and tried to reinstall a couple of days ago. The reinstall a couple of days ago failed. Todays install worked and I recall seeing php54-apache2handler get installed during the installation. I also (after your message) ran selfupdate and upgrade mythweb.27. On the upgrade, it just checked for linking errors.

Browser still can't connect, unfortunately.

Are you contemplating providing instructions to transition to your new installer, for people who have existing installations?

comment:12 in reply to:  11 ; Changed 10 years ago by ctreleaven (Craig Treleaven)

Replying to alh_ports@…:

Browser still can't connect, unfortunately.

The machine you're running MythWeb on has a working mythbackend (0.27) and the MySQL database, right?

Please copy/paste the exact error message.

What does 'ps -Ax |grep httpd' report?

Check the Apache logs at '/opt/local/apache2/logs' to see if they give us any clues.

Are you contemplating providing instructions to transition to your new installer, for people who have existing installations?

Not really. There are some people using MacPorts for other reasons that will want to install Myth. Once you've got MacPorts, XCode and Myth installed, there is no good reason to the all-in-one .dmg installer. For one thing, you have to be very careful with the PATH to ensure you get the version you really wanted. Plus, you can use MacPorts to install other useful software like MPlayer, mediainfo, etc.

comment:13 in reply to:  12 ; Changed 10 years ago by alh_ports@…

Thanks for responding so quickly.

The machine you're running MythWeb on has a working mythbackend (0.27) and the MySQL database, right?

Yes. Mythbackend has been working fine throughout, recording scheduled programs and playing back recordings.

Please copy/paste the exact error message.

The only error I am aware of is Safari saying "safari can't connect to the server".

What does 'ps -Ax |grep httpd' report?

Blank response.

Check the Apache logs at '/opt/local/apache2/logs' to see if they give us any clues.

Nothing has been logged since I updated ports/uninstalled mythweb on Sunday. These are the last entries in the error log:

[Sun Sep 21 14:04:57 2014] [warn] Init: Session Cache is not configured [hint: SSLSessionCache]
[Sun Sep 21 14:05:01 2014] [notice] Digest: generating secret for digest authentication ...
[Sun Sep 21 14:05:01 2014] [notice] Digest: done
[Sun Sep 21 14:05:02 2014] [warn] pid file /opt/local/apache2/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Sun Sep 21 14:05:02 2014] [notice] Apache/2.2.27 (Unix) mod_ssl/2.2.27 OpenSSL/1.0.1i DAV/2 PHP/5.3.28 configured -- resuming normal operations
[Sun Sep 21 18:22:28 2014] [notice] caught SIGTERM, shutting down

Last entries in the access.log are at 14:xx on Sunday (i.e. before the failure). I guess that means apache is not running, so I tried:

sudo /opt/local/apache2/bin/apachectl start

and I got

httpd: Syntax error on line 486 of /opt/local/apache2/conf/httpd.conf: Could not open configuration file /opt/local/apache2/conf/extra/mod_php.conf: No such file or directory

Don't know where to go from here.

comment:14 in reply to:  13 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to alh_ports@…:

The only error I am aware of is Safari saying "safari can't connect to the server".

What does 'ps -Ax |grep httpd' report?

Blank response.

So Apache is not running. That's why Safari cannot connect to it.

and I got

httpd: Syntax error on line 486 of /opt/local/apache2/conf/httpd.conf: Could not open configuration file /opt/local/apache2/conf/extra/mod_php.conf: No such file or directory

Don't know where to go from here.

So your httpd.conf is trying to include a file that doesn't exist, that's why Apache isn't starting.

With php54-apache2handler, the file mod_php.conf has been renamed; it's now called mod_php54.conf. (You can learn this by using the command "port contents php54-apache2handler".) Please update your httpd.conf accordingly.

comment:15 Changed 10 years ago by ctreleaven (Craig Treleaven)

In step 2), above, we need to add:

At the end of the httpd.conf file, add the following lines so that Apache includes the mod_php "AddType" configurations

# 
# Include PHP configurations
#
Include conf/extra/mod_php54.conf

comment:16 Changed 10 years ago by alh_ports@…

I currently have this:

# 
# Include PHP configurations
#
Include conf/extra/mod_php.conf

So, instead of adding the lines as you indicated, I have changed "mod_php.conf" to "mod_php54.conf", and it now works!

Thanks very much!

comment:17 Changed 10 years ago by ctreleaven (Craig Treleaven)

Thanks for reporting back!

comment:18 Changed 10 years ago by ctreleaven (Craig Treleaven)

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.