Configure options --enable-cdrskin-fifo-odirect, --enable-dvd-obs-64k
This commit is contained in:
parent
25489521bb
commit
b28165f10b
@ -12,6 +12,7 @@ lib_LTLIBRARIES = libburn/libburn.la
|
|||||||
# Build libraries
|
# Build libraries
|
||||||
libburn_libburn_la_LDFLAGS = \
|
libburn_libburn_la_LDFLAGS = \
|
||||||
-version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
|
-version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
|
||||||
|
libburn_libburn_la_CFLAGS = $(LIBBURN_DVD_OBS_64K)
|
||||||
libburn_libburn_la_LIBADD = $(LIBBURN_ARCH_LIBS) $(THREAD_LIBS)
|
libburn_libburn_la_LIBADD = $(LIBBURN_ARCH_LIBS) $(THREAD_LIBS)
|
||||||
libburn_libburn_la_SOURCES = \
|
libburn_libburn_la_SOURCES = \
|
||||||
libburn/async.c \
|
libburn/async.c \
|
||||||
@ -112,7 +113,8 @@ test_structest_SOURCES = test/structest.c
|
|||||||
|
|
||||||
## cdrskin construction site - ts A60816 - A91012
|
## cdrskin construction site - ts A60816 - A91012
|
||||||
cdrskin_cdrskin_CPPFLAGS = -Ilibburn
|
cdrskin_cdrskin_CPPFLAGS = -Ilibburn
|
||||||
cdrskin_cdrskin_CFLAGS = -DCdrskin_libburn_0_7_3
|
cdrskin_cdrskin_CFLAGS = -DCdrskin_libburn_0_7_3 \
|
||||||
|
$(CDRSKIN_O_DIRECT_DEF) $(CDRSKIN_DVD_OBS_64K)
|
||||||
|
|
||||||
# cdrskin_cdrskin_LDADD = $(libburn_libburn_la_OBJECTS) $(LIBBURN_EXTRALIBS)
|
# cdrskin_cdrskin_LDADD = $(libburn_libburn_la_OBJECTS) $(LIBBURN_EXTRALIBS)
|
||||||
# ts A80123, change proposed by Simon Huggins to cause dynamic libburn linking
|
# ts A80123, change proposed by Simon Huggins to cause dynamic libburn linking
|
||||||
|
@ -124,7 +124,7 @@ struct CdrfifO {
|
|||||||
struct burn_source object.
|
struct burn_source object.
|
||||||
@param chunk_size Size of buffer block for a single transaction (0=default)
|
@param chunk_size Size of buffer block for a single transaction (0=default)
|
||||||
@param buffer_size Size of fifo buffer
|
@param buffer_size Size of fifo buffer
|
||||||
@param flag Unused yet
|
@param flag bit0= Debugging verbosity
|
||||||
@return 1 on success, <=0 on failure
|
@return 1 on success, <=0 on failure
|
||||||
*/
|
*/
|
||||||
int Cdrfifo_new(struct CdrfifO **ff, int source_fd, int dest_fd,
|
int Cdrfifo_new(struct CdrfifO **ff, int source_fd, int dest_fd,
|
||||||
@ -180,6 +180,8 @@ int Cdrfifo_new(struct CdrfifO **ff, int source_fd, int dest_fd,
|
|||||||
o->chain_idx= 0;
|
o->chain_idx= 0;
|
||||||
|
|
||||||
#ifdef Cdrskin_read_o_direcT
|
#ifdef Cdrskin_read_o_direcT
|
||||||
|
if(flag & 1)
|
||||||
|
fprintf(stderr,"cdrfifo: DEBUG : allocating fifo buffer via mmap()\n");
|
||||||
o->buffer= mmap(NULL, (size_t) buffer_size, PROT_READ | PROT_WRITE,
|
o->buffer= mmap(NULL, (size_t) buffer_size, PROT_READ | PROT_WRITE,
|
||||||
MAP_SHARED | MAP_ANONYMOUS, -1, (off_t) 0);
|
MAP_SHARED | MAP_ANONYMOUS, -1, (off_t) 0);
|
||||||
if(o->buffer == MAP_FAILED)
|
if(o->buffer == MAP_FAILED)
|
||||||
@ -188,7 +190,7 @@ int Cdrfifo_new(struct CdrfifO **ff, int source_fd, int dest_fd,
|
|||||||
o->buffer= TSOB_FELD(char,buffer_size);
|
o->buffer= TSOB_FELD(char,buffer_size);
|
||||||
if(o->buffer==NULL)
|
if(o->buffer==NULL)
|
||||||
goto failed;
|
goto failed;
|
||||||
#endif /* Cdrskin_read_o_direcT */
|
#endif /* ! Cdrskin_read_o_direcT */
|
||||||
|
|
||||||
return(1);
|
return(1);
|
||||||
failed:;
|
failed:;
|
||||||
|
@ -33,7 +33,7 @@ struct CdrfifO;
|
|||||||
struct burn_source object.
|
struct burn_source object.
|
||||||
@param chunk_size Size of buffer block for a single transaction (0=default)
|
@param chunk_size Size of buffer block for a single transaction (0=default)
|
||||||
@param buffer_size Size of fifo buffer
|
@param buffer_size Size of fifo buffer
|
||||||
@param flag unused yet
|
@param flag bit0= Debugging verbosity
|
||||||
@return 1 on success, <=0 on failure
|
@return 1 on success, <=0 on failure
|
||||||
*/
|
*/
|
||||||
int Cdrfifo_new(struct CdrfifO **ff, int source_fd, int dest_fd,
|
int Cdrfifo_new(struct CdrfifO **ff, int source_fd, int dest_fd,
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
.\" First parameter, NAME, should be all caps
|
.\" First parameter, NAME, should be all caps
|
||||||
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
||||||
.\" other parameters are allowed: see man(7), man(1)
|
.\" other parameters are allowed: see man(7), man(1)
|
||||||
.TH CDRSKIN 1 "Nov 15, 2009"
|
.TH CDRSKIN 1 "Nov 16, 2009"
|
||||||
.\" Please adjust this date whenever revising the manpage.
|
.\" Please adjust this date whenever revising the manpage.
|
||||||
.\"
|
.\"
|
||||||
.\" Some roff macros, for reference:
|
.\" Some roff macros, for reference:
|
||||||
@ -902,9 +902,10 @@ overwriteable DVD-RW it is 32k.
|
|||||||
.BI dvd_obs= default|32k|64k
|
.BI dvd_obs= default|32k|64k
|
||||||
Linux specific:
|
Linux specific:
|
||||||
Set the number of bytes to be transmitted with each write operation to DVD
|
Set the number of bytes to be transmitted with each write operation to DVD
|
||||||
or BD media. A number of 64 KB may improve throughput with bus systems which
|
or BD media. Tracks get padded up to the next multiple of this write
|
||||||
show latency problems. The default depends on media type and option
|
size. A number of 64 KB may improve throughput with bus systems which
|
||||||
stream_recording= .
|
show latency problems. The default depends on media type, option
|
||||||
|
stream_recording=, and on compile time options.
|
||||||
.TP
|
.TP
|
||||||
.BI fallback_program= command
|
.BI fallback_program= command
|
||||||
Set a command name to be executed if cdrskin encounters a known cdrecord
|
Set a command name to be executed if cdrskin encounters a known cdrecord
|
||||||
|
@ -1319,6 +1319,7 @@ int Cdrtrack_seek_isosize(struct CdrtracK *track, int fd, int flag)
|
|||||||
bit0=debugging verbosity
|
bit0=debugging verbosity
|
||||||
bit1=open as source for direct write:
|
bit1=open as source for direct write:
|
||||||
no audio extract, no minimum track size
|
no audio extract, no minimum track size
|
||||||
|
bit2=permission to use O_DIRECT (if enabled at compile time)
|
||||||
@return <=0 error, 1 success
|
@return <=0 error, 1 success
|
||||||
*/
|
*/
|
||||||
int Cdrtrack_open_source_path(struct CdrtracK *track, int *fd, int flag)
|
int Cdrtrack_open_source_path(struct CdrtracK *track, int *fd, int flag)
|
||||||
@ -1408,12 +1409,18 @@ int Cdrtrack_open_source_path(struct CdrtracK *track, int *fd, int flag)
|
|||||||
return(-1);
|
return(-1);
|
||||||
if(is_wav==-3)
|
if(is_wav==-3)
|
||||||
return(0);
|
return(0);
|
||||||
if(is_wav==0)
|
if(is_wav==0) {
|
||||||
#ifdef Cdrskin_read_o_direcT
|
#ifdef Cdrskin_read_o_direcT
|
||||||
*fd= open64(track->source_path, O_RDONLY | O_DIRECT);
|
if(flag & 4) {
|
||||||
#else
|
*fd= open64(track->source_path, O_RDONLY | O_DIRECT);
|
||||||
*fd= open(track->source_path, O_RDONLY);
|
if(flag & 1)
|
||||||
|
fprintf(stderr,"cdrskin: DEBUG : opened track inlet O_DIRECT\n");
|
||||||
|
} else
|
||||||
#endif
|
#endif
|
||||||
|
{
|
||||||
|
*fd= open(track->source_path, O_RDONLY);
|
||||||
|
}
|
||||||
|
}
|
||||||
if(*fd==-1) {
|
if(*fd==-1) {
|
||||||
fprintf(stderr,"cdrskin: failed to open source address '%s'\n",
|
fprintf(stderr,"cdrskin: failed to open source address '%s'\n",
|
||||||
track->source_path);
|
track->source_path);
|
||||||
@ -1499,7 +1506,8 @@ int Cdrtrack_attach_fifo(struct CdrtracK *track, int *outlet_fd,
|
|||||||
*outlet_fd= -1;
|
*outlet_fd= -1;
|
||||||
if(track->fifo_size<=0)
|
if(track->fifo_size<=0)
|
||||||
return(2);
|
return(2);
|
||||||
ret= Cdrtrack_open_source_path(track,&source_fd,flag&1);
|
ret= Cdrtrack_open_source_path(track,&source_fd,
|
||||||
|
(flag&1) | (4 * (track->fifo_size >= 256 * 1024)));
|
||||||
if(ret<=0)
|
if(ret<=0)
|
||||||
return(ret);
|
return(ret);
|
||||||
if(pipe(pipe_fds)==-1)
|
if(pipe(pipe_fds)==-1)
|
||||||
@ -1516,7 +1524,7 @@ int Cdrtrack_attach_fifo(struct CdrtracK *track, int *outlet_fd,
|
|||||||
|
|
||||||
/* >>> ??? obtain track sector size and use instead of 2048 ? */
|
/* >>> ??? obtain track sector size and use instead of 2048 ? */
|
||||||
|
|
||||||
ret= Cdrfifo_new(&ff,source_fd,pipe_fds[1],2048,track->fifo_size,0);
|
ret= Cdrfifo_new(&ff,source_fd,pipe_fds[1],2048,track->fifo_size, flag & 1);
|
||||||
if(ret<=0)
|
if(ret<=0)
|
||||||
return(ret);
|
return(ret);
|
||||||
if(previous_fifo!=NULL)
|
if(previous_fifo!=NULL)
|
||||||
@ -1591,6 +1599,7 @@ int Cdrtrack_add_to_session(struct CdrtracK *track, int trackno,
|
|||||||
/*
|
/*
|
||||||
bit0= debugging verbosity
|
bit0= debugging verbosity
|
||||||
bit1= apply padding hack (<<< should be unused for now)
|
bit1= apply padding hack (<<< should be unused for now)
|
||||||
|
bit2= permission to use O_DIRECT (if enabled at compile time)
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
struct burn_track *tr;
|
struct burn_track *tr;
|
||||||
@ -1606,7 +1615,7 @@ int Cdrtrack_add_to_session(struct CdrtracK *track, int trackno,
|
|||||||
|
|
||||||
/* Note: track->track_type may get set in here */
|
/* Note: track->track_type may get set in here */
|
||||||
if(track->source_fd==-1) {
|
if(track->source_fd==-1) {
|
||||||
ret= Cdrtrack_open_source_path(track,&source_fd,(flag&1));
|
ret= Cdrtrack_open_source_path(track, &source_fd, flag & (4 | 1));
|
||||||
if(ret<=0)
|
if(ret<=0)
|
||||||
goto ex;
|
goto ex;
|
||||||
}
|
}
|
||||||
@ -5995,8 +6004,10 @@ thank_you_for_patience:;
|
|||||||
if(skin->is_writing)
|
if(skin->is_writing)
|
||||||
fprintf(stderr,"\n");
|
fprintf(stderr,"\n");
|
||||||
pending[0]= 0;
|
pending[0]= 0;
|
||||||
|
/*
|
||||||
if(bytes_to_write > 0 && skin->verbosity >= Cdrskin_verbose_debuG)
|
if(bytes_to_write > 0 && skin->verbosity >= Cdrskin_verbose_debuG)
|
||||||
sprintf(pending, " pnd %.f", bytes_to_write - written_total_bytes);
|
sprintf(pending, " pnd %.f", bytes_to_write - written_total_bytes);
|
||||||
|
*/
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
"\rcdrskin: thank you for being patient for %.f seconds%21.21s",
|
"\rcdrskin: thank you for being patient for %.f seconds%21.21s",
|
||||||
elapsed_total_time, pending);
|
elapsed_total_time, pending);
|
||||||
@ -6602,7 +6613,8 @@ int Cdrskin_direct_write(struct CdrskiN *skin, int flag)
|
|||||||
&source_path,&source_fd,&is_from_stdin,0);
|
&source_path,&source_fd,&is_from_stdin,0);
|
||||||
if(source_fd==-1) {
|
if(source_fd==-1) {
|
||||||
ret= Cdrtrack_open_source_path(skin->tracklist[0],&source_fd,
|
ret= Cdrtrack_open_source_path(skin->tracklist[0],&source_fd,
|
||||||
2|(skin->verbosity>=Cdrskin_verbose_debuG));
|
2 | (skin->verbosity >= Cdrskin_verbose_debuG) |
|
||||||
|
(4 * (skin->fifo_size >= 256 * 1024)));
|
||||||
if(ret<=0)
|
if(ret<=0)
|
||||||
goto ex;
|
goto ex;
|
||||||
}
|
}
|
||||||
@ -6836,6 +6848,8 @@ burn_failed:;
|
|||||||
hflag= (skin->verbosity>=Cdrskin_verbose_debuG);
|
hflag= (skin->verbosity>=Cdrskin_verbose_debuG);
|
||||||
if(i==skin->track_counter-1)
|
if(i==skin->track_counter-1)
|
||||||
Cdrtrack_ensure_padding(skin->tracklist[i],hflag&1);
|
Cdrtrack_ensure_padding(skin->tracklist[i],hflag&1);
|
||||||
|
if(skin->fifo_size >= 256 * 1024)
|
||||||
|
hflag|= 4;
|
||||||
ret= Cdrtrack_add_to_session(skin->tracklist[i],i,session,hflag);
|
ret= Cdrtrack_add_to_session(skin->tracklist[i],i,session,hflag);
|
||||||
if(ret<=0) {
|
if(ret<=0) {
|
||||||
fprintf(stderr,"cdrskin: FATAL : Cannot add track %d to session.\n",i+1);
|
fprintf(stderr,"cdrskin: FATAL : Cannot add track %d to session.\n",i+1);
|
||||||
@ -6972,9 +6986,14 @@ burn_failed:;
|
|||||||
burn_write_opts_set_stream_recording(o, skin->stream_recording_is_set);
|
burn_write_opts_set_stream_recording(o, skin->stream_recording_is_set);
|
||||||
#endif
|
#endif
|
||||||
#ifdef Cdrskin_libburn_has_fsync_obS
|
#ifdef Cdrskin_libburn_has_fsync_obS
|
||||||
burn_write_opts_set_dvd_obs(o, skin->dvd_obs);
|
#ifdef Cdrskin_dvd_obs_default_64K
|
||||||
|
if(skin->dvd_obs == 0)
|
||||||
|
burn_write_opts_set_dvd_obs(o, 64 * 1024);
|
||||||
|
else
|
||||||
|
#endif
|
||||||
|
burn_write_opts_set_dvd_obs(o, skin->dvd_obs);
|
||||||
burn_write_opts_set_stdio_fsync(o, skin->stdio_sync);
|
burn_write_opts_set_stdio_fsync(o, skin->stdio_sync);
|
||||||
#endif
|
#endif /* Cdrskin_libburn_has_fsync_obS */
|
||||||
|
|
||||||
if(skin->dummy_mode) {
|
if(skin->dummy_mode) {
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
|
@ -1 +1 @@
|
|||||||
#define Cdrskin_timestamP "2009.11.15.165016"
|
#define Cdrskin_timestamP "2009.11.16.165420"
|
||||||
|
38
configure.ac
38
configure.ac
@ -111,15 +111,15 @@ AC_SUBST(BURN_VERSION)
|
|||||||
dnl Libtool versioning
|
dnl Libtool versioning
|
||||||
LT_RELEASE=$BURN_MAJOR_VERSION.$BURN_MINOR_VERSION.$BURN_MICRO_VERSION
|
LT_RELEASE=$BURN_MAJOR_VERSION.$BURN_MINOR_VERSION.$BURN_MICRO_VERSION
|
||||||
dnl
|
dnl
|
||||||
dnl ts A91012
|
dnl ts A91116
|
||||||
dnl ### This is the release version libburn-0.7.2 = libburn.so.4.37.0
|
dnl ### This is the release version libburn-0.7.2 = libburn.so.4.37.0
|
||||||
dnl This is the development version after above release version
|
dnl This is the development version after above release version
|
||||||
dnl LT_CURRENT++, LT_AGE++ has not yet happened.
|
dnl ### LT_CURRENT++, LT_AGE++ has not yet happened.
|
||||||
dnl ### LT_CURRENT++, LT_AGE++ has happened meanwhile.
|
dnl LT_CURRENT++, LT_AGE++ has happened meanwhile.
|
||||||
dnl
|
dnl
|
||||||
dnl SONAME = 41 - 37 = 4 . Linux library name = libburn.so.4.37.0
|
dnl SONAME = 42 - 38 = 4 . Linux library name = libburn.so.4.38.0
|
||||||
LT_CURRENT=41
|
LT_CURRENT=42
|
||||||
LT_AGE=37
|
LT_AGE=38
|
||||||
LT_REVISION=0
|
LT_REVISION=0
|
||||||
LT_CURRENT_MINUS_AGE=`expr $LT_CURRENT - $LT_AGE`
|
LT_CURRENT_MINUS_AGE=`expr $LT_CURRENT - $LT_AGE`
|
||||||
|
|
||||||
@ -198,6 +198,32 @@ else
|
|||||||
CFLAGS="$CFLAGS -DDEBUG"
|
CFLAGS="$CFLAGS -DDEBUG"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# ts A91116
|
||||||
|
AC_ARG_ENABLE(cdrskin-fifo-odirect,
|
||||||
|
[ --enable-cdrskin-fifo-odirect Enable use of O_DIRECT with cdrskin fifo inlet, default=no],
|
||||||
|
, enable_cdrskin_fifo_odirect=no)
|
||||||
|
if test x$enable_cdrskin_fifo_odirect = xyes; then
|
||||||
|
CDRSKIN_O_DIRECT_DEF="-DCdrskin_read_o_direcT"
|
||||||
|
echo "enabled use of O_DIRECT with cdrskin fifo inlet"
|
||||||
|
else
|
||||||
|
CDRSKIN_O_DIRECT_DEF=
|
||||||
|
echo "disabled use of O_DIRECT with cdrskin fifo inlet"
|
||||||
|
fi
|
||||||
|
AC_SUBST(CDRSKIN_O_DIRECT_DEF)
|
||||||
|
|
||||||
|
# ts A91116
|
||||||
|
AC_ARG_ENABLE(dvd-obs-64k,
|
||||||
|
[ --enable-dvd-obs-64k 64 KB default size for DVD/BD writing, default=no],
|
||||||
|
, enable_fifo_odirect=no)
|
||||||
|
if test x$enable_dvd_obs_64k = xyes; then
|
||||||
|
LIBBURN_DVD_OBS_64K="-DLibburn_dvd_obs_default_64K"
|
||||||
|
echo "enabled write size default 64 KB on DVD and BD"
|
||||||
|
else
|
||||||
|
LIBBURN_DVD_OBS_64K=
|
||||||
|
echo "disabled write size default 64 KB on DVD and BD"
|
||||||
|
fi
|
||||||
|
AC_SUBST(LIBBURN_DVD_OBS_64K)
|
||||||
|
|
||||||
|
|
||||||
dnl Determine target directory for libburn-*.pc
|
dnl Determine target directory for libburn-*.pc
|
||||||
dnl Important: Must be performed _after_ TARGET_SHIZZLE
|
dnl Important: Must be performed _after_ TARGET_SHIZZLE
|
||||||
|
@ -1914,6 +1914,9 @@ int burn_dvd_write_sync(struct burn_write_opts *o,
|
|||||||
o->obs_pad = 1; /* fill-up track's last 32k buffer */
|
o->obs_pad = 1; /* fill-up track's last 32k buffer */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef Libburn_dvd_obs_default_64K
|
||||||
|
o->obs = 64 * 1024;
|
||||||
|
#endif
|
||||||
|
|
||||||
/* <<< test only : Does this increase effective speed with USB ?
|
/* <<< test only : Does this increase effective speed with USB ?
|
||||||
ts A90801 : 64kB: speed with 16x DVD-R is 12 rather than 8
|
ts A90801 : 64kB: speed with 16x DVD-R is 12 rather than 8
|
||||||
@ -1932,7 +1935,7 @@ int burn_dvd_write_sync(struct burn_write_opts *o,
|
|||||||
libdax_msgs_submit(libdax_messenger, d->global_index,
|
libdax_msgs_submit(libdax_messenger, d->global_index,
|
||||||
0x00000002, LIBDAX_MSGS_SEV_DEBUG,
|
0x00000002, LIBDAX_MSGS_SEV_DEBUG,
|
||||||
LIBDAX_MSGS_PRIO_ZERO, msg, 0, 0);
|
LIBDAX_MSGS_PRIO_ZERO, msg, 0, 0);
|
||||||
o->obs = BUFFER_SIZE;
|
o->obs = 32 * 1024; /* This size is required to work */
|
||||||
}
|
}
|
||||||
|
|
||||||
sprintf(msg, "dvd/bd Profile= %2.2Xh , obs= %d , obs_pad= %d",
|
sprintf(msg, "dvd/bd Profile= %2.2Xh , obs= %d , obs_pad= %d",
|
||||||
|
Loading…
Reference in New Issue
Block a user