rpms/mythtv/F-16 ChangeLog, NONE, 1.1 mythbackend.init, 1.3, 1.4 mythbackend.sysconfig, 1.2, 1.3 mythtv-0.25.1-fixes.patch, NONE, 1.1 mythtv.logrotate.sysd, NONE, 1.1 mythtv.logrotate.sysv, NONE, 1.1 mythbackend.service, 1.5, 1.6 mythtv.spec, 1.93, 1.94 sources, 1.53, 1.54 mythbackend.logrotate, 1.2, NONE mythtv-0.25-fixes.patch, 1.5, NONE mythtv_0.25_gcc_4.7.patch, 1.1, NONE mythweb.conf, 1.1, NONE

Richard Shaw hobbes1069 at rpmfusion.org
Fri Jul 6 02:46:09 CEST 2012


Author: hobbes1069

Update of /cvs/free/rpms/mythtv/F-16
In directory old02.ovh.rpmfusion.lan:/tmp/cvs-serv12793

Modified Files:
	mythbackend.service mythtv.spec sources 
Added Files:
	ChangeLog mythbackend.init mythbackend.sysconfig 
	mythtv-0.25.1-fixes.patch mythtv.logrotate.sysd 
	mythtv.logrotate.sysv 
Removed Files:
	mythbackend.logrotate mythtv-0.25-fixes.patch 
	mythtv_0.25_gcc_4.7.patch mythweb.conf 
Log Message:
* Tue Jun 05 2012 Richard Shaw <hobbes1069 at gmail.com> - 0.25.1-1
- Update to latest fixes/0.25.
- Move mythweb to a stand alone package.



--- NEW FILE ChangeLog ---
commit 1d41f74720f0c89ef73e25fe7586e33caf946802
Author: Jim Stichnoth <jstichnoth at mythtv.org>
Date:   Fri Jun 22 16:32:27 2012 -0700

    Allow visualizations to be turned on during playback.
    
    In particular, allow the Audio>Visualizations submenu to appear in the
    Playback OSD menu.
    (cherry picked from commit 85e3a38349713330d30628dfeb33059b8d9c60bf)

commit 6ae8bec70b17027f858793da48f1227adabd2d38
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Thu Jul 5 00:02:08 2012 +0100

    Fix a bug resulting in multiple copies of the same track being inserted into the database

commit 11d7795503b869aeb09b66d55f0430fcf504f924
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Wed Jul 4 20:03:11 2012 +0100

    Protect the reschedule queue with a seperate lock to fix a backend deadlock.
    
     Fixes a deadlock in mythbackend caused when a reschedule request occurs
     immedately prior to a recording starting.
    
     The recorder thread locks the scheduler when starting a recording. The pending
     reschedule request handled in the event loop waits for the scheduler lock to be
     released blocking the event loop. The backend is now stopped from handling any
     further events or protocol requests, meanwhile the recorder is waiting on
     events to be processed before it will release the lock resulting in an
     irrecoverable deadlock (or hang) and the failure of the recording.
    
     This deadlock was more likely to be triggered for users of EIT because it will
     ask for a reschedule every 5 minutes in addition to any reschedules triggered
     through other means.
    
     Refs #10771

commit 48ac7cfb51e82c3ddbaab489810b560fb8271531
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Wed Jul 4 19:42:15 2012 +0100

    Revert "Protect the reschedule queue with a seperate lock to fix a backend deadlock."
    
    This reverts commit 5eb97790f3c36f9d2524275e545189cafda9d48a.
    
    While this seems to work well in master, it appears to make the
    situation worse in 0.25 and I really don't have the time to figure out
    why. Anyone experiencing the pre-existing deadlock will need to
    upgrade to 0.26 when it's released. Refs #10771

commit 67522d8a9ddfef6512a9d1f0a75f0f1cfef72e0e
Author: Gavin Hurlbut <ghurlbut at mythtv.org>
Date:   Tue Jul 3 23:50:23 2012 -0700

    Reworked all of the NOAA/NWS Weather Scripts
    
    Seems weather.gov has moved the urls for nearly all their data services.  On
    top of that, the SOAP response is gzip encoded by default, and SOAP::Lite is
    stupid and can't handle it.  Also, we were missing the Units parameter which
    is now required.
    
    Fixes #10821
    (cherry picked from commit b8a78aeb35167a676a7e25c342a1869e8016d76a)

commit 1282eb3fa007911f34aee70f1f0b8dadbd8918c6
Author: Gavin Hurlbut <ghurlbut at mythtv.org>
Date:   Sun Jul 1 22:50:07 2012 -0700

    Minor formatting, plus add back the bufferMutex

commit 0969941c7706067560d94002712be9b2fbc076f8
Merge: 65913e7 199342e
Author: Gavin Hurlbut <ghurlbut at mythtv.org>
Date:   Sun Jul 1 22:45:31 2012 -0700

    Merge remote branch 'glidos/fixes/0.25' into fixes/0.25

commit 65913e707c404abbba89274a78feefa24c4d658c
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Fri Jun 29 23:37:28 2012 +0100

    Fix incorrect cast causing loss of integer precision in RingBuffer
    (cherry picked from commit 7aea3131a8801c09617012d3e892ec4fa68f626a)

commit 5eb97790f3c36f9d2524275e545189cafda9d48a
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Fri Jun 29 13:28:45 2012 +0100

    Protect the reschedule queue with a seperate lock to fix a backend deadlock.
    
    Fixes a deadlock in mythbackend caused when a reschedule request occurs
    immedately prior to a recording starting.
    
    The recorder thread locks the scheduler when starting a recording. The pending
    reschedule request handled in the event loop waits for the scheduler lock to be
    released blocking the event loop. The backend is now stopped from handling any
    further events or protocol requests, meanwhile the recorder is waiting on
    events to be processed before it will release the lock resulting in an
    irrecoverable deadlock (or hang) and the failure of the recording.
    
    This deadlock was more likely to be triggered for users of EIT because it will
    ask for a reschedule every 5 minutes in addition to any reschedules triggered
    through other means.
    
    Refs #10771
    
    Backported from master 788bc510ede427e43e77e8aaf53d8cf047d89b46

commit 5b843c1287e546a7d49f59b3ae911c17279c43f5
Author: David Engel <dengel at mythtv.org>
Date:   Wed Jun 27 17:06:49 2012 -0500

    Don't create a watch list for the "Deleted" recording group.
    
    Fixes #10854.
    
    (cherry picked from commit 22ed71e4d9eeddccae0e1b4f40321e3f624e7b4e)

commit a3f400ebeb43dcaf31ba11ba742e4731e6dae20b
Author: Daniel Thor Kristjansson <dkristjansson at mythtv.org>
Date:   Tue Jun 26 13:23:41 2012 -0400

    Clean up deferred deletes MThreadPool.
    
    In case someone uses QObject::deleteLater() within a QRunnable
    passed to MThreadPool, this adds a cleanup of those when done
    with the QRunnable.

commit 25dd4ce330e7b36d1c8e5e14d94a4dcdcd4cd021
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Mon Jun 25 11:43:28 2012 +0100

    Move QUERY_FILETRANSFER handling to improve backend performance.
    
    This significantly reduces the backend CPU usage for me when streaming a
    recording or other file to the frontend.
    
    Each time we send a command to the backend we perform a number of string
    comparisons to find the correct handler. In the cases where that same command
    is sent regularly, maybe several times a second those comparisons can stack up
    to result in a high CPU load. This can be avoided by moving the most frequently
    used commands to the top of the list thereby avoiding a couple of dozen or more
    comparisons each time.
    
    There may be other commands that should be moved to the top with similar
    benefit.
    (cherry picked from commit 529853d11587ebee0b77753272d6dcc1a5404a11)

commit ce8f9e25a627d4b164361a5328c3e013dd68476e
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Sun Jun 24 10:36:28 2012 +0100

    Following Freesats switch from Astra 2D to Astra 1G update the transport ids associated with Freesat EIT fixups
    (cherry picked from commit 0312ff912a743178f2ef54967866b42c894d7c4b)

commit 73bc45e0e3d4bf5c137bd57b091bd4a23d0bce8d
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu Jun 21 01:39:44 2012 -0400

    Add Genre list and associated Movie search
    (cherry picked from commit 6e7725de7d8507c3675aa89b17a49da06abc7cc2)

commit 97f8819df59cba6b7b522ac71bfc46aa09b17527
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu Jun 21 01:11:56 2012 -0400

    Add Studio search method.
    (cherry picked from commit c2bb6aee239e1e53ba95da232ed84ee5da21685b)

commit 42b63d3ae53d8bd31fff7331a54b3cae093825b2
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu Jun 21 01:43:59 2012 -0400

    Add TMDBv3 file missed during previous backports.

commit 6aa7fbe106dbf88c2c067a0184a52d814cef1978
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Wed Jun 20 04:18:37 2012 -0400

    Changes seconds to milliseconds in poller loop.
    
    This corrects the timeout duration in the poller loop used to read data
    from external programs.  Code was written assuming timeouts in floating
    point seconds, while poll() API takes milliseconds.  Ahh.. consistency..
    
    Fixes #10837
    (cherry picked from commit 76433930fed60342a4b2929c6ff94a8413673e5b)

commit effb32be550172b9341e17b493d209e468c5be17
Author: Daniel Thor Kristjansson <danielk at cuymedia.net>
Date:   Sat Jun 16 14:22:48 2012 -0400

    Match Lock with Unlock in OutboundRequestHandler::DoConnectToMaster() socket error handling code.
    
    This was fixed in [f2a0d748] in trunk.

commit 67883dde998c45ad587a3f687c8e86507ffe324a
Author: Daniel Thor Kristjansson <dkristjansson at mythtv.org>
Date:   Wed Jun 6 13:24:29 2012 -0400

    Fixes #10685. Handle job queue properly for back-to-back recordings.

commit 35c3c97b70c987dc77dff06b16862abac3aa51b1
Author: Daniel Thor Kristjansson <danielk at cuymedia.net>
Date:   Sat Jun 16 14:15:57 2012 -0400

    Fix use of deleted socket in MythCoreContext::ConnectEventSocket()
    
    This was fixed in [f2a0d748] in trunk.

commit 3a9dea901cd46ac240c022bbeee79841f738042d
Author: Daniel Kristjansson <danielk at cuymedia.net>
Date:   Mon May 28 12:02:16 2012 -0400

    Refs #10712. Add error checking, proper formatting, and improve debugging of previous commit.

commit 18e0f2fd2d6b5b7724e8df0ee893817e192a4903
Author: Simon Sinister <simon.sinister at sbcglobal.net>
Date:   Mon May 28 11:50:53 2012 -0400

    Fixes #10712. Add support for HDHR Prime without CableCard.

commit 05839fa0dd4c521affb811282d640e628230b40b
Author: Daniel Kristjansson <danielk at cuymedia.net>
Date:   Mon May 28 11:46:59 2012 -0400

    Use correct RecordingInfo* in FinishedRecording()'s SendMythSystemRecEvent().

commit 1555f0381252a7231e655efa351c3931d3caa595
Author: Daniel Thor Kristjansson <danielk at cuymedia.net>
Date:   Sat Jun 9 13:46:32 2012 -0400

    Define USING_MINGW when building programs with MinGW

commit 6a9af0260bf4d7c80e77a7889e999c4f0bb91867
Author: Jim Stichnoth <jstichnoth at mythtv.org>
Date:   Fri Jun 15 11:18:23 2012 -0700

    Subtitles: Be less aggressive about auto-selecting a forced track.
    
    1. Don't favor a forced subtitle track if DefaultCCMode=1 (i.e., the
    user already wants subtitles or captions which are likely to also
    contain the force subtitles).
    
    2. Don't favor a forced subtitle track if AllowForcedSubtitles=0
    (i.e., the user doesn't want to be inflicted with forced subtitles).
    
    3. Only favor a forced track if it is a subtitle track.  (Do any other
    track types ever have the forced flag set?)
    
    Note that this still may not be perfect, e.g. a user may end up
    auto-displaying cc608 captions where a forced subtitle track is still
    needed for the complete experience.
    
    Refs #10808
    (cherry picked from commit 689a7b5d526099c2ec533701625ae62ddbba6d44)

commit 3b41cb7ae550bf0cf58cad8fe814d6bd7c03df0f
Author: Jim Stichnoth <jstichnoth at mythtv.org>
Date:   Fri Jun 15 07:07:04 2012 -0700

    Subtitles: Favor forced tracks for auto-track selection.  Refs #10808
    
    For first-time auto-track selection, we put highest priority on forced
    tracks, second priority on user language preference, and third
    priority on track order.
    
    This changes the previous behavior only by adding the forced flag to
    the criteria.
    (cherry picked from commit ea554c9cbe5fc86c4a4e301eb9f97fd90abbe7a4)

commit 56fd9e2cd63c4700f90f6e0b9326d36bc38cff92
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Mon May 21 02:32:30 2012 -0400

    Move interactive access to separate script.
    
    This removes the interactive behavior of tmdb_api.py and places it in a
    new script.  The script can be run from the source directory, but does
    not get installed with the library.
    (cherry picked from commit 76c8c518ff8dcc1206a984d2a5c12503f194870a)

commit cdc03f4b09fd6a77893aa1df5948f128dd86b391
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu May 3 02:56:30 2012 -0400

    Add method to search for movies similar to current.
    (cherry picked from commit 30a0d398cc5f40487a69ddcc3beff77b09052def)

commit 1c03ae068b8acb9bbde6dd439af482498e3b89ff
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu May 3 02:43:07 2012 -0400

    Clean up __repr__ methods, and impose soft 80-character line limit.
    (cherry picked from commit 676cbb1aaf9c8d19d207ec9575ffaa9665d8e710)

commit c9be5e2eec12cdbfbf5556aefadb1ee63cba1160
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu May 3 01:12:28 2012 -0400

    Improve handling of invalid responses from TMDB
    
    When an HTML error is received from the TMDB API, this will now attempt
    to process a specific error type from the returned JSON.  If no error
    type is given, or the resposnse was not JSON, it will raise the previous
    TMDBHTTPError.
    (cherry picked from commit 7425634d7b92f8bbe9abdc8b50c4148c96c87f40)

commit f7f76e55b0ff198d19b3dce2474f98f934717a48
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Tue May 1 15:50:44 2012 -0400

    Use `date` rather than `datetime` for storing dates.
    (cherry picked from commit c2ef5d143f1bfc9931ef9f7487fda3b93780fe8f)

commit e900fa37b2680d79cf26096a89555a31121b00f2
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Mon Apr 30 20:07:29 2012 -0400

    Correct file cache error handling to ignore rather than raise errors.
    (cherry picked from commit 27dff377fe6612b870a4cf28b9c058567be1a3bb)

commit d590289d80ffffc792b4e386f1f2bbbcea3478dc
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Mon Apr 30 16:50:20 2012 -0400

    Use `date` type rather than `datetime` for 'releasedate attribute'.
    (cherry picked from commit 5b86d8bb95c69205d8669bb23c30ccd6b8514c4b)

commit 5f5ca21fbd51ec0771034abc45e1b607c0b8db50
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Mon Apr 30 16:49:57 2012 -0400

    Bypass aborts resulting from attempting to process empty strings.
    (cherry picked from commit aa0e26f1abc7370d8840abdfd8ced2fdf2ef76f7)

commit 7563f810ae017226023b476b7a5d0f9d863aa3f3
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Mon Apr 30 02:12:12 2012 -0400

    Correct missed changes in __init__.py
    (cherry picked from commit 361e06851f02f5a70f554fcee0890a7a37e6ad95)

commit b277cc3bd8a723c2621e80d0d9506a46c7f5ca9a
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Mon Apr 30 01:59:11 2012 -0400

    Add adult filter for people searches
    (cherry picked from commit b28c566ef2b6a6379821bcc9023f84cba04b4e05)

commit 81dabbc40b0b3fdc1b542a9d7fe9da74f0fbbefd
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sat Apr 14 18:26:59 2012 -0400

    Add assorted authenticated methods.
    
    This adds methods for setting ratings and favorite status against
    movies, as well as pulling lists of movies for which those have been
    set. This adds a bypass in the cache to not operate on anything with a
    lifetime of '0'.
    (cherry picked from commit fb7c7cd3dfd4692e6c5acc61f0d2fd927b04d50e)

commit 9439a827f3c1178ad33a81a326d5e0ed87cdca31
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sat Apr 14 17:31:20 2012 -0400

    Add basic session handling and passthrough.
    (cherry picked from commit 3debcd531d8ed454b8ed9f4b61da6e03690ce13c)

commit 1493687d26482b777d07eb02f5fda77d0b501cef
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sat Apr 14 15:30:26 2012 -0400

    Corrects handling of '0' for cast ordering.
    (cherry picked from commit 500454560030795a7c914cb985c30711e302d65a)

commit 59cc85156d402eb2bdd91c088d44407fb8e6df3a
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Wed Apr 11 01:28:27 2012 -0400

    Improve file cache performance.
    
    This reworks the cache framework, and alters the file cache engine to
    support incremental writes. This allows the results from 256 queries to
    be stored before having to rewrite the file. Previously, having to
    rewrite the entire cache file on each step would take longer than
    actually querying TMDB once the cache stored more than ~100 entries.
    
    May be a bit fragile.
    (cherry picked from commit 23fa543ceb2690340e74d257a6bc86f817c02be6)

commit 2fd53643f8911e92c01fb49ca3cd2710d735831b
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Wed Apr 11 01:24:21 2012 -0400

    Fix Cache exceptions.
    (cherry picked from commit 642de961e034072eaf6342c01451b040f0b9ab3b)

commit b0e61cffcced4170c1fe8821155a830f9f38056a
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Wed Apr 11 01:23:18 2012 -0400

    Remove empty space.
    (cherry picked from commit c35f455ee4bf2dbaac87f6ce2fca2f489cd2d209)

commit ac4a15845876f5802ce78152543e1cb19ec9e04e
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Mon Apr 2 13:28:11 2012 -0400

    Adds proper encoding to strings being passed to a request.
    (cherry picked from commit e0d604111ba9f09e4f161d4280ea132e0e4a1990)

commit 802d86c668bacd3e6089ad9c5c9b2cd092d344bf
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sun Apr 1 03:14:49 2012 -0400

    Add slice support to search result pager.
    (cherry picked from commit 86b54a14992a24c3f727efd5247842ee2d2393c3)

commit 9c3fb94c1136f270d4a02a4ff294e6484b3b7d83
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sat Mar 31 20:14:52 2012 -0400

    Update Logo() class with proper image sizes from Configuration().
    (cherry picked from commit 2198d9ef21d5aaf47550084b8904e3da73137956)

commit 47b77a6bd2b17ea5962d1c78751e33305cdd1aa2
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sat Mar 31 20:03:41 2012 -0400

    Correct Studio.logo processing.
    (cherry picked from commit 2e4bc644b0d2b0277a18ffa0b0e66aa18c17dfc6)

commit 8ec550daa5a9a75c65b57fd5d3b62692bcb1e93b
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sat Mar 31 19:52:53 2012 -0400

    Allow locale fallthrough for movie images and alternate titles.
    
    When fallthrough is enabled, queries for backdrops, posters, and
    alternate titles will not filter for the selected locale, but will
    instead sort the results to place those matching the specified locale at
    the top of the list.
    
    Also resolves an issue where Request() was incorrectly passing 'None' as
    an argument when no locale was set.
    (cherry picked from commit ddc0cb0550b8de72e4ddad874ad05865b3b50c3f)

commit e0462f253faf920793bb76a84869cb98b4b4a218
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Sat Mar 31 19:15:39 2012 -0400

    Allow Datalists to be sorted natively without supplying a key.
    (cherry picked from commit 61045e47bca155fb40ec2de47d01cd86bd28992b)

commit afc068223b062e6579586d10be2f7d0d1441524d
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Fri Mar 30 00:49:19 2012 -0400

    Correct cache file selection logic inverted by 4663490f8fa.
    (cherry picked from commit 75a14b7da282f15fc84819418ec845e86559eaf2)

commit d750957b9b841d15d2c208e13df57e39419a1eb5
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Fri Mar 30 00:48:04 2012 -0400

    Update README for additional options.
    (cherry picked from commit 166655c70bb4ac340c6e559b167114f3e08bbdc0)

commit a2cb6df059542bf62f627f79310e9a891d4e891d
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Fri Mar 30 00:41:31 2012 -0400

    Add support for additional Studio information.
    (cherry picked from commit e99630e023a6ae8033bba27528e9a3ca45e72c1e)

commit ea43a7777f68d4b317138904b6e53616c10a9d52
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu Mar 29 23:43:12 2012 -0400

    Add 'adult' and 'alias' to Person class.
    (cherry picked from commit 38922793f5732d10c4dfbcf6d421d40667812675)

commit 4e2e129393ecef050134d605888bfec2c565599c
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu Mar 29 14:15:19 2012 -0400

    Improves cache file selection for Windows.
    (cherry picked from commit 263d8680de3566f2109b76b4b1d4d2779b967d10)

commit 631ae1075c35107d759c83fa1faa519841949397
Author: Raymond Wagner <rwagner at mythtv.org>
Date:   Thu Mar 29 13:36:54 2012 -0400

    Add __contains__ for proper lookup in cache Engines class.
    (cherry picked from commit 08bffa5f6df497f28fe3481fe80b517628b0f1a3)

commit 648f0aec326c03b39091fda8ac64450d0f0e76e3
Author: Michael T. Dean <mdean at mythtv.org>
Date:   Thu Jun 7 00:17:48 2012 -0400

    Fix exists check in mythcommflag
    
    for files that aren't visible to the master backend.  Thanks to fedora a
    ready2think for the patch.  Fixes #10810.
    (cherry picked from commit c5803f1dc6b1da7d77222c43ce074bb04d9bc983)

commit 016db04aff2bc8c2de1d4af9d920366ed568910b
Author: Stuart Morgan <smorgan at mythtv.org>
Date:   Wed Jun 6 22:05:19 2012 +0100

    Give more space for the channel number in the Terra OSD
    (cherry picked from commit f842d1b1f68a6b7a0933bbd7dac1e8d381fc9fee)

commit 199342ef7a3fe6230a11de547b2a8df6d07dff34
Author: Paul Gardiner <paul at glidos.site>
Date:   Sun May 27 11:44:30 2012 +0100

    Calculate timecodes more accurately (suggeseted by JYA)
    
    Also add comments explaining the algorithm.

commit 34711d84919ea49221461d41566669de1500a0d8
Author: Paul Gardiner <paul at glidos.site>
Date:   Fri May 4 17:09:57 2012 +0100

    Fix passthrough case of mythtrancode running in fifo mode
    
    Also simplify AudiReencodeBuffer::AddData()


Index: mythbackend.init
===================================================================
RCS file: mythbackend.init
diff -N mythbackend.init
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ mythbackend.init	6 Jul 2012 00:46:08 -0000	1.4
@@ -0,0 +1,97 @@
+#!/bin/bash
+#
+# Startup script for mythbackend
+#
+# chkconfig: - 86 14
+# description: mythbackend.
+# processname: mythbackend
+# pidfile: /var/run/mythbackend.pid
+# config:
+
+# Source function library.
+. /etc/init.d/functions
+
+if [ -f /etc/sysconfig/mythbackend ]; then
+        . /etc/sysconfig/mythbackend
+fi
+
+## Defaults, override them in /etc/sysconfig/mythbackend
+MYTHTV_HOME=${MYTHTV_HOME:-/etc/mythtv}
+MYTHBACKEND_USER=${MYTHBACKEND_USER:-root}
+
+binary=/usr/bin/mythbackend
+prog=mythbackend
+RETVAL=0
+OPTIONS="$OPTIONS --daemon --user ${MYTHBACKEND_USER} --logpath /var/log/mythtv --pidfile /var/run/$prog.pid"
+
+start() {
+  echo -n $"Starting $prog: "
+  touch /var/run/mythbackend.pid
+  if [ "${MYTHBACKEND_USER}" != root ]; then
+    chown ${MYTHBACKEND_USER}:${MYTHBACKEND_USER} /var/run/mythbackend.pid
+    if [ -d /dev/dvb ]; then
+      /usr/bin/setfacl -m u:${MYTHBACKEND_USER}:rwx -R /dev/dvb/
+    fi
+    if [ -d /dev/snd ]; then
+      /usr/bin/setfacl -m u:${MYTHBACKEND_USER}:rwx -R /dev/snd/
+    fi
+    for f in $(ls /dev/video* 2>/dev/null); do
+      /usr/bin/setfacl -m u:${MYTHBACKEND_USER}:rw- $f
+    done
+    for f in $(ls /dev/vbi* 2>/dev/null); do
+      /usr/bin/setfacl -m u:${MYTHBACKEND_USER}:rw- $f
+    done
+  fi
+  export MYTHCONFDIR="$MYTHTV_HOME"
+  export HOME="$MYTHTV_HOME"
+  daemon $binary $OPTIONS
+  RETVAL=$?
+  echo
+  [ $RETVAL = 0 ] && touch /var/lock/subsys/$prog
+  return $RETVAL
+}
+
+stop() {
+  echo -n $"Stopping $prog: "
+  killproc $binary
+  RETVAL=$?
+  if [ "${MYTHBACKEND_USER}" != root ]; then
+    if [ -d /dev/dvb ]; then
+      /usr/bin/setfacl -x u:${MYTHBACKEND_USER} -R /dev/dvb/
+    fi
+    if [ -d /dev/snd ]; then
+      /usr/bin/setfacl -x u:${MYTHBACKEND_USER} -R /dev/snd/
+    fi
+    for f in $(ls /dev/video* 2>/dev/null); do
+      /usr/bin/setfacl -x u:${MYTHBACKEND_USER} $f
+    done
+    for f in $(ls /dev/vbi* 2>/dev/null); do
+      /usr/bin/setfacl -x u:${MYTHBACKEND_USER} $f
+    done
+  fi
+  echo
+  [ $RETVAL = 0 ] && rm -f /var/lock/subsys/$prog /var/run/$prog.pid
+}
+
+# See how we were called.
+case "$1" in
+  start)
+	start
+	;;
+  stop)
+	stop
+	;;
+  reload|restart)
+	stop
+	start
+	;;
+  status)
+	status $prog
+	RETVAL=$?
+	;;
+  *)
+	echo $"Usage: $prog {start|stop|status|restart}"
+	exit 1
+esac
+
+exit $RETVAL


Index: mythbackend.sysconfig
===================================================================
RCS file: mythbackend.sysconfig
diff -N mythbackend.sysconfig
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ mythbackend.sysconfig	6 Jul 2012 00:46:08 -0000	1.3
@@ -0,0 +1,10 @@
+#MYTHTV_HOME=/etc/mythtv
+# mythbackend runs as root by default, but support for running as a non-root
+# user should be functional. However, switching to a non-root user on an
+# existing setup will require fixing up permissions on files mythbackend
+# needs access to -- particularly, your recordings, which are owned by the
+# user mythbackend runs as. If you switch from running as root to running as
+# user mythtv, deleting existing recordings won't work until their file
+# ownership has been changed from root to mythtv as well.
+#MYTHBACKEND_USER=mythtv
+#OPTIONS=

mythtv-0.25.1-fixes.patch:
 mythplugins/mythmusic/mythmusic/metadata.cpp                      |    6 
 mythplugins/mythweather/mythweather/scripts/us_nws/NDFDParser.pm  |    3 
 mythplugins/mythweather/mythweather/scripts/us_nws/ndfd.pl        |   17 
 mythplugins/mythweather/mythweather/scripts/us_nws/ndfd18.pl      |   13 
 mythplugins/mythweather/mythweather/scripts/us_nws/ndfdXML.pm     |   24 
 mythplugins/mythweather/mythweather/scripts/us_nws/nws-alert.pl   |    8 
 mythplugins/mythweather/mythweather/scripts/us_nws/nwsxml.pl      |   12 
 mythtv/bindings/python/MythTV/utility.py                          |    2 
 mythtv/bindings/python/tmdb3/README                               |   51 +
 mythtv/bindings/python/tmdb3/setup.py                             |    2 
 mythtv/bindings/python/tmdb3/tmdb3/__init__.py                    |    7 
 mythtv/bindings/python/tmdb3/tmdb3/cache.py                       |   35 -
 mythtv/bindings/python/tmdb3/tmdb3/cache_engine.py                |   31 
 mythtv/bindings/python/tmdb3/tmdb3/cache_file.py                  |  342 +++++++---
 mythtv/bindings/python/tmdb3/tmdb3/cache_null.py                  |    4 
 mythtv/bindings/python/tmdb3/tmdb3/locales.py                     |   72 +-
 mythtv/bindings/python/tmdb3/tmdb3/pager.py                       |    2 
 mythtv/bindings/python/tmdb3/tmdb3/request.py                     |   49 +
 mythtv/bindings/python/tmdb3/tmdb3/tmdb_api.py                    |  339 ++++++---
 mythtv/bindings/python/tmdb3/tmdb3/tmdb_auth.py                   |  131 +++
 mythtv/bindings/python/tmdb3/tmdb3/tmdb_exceptions.py             |   17 
 mythtv/bindings/python/tmdb3/tmdb3/util.py                        |   44 +
 mythtv/libs/libmythbase/mthreadpool.cpp                           |    1 
 mythtv/libs/libmythbase/mythcorecontext.cpp                       |    2 
 mythtv/libs/libmythprotoserver/requesthandler/outboundhandler.cpp |    2 
 mythtv/libs/libmythtv/decoderbase.cpp                             |   46 -
 mythtv/libs/libmythtv/dtvmultiplex.cpp                            |    4 
 mythtv/libs/libmythtv/eithelper.cpp                               |   19 
 mythtv/libs/libmythtv/hdhrstreamhandler.cpp                       |   28 
 mythtv/libs/libmythtv/mythplayer.cpp                              |    3 
 mythtv/libs/libmythtv/mythplayer.h                                |    3 
 mythtv/libs/libmythtv/ringbuffer.cpp                              |    2 
 mythtv/libs/libmythtv/tv_rec.cpp                                  |   74 +-
 mythtv/libs/libmythtv/tv_rec.h                                    |    5 
 mythtv/programs/mythbackend/mainserver.cpp                        |   16 
 mythtv/programs/mythbackend/scheduler.cpp                         |   43 +
 mythtv/programs/mythbackend/scheduler.h                           |    6 
 mythtv/programs/mythcommflag/main.cpp                             |    7 
 mythtv/programs/mythfrontend/playbackbox.cpp                      |    3 
 mythtv/programs/mythtranscode/transcode.cpp                       |  147 +---
 mythtv/programs/programs-libs.pro                                 |    1 
 mythtv/themes/Terra/osd.xml                                       |    4 
 scripts/pytmdb3.py                                                |   53 +
 tmdb3/tmdb_auth.py                                                |  131 +++
 44 files changed, 1367 insertions(+), 444 deletions(-)

--- NEW FILE mythtv-0.25.1-fixes.patch ---
 mythplugins/mythmusic/mythmusic/metadata.cpp       |    6 +
 .../mythweather/scripts/us_nws/NDFDParser.pm       |    3 +-
 .../mythweather/mythweather/scripts/us_nws/ndfd.pl |   17 +-
 .../mythweather/scripts/us_nws/ndfd18.pl           |   13 +-
 .../mythweather/scripts/us_nws/ndfdXML.pm          |   24 +-
 .../mythweather/scripts/us_nws/nws-alert.pl        |    8 +-
 .../mythweather/scripts/us_nws/nwsxml.pl           |   12 +-
 mythtv/bindings/python/MythTV/utility.py           |    2 +-
 mythtv/bindings/python/tmdb3/README                |   51 +++-
 mythtv/bindings/python/tmdb3/setup.py              |    2 +-
 mythtv/bindings/python/tmdb3/tmdb3/__init__.py     |    7 +-
 mythtv/bindings/python/tmdb3/tmdb3/cache.py        |   35 ++-
 mythtv/bindings/python/tmdb3/tmdb3/cache_engine.py |   31 ++-
 mythtv/bindings/python/tmdb3/tmdb3/cache_file.py   |  342 ++++++++++++++++----
 mythtv/bindings/python/tmdb3/tmdb3/cache_null.py   |    4 +-
 mythtv/bindings/python/tmdb3/tmdb3/locales.py      |   72 ++++-
 mythtv/bindings/python/tmdb3/tmdb3/pager.py        |    2 +
 mythtv/bindings/python/tmdb3/tmdb3/request.py      |   49 +++-
 mythtv/bindings/python/tmdb3/tmdb3/tmdb_api.py     |  339 ++++++++++++++------
 mythtv/bindings/python/tmdb3/tmdb3/tmdb_auth.py    |  131 ++++++++
 .../bindings/python/tmdb3/tmdb3/tmdb_exceptions.py |   17 +-
 mythtv/bindings/python/tmdb3/tmdb3/util.py         |   44 ++-
 mythtv/libs/libmythbase/mthreadpool.cpp            |    1 +
 mythtv/libs/libmythbase/mythcorecontext.cpp        |    2 +-
 .../requesthandler/outboundhandler.cpp             |    2 +
 mythtv/libs/libmythtv/decoderbase.cpp              |   46 ++-
 mythtv/libs/libmythtv/dtvmultiplex.cpp             |    4 +-
 mythtv/libs/libmythtv/eithelper.cpp                |   19 ++
 mythtv/libs/libmythtv/hdhrstreamhandler.cpp        |   28 ++-
 mythtv/libs/libmythtv/mythplayer.cpp               |    3 +-
 mythtv/libs/libmythtv/mythplayer.h                 |    3 +
 mythtv/libs/libmythtv/ringbuffer.cpp               |    2 +-
 mythtv/libs/libmythtv/tv_rec.cpp                   |   74 +++--
 mythtv/libs/libmythtv/tv_rec.h                     |    5 +-
 mythtv/programs/mythbackend/mainserver.cpp         |   16 +-
 mythtv/programs/mythbackend/scheduler.cpp          |   43 ++-
 mythtv/programs/mythbackend/scheduler.h            |    6 +
 mythtv/programs/mythcommflag/main.cpp              |    7 +-
 mythtv/programs/mythfrontend/playbackbox.cpp       |    3 +-
 mythtv/programs/mythtranscode/transcode.cpp        |  147 +++------
 mythtv/programs/programs-libs.pro                  |    1 +
 mythtv/themes/Terra/osd.xml                        |    4 +-
 scripts/pytmdb3.py                                 |   53 +++
 tmdb3/tmdb_auth.py                                 |  131 ++++++++
 44 files changed, 1367 insertions(+), 444 deletions(-)

diff --git a/mythplugins/mythmusic/mythmusic/metadata.cpp b/mythplugins/mythmusic/mythmusic/metadata.cpp
index 18ac7e3..4e167b0 100644
--- a/mythplugins/mythmusic/mythmusic/metadata.cpp
+++ b/mythplugins/mythmusic/mythmusic/metadata.cpp
@@ -171,6 +171,12 @@ bool Metadata::isInDatabase()
     bool retval = false;
 
     QString sqldir = m_filename.section('/', 0, -2);
+
+    // Filename is the absolute path, we want the relative path
+    QString musicdir = gCoreContext->GetSetting("MusicLocation");
+    if (sqldir.startsWith(musicdir))
+        sqldir.remove(0, musicdir.length());
+    
     QString sqlfilename = m_filename.section('/', -1);
 
     MSqlQuery query(MSqlQuery::InitCon());
diff --git a/mythplugins/mythweather/mythweather/scripts/us_nws/NDFDParser.pm b/mythplugins/mythweather/mythweather/scripts/us_nws/NDFDParser.pm
index 2be6748..4ede85d 100644
--- a/mythplugins/mythweather/mythweather/scripts/us_nws/NDFDParser.pm
+++ b/mythplugins/mythweather/mythweather/scripts/us_nws/NDFDParser.pm
@@ -177,7 +177,7 @@ sub timeChar {
 ########## Exported method to do parsing #################
 
 sub doParse {
-    my ($lat, $lon, $start, $end, $params) = @_;
+    my ($lat, $lon, $start, $end, $units, $params) = @_;
     my $product = "time-series";
 
     my $NDFD_XML = ndfdXML->NDFDgen(SOAP::Data->name("latitude" => $lat), 
@@ -185,6 +185,7 @@ sub doParse {
         SOAP::Data->name("product" => $product),
         SOAP::Data->name("startTime" => $start),
         SOAP::Data->name("endTime" => $end),
+        SOAP::Data->name("Unit" => $units),
         SOAP::Data->name("weatherParameters" => 
             \SOAP::Data->value(
                 SOAP::Data->type('boolean')->name("maxt" => $params->{maxt}),
diff --git a/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd.pl b/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd.pl
index 081bb12..c16fb55 100755
--- a/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd.pl
+++ b/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd.pl
@@ -22,9 +22,9 @@ use Getopt::Std;
 our ($opt_v, $opt_t, $opt_T, $opt_l, $opt_u, $opt_d); 
 
 my $name = 'NDFD-6_day';
-my $version = 0.3;
-my $author = 'Lucien Dunning';
-my $email = 'ldunning at gmail.com';
+my $version = 0.4;
+my $author = 'Gavin Hurlbut & Lucien Dunning';
+my $email = 'gjhurlbu at gmail.com';
 my $updateTimeout = 15*60;
 my $retrieveTimeout = 30;
 my @types = ('3dlocation', '6dlocation',  'updatetime', 
@@ -119,7 +119,8 @@ if (open (CACHE, "$dir/ndfd_cache_${latitude}_${longitude}")) {
 } 
 
 if ($getData) {
-    ($result, $creationdate) = NDFDParser::doParse($latitude, $longitude, $d1, $d2, $param);
+    my $unit = ($units eq "SI" ? "m" : "e");
+    ($result, $creationdate) = NDFDParser::doParse($latitude, $longitude, $d1, $d2, $unit, $param);
     # output cache
     open(CACHE, ">$dir/ndfd_cache_${latitude}_${longitude}") or 
         die "cannot open cache ($dir/ndfd_cache_${latitude}_${longitude}) for writing";
@@ -171,17 +172,9 @@ foreach $time (sort(keys(%$result))) {
     }
     my $geticon = 0;
     if ($lowindex <= 5 && $result->{$time}->{temperature_minimum}) { 
-        if ($units eq 'SI') {
-            $result->{$time}->{temperature_minimum} =
-                int ( (5/9) * ($result->{$time}->{temperature_minimum}-32));
-        }
         print "low-${lowindex}::$result->{$time}->{temperature_minimum}\n";
         $lowindex++;
     } elsif ($hiindex <= 5 && $result->{$time}->{temperature_maximum}) {
-        if ($units eq 'SI') {
-            $result->{$time}->{temperature_maximum} =
-                int ( (5/9) * ($result->{$time}->{temperature_maximum}-32));
-        }
         print "high-${hiindex}::$result->{$time}->{temperature_maximum}\n";
         $hiindex++;
         $geticon = 1;
diff --git a/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd18.pl b/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd18.pl
index ae99c99..f4b8049 100755
--- a/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd18.pl
+++ b/mythplugins/mythweather/mythweather/scripts/us_nws/ndfd18.pl
@@ -18,9 +18,9 @@ use Date::Manip;
 our ($opt_v, $opt_t, $opt_T, $opt_l, $opt_u, $opt_d); 
 
 my $name = 'NDFD-18_Hour';
-my $version = 0.2;
-my $author = 'Lucien Dunning';
-my $email = 'ldunning at gmail.com';
+my $version = 0.3;
+my $author = 'Gavin Hurlbut & Lucien Dunning';
+my $email = 'gjhurlbu at gmail.com';
 my $updateTimeout = 15*60;
 my $retrieveTimeout = 30;
 my @types = ('18hrlocation',  'updatetime', 
@@ -116,7 +116,8 @@ if (open (CACHE, "$dir/ndfd18_cache_${latitude}_${longitude}")) {
 } 
 
 if ($getData) {
-    ($result, $creationdate) = NDFDParser::doParse($latitude, $longitude, $d1, $d2, $param);
+    my $unit = ($units eq "SI" ? "m" : "e");
+    ($result, $creationdate) = NDFDParser::doParse($latitude, $longitude, $d1, $d2, $unit, $param);
     # output cache
     open(CACHE, ">$dir/ndfd18_cache_${latitude}_${longitude}") or 
         die "cannot open cache ($dir/ndfd18_cache_${latitude}_${longitude}) for writing";
@@ -149,10 +150,6 @@ foreach my $time (sort keys %$result) {
     }
 
     print "time-${index}::" . UnixDate($time, "%i %p\n");
-    if ($units eq 'SI') {
-        $result->{$time}->{temperature_hourly} =
-            int( (5/9) * ($result->{$time}->{temperature_hourly}-32));
-    }
     print "temp-${index}::$result->{$time}->{temperature_hourly}\n";
     print "pop-${index}::$pop12 %\n";
     $icon = $result->{$time}->{'conditions-icon_forecast-NWS'};
diff --git a/mythplugins/mythweather/mythweather/scripts/us_nws/ndfdXML.pm b/mythplugins/mythweather/mythweather/scripts/us_nws/ndfdXML.pm
index 873ff8e..4cef7fb 100644
--- a/mythplugins/mythweather/mythweather/scripts/us_nws/ndfdXML.pm
+++ b/mythplugins/mythweather/mythweather/scripts/us_nws/ndfdXML.pm
@@ -5,9 +5,9 @@ package ndfdXML;
 
 my %methods = (
   NDFDgenByDay => {
-    endpoint => 'http://www.weather.gov/forecasts/xml/SOAP_server/ndfdXMLserver.php',
-    soapaction => 'http://www.weather.gov/forecasts/xml/DWMLgen/wsdl/ndfdXML.wsdl#NDFDgenByDay',
-    uri => 'http://www.weather.gov/forecasts/xml/DWMLgen/wsdl/ndfdXML.wsdl',
+    endpoint => 'http://graphical.weather.gov/xml/SOAP_server/ndfdXMLserver.php',
+    soapaction => 'http://graphical.weather.gov/xml/DWMLgen/wsdl/ndfdXML.wsdl#NDFDgenByDay',
+    uri => 'http://graphical.weather.gov/xml/DWMLgen/wsdl/ndfdXML.wsdl',
     parameters => [
       SOAP::Data->new(name => 'latitude', type => 'xsd:decimal', attr => {}),
       SOAP::Data->new(name => 'longitude', type => 'xsd:decimal', attr => {}),
@@ -17,15 +17,16 @@ my %methods = (
     ],
   },
   NDFDgen => {
-    endpoint => 'http://www.weather.gov/forecasts/xml/SOAP_server/ndfdXMLserver.php',
-    soapaction => 'http://www.weather.gov/forecasts/xml/DWMLgen/wsdl/ndfdXML.wsdl#NDFDgen',
-    uri => 'http://www.weather.gov/forecasts/xml/DWMLgen/wsdl/ndfdXML.wsdl',
+    endpoint => 'http://graphical.weather.gov/xml/SOAP_server/ndfdXMLserver.php',
+    soapaction => 'http://graphical.weather.gov/xml/DWMLgen/wsdl/ndfdXML.wsdl#NDFDgen',
+    uri => 'http://graphical.weather.gov/xml/DWMLgen/wsdl/ndfdXML.wsdl',
     parameters => [
       SOAP::Data->new(name => 'latitude', type => 'xsd:decimal', attr => {}),
       SOAP::Data->new(name => 'longitude', type => 'xsd:decimal', attr => {}),
-      SOAP::Data->new(name => 'product', type => 'typens:productType', attr => {}),
+      SOAP::Data->new(name => 'product', type => 'xsd:string', attr => {}),
[...2814 lines suppressed...]
+            <area>20,95,110,30</area>
             <font>baseextralarge</font>
             <align>hcenter</align>
             <template>%CHANNUM%</template>
diff --git a/scripts/pytmdb3.py b/scripts/pytmdb3.py
new file mode 100755
index 0000000..f6a3e64
--- /dev/null
+++ b/scripts/pytmdb3.py
@@ -0,0 +1,53 @@
+#!/usr/bin/env python
+
+from optparse import OptionParser
+from tmdb3 import *
+
+import sys
+
+if __name__ == '__main__':
+    # this key is registered to this library for testing purposes.
+    # please register for your own key if you wish to use this
+    # library in your own application.
+    # http://help.themoviedb.org/kb/api/authentication-basics
+    set_key('1acd79ff610c77f3040073d004f7f5b0')
+
+    parser = OptionParser()
+    parser.add_option('-v', "--version", action="store_true", default=False,
+                      dest="version", help="Display version.")
+    parser.add_option('-d', "--debug", action="store_true", default=False,
+                      dest="debug", help="Enables verbose debugging.")
+    parser.add_option('-c', "--no-cache", action="store_true", default=False,
+                      dest="nocache", help="Disables request cache.")
+    opts, args = parser.parse_args()
+
+    if opts.version:
+        from tmdb3.tmdb_api import __title__, __purpose__, __version__, __author__
+        print __title__
+        print ""
+        print __purpose__
+        print "Version: "+__version__
+        sys.exit(0)
+
+#   TODO: make this actually do something
+#    if opts.debug:
+#        DEBUG = True
+
+    if opts.nocache:
+        set_cache(engine='null')
+    else:
+        set_cache(engine='file', filename='/tmp/pytmdb3.cache')
+
+    banner = 'PyTMDB3 Interactive Shell.'
+    import code
+    try:
+        import readline, rlcompleter
+    except ImportError:
+        pass
+    else:
+        readline.parse_and_bind("tab: complete")
+        banner += ' TAB completion available.'
+    namespace = globals().copy()
+    namespace.update(locals())
+    code.InteractiveConsole(namespace).interact(banner)
+
diff --git a/tmdb3/tmdb_auth.py b/tmdb3/tmdb_auth.py
new file mode 100644
index 0000000..8583b99
--- /dev/null
+++ b/tmdb3/tmdb_auth.py
@@ -0,0 +1,131 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+#-----------------------
+# Name: tmdb_auth.py
+# Python Library
+# Author: Raymond Wagner
+# Purpose: Provide authentication and session services for 
+#          calls against the TMDB v3 API
+#-----------------------
+
+from datetime import datetime as _pydatetime, \
+                     tzinfo as _pytzinfo
+import re
+class datetime( _pydatetime ):
+    """Customized datetime class with ISO format parsing."""
+    _reiso = re.compile('(?P<year>[0-9]{4})'
+                       '-(?P<month>[0-9]{1,2})'
+                       '-(?P<day>[0-9]{1,2})'
+                        '.'
+                        '(?P<hour>[0-9]{2})'
+                       ':(?P<min>[0-9]{2})'
+                       '(:(?P<sec>[0-9]{2}))?'
+                        '(?P<tz>Z|'
+                            '(?P<tzdirec>[-+])'
+                            '(?P<tzhour>[0-9]{1,2})'
+                            '(:)?'
+                            '(?P<tzmin>[0-9]{2})?'
+                        ')?')
+
+    class _tzinfo( _pytzinfo):
+        def __init__(self, direc='+', hr=0, min=0):
+            if direc == '-':
+                hr = -1*int(hr)
+            self._offset = timedelta(hours=int(hr), minutes=int(min))
+        def utcoffset(self, dt): return self._offset
+        def tzname(self, dt): return ''
+        def dst(self, dt): return timedelta(0)
+
+    @classmethod
+    def fromIso(cls, isotime, sep='T'):
+        match = cls._reiso.match(isotime)
+        if match is None:
+            raise TypeError("time data '%s' does not match ISO 8601 format" \
+                                % isotime)
+
+        dt = [int(a) for a in match.groups()[:5]]
+        if match.group('sec') is not None:
+            dt.append(int(match.group('sec')))
+        else:
+            dt.append(0)
+        if match.group('tz'):
+            if match.group('tz') == 'Z':
+                tz = cls._tzinfo()
+            elif match.group('tzmin'):
+                tz = cls._tzinfo(*match.group('tzdirec','tzhour','tzmin'))
+            else:
+                tz = cls._tzinfo(*match.group('tzdirec','tzhour'))
+            dt.append(0)
+            dt.append(tz)
+        return cls(*dt)
+
+from request import Request
+from tmdb_exceptions import *
+
+syssession = None
+
+def set_session(sessionid):
+    global syssession
+    syssession = Session(sessionid)
+
+def get_session(sessionid=None):
+    global syssession
+    if sessionid:
+        return Session(sessionid)
+    elif syssession is not None:
+        return syssession
+    else:
+        return Session.new()
+
+class Session( object ):
+
+    @classmethod
+    def new(cls):
+        return cls(None)
+
+    def __init__(self, sessionid):
+        self.sessionid = sessionid
+
+    @property
+    def sessionid(self):
+        if self._sessionid is None:
+            if self._authtoken is None:
+                raise TMDBError("No Auth Token to produce Session for")
+            # TODO: check authtokenexpiration against current time
+            req = Request('authentication/session/new', \
+                                            request_token=self._authtoken)
+            req.lifetime = 0
+            dat = req.readJSON()
+            if not dat['success']:
+                raise TMDBError("Session generation failed")
+            self._sessionid = dat['session_id']
+        return self._sessionid
+
+    @sessionid.setter
+    def sessionid(self, value):
+        self._sessionid = value
+        self._authtoken = None
+        self._authtokenexpiration = None
+        if value is None:
+            self.authenticated = False
+        else:
+            self.authenticated = True
+
+    @property
+    def authtoken(self):
+        if self.authenticated:
+            raise TMDBError("Session is already authenticated")
+        if self._authtoken is None:
+            req = Request('authentication/token/new')
+            req.lifetime = 0
+            dat = req.readJSON()
+            if not dat['success']:
+                raise TMDBError("Auth Token request failed")
+            self._authtoken = dat['request_token']
+            self._authtokenexpiration = datetime.fromIso(dat['expires_at'])
+        return self._authtoken
+
+    @property
+    def callbackurl(self):
+        return "http://www.themoviedb.org/authenticate/"+self._authtoken
+


--- NEW FILE mythtv.logrotate.sysd ---
/var/log/mythtv/mythbackend.log /var/log/mythtv/myth*.*.*.log {
    notifempty
    missingok
    compress
    compresscmd /usr/bin/bzip2
    uncompresscmd /usr/bin/bunzip2
    compressext .bz2
    weekly
    rotate 4
    size 10M
    postrotate
         /bin/systemctl kill mythbackend.service --signal=HUP --kill-who=main 2>/dev/null || true
    endscript
}


--- NEW FILE mythtv.logrotate.sysv ---
/var/log/mythtv/myth*.log {
    notifempty
    missingok
    compress
    compresscmd /usr/bin/bzip2
    uncompresscmd /usr/bin/bunzip2
    compressext .bz2
    weekly
    rotate 4
    size 10M
    postrotate
       /bin/kill -HUP `cat /var/run/mythbackend.pid 2>/dev/null` 2> /dev/null || true
    endscript
}


Index: mythbackend.service
===================================================================
RCS file: /cvs/free/rpms/mythtv/F-16/mythbackend.service,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- mythbackend.service	18 Apr 2012 20:44:54 -0000	1.5
+++ mythbackend.service	6 Jul 2012 00:46:08 -0000	1.6
@@ -32,7 +32,8 @@
 [Unit]
 Description=MythTV backend service
 After=network.target mysqld.service
-Wants=httpd.service
+# uncomment the following line if you will be using the mythweb plugin.
+#Wants=httpd.service
 
 [Service]
 Type=simple


Index: mythtv.spec
===================================================================
RCS file: /cvs/free/rpms/mythtv/F-16/mythtv.spec,v
retrieving revision 1.93
retrieving revision 1.94
diff -u -r1.93 -r1.94
--- mythtv.spec	4 May 2012 20:23:55 -0000	1.93
+++ mythtv.spec	6 Jul 2012 00:46:08 -0000	1.94
@@ -48,7 +48,6 @@
 # --without mythnews
 # --without mythweather
 # --without mythzoneminder
-# --without mythweb
 #
 
 ################################################################################
@@ -60,15 +59,12 @@
 %define desktop_vendor RPMFusion
 
 # Git revision and branch ID
-# 0.24 release: git tag v0.24.1
-%define _gitrev 1a671d0
+# 0.25 release: git tag v0.25.1
+%define _gitrev c2c276d
 
 # Mythtv and plugins from github.com
-%global githash1 g1f5962a
-%global githash2 9615da9
-# Mythweb from github.com
-%global githash3 g1d056f7
-%global githash4 0fc49a5
+%global githash1 gc2c276d
+%global githash2 4c30a85
 
 %define branch fixes/0.25
 
@@ -81,12 +77,12 @@
 Group:          Applications/Multimedia
 
 # Version/Release info
-Version:        0.25
+Version:        0.25.1
 %if "%{branch}" == "master"
 Release:        0.1.git.%{_gitrev}%{?dist}
 #Release: 0.1.rc1%{?dist}
 %else
-Release:        6%{?dist}
+Release:        1%{?dist}
 %endif
 
 # The primary license is GPLv2+, but bits are borrowed from a number of
@@ -131,7 +127,6 @@
 %define with_mythmusic      %{?_without_mythmusic:      0} %{!?_without_mythmusic:       1}
 %define with_mythnews       %{?_without_mythnews:       0} %{!?_without_mythnews:        1}
 %define with_mythweather    %{?_without_mythweather:    0} %{!?_without_mythweather:     1}
-%define with_mythweb        %{?_without_mythweb:        0} %{!?_without_mythweb:         1}
 %define with_mythzoneminder %{?_without_mythzoneminder: 0} %{!?_without_mythzoneminder:  1}
 %define with_mythnetvision  %{?_without_mythnetvision:  0} %{!?_without_mythnetvision:   1}
 
@@ -139,25 +134,22 @@
 
 # https://github.com/MythTV/mythtv/tarball/v0.25
 Source0:   MythTV-%{name}-v%{version}-0-%{githash1}.tar.gz
-# https://github.com/MythTV/mythweb/tarball/v0.25
-Source1:   MythTV-mythweb-v%{version}-0-%{githash3}.tar.gz
 
-Patch0:    mythtv-0.25-fixes.patch
-#Patch1:    mythweb-%{version}-fixes.patch
-Patch2:    mythtv_0.25_gcc_4.7.patch
+Patch0:    mythtv-0.25.1-fixes.patch
 
 Source10:  PACKAGE-LICENSING
-#Source101: mythbackend.sysconfig
-#Source102: mythbackend.init
-Source103: mythbackend.logrotate
-Source104: mythbackend.service
+Source11:  ChangeLog
+Source101: mythbackend.sysconfig
+Source102: mythbackend.init
+Source103: mythtv.logrotate.sysv
+Source104: mythtv.logrotate.sysd
+Source105: mythbackend.service
 Source106: mythfrontend.png
 Source107: mythfrontend.desktop
 Source108: mythtv-setup.png
 Source109: mythtv-setup.desktop
 Source110: mysql.txt
 Source111: 99-mythbackend.rules
-Source401: mythweb.conf
 
 
 # Global MythTV and Shared Build Requirements
@@ -222,7 +214,6 @@
 BuildRequires:  libogg-devel
 BuildRequires:  libtheora-devel
 BuildRequires:  libvorbis-devel >= 1.0
-BuildRequires:  mjpegtools-devel >= 1.6.1
 BuildRequires:  taglib-devel >= 1.6
 BuildRequires:  x264-devel
 BuildRequires:  xvidcore-devel >= 0.9.1
@@ -354,6 +345,7 @@
 Requires:  php-MythTV         = %{version}-%{release}
 Requires:  python-MythTV      = %{version}-%{release}
 Requires:  mythplugins        = %{version}-%{release}
+Requires:  mythweb
 Requires:  mysql-server >= 5, mysql >= 5
 Requires:  xmltv
 
@@ -387,8 +379,9 @@
 ################################################################################
 
 %package docs
-Summary: MythTV documentation
-Group:   Documentation
+Summary:   MythTV documentation
+Group:     Documentation
+BuildArch: noarch
 
 %description docs
 The MythTV documentation, database initialization file
@@ -516,9 +509,8 @@
 Requires:  perl(XML::Simple)
 Requires:  mythtv-common       = %{version}-%{release}
 Requires:  mythtv-base-themes  = %{version}
+Requires:  python-MythTV python-lxml
 Provides:  mythtv-frontend-api = %{mythfeapiver}
-Obsoletes: mythcontrols        < %{version}-%{release}
-Provides:  mythcontrols        = %{version}-%{release}
 Obsoletes: mythvideo           < %{version}-%{release}
 Provides:  mythvideo           = %{version}-%{release}
 
@@ -571,13 +563,7 @@
 %package common
 Summary: Common components needed by multiple other MythTV components
 Group: Applications/Multimedia
-# mythphone is now DOA, but we need this for upgrade path preservation.
-Provides: mythphone = %{version}-%{release}
-Obsoletes: mythphone < %{version}-%{release}
-# same deal for mythflix
-Provides: mythflix = %{version}-%{release}
-Obsoletes: mythflix < %{version}-%{release}
-# and now mythmovies
+# mythpmovies is now DOA, but we need this for upgrade path preservation.
 Provides: mythmovies = %{version}-%{release}
 Obsoletes: mythmovies < %{version}-%{release}
 
@@ -594,8 +580,7 @@
 %package -n perl-MythTV
 Summary:        Perl bindings for MythTV
 Group:          Development/Languages
-# Wish we could do this:
-#BuildArch:      noarch
+BuildArch:      noarch
 
 Requires:       perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
 Requires:       perl(DBD::mysql)
@@ -614,8 +599,7 @@
 %package -n php-MythTV
 Summary:        PHP bindings for MythTV
 Group:          Development/Languages
-# Wish we could do this:
-#BuildArch:      noarch
+BuildArch:      noarch
 
 %description -n php-MythTV
 Provides a PHP-based interface to interacting with MythTV.
@@ -629,8 +613,7 @@
 %package -n python-MythTV
 Summary:        Python bindings for MythTV
 Group:          Development/Languages
-# Wish we could do this:
-#BuildArch:      noarch
+BuildArch:      noarch
 
 Requires:       MySQL-python
 Requires:       PyXML
@@ -658,7 +641,6 @@
 Requires:  mythbrowser    = %{version}-%{release}
 Requires:  mytharchive    = %{version}-%{release}
 Requires:  mythzoneminder = %{version}-%{release}
-Requires:  mythweb        = %{version}-%{release}
 Requires:  mythnetvision  = %{version}-%{release}
 
 %description -n mythplugins
@@ -683,7 +665,6 @@
 Requires:  python >= 2.3.5
 Requires:  python-imaging
 Requires:  transcode >= 1.0.2
-Requires:  m2vrequantiser
 Requires:  pmount
 
 %description -n mytharchive
@@ -772,22 +753,6 @@
 
 %endif
 ################################################################################
-%if %{with_mythweb}
-
-%package -n mythweb
-Summary:   The web interface to MythTV
-Group:     Applications/Multimedia
-Requires:  httpd >= 1.3.26
-Requires:  php >= 5.1
-Requires:  php-mysql
-Requires:  php-process
-Requires:  php-MythTV
-
-%description -n mythweb
-The web interface to MythTV.
-
-%endif
-################################################################################
 %if %{with_mythzoneminder}
 
 %package -n mythzoneminder
@@ -813,6 +778,7 @@
 Requires:  python-MythTV = %{version}-%{release}
 Requires:  python-pycurl
 Requires:  python >= 2.5
+Requires:  python-lxml
 # This is packaged in adobe's yum repo
 #Requires:  flash-plugin
 
@@ -829,19 +795,6 @@
 ################################################################################
 
 %prep
-#### MythWeb
-# Provided as a separate download so we deal with it here.
-%setup -q -T -b 1 -n MythTV-mythweb-%{githash4}
-
-# Fix up permissions for MythWeb
-chmod -R g-w ./*
-
-# Remove execute bits from some php mythweb files
-#    chmod -x mythweb/classes/*.php
-
-
-#### MythTV
-#setup -q -c -a 1
 %setup -q -n MythTV-%{name}-%{githash2}
 
 # Replace static lib paths with %{_lib} so we build properly on x86_64
@@ -853,8 +806,9 @@
     fi
 
 %patch0 -p1 -b .mythtv
-#patch1 -p1 -b .mythplug
-%patch2 -p1 -b .gcc47
+
+# Install ChangeLog
+install -m 0644 %{SOURCE11} .
 
 pushd mythtv
 
@@ -1082,17 +1036,22 @@
 # mysql.txt and other config/init files
     install -m 0644 %{SOURCE110} %{buildroot}%{_sysconfdir}/mythtv/
     echo "# to be filled in by mythtv-setup" > %{buildroot}%{_sysconfdir}/mythtv/config.xml
+
+    ### SystemD based setup. ###
     %if 0%{?fedora} >= 16
-    install -p -m 0644 %{SOURCE104} %{buildroot}%{_unitdir}/
+    install -p -m 0644 %{SOURCE105} %{buildroot}%{_unitdir}/
+    install -p -m 0644 %{SOURCE104} %{buildroot}%{_sysconfdir}/logrotate.d/mythtv
     # Install udev rules for devices that may initialize late in the boot
     # process so they are available for mythbackend.
     mkdir -p %{buildroot}/lib/udev/rules.d/
     install -p -m 0644 %{SOURCE111} %{buildroot}/lib/udev/rules.d/
+
+    ### SysV based setup. ###
     %else
     install -p -m 0755 %{SOURCE102} %{buildroot}%{_sysconfdir}/init.d/mythbackend
     install -p -m 0644 %{SOURCE101} %{buildroot}%{_sysconfdir}/sysconfig/mythbackend
+    install -p -m 0644 %{SOURCE103} %{buildroot}%{_sysconfdir}/logrotate.d/mythtv
     %endif
-    install -p -m 0644 %{SOURCE103} %{buildroot}%{_sysconfdir}/logrotate.d/mythbackend
 
 # Desktop entries
     mkdir -p %{buildroot}%{_datadir}/pixmaps
@@ -1142,19 +1101,6 @@
 %endif
 popd
 
-%if %{with_mythweb}
-    pushd ../MythTV-mythweb-%{githash4}
-    mkdir -p %{buildroot}%{_datadir}/mythweb
-    cp -a * %{buildroot}%{_datadir}/mythweb/
-    mkdir -p %{buildroot}%{_datadir}/mythweb/{image_cache,php_sessions}
-
-    mkdir -p %{buildroot}%{_sysconfdir}/httpd/conf.d
-    cp %{SOURCE401} %{buildroot}%{_sysconfdir}/httpd/conf.d/
-    # drop .htaccess file, settings handled in the above
-    rm -f %{buildroot}%{_datadir}/mythweb/data/.htaccess
-    popd
-%endif
-
 # And back to the build/install root
 %endif
 
@@ -1252,6 +1198,7 @@
 ################################################################################
 
 %files
+%doc ChangeLog mythtv/PACKAGE-LICENSING
 
 %files docs
 %doc mythtv/README*
@@ -1263,7 +1210,6 @@
 # Do we really need the API documentation?
 #%doc mythtv/docs/*.html mythtv/docs/*.png
 #%doc mythtv/docs/*.txt
-%doc mythtv/PACKAGE-LICENSING
 %doc mythtv/contrib
 
 %files common
@@ -1302,7 +1248,7 @@
 %{_sysconfdir}/init.d/mythbackend
 %config(noreplace) %{_sysconfdir}/sysconfig/mythbackend
 %endif
-%config(noreplace) %{_sysconfdir}/logrotate.d/mythbackend
+%config(noreplace) %{_sysconfdir}/logrotate.d/mythtv
 %attr(-,mythtv,mythtv) %dir %{_localstatedir}/log/mythtv
 %{_datadir}/mythtv/internetcontent/
 %{_datadir}/mythtv/html/
@@ -1461,15 +1407,6 @@
 %{_datadir}/mythtv/mythweather/*
 %endif
 
-%if %{with_mythweb}
-%files -n mythweb
-%doc ../MythTV-mythweb-%{githash4}/README
-%doc ../MythTV-mythweb-%{githash4}/LICENSE
-%config(noreplace) %{_sysconfdir}/httpd/conf.d/mythweb.conf
-%defattr(-,apache,apache,0775)
-%{_datadir}/mythweb/
-%endif
-
 %if %{with_mythzoneminder}
 %files -n mythzoneminder
 %{_libdir}/mythtv/plugins/libmythzoneminder.so
@@ -1494,15 +1431,15 @@
 
 ################################################################################
 
-%clean
-rm -rf %{buildroot}
-%if %{with_mythweb}
-rm -rf ../MythTV-mythweb-%{githash4}
-%endif
-
-################################################################################
 
 %changelog
+* Tue Jun 05 2012 Richard Shaw <hobbes1069 at gmail.com> - 0.25.1-1
+- Update to latest fixes/0.25.
+- Move mythweb to a stand alone package.
+
+* Fri May 11 2012 Richard Shaw <hobbes1069 at gmail.com> - 0.25-7
+- Update to latest 0.25/fixes.
+
 * Fri May 04 2012 Richard Shaw <hobbes1069 at gmail.com> - 0.25-6
 - Add Bonjour (Airplay) support.
 - Fix user creation for packages that create directories owned by mythtv user.


Index: sources
===================================================================
RCS file: /cvs/free/rpms/mythtv/F-16/sources,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -r1.53 -r1.54
--- sources	13 Apr 2012 21:18:34 -0000	1.53
+++ sources	6 Jul 2012 00:46:08 -0000	1.54
@@ -1,2 +1 @@
-68928bcd22857d4905cc6141e3b7f7dc  MythTV-mythtv-v0.25-0-g1f5962a.tar.gz
-370bf39a67c1d405d455e4ff74180cba  MythTV-mythweb-v0.25-0-g1d056f7.tar.gz
+fb9dd6b59786e579237fa579d49f104c  MythTV-mythtv-v0.25.1-0-gc2c276d.tar.gz


--- mythbackend.logrotate DELETED ---


--- mythtv-0.25-fixes.patch DELETED ---


--- mythtv_0.25_gcc_4.7.patch DELETED ---


--- mythweb.conf DELETED ---


More information about the rpmfusion-commits mailing list