AC_SUBST(REQUIRES)
AC_CONFIG_FILES([src/lib/libcec.pc])
-AC_OUTPUT([Makefile src/lib/Makefile src/testclient/Makefile])
+AC_OUTPUT([Makefile src/lib/Makefile src/testclient/Makefile src/cec-config/Makefile])
/*!
* @brief Create a new libCEC instance.
* @param configuration The configuration to pass to libCEC
+ * @param strLib The name of and/or path to libCEC
* @return An instance of ICECAdapter or NULL on error.
*/
-CEC::ICECAdapter *LibCecInitialise(const CEC::CecAdapterConfiguration &configuration)
+CEC::ICECAdapter *LibCecInitialise(const CEC::libcec_configuration *configuration, const char *strLib = NULL)
{
if (!g_libCEC)
{
}
}
- typedef void* _LibCecInitialise(const CEC::CecAdapterConfiguration &);
+ typedef void* _LibCecInitialise(const CEC::libcec_configuration *);
_LibCecInitialise* LibCecInitialise = (_LibCecInitialise*) dlsym(g_libCEC, "CECInitialise");
if (!LibCecInitialise)
{
bin_PROGRAMS = cec-config
-cec_client_SOURCES = cec-config.cpp
+cec_config_SOURCES = cec-config.cpp
-cec_client_CPPFLAGS = -I@abs_top_srcdir@/include
-cec_client_LDFLAGS = @LIBS_DL@
\ No newline at end of file
+cec_config_CPPFLAGS = -I@abs_top_srcdir@/include
+cec_config_LDFLAGS = @LIBS_DL@
\ No newline at end of file
return currentTvPower == CEC_POWER_STATUS_ON;
}
-int main (int argc, char *argv[])
+int main (int UNUSED(argc), char *UNUSED(argv[]))
{
PrintToStdOut("=== USB-CEC Adapter Configuration ===\n");
if (!OpenConnection())
configuration->iPhysicalAddress = m_iPhysicalAddress;
configuration->iHDMIPort = m_iHDMIPort;
configuration->baseDevice = m_iBaseDevice;
- snprintf(configuration->strDeviceName, 13, m_strDeviceName.c_str());
+ snprintf(configuration->strDeviceName, 13, "%s", m_strDeviceName.c_str());
configuration->deviceTypes = m_types;
return true;
}