Hi Simeon
How do I apply these patches, I'm doing something wrong. Here's my original
build error and the output of my patch attempt. I'm on Gentoo (Sabayon 3.5)
AMD 64 quad core. I installed mpeg4ip  via emerge.
Thanks in advance
Daniel

++++++++++++++ORIGINAL BUILD OUTPUT+++++++++++++++++++++++++++

make[6]: *** [faad2.lo] Error 1
make[6]: Leaving directory
`/home/daniel/src/cinelerra-4/quicktime/thirdparty/fa
ad2-2.0/plugins/mpeg4ip'
make[5]: *** [all-recursive] Error 1
make[5]: Leaving directory
`/home/daniel/src/cinelerra-4/quicktime/thirdparty/fa
ad2-2.0/plugins'
make[4]: *** [all-recursive] Error 1
make[4]: Leaving directory
`/home/daniel/src/cinelerra-4/quicktime/thirdparty/fa
ad2-2.0'
make[3]: *** [all] Error 2
make[3]: Leaving directory
`/home/daniel/src/cinelerra-4/quicktime/thirdparty/fa
ad2-2.0'
make[2]: *** [x86_64/faad] Error 2
make[2]: Leaving directory `/home/daniel/src/cinelerra-4/quicktime'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/daniel/src/cinelerra-4'
make: *** [all] Error 2


++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++PATCH OUTPUT+++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
[EMAIL PROTECTED] ~/src/cinelerra-4 $ ls
aa_file.cpp.patch  builerr1.txt~
COPYING            global_config      Makefile       plugins    soundtest.c
bin                cincvcinelerra4firsthintsandpatchesforcompiling.zip
doc                guicast            mpeg2enc       po         thirdparty
build              cinelerra
faad2.cpp.1.patch  hvirtual_config.h  mplexlo        quicktime
builerr1.txt       configure
faad2.cpp.2.patch  libmpeg3           plugin_config  README
[EMAIL PROTECTED] ~/src/cinelerra-4 $ rm
cincvcinelerra4firsthintsandpatchesforcompiling.zip
[EMAIL PROTECTED] ~/src/cinelerra-4 $ patch -i faad2.cpp.2.patch
can't find file to patch at input line 3
Perhaps you should have used the -p or --strip option?
The text leading up to this was:
--------------------------
|--- faad2.cpp   2008-05-31 11:25:31.000000000 +0200
|+++
/static/cinelerra/cin4/quicktime/thirdparty/faad2-2.0/plugins/mpeg4ip/faad2.cpp
2008-08-12 16:59:50.000000000 +0200
--------------------------
File to patch:
Skip this patch? [y] y
Skipping patch.
patch: **** malformed patch at line 95:

[EMAIL PROTECTED] ~/src/cinelerra-4 $ patch -i faad2.cpp.1.patch
can't find file to patch at input line 3
Perhaps you should have used the -p or --strip option?
The text leading up to this was:
--------------------------
|--- faad2.cpp   2008-05-31 11:25:31.000000000 +0200
|+++
/static/cinelerra/cin4/quicktime/thirdparty/faad2-2.0/plugins/mpeg4ip/faad2.cpp
2008-08-12 16:59:50.000000000 +0200
--------------------------
File to patch:
Skip this patch? [y] y
Skipping patch.
5 out of 5 hunks ignored
[EMAIL PROTECTED] ~/src/cinelerra-4 $ patch -p faad2.cpp.1.patch
patch: **** strip count faad2.cpp.1.patch is not a number
[EMAIL PROTECTED] ~/src/cinelerra-4 $ patch -i aa_file.cpp.patch
can't find file to patch at input line 3
Perhaps you should have used the -p or --strip option?
The text leading up to this was:
--------------------------
|--- aa_file.cpp 2008-05-31 11:25:31.000000000 +0200
|+++
/static/cinelerra/cin4/quicktime/thirdparty/faad2-2.0/plugins/mpeg4ip/aa_file.cpp
2008-08-12 15:33:10.000000000 +0200
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
1 out of 1 hunk ignored
[EMAIL PROTECTED] ~/src/cinelerra-4 $ patch -i -p aa_file.cpp.patch
patch: **** Can't open patch file -p : No such file or directory
[EMAIL PROTECTED] ~/src/cinelerra-4 $ patch -p aa_file.cpp.patch
patch: **** strip count aa_file.cpp.patch is not a number
[EMAIL PROTECTED] ~/src/cinelerra-4 $
.

On Tue, Aug 12, 2008 at 5:01 PM, Simeon Völkel <
[EMAIL PROTECTED]> wrote:

> Hello,
>
> I've just compiled Cinelerra Version 4 on my Gentoo Linux.
>
> I'd like to share my changes I had to make to make cin4
> compile for me in the hope someone else finds the following
> information useful.
>
>
> I didn't succeed in compiling cin4 without corrupting
>
> quicktime/thirdparty/faad2-2.0/plugins/mpeg4ip/faad2.cpp
>
> That's why I split up the second diff: The first version
> seems to be crucial to compile cin4 on a 32bit (Gentoo?)
> Linux, the second file contains the first one plus a work-
> around to make cin4 actually compile for me.
>
> Both files are outputs of diff -u.
>
>
> === Annotations for compiling ===
>
> Obviously, with version 4, a new dependency was introduced:
> mpeg4ip. Without having the (devel-!) package installed,
> you are likely to run into errors like
>
> faad2.h:28:26: error: codec_plugin.h: No such file or directory
>
> On Gentoo you'll just have to emerge mpeg4ip of course.
>
>
> Secondly: Errors like
>
> faad2.cpp:86: error: invalid conversion from 'long unsigned int*' to
> 'uint32_t*'
>
> should be solved by applying my patches. Just as e.g.
>
> faad2.cpp:242: error: too few arguments to function
>
> and others.
>
> Unfortunately I wasn't able to fix the errors in line 370 of faad2.cpp
> Example:
>
> faad2.cpp:370: error: cannot convert 'codec_data_t* (*)(const char*, int,
> int, format_list_t*, audio_info_t*, const uint8_t*, uint32_t, audio_vft_t*,
> void*)' to 'const char*' in initialization
>
> Maybe Someone(TM) can solve that. I worked around by commenting
> the call to makro out. (see faad2.cpp.2.patch)
>
>
> === Annotations for running cinelerra-4 ===
>
> Paradoxically sudo make install didn't install (here) cinelerra in
> /usr/local/bin but inside the local directory. Start cin4 by typing
> ./bin/cinelerra in cinelerra-4 (where you just typed make).
>
> Monitoring audio when playing video in the record-dialog and Video-in
> does not work for me 'out of the box', even if the checkbox is marked.
> The audio-settings work for normal playback. If I find out how to get
> this working here, I'll tell you. ;-)
>
> Finally I'd like to say "Thank you for Cinelerra-4" to Adam Williams.
>
> SimAV
>
> --- aa_file.cpp 2008-05-31 11:25:31.000000000 +0200
> +++
> /static/cinelerra/cin4/quicktime/thirdparty/faad2-2.0/plugins/mpeg4ip/aa_file.cpp
>   2008-08-12 15:33:10.000000000 +0200
> @@ -56,7 +56,7 @@
>                  aac->m_buffer_size_max,
>                  aac->m_ifile);
>
> -  unsigned long freq;
> +  uint32_t freq;
>   unsigned char chans;
>
>   faacDecInit(aac->m_info, (unsigned char *)aac->m_buffer,
>
> --- faad2.cpp   2008-05-31 11:25:31.000000000 +0200
> +++
> /static/cinelerra/cin4/quicktime/thirdparty/faad2-2.0/plugins/mpeg4ip/faad2.cpp
>     2008-08-12 16:59:50.000000000 +0200
> @@ -76,7 +76,7 @@
>   }
>
>   aac->m_info = faacDecOpen();
> -  unsigned long srate;
> +  uint32_t srate;
>   unsigned char chan;
>   if ((userdata == NULL && fmtp == NULL) ||
>       (faacDecInit2(aac->m_info,
> @@ -97,7 +97,7 @@
>       aac->m_output_frame_size = 960;
>     }
>   }
> -  aac->m_freq = srate;
> +  aac->m_freq =  srate;
>   aac->m_chans = chan;
>   aac->m_faad_inited = 1;
>   aac->m_msec_per_frame = aac->m_output_frame_size;
> @@ -188,7 +188,7 @@
>      * If not initialized, do so.
>      */
>     abort();
> -    unsigned long freq;
> +    uint32_t freq;
>     unsigned char chans;
>
>     faacDecInit(aac->m_info,
> @@ -237,9 +237,9 @@
>       aac->m_vft->audio_configure(aac->m_ifptr,
>                   aac->m_freq,
>                   aac->m_chans,
> -                  AUDIO_S16SYS,
> +                  (audio_format_t) AUDIO_S16SYS,
>                   aac->m_output_frame_size);
> -      uint8_t *now = aac->m_vft->audio_get_buffer(aac->m_ifptr);
> +      uint8_t *now = aac->m_vft->audio_get_buffer(aac->m_ifptr,
> aac->m_freq, aac->m_current_time);
>       aac->m_audio_inited = 1;
>     }
>     /*
> @@ -322,7 +322,7 @@
>   }
>   if (userdata != NULL) {
>     mpeg4_audio_config_t audio_config;
> -    decode_mpeg4_audio_config(userdata, userdata_size, &audio_config);
> +    decode_mpeg4_audio_config(userdata, userdata_size, &audio_config,
> false);
>     message(LOG_DEBUG, "aac", "audio type is %d",
> audio_config.audio_object_type);
>     if (fmtp != NULL) free_fmtp_parse(fmtp);
>
>
>
> --- faad2.cpp   2008-05-31 11:25:31.000000000 +0200
> +++
> /static/cinelerra/cin4/quicktime/thirdparty/faad2-2.0/plugins/mpeg4ip/faad2.cpp
>     2008-08-12 16:59:50.000000000 +0200
> @@ -76,7 +76,7 @@
>   }
>
>   aac->m_info = faacDecOpen();
> -  unsigned long srate;
> +  uint32_t srate;
>   unsigned char chan;
>   if ((userdata == NULL && fmtp == NULL) ||
>       (faacDecInit2(aac->m_info,
> @@ -97,7 +97,7 @@
>       aac->m_output_frame_size = 960;
>     }
>   }
> -  aac->m_freq = srate;
> +  aac->m_freq =  srate;
>   aac->m_chans = chan;
>   aac->m_faad_inited = 1;
>   aac->m_msec_per_frame = aac->m_output_frame_size;
> @@ -188,7 +188,7 @@
>      * If not initialized, do so.
>      */
>     abort();
> -    unsigned long freq;
> +    uint32_t freq;
>     unsigned char chans;
>
>     faacDecInit(aac->m_info,
> @@ -237,9 +237,9 @@
>       aac->m_vft->audio_configure(aac->m_ifptr,
>                   aac->m_freq,
>                   aac->m_chans,
> -                  AUDIO_S16SYS,
> +                  (audio_format_t) AUDIO_S16SYS,
>                   aac->m_output_frame_size);
> -      uint8_t *now = aac->m_vft->audio_get_buffer(aac->m_ifptr);
> +      uint8_t *now = aac->m_vft->audio_get_buffer(aac->m_ifptr,
> aac->m_freq, aac->m_current_time);
>       aac->m_audio_inited = 1;
>     }
>     /*
> @@ -322,7 +322,7 @@
>   }
>   if (userdata != NULL) {
>     mpeg4_audio_config_t audio_config;
> -    decode_mpeg4_audio_config(userdata, userdata_size, &audio_config);
> +    decode_mpeg4_audio_config(userdata, userdata_size, &audio_config,
> false);
>     message(LOG_DEBUG, "aac", "audio type is %d",
> audio_config.audio_object_type);
>     if (fmtp != NULL) free_fmtp_parse(fmtp);
>
> @@ -367,6 +367,8 @@
>                aac_file_eof
>                );
>  #else
> +//commented this Makro out in order to make cinelerra4 compileable
> +/*
>  AUDIO_CODEC_WITH_RAW_FILE_PLUGIN("faad2",
>                aac_codec_create,
>                aac_do_pause,
> @@ -382,7 +384,34 @@
>                NULL,
>                0
>                );
> +*/
> +//expanded the makro for error-hunting :)
> +//this causes gcc to print out a different error.....
> +/*extern "C" {
> +codec_plugin_t mpeg4ip_codec_plugin
> +=
> +{ "faad2",
> +"audio",
> +"1.0",
> +aac_codec_create,
> +__null,
> +aac_do_pause,
> +aac_decode,
> +aac_close,
> +aac_codec_check,
> +aac_file_check,
> +aac_file_next_frame,
> +aac_file_used_for_frame,
> +aac_raw_file_seek_to,
> +__null,
> +aac_file_eof,
> +__null,
> +__null,
> +__null,
> +0,
> +__null,
> +};
> +};
> +*/
>  #endif
>  /* end file aa.cpp */
>
>
>

Reply via email to