Other OSs would otherwise lose the explanation (& I'd forget too). This file is: http://www.berklix.com/~jhs/src/bsd/fixes/FreeBSD/ports/gen/multimedia/acidrip/files/patch-ja.REL=7.1-RELEASE by "Julian Stacey" Never delete this file even when no longer needed on newer releases of FreeBSD, because generic port is orphaned, & below contains the only explanation of why my change was needed, & its appropriate to other OS's too. Needed for FreeBSD: ports-cur 7772 Sun Apr 12 15:08:18 CEST 2009 7.1-RELEASE 7.2-RELEASE Not needed for FreeBSD-8.0-RELEASE as it was commited after my http://www.freebsd.org/cgi/query-pr.cgi?pr=129478 to ports/multimedia/acidrip/files/patch-AcidRip__acidrip.pm Summary: This contains a bug fix to Acidrip written in Perl Acidrip is no longer maintained by original generic author. I wrote this patch, but am a C not Perl programmer, & do not want responsibility of forking Acidrip & accepting other Perl patches to generic Acidrip for all OS's. Until/ unless someone does that job, we should commit this fix to FreeBSD ports structure. Email text appended in chronological order at end of file. What it changes in installation: /usr/local/lib/perl5/site_perl/5.8.8/AcidRip/acidrip.pm What it avoids: Error Messages: On bottom line of main box, left of debug button: "Mencoder interrupted by user" In Log file: AcidRip message - Running nice mencoder \.\.\/my_video\.iso \ -info srcform="DVD ripped by acidrip.sf.net" \ -oac copy \ -ovc xvid \ -xvidencopts :bitrate=2117:pass=1 \ -vf pp=de,crop=0:0:0:0,scale=720:-2 \ -o "/dev/null" Error parsing option on the command line: -xvidencopts The fix removes the spurious ':' before 'bitrate' ------------------------------------------------------------------------------- A diff -c (context diff) *** AcidRip/acidrip.pm.orig Sat Dec 6 12:35:37 2008 --- AcidRip/acidrip.pm Sat Dec 6 13:04:18 2008 *************** *** 218,224 **** $menc{'video'} .= ":pass=$::settings->{'video_pass'}" if $::settings->{'video_passes'} > 1; } if ( $::settings->{'video_codec'} eq 'xvid' ) { ! $menc{'video'} = "-ovc xvid -xvidencopts $::settings->{'xvid_options'}:bitrate=$::settings->{'video_bitrate'}"; $menc{'video'} .= ":pass=$::settings->{'video_pass'}" if $::settings->{'video_passes'} > 1; } if ( $::settings->{'video_codec'} eq 'nuv' ) { --- 218,244 ---- $menc{'video'} .= ":pass=$::settings->{'video_pass'}" if $::settings->{'video_passes'} > 1; } if ( $::settings->{'video_codec'} eq 'xvid' ) { ! #---------------- ! #ORIGINAL $menc{'video'} = "-ovc xvid -xvidencopts $::settings->{'xvid_options'}:bitrate=$::settings->{'video_bitrate'}"; ! $menc{'video'} = "-ovc xvid -xvidencopts "; ! if ( $::settings->{'xvid_options'} eq '' ) ! { ! # my $msgaa = "AA You have no xvid_options set."; ! # message($msgaa); ! # print $msgaa . "\n"; ! # my $msgbb = "BB You have no xvid_options set."; ! # message($msgbb); ! # print $msgbb . "\n"; ! } ! else ! { ! # my $msgaa = "AA You do have some xvid_options set."; ! # message($msgaa); ! # print $msgaa . "\n"; ! # my $msgbb = "BB You do have some xvid_options set."; ! # message($msgbb); ! # print $msgbb . "\n"; ! $menc{'video'} .= "$::settings->{'xvid_options'}:" ; ! } ! $menc{'video'} .= "bitrate=$::settings->{'video_bitrate'}"; ! #---------------- $menc{'video'} .= ":pass=$::settings->{'video_pass'}" if $::settings->{'video_passes'} > 1; } if ( $::settings->{'video_codec'} eq 'nuv' ) { ------------------------------------------------------------------------------- A diff -u (context diff) (each line prepended by an added "# " else my automated patch applier would reverse the effect of the diff -c above.) # --- AcidRip/acidrip.pm.orig 2004-07-25 16:03:09.000000000 +0200 # +++ AcidRip/acidrip.pm 2008-12-08 15:22:40.000000000 +0100 # @@ -218,7 +218,29 @@ # $menc{'video'} .= ":pass=$::settings->{'video_pass'}" if $::settings->{'video_passes'} > 1; # } # if ( $::settings->{'video_codec'} eq 'xvid' ) { # - $menc{'video'} = "-ovc xvid -xvidencopts $::settings->{'xvid_options'}:bitrate=$::settings->{'video_bitrate'}"; # +#---------------- # +#ORIGINAL $menc{'video'} = "-ovc xvid -xvidencopts $::settings->{'xvid_options'}:bitrate=$::settings->{'video_bitrate'}"; # + $menc{'video'} = "-ovc xvid -xvidencopts "; # + if ( $::settings->{'xvid_options'} eq '' ) # + { # + # my $msgaa = "AA You have no xvid_options set."; # + # message($msgaa); # + # print $msgaa . "\n"; # + # my $msgbb = "BB You have no xvid_options set."; # + # message($msgbb); # + # print $msgbb . "\n"; # + } # + else # + { # + # my $msgaa = "AA You do have some xvid_options set."; # + # message($msgaa); # + # print $msgaa . "\n"; # + # my $msgbb = "BB You do have some xvid_options set."; # + # message($msgbb); # + # print $msgbb . "\n"; # + $menc{'video'} .= "$::settings->{'xvid_options'}:" ; # + } # + $menc{'video'} .= "bitrate=$::settings->{'video_bitrate'}"; # $menc{'video'} .= ":pass=$::settings->{'video_pass'}" if $::settings->{'video_passes'} > 1; # } # if ( $::settings->{'video_codec'} eq 'nuv' ) { # @@ -896,7 +918,7 @@ # use vars qw($defaults); # # $defaults = { # - 'dvd_device' => '/dev/dvd', # + 'dvd_device' => '/dev/acd0', # 'selected_track' => 0, # 'selected_chapters_start' => 0, # 'selected_chapters_end' => 0, ------------------------------------------------------------------------------- To trigger the fault that needs this fix, appended is a frozen copy of ~jhs/.acidriprc in particular note video_codec = xvid is needed to trigger the fault. dvd_device = film.iso filesize = 1500 filename = %T-%L-%wx%h audio_codec = mp3lame audio_mp3lame_options = abr:br=128 audio_lavc_options = acodec=mp3:abitrate=128 video_codec = xvid scale_enable = 1 autoload = 0 mpegfile = 0 eject = 0 scale_auto = 1 scale_width = 720 crop_enable = 1 language = English mencoder = nice mencoder mplayer = mplayer lsdvd = lsdvd tooltips = 1 video_passes = 3 video_bitrate_lock = 0 lavc_options = vcodec=mpeg4:vhq:v4mv:vqmin=2 total_blocks = 1 overwrite = 0 cache = 0 cache_directory = /dvd-tmp/acidrip-cache vf_pre_enable = 1 vf_post_enable = 0 vf_pre = pp=de del_cache = 1 ppc_bug = 0 compact = 0 flickbook_preview = 0 enforce_space = 1 vobsubout = 0 video_bitrate = 0 ui_language = English ------------------------------------------------------------------------------- Hi acid_kewpie@@@users.sourceforge.net Patch written by jhs@@@berklix.com 2008.12.05 It is a bug fix, not an enhancement. It applies to FreeBSD-7.1-BETA2 /usr/ports/multimedia/acidrip acidrip-0.14.tar.gz /usr/local/bin/perl5.8.8 The exact ~/.acidriprc that I used with it is also appended. The problem was, the log failed at this point: mencoder \.\/\/DVDVOLUME1\-1\.vob -alang English -info \ srcform="DVD ripped by acidrip.sf.net" -oac mp3lame \ -lameopts abr:br=128 -ovc xvid -xvidencopts :bitrate=4878 \ -vf pp=de,crop=0:0:0:0,scale=720:-2 -o "./something-1.avi" Option xvidencopts: Unknown suboption Error parsing option on the command line: -xvidencopts Hand running the line above after removing the ":" before "bitrate" worked ok, so I then fixed the Perl script to not prepend ":" before "bitrate" if xvid_options was null string. I assume if I had had eg: xvid_options = SOMETHING it would have chanced to get past the syntax error but xvid_options was not set by default, & I did not know dummy values I might set there to satisfy the syntax, & anyway its better to fix the Perl than set a dummy value. The still included extra debug is a bit verbose as I am a C programmer, first venturing into Perl. ------------------------------------------------------------------------------- From: "Chris Phillips" Date: Sat, 6 Dec 2008 14:30:26 +0000 To: "Julian Stacey" Thanks, unfortunately I'm no longer developing this. feel free to fork, or just patch within ports. Cheers Chris ------------------------------------------------------------------------------- OK, Thanks Chris, I'll try to feed it to FreeBSD ports/ for now, I don't think I'm up to being a fork leader, 'cos this is Perl, & its the 1st Perl I recall hacking :-) Gary did you retain your ports/ commit bit ? Julian ------------------------------------------------------------------------------- > .acidriprc ... irrelevant Not so. .acidriprc by default omits video_codec = xvid (or uses lavc, whatever). Then acidrip works with lavc, (no syntax error) but produces lavc, not usable on hardware players that need divx. Also I suspect if one were to add to .acidriprc xvid_option=ANYTHING_PLAUSIBLE Then acidrip would again not suffer syntax error, as ":" before "bitrate" would then be appropriate.