[mythtv-commits] Ticket #11317: change to ./configure to detect libcec >=2

MythTV noreply at mythtv.org
Mon Dec 31 22:15:54 UTC 2012


#11317: change to ./configure to detect libcec >=2
-------------------------------------------------+---------------------
     Reporter:  scox_nz@…                        |      Owner:  stuartm
         Type:  Bug Report - General             |     Status:  new
     Priority:  minor                            |  Milestone:  0.25.4
    Component:  MythTV - User Interface Library  |    Version:  0.25
     Severity:  low                              |   Keywords:  libcec
Ticket locked:  0                                |
-------------------------------------------------+---------------------
 Currently the ./configure script cannot detect a version 2 libcec library

 The code below (when included in the ./configure script) will compile
 against the version 2 library



 #include <libcec/cec.h>
 #include <iostream>
 #include <cstdio>
 using namespace std;
 using namespace CEC;
 #include <libcec/cecloader.h>
 #define CEC_CONFIG_VERSION CEC_CLIENT_VERSION_CURRENT;

 libcec_configuration g_config;
 int main(void) {
     if (CEC_LIB_VERSION_MAJOR < 1 || (CEC_LIB_VERSION_MAJOR == 1 &&
                                       CEC_LIB_VERSION_MINOR < 5))
         return 0;

   g_config.Clear();
   snprintf(g_config.strDeviceName, 13, "CECTester");
   g_config.clientVersion       = CEC_CONFIG_VERSION;
   g_config.bActivateSource     = 0;

   ICECAdapter *parser = LibCecInitialise(&g_config);
 return (long)  parser;
 }

-- 
Ticket URL: <http://code.mythtv.org/trac/ticket/11317>
MythTV <http://code.mythtv.org/trac>
MythTV Media Center


More information about the mythtv-commits mailing list