Skip to content

Commit

Permalink
use configure option --enable-aitscan, disabled by default
Browse files Browse the repository at this point in the history
  • Loading branch information
TangoCash committed Sep 29, 2021
1 parent b855a12 commit 6942755
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 1 deletion.
5 changes: 5 additions & 0 deletions configure.ac
Expand Up @@ -174,6 +174,11 @@ if test "$enable_lcd4linux" = "yes"; then
AC_DEFINE(ENABLE_LCD4LINUX, 1, [include Lcd4Linux support])
fi

AC_ARG_ENABLE(aitscan,
AS_HELP_STRING([--enable-aitscan], [enable Application Information Table support @<:@default=no@:>@]),
AC_DEFINE(ENABLE_AIT, 1, [enable Application Information Table support]))
AM_CONDITIONAL(ENABLE_AIT, test "$enable_aitscan" = "yes")

AC_ARG_ENABLE(keyboard-no-rc,
AS_HELP_STRING([--enable-keyboard-no-rc], [enable keyboard control, disable rc control @<:@default=no@:>@]),
AC_DEFINE(KEYBOARD_INSTEAD_OF_REMOTE_CONTROL, 1, [enable keyboard control, disable rc control]))
Expand Down
4 changes: 4 additions & 0 deletions src/zapit/include/zapit/zapit.h
Expand Up @@ -19,7 +19,9 @@
#include <zapit/bouquets.h>
#include <zapit/femanager.h>
#include <zapit/fastscan.h>
#ifdef ENABLE_AIT
#include <zapit/scanait.h>
#endif

#define PAL 0
#define NTSC 1
Expand Down Expand Up @@ -168,7 +170,9 @@ class CZapit : public OpenThreads::Thread
t_channel_id lastChannelTV;
int abort_zapit;
int pmt_update_fd;
#ifdef ENABLE_AIT
CAit *ait;
#endif
//void LoadAudioMap();
void SaveAudioMap();
void SaveVolumeMap();
Expand Down
6 changes: 5 additions & 1 deletion src/zapit/src/Makefile.am
Expand Up @@ -25,7 +25,6 @@ libzapit_a_SOURCES = \
frontend.cpp \
getservices.cpp \
pat.cpp \
scanait.cpp \
scanbat.cpp \
scan.cpp \
scannit.cpp \
Expand All @@ -34,6 +33,11 @@ libzapit_a_SOURCES = \
transponder.cpp \
zapit.cpp

if ENABLE_AIT
libzapit_a_SOURCES += \
scanait.cpp
endif

if ENABLE_FASTSCAN
libzapit_a_SOURCES += \
fastscan.cpp
Expand Down
4 changes: 4 additions & 0 deletions src/zapit/src/zapit.cpp
Expand Up @@ -144,7 +144,9 @@ CZapit::CZapit()
pip_channel_id = 0;
lock_channel_id = 0;
pip_fe = NULL;
#ifdef ENABLE_AIT
ait = new CAit();
#endif
}

CZapit::~CZapit()
Expand Down Expand Up @@ -667,8 +669,10 @@ bool CZapit::ZapIt(const t_channel_id channel_id, bool forupdate, bool startplay
if (update_pmt)
pmt_set_update_filter(current_channel, &pmt_update_fd);

#ifdef ENABLE_AIT
ait->setDemux(current_channel->getRecordDemux());
ait->Parse(current_channel);
#endif

return true;
}
Expand Down

0 comments on commit 6942755

Please sign in to comment.