summaryrefslogtreecommitdiff
path: root/v4l/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'v4l/scripts')
-rwxr-xr-xv4l/scripts/gentree.pl2
-rwxr-xr-xv4l/scripts/make_config_compat.pl100
-rwxr-xr-xv4l/scripts/make_makefile.pl4
-rwxr-xr-xv4l/scripts/release.sh2
4 files changed, 105 insertions, 3 deletions
diff --git a/v4l/scripts/gentree.pl b/v4l/scripts/gentree.pl
index fccaedff4..1968bb334 100755
--- a/v4l/scripts/gentree.pl
+++ b/v4l/scripts/gentree.pl
@@ -73,6 +73,8 @@ my %defs = (
'BUZ_USE_HIMEM' => 1,
'NEED_SOUND_DRIVER_H' => 0,
'TTUSB_KERNEL' => 1,
+ 'NO_PCM_LOCK' => 0,
+ 'NEED_ALGO_CONTROL' => 0,
);
#################################################################
diff --git a/v4l/scripts/make_config_compat.pl b/v4l/scripts/make_config_compat.pl
index bd34e7193..3a8bdd81e 100755
--- a/v4l/scripts/make_config_compat.pl
+++ b/v4l/scripts/make_config_compat.pl
@@ -102,6 +102,101 @@ sub check_bool()
close INDEP;
}
+sub check_is_singular()
+{
+ my $file = "$kdir/include/linux/list.h";
+ my $need_compat = 1;
+
+ open INNET, "<$file" or die "File not found: $file";
+ while (<INNET>) {
+ if (m/list_is_singular/) {
+ $need_compat = 0;
+ last;
+ }
+ }
+
+ if ($need_compat) {
+ $out.= "\n#define NEED_IS_SINGULAR 1\n";
+ }
+ close INNET;
+}
+
+sub check_clamp()
+{
+ my $file = "$kdir/include/linux/kernel.h";
+ my $need_compat = 1;
+
+ open INNET, "<$file" or die "File not found: $file";
+ while (<INNET>) {
+ if (m/define\s+clamp/) {
+ $need_compat = 0;
+ last;
+ }
+ }
+
+ if ($need_compat) {
+ $out.= "\n#define NEED_CLAMP 1\n";
+ }
+ close INNET;
+}
+
+sub check_proc_create()
+{
+ my $file = "$kdir/include/linux/proc_fs.h";
+ my $need_compat = 1;
+
+ open INNET, "<$file" or die "File not found: $file";
+ while (<INNET>) {
+ if (m/proc_create/) {
+ $need_compat = 0;
+ last;
+ }
+ }
+
+ if ($need_compat) {
+ $out.= "\n#define NEED_PROC_CREATE 1\n";
+ }
+ close INNET;
+}
+
+sub check_pcm_lock()
+{
+ my $file = "$kdir/include/sound/pcm.h";
+ my $need_compat = 1;
+
+ open INNET, "<$file" or die "File not found: $file";
+ while (<INNET>) {
+ if (m/pcm_stream_lock/) {
+ $need_compat = 0;
+ last;
+ }
+ }
+
+ if ($need_compat) {
+ $out.= "\n#define NO_PCM_LOCK 1\n";
+ }
+ close INNET;
+}
+
+sub check_algo_control()
+{
+ my $file = "$kdir/include/linux/i2c.h";
+ my $need_compat = 0;
+
+ open INNET, "<$file" or die "File not found: $file";
+ while (<INNET>) {
+ if (m/algo_control/) {
+ $need_compat = 1;
+ last;
+ }
+ }
+
+ if ($need_compat) {
+ $out.= "\n#define NEED_ALGO_CONTROL 1\n";
+ }
+ close INNET;
+}
+
sub check_other_dependencies()
{
check_spin_lock();
@@ -109,6 +204,11 @@ sub check_other_dependencies()
check_snd_ctl_boolean_mono_info();
check_snd_pcm_rate_to_rate_bit();
check_bool();
+ check_is_singular();
+ check_clamp();
+ check_proc_create();
+ check_pcm_lock();
+ check_algo_control();
}
# Do the basic rules
diff --git a/v4l/scripts/make_makefile.pl b/v4l/scripts/make_makefile.pl
index ce6f00516..43c563d47 100755
--- a/v4l/scripts/make_makefile.pl
+++ b/v4l/scripts/make_makefile.pl
@@ -166,10 +166,10 @@ sub removeubuntu()
my $filelist;
while ( my ($dir, $files) = each(%instdir) ) {
- $filelist .= join(' ', keys %$files);
+ $filelist .= ' '. join(' ', keys %$files);
}
while ( my ($dir, $files) = each(%obsolete) ) {
- $filelist .= join(' ', keys %$files);
+ $filelist .= ' ' . join(' ', keys %$files);
}
$filelist =~ s/\s+$//;
diff --git a/v4l/scripts/release.sh b/v4l/scripts/release.sh
index 4e9c810bc..5055675d6 100755
--- a/v4l/scripts/release.sh
+++ b/v4l/scripts/release.sh
@@ -16,7 +16,7 @@ files_common="$files_v4l $files_tuner $files_i2c doc"
files_ir="ir-common.[ch]"
files_audio="msp3400.[ch] tvaudio.[ch] tvmixer.[ch]"
-files_bttv="bt848.h btcx*.[ch] bttv*.[ch] bt832.[ch] ir-kbd*.c"
+files_bttv="bt848.h btcx*.[ch] bttv*.[ch] ir-kbd*.c"
files_saa="saa7134*.[ch] saa6752hs.[ch] ir-kbd-i2c.c"
files_cx="btcx*.[ch] cx*.[ch]"