Compare commits

..

4 Commits
1.3.2 ... 1.3.0

Author SHA1 Message Date
311d5347e1 Updated change log 2013-05-17 09:42:50 +00:00
da046bc232 Updated cdrskin tarball generator 2013-05-17 09:36:27 +00:00
5c1ef0d55a Made number transition to 1.3.0 2013-05-17 09:35:09 +00:00
5c2c4e3b40 Branching for libburn release 1.3.0 2013-05-17 08:12:20 +00:00
40 changed files with 949 additions and 3420 deletions

View File

@ -1,27 +1,3 @@
SVN trunk (to become libburn-1.3.2 or higher)
===============================================================================
* Bug fix: cdrskin -msinfo on DVD and BD reported
old session start = next writable address.
Regression introduced by version 1.2.8 (rev 4956).
* Bug fix: The signal handler aborted on SIGCONT, SIGTSTP, SIGTTIN, SIGTTOU
* New API call burn_make_input_sheet_v07t()
* API call burn_session_input_sheet_v07t(): read multiple blocks from same file
* New API calls burn_drive_extract_audio(), burn_drive_extract_audio_track()
* New cdrskin option textfile_to_v07t=
* New cdrskin options cdtext_to_textfile= and cdtext_to_v07t=
* New cdrskin options extract_audio_to= , extract_tracks= , extract_basename= ,
--extract_dap
* New cdrskin option --pacifier_with_newline
* Improved granularity of SCSI log time measurement, now with timestamp
* Optional "make doc" now demands doxygen 1.8.4
libburn-1.3.0.pl01.tar.gz Fri May 31 2013
===============================================================================
* Bug fix: cdrskin -msinfo on DVD and BD reported
old session start = next writable address.
Regression introduced by version 1.2.8.
libburn-1.3.0.tar.gz Fri May 17 2013
===============================================================================
* Bug fix: Full formatting of BD-RE used certification regardless of drive

View File

@ -118,9 +118,9 @@ test_structest_CPPFLAGS = -Ilibburn
test_structest_LDADD = $(libburn_libburn_la_OBJECTS) $(LIBBURN_EXTRALIBS)
test_structest_SOURCES = test/structest.c
## cdrskin construction site - ts A60816 - B30807
## cdrskin construction site - ts A60816 - B30517
cdrskin_cdrskin_CPPFLAGS = -Ilibburn
cdrskin_cdrskin_CFLAGS = -DCdrskin_libburn_1_3_2
cdrskin_cdrskin_CFLAGS = -DCdrskin_libburn_1_3_0
# cdrskin_cdrskin_LDADD = $(libburn_libburn_la_OBJECTS) $(LIBBURN_EXTRALIBS)
# ts A80123, change proposed by Simon Huggins to cause dynamic libburn linking

18
README
View File

@ -11,7 +11,7 @@ Still containing parts of Libburn. By Derek Foreman <derek@signalmarketing.com>
and Ben Jansens <xor@orodu.net>
Copyright (C) 2002-2006 Derek Foreman and Ben Jansens
http://files.libburnia-project.org/releases/libburn-1.3.2.tar.gz
http://files.libburnia-project.org/releases/libburn-1.3.0.tar.gz
------------------------------------------------------------------------------
@ -19,10 +19,10 @@ Copyright (C) 2002-2006 Derek Foreman and Ben Jansens
From tarball
Obtain libburn-1.3.2.tar.gz, take it to a directory of your choice and do:
Obtain libburn-1.3.0.tar.gz, take it to a directory of your choice and do:
tar xzf libburn-1.3.2.tar.gz
cd libburn-1.3.2
tar xzf libburn-1.3.0.tar.gz
cd libburn-1.3.0
./configure --prefix=/usr
make
@ -702,16 +702,6 @@ Project history as far as known to me:
introduced new boot preparation capabilities have been tested. New
boot preparation options for GRUB2 were added.
- Fri May 31 2013 patch release libburn-1.3.0.pl01:
cdrskin -msinfo on DVD and BD reported as old session start the same
number as the next writable address.
Regression introduced by version 1.2.8.
- Fri Aug 07 2013 release 1.3.2:
cdrskin has aquired the capability to copy audio tracks to .wav files.
It can extract CD-TEXT in a form that is readable for humans and for
cdrskin itself. Several small bugs were fixed in xorriso. Its capabilities
to serve frontend programs in dialog mode have been improved.
------------------------------------------------------------------------------

View File

@ -4,7 +4,7 @@
cdrskin. By Thomas Schmitt <scdbackup@gmx.net>
Integrated sub project of libburnia-project.org but also published via:
http://scdbackup.sourceforge.net/cdrskin_eng.html
http://scdbackup.sourceforge.net/cdrskin-1.3.2.tar.gz
http://scdbackup.sourceforge.net/cdrskin-1.3.0.tar.gz
Copyright (C) 2006-2013 Thomas Schmitt, provided under GPL version 2 or later.
------------------------------------------------------------------------------
@ -26,10 +26,10 @@ By using this software you agree to the disclaimer at the end of this text
Compilation, First Glimpse, Installation
Obtain cdrskin-1.3.2.tar.gz, take it to a directory of your choice and do:
Obtain cdrskin-1.3.0.tar.gz, take it to a directory of your choice and do:
tar xzf cdrskin-1.3.2.tar.gz
cd cdrskin-1.3.2
tar xzf cdrskin-1.3.0.tar.gz
cd cdrskin-1.3.0
Within that directory execute:
@ -191,11 +191,6 @@ See below "Audio CD" for specifications.
cdrskin -v dev=0,1,0 blank=fast -eject speed=48 -sao \
-audio -swab track0[1-5].cd /path/to/track6.wav
Extract audio tracks and CD-TEXT from CD into directory /home/me/my_cd:
mkdir /home/me/my_cd
cdrskin -v dev=/dev/sr0 extract_audio_to=/home/me/my_cd \
cdtext_to_v07t=/home/me/my_cd/cdtext.v07t
Restrictions

View File

@ -38,7 +38,7 @@ original="./libburn_svn_release.tgz"
# My changes are in $changes , mainly in $changes/cdrskin
changes="./libburn-release"
skin_release="1.3.2"
skin_release="1.3.0"
patch_level=""
# patch_level=".pl00"
skin_rev="$skin_release""$patch_level"

View File

@ -38,7 +38,7 @@ original="./libburn_svn.tgz"
# My changes are in $changes , mainly in $changes/cdrskin
changes="./libburn-develop"
skin_release="1.3.3"
skin_release="1.3.1"
patch_level=""
skin_rev="$skin_release""$patch_level"

View File

@ -2,7 +2,7 @@
.\" First parameter, NAME, should be all caps
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
.\" other parameters are allowed: see man(7), man(1)
.TH CDRSKIN 1 "Version 1.3.2, Aug 07, 2013"
.TH CDRSKIN 1 "Version 1.3.0, May 17, 2013"
.\" Please adjust this date whenever revising the manpage.
.\"
.\" Some roff macros, for reference:
@ -37,7 +37,7 @@ Blanking of CD-RW and DVD-RW.
.br
Formatting of DVD-RW, DVD+RW, DVD-RAM, BD.
.br
Burning of data tracks or audio tracks with CD-TEXT to CD,
Burning of data or audio tracks to CD,
.br
either in versatile Track at Once mode (TAO)
.br
@ -55,8 +55,6 @@ on overwriteable DVD+RW, DVD-RW, DVD-RAM, BD-RE
.br
or on data file or block device.
.br
Extraction of audio tracks and CD-TEXT to hard disk files.
.br
Bus scan, burnfree, speed options, retrieving media info, padding, fifo.
.br
See section EXAMPLES at the end of this text.
@ -996,25 +994,6 @@ the default.
This setting applies only to CD SAO writing. It overrides the track number
settings caused by options cuefile= or input_sheet_v07t=.
.TP
.BI cdtext_to_textfile= path
Extract the CD-TEXT packs from the lead-in of an audio CD and write them to
the file with the given path. If CD-TEXT can be retrieved, then this file
will be suitable for option textfile=.
.br
Not all drives can read CD-TEXT and not all audio CDs bear CD-TEXT.
It is not considered an error if no CD-TEXT is available.
.TP
.BI cdtext_to_v07t= path
Extract the CD-TEXT packs from the lead-in of an audio CD and write them
as human readable Sony Input Sheet Version 0.7T to the file with the
given path. If CD-TEXT can be retrieved, then this file
will be suitable for option input_sheet_v07t=.
.br
If the given path is "-", then the result is printed to standard output.
.br
Not all drives can read CD-TEXT and not all audio CDs bear CD-TEXT.
It is not considered an error if no CD-TEXT is available.
.TP
.BI \--demand_a_drive
Exit with a nonzero value if no drive can be found during a bus scan.
.TP
@ -1070,6 +1049,7 @@ media dependend transaction size. With DVD-RAM, BD-RE, DVD+RW this is 2k, with
overwriteable DVD-RW it is 32k.
.TP
.BI dvd_obs= default|32k|64k
Linux specific:
Set the number of bytes to be transmitted with each write operation to DVD
or BD media. With most write types, tracks get padded up to the next multiple
of this write size (see option --obs_pad).
@ -1077,32 +1057,6 @@ A number of 64 KB may improve throughput with systems
which show latency problems. The default depends on media type, option
stream_recording=, and on compile time options.
.TP
.BI extract_audio_to= directory_path
Extract tracks from an audio CD as separate WAVE audio files into the
given directory.
This directory has to already exist, but none of the track files may exist.
This option will rather fail than overwrite an existing file.
.br
By default all tracks of the CD are extracted to files with names
trackNN.wav, where NN is the track number from 01 to at most 99.
.TP
.BI extract_basename= name
Set a filename which shall be used by extract_audio_to= instead of the default
name "track".
.TP
.BI --extract_dap
Enable Digital Audio Play flaw obscuring mechanisms
like audio data mute and interpolate.
.TP
.BI extract_tracks= number[,number[,...]]
Set a list of track numbers to define which tracks shall be extracted
by extract_audio_to=.
If no extract_tracks= is given, then all audio tracks get extracted.
It is permissible to have more than one extract_tracks= option in order
to split a long list into shorter pieces.
.br
The lowest permissible track number is 1, the highest is 99.
.TP
.BI fallback_program= command
Set a command name to be executed if cdrskin encounters a known cdrecord
option which it does not yet support. If a non-empty command is given with
@ -1186,15 +1140,7 @@ growisofs -dvd-compat is roughly equivalent to cdrskin without option -multi.
.BI input_sheet_v07t= path
Read CD-TEXT definitions from a Sony Input Sheet version 0.7T. Up to eight
or seven such sheets can be read by multiple input_sheet_v07t= options.
Each will define one CD-TEXT language block.
.br
The first line of a sheet file decides whether more than one sheet
may be defined by the file. If it is
.br
Input Sheet Version = 0.7T
.br
then each further line with that text switches to the next sheet for the next block.
If it is not, then all definitions apply to a single block.
Each will define a CD-TEXT language block.
.br
The information in such a sheet is given by text lines of the following form:
.br
@ -1331,11 +1277,6 @@ which usually lack a motorized tray loader.
Only if used as first command line argument this option prevents reading and
interpretation of eventual startup files. See section FILES below.
.TP
.BI \--pacifier_with_newline
Adds a newline character to each pacifier line that would elsewise be
overwritten by the next pacifier line. Such lines are emitted during a
run of writing, formatting, or blanking if option -v is given.
.TP
.BI \--prodvd_cli_compatible
Activates behavior modifications with some DVD situations which bring cdrskin
nearer to the behavior of cdrecord-ProDVD:
@ -1398,17 +1339,6 @@ is possible with the given options.
This option redirects to stderr all message output except its own result
string and eventual output of -msinfo.
.TP
.BI textfile_to_v07t= path
Read a CD-TEXT pack file (e.g. cdtext.dat from a run with -v -v -toc)
and print its content in the human readable format that is described
with option input_sheet_v07t=.
.br
The program run ends immediately thereafter.
No drive scan will happen and no drive will be aquired.
.br
To avoid the cdrskin start message in the output, run:
cdrskin textfile_to_v07t=cdtext.dat | grep -v '^cdrskin'
.TP
.BI --two_channel
Indicate for subsequent tracks that they were mastered with two channels.
.TP
@ -1647,7 +1577,7 @@ cdrskin -v dev=/dev/sr0 blank=deformat_sequential
.br
cdrskin -v dev=/dev/hdc speed=12 fs=8m \\
.br
blank=as_needed -eject padsize=300k my_image.iso
blank=as_needed -eject padsize=300k my_image.iso
.SS
.B Write compressed afio archive on-the-fly (not possible with minimally blanked DVD-RW or DVD-R DL):
.br
@ -1655,7 +1585,7 @@ find . | afio -oZ - | \\
.br
cdrskin -v dev=0,1,0 fs=32m speed=8 \\
.br
blank=as_needed padsize=300k -
blank=as_needed padsize=300k -
.SS
.B Write multi-session to the same CD, DVD-R[W], DVD+R[/DL], or BD-R:
.br
@ -1677,25 +1607,16 @@ mkisofs ... -C "$c_values" ...
.br
x=$(cdrskin dev=/dev/sr0 -multi \\
.br
--tell_media_space 2>/dev/null)
--tell_media_space 2>/dev/null)
.br
echo "Available: $x blocks of 2048 data bytes"
.SS
.B Write audio tracks and CD-TEXT to CD:
.B Write audio tracks to CD:
.br
cdrskin -v dev=ATA:1,0,0 speed=48 -sao \\
.br
input_sheet_v07t=cdtext.v07t \\
track1.wav track2.au -audio -swab track3.raw
.br
track1.wav track2.au -audio -swab track3.raw
.SS
.B Extract audio tracks and CD-TEXT from CD into directory /home/me/my_cd:
.br
mkdir /home/me/my_cd
.br
cdrskin -v dev=/dev/sr0 extract_audio_to=/home/me/my_cd \\
.br
cdtext_to_v07t=/home/me/my_cd/cdtext.v07t
.SH FILES
.SS
Startup files:

File diff suppressed because it is too large Load Diff

View File

@ -65,7 +65,7 @@ connected via SCSI, PATA (aka IDE, ATA), USB, or SATA.
GPL software included:<BR>
</H2>
<DL>
<DT>libburn-1.3.2</DT>
<DT>libburn-1.3.0</DT>
<DD>(founded by Derek Foreman and Ben Jansens,
developed and maintained since August 2006 by
Thomas Schmitt from team of libburnia-project.org)
@ -200,13 +200,13 @@ Standalone ISO 9660 multi-session CD/DVD/BD tool
<P>
<DL>
<DT>Download as source code (see README):</DT>
<DD><A HREF="cdrskin-1.3.2.tar.gz">cdrskin-1.3.2.tar.gz</A>
<DD><A HREF="cdrskin-1.3.0.tar.gz">cdrskin-1.3.0.tar.gz</A>
(950 KB).
</DD>
<DD><A HREF="cdrskin-1.3.2.tar.gz.sig">cdrskin-1.3.2.tar.gz.sig</A></DD>
<DD><A HREF="cdrskin-1.3.0.tar.gz.sig">cdrskin-1.3.0.tar.gz.sig</A></DD>
<DD>
(detached GPG signature for verification by
<KBD>gpg --verify cdrskin-1.3.2.tar.gz.sig cdrskin-1.3.2.tar.gz</KBD>
<KBD>gpg --verify cdrskin-1.3.0.tar.gz.sig cdrskin-1.3.0.tar.gz</KBD>
<BR>
after <KBD>gpg --keyserver keys.gnupg.net --recv-keys ABC0A854</KBD>).
</DD>
@ -257,39 +257,21 @@ cdrskin_0.4.2.pl00-x86-suse9_0-static.tar.gz</A>, (310 KB), -static compiled,
<HR>
<P>
Enhancements towards previous stable version cdrskin-1.3.0:
Enhancements towards previous stable version cdrskin-1.2.8:
<UL>
<LI>
New option textfile_to_v07t=
</LI>
<LI>
New options cdtext_to_textfile= and cdtext_to_v07t=
</LI>
<LI>
New options extract_audio_to= , extract_tracks= , extract_basename= ,
--extract_dap
</LI>
<LI>
Improved granularity of SCSI log time measurement, now with timestamp
</LI>
<LI>
New cdrskin option --pacifier_with_newline
</LI>
<LI>none</LI>
<!--
<LI>none</LI>
-->
</UL>
Bug fixes towards cdrskin-1.3.0:
Bug fixes towards cdrskin-1.2.8:
<UL>
<LI>
cdrskin -msinfo on DVD and BD reported
old session start = next writable address.
Regression introduced by version 1.2.8.
(Also fixed by patch release 1.3.0.pl01 in may 2013.)
Full formatting of BD-RE used certification regardless of drive capabilities
</LI>
<LI>
The signal handler aborted on SIGCONT, SIGTSTP, SIGTTIN, SIGTTOU
DVD+R with damaged TOC were reported by -minfo with wrong end address
</LI>
<!--
<LI>none</LI>
@ -300,10 +282,12 @@ The signal handler aborted on SIGCONT, SIGTSTP, SIGTTIN, SIGTTOU
<P>
<DL>
<DT><H3>Development snapshot, version 1.3.3 :</H3></DT>
<DD>Enhancements towards current stable version 1.3.2:
<DT><H3>Development snapshot, version 1.3.1 :</H3></DT>
<DD>Enhancements towards current stable version 1.3.0:
<UL>
<LI>none yet</LI>
<LI>
none yet
</LI>
<!--
<LI>none yet</LI>
-->
@ -311,7 +295,7 @@ The signal handler aborted on SIGCONT, SIGTSTP, SIGTTIN, SIGTTOU
</UL>
</DD>
<DD>Bug fixes towards cdrskin-1.3.2:
<DD>Bug fixes towards cdrskin-1.3.0:
<UL>
<LI>none yet</LI>
<!--
@ -321,10 +305,10 @@ The signal handler aborted on SIGCONT, SIGTSTP, SIGTTIN, SIGTTOU
</DD>
<DD>&nbsp;</DD>
<DD><A HREF="README_cdrskin_devel">README 1.3.3</A>
<DD><A HREF="cdrskin__help_devel">cdrskin-1.3.3 --help</A></DD>
<DD><A HREF="cdrskin_help_devel">cdrskin-1.3.3 -help</A></DD>
<DD><A HREF="man_1_cdrskin_devel.html">man cdrskin (as of 1.3.3)</A></DD>
<DD><A HREF="README_cdrskin_devel">README 1.3.1</A>
<DD><A HREF="cdrskin__help_devel">cdrskin-1.3.1 --help</A></DD>
<DD><A HREF="cdrskin_help_devel">cdrskin-1.3.1 -help</A></DD>
<DD><A HREF="man_1_cdrskin_devel.html">man cdrskin (as of 1.3.1)</A></DD>
<DD>&nbsp;</DD>
<DT>Maintainers of cdrskin unstable packages please use SVN of
<A HREF="http://libburnia-project.org"> libburnia-project.org</A></DT>
@ -344,7 +328,7 @@ admins with full system souvereignty.</DT>
<A HREF="README_cdrskin_devel">upcoming README</A> ):
</DD>
<DD>
<A HREF="cdrskin-1.3.3.tar.gz">cdrskin-1.3.3.tar.gz</A>
<A HREF="cdrskin-1.3.1.tar.gz">cdrskin-1.3.1.tar.gz</A>
(950 KB).
</DD>

View File

@ -1 +1 @@
#define Cdrskin_timestamP "2013.08.07.093001"
#define Cdrskin_timestamP "2013.05.17.090001"

View File

@ -11814,7 +11814,7 @@ Made number transition to 1.3.0
+ cdrskin/add_ts_changes_to_libburn_1_3_1
Updated cdrskin tarball generator
17 May 2013 [5047]
17 May 2013 []
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
@ -11827,333 +11827,26 @@ Updated change log
address
17 May 2013 [5051]
- cdrskin/add_ts_changes_to_libburn_1_2_8
- cdrskin/add_ts_changes_to_libburn_1_2_9
+ cdrskin/add_ts_changes_to_libburn_1_3_0
+ cdrskin/add_ts_changes_to_libburn_1_3_1
Updated cdrskin tarball generator
2013.05.17.180032 [5052]
Makefile.am
configure.ac
README
libburn/libburn.h
cdrskin/cdrskin.c
cdrskin/cdrskin.1
cdrskin/README
cdrskin/compile_cdrskin.sh
cdrskin/cdrskin_timestamp.h
cdrskin/cdrskin_eng.html
Made number transition to 1.3.1
17 May 2013 [5053]
[]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
17 May 2013 [5054]
svn move -m libburn release 1.3.0 is ready
------------------------------------ cycle - cdrskin-1.3.1 -
------------------------------------ cycle - cdrskin-1.3.1 - 2013.05.17.181442
[]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.1 -
2013.05.19.114643 [5059]
libburn/libburn.h
libburn/cdtext.c
doc/cdtext.txt
libburn/libburn.ver
New API call burn_make_input_sheet_v07t()
2013.05.19.114854 [5060]
cdrskin/cdrskin.c
cdrskin/cdrskin.1
New option textfile_to_v07t=
2013.05.19.154838 [5061]
cdrskin/cdrskin.c
cdrskin/cdrskin.1
New options cdtext_to_textfile= and cdtext_to_v07t=
2013.05.20.104814 [5062]
libburn/libburn.h
libburn/cdtext.c
[]
libburn/libdax_msgs.h
API call burn_session_input_sheet_v07t(): read multiple blocks from same file
Changed item description in list of error codes
2013.05.20.110128 [5063]
cdrskin/cdrskin.c
cdrskin/cdrskin.1
Allowed option input_sheet_v07t= to read multiple blocks from same file
2013.05.20.124448 [5064]
libburn/cdtext.c
Bug fixes with new API call burn_make_input_sheet_v07t()
2013.05.20.124520 [5065]
cdrskin/cdrskin.c
Closed memory leak introduced by rev 5063
20 May 2013 [5066]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.1 - 2013.05.20.141737
* New API call burn_make_input_sheet_v07t()
* New option textfile_to_v07t=
* New options cdtext_to_textfile= and cdtext_to_v07t=
* API call burn_session_input_sheet_v07t(): read multiple blocks from same file
2013.05.21.081819 [5067]
cdrskin/cdrskin.c
Defaulting -sao -multi to -tao -multi if -sao -multi is not possible
2013.05.23.154249 [5068]
libburn/libburn.h
libburn/file.c
libburn/util.h
libburn/util.c
libburn/libdax_msgs.h
libburn/libdax_msgs.c
libburn/libburn.ver
New API calls burn_drive_extract_audio(), burn_drive_extract_audio_track()
2013.05.23.154249 [5069]
cdrskin/cdrskin.c
cdrskin/cdrskin.1
New cdrskin options extract_audio_to= , extract_tracks= , extract_basename= , --extract_dap
23 May 2013 [5070]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.1 - 2013.05.23.155617
* New API calls burn_drive_extract_audio(), burn_drive_extract_audio_track()
* New cdrskin options extract_audio_to= , extract_tracks= , extract_basename= ,
--extract_dap
23 May 2013 [5071]
doc/cdtext.txt
Updated documentation about CD-TEXT
2013.05.26.185945 [5072]
cdrskin/cdrskin.c
Luring K3B into using -xa rather than -xa1
2013.05.30.133008 [5076]
cdrskin/cdrskin.c
Bug fix: cdrskin -msinfo on DVD and BD reported
old session start == next writable address.
Regression introduced by version 1.2.8 (rev 4956).
[]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.1 - 2013.05.30.133756
* Bug fix: cdrskin -msinfo on DVD and BD reported
old session start == next writable address.
Regression introduced by version 1.2.8 (rev 4956).
31 May 2013 [5079]
svn copy -m Branching for libburn bugfix release 1.3.0.pl01
http://svn.libburnia-project.org/libburn/tags/1.3.0
http://svn.libburnia-project.org/libburn/branches/1.3.0.pl01
2013.05.31.080001 [5080]
cdrskin/cdrskin.c
Bug fix: cdrskin -msinfo on DVD and BD reported
old session start = next writable address.
Regression introduced by version 1.2.8 (rev 4956).
31 May 2013 [5081]
README
cdrskin/README
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Mentioned bug fix and pl01
31 May 2013 [5082]
svn move -m libburn bugfix release 1.3.0.pl01 is ready
http://svn.libburnia-project.org/libburn/branches/1.3.0.pl01
http://svn.libburnia-project.org/libburn/tags/1.3.0.pl01
------------------------------ release - libburn-1.3.0.pl01 - 2013.05.31.080001
* Bug fix: cdrskin -msinfo on DVD and BD reported
old session start = next writable address.
Regression introduced by version 1.2.8 (rev 4956).
31 May 2013 [5083]
README
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Mentioned bug fix and pl01
2013.06.09.152602 [5087]
libburn/transport.h
libburn/init.h
libburn/init.c
libburn/util.h
libburn/util.c
libburn/spc.h
libburn/spc.c
libburn/sg-linux.c
libburn/sg-solaris.c
libburn/sg-libcdio.c
libburn/sg-freebsd.c
Improved granularity of SCSI log time measurement and added absolute timestamp
2013.06.09.154237 [5088]
libburn/util.c
Prepared for optional use of clock_gettime()
2013.06.09.163052 [5089]
libburn/util.c
libburn/spc.c
Some polishing of SCSI log time measurement
12 Jun 2013 [5090]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.1 - 2013.06.12.104457
* Improved granularity of SCSI log time measurement, now with timestamp
24 Jun 2013 [5091]
test/telltoc.c
Removed inactive test code from telltoc.c
2013.06.28.104134 [5093]
cdrskin/cdrskin.c
Making sure in cdrskin that off_t is large enough before starting libburn
2013.06.28.104316 [5094]
cdrskin/cdrskin.c
Removed an obsolete note message from cdrskin --devices
2013.07.01.155958 [5097]
libburn/libburn.h
libburn/init.c
libburn/cleanup.c
New mode bit8 with burn_set_signal_handling() to particularly ignore SIGPIPE
2013.07.08.145600 [5110]
libburn/cleanup.c
Corrected typo in a comment
2013.07.08.151826 [5111]
cdrskin/cdrskin.c
cdrskin/cdrskin.1
New option --pacifier_with_newline
2013.07.21.170714 [5112]
libburn/os-dummy.h
libburn/os-freebsd.h
libburn/os-libcdio.h
libburn/os-linux.h
libburn/os-solaris.h
Bug fix: The signal handler aborted on SIGCONT, SIGTSTP, SIGTTIN, SIGTTOU
2013.07.29.091415 [5114]
libburn/libburn.h
Reacted on warnings of Debian build service about doxygen flaws
2013.08.04.100247 [5116]
configure.ac
libburn/write.c
cdrskin/cdrskin.1
Changed default write chunk size for BD to 64 KiB
2013.08.04.124449 [5122]
libburn/libburn.h
Reacted on advise from Helmut Grohne to avoid confusion of doxygen
04 Aug 2013 [5124]
doc/doxygen.conf.in
Update of doxygen configuration for version 1.8.4 provided by George Danchev
07 Aug 2013 [5125]
svn copy -m Branching for libburn release 1.3.2
2013.08.07.093001 [5126]
Makefile.am
configure.ac
README
libburn/libburn.h
cdrskin/cdrskin.c
cdrskin/cdrskin.1
cdrskin/README
cdrskin/compile_cdrskin.sh
cdrskin/cdrskin_timestamp.h
cdrskin/cdrskin_eng.html
Made number transition to 1.3.2
07 Aug 2013 [5127]
- cdrskin/add_ts_changes_to_libburn_1_3_0
- cdrskin/add_ts_changes_to_libburn_1_3_1
+ cdrskin/add_ts_changes_to_libburn_1_3_2
+ cdrskin/add_ts_changes_to_libburn_1_3_3
Updated cdrskin tarball generator
[]
ChangeLog
cdrskin/changelog.txt
Documented changes and release timestamp
----------------------------------- release - cdrskin-1.3.2 - 2013.08.07.093001
* Bug fix: cdrskin -msinfo on DVD and BD reported
old session start = next writable address.
Regression introduced by version 1.2.8 (rev 4956).
* Bug fix: The signal handler aborted on SIGCONT, SIGTSTP, SIGTTIN, SIGTTOU
* New API call burn_make_input_sheet_v07t()
* API call burn_session_input_sheet_v07t(): read multiple blocks from same file
* New API calls burn_drive_extract_audio(), burn_drive_extract_audio_track()
* New cdrskin option textfile_to_v07t=
* New cdrskin options cdtext_to_textfile= and cdtext_to_v07t=
* New cdrskin options extract_audio_to= , extract_tracks= , extract_basename= ,
--extract_dap
* New cdrskin option --pacifier_with_newline
* Improved granularity of SCSI log time measurement, now with timestamp
* Optional "make doc" now demands doxygen 1.8.4
[]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.3 -
[]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.3 -
[]
ChangeLog
cdrskin/cdrskin_eng.html
cdrskin/changelog.txt
Updated change log
------------------------------------ cycle - cdrskin-1.3.3 -
**********************************************************************
@ -12167,6 +11860,12 @@ Important: When adding a public API function then add its name to file
cdrskin option to emit pacifiers with newline rather than carriage return
cdrskin does not have a runtime check for sizeof(off_t) >= 6.
CD-TEXT:
- with SAO
- libburn:
@ -12174,7 +11873,8 @@ CD-TEXT:
- .inf files
- enforcing constraints:
- examine how drives react on wodim's cue sheet of INDEX 00 == INDEX 01
>>> produce v07t text sheet from binary text pack array
>>> bring make_v07t.c into libburn
qemu:

View File

@ -8,7 +8,7 @@ debug_opts="-O2"
def_opts=
largefile_opts="-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1"
fifo_opts=""
libvers="-DCdrskin_libburn_1_3_2"
libvers="-DCdrskin_libburn_1_3_0"
# To be used if Makefile.am uses libburn_libburn_la_CFLAGS
# burn="libburn/libburn_libburn_la-"
@ -41,15 +41,15 @@ do
elif test "$i" = "-compile_dewav"
then
compile_dewav=1
elif test "$i" = "-libburn_1_3_2"
elif test "$i" = "-libburn_1_3_0"
then
libvers="-DCdrskin_libburn_1_3_2"
libvers="-DCdrskin_libburn_1_3_0"
libdax_audioxtr_o="$burn"libdax_audioxtr.o
libdax_msgs_o="$burn"libdax_msgs.o
cleanup_src_or_obj="$burn"cleanup.o
elif test "$i" = "-libburn_svn"
then
libvers="-DCdrskin_libburn_1_3_3"
libvers="-DCdrskin_libburn_1_3_1"
libdax_audioxtr_o="$burn"libdax_audioxtr.o
libdax_msgs_o="$burn"libdax_msgs.o
cleanup_src_or_obj="$burn"cleanup.o
@ -99,7 +99,7 @@ do
echo "Options:"
echo " -compile_cdrfifo compile program cdrskin/cdrfifo."
echo " -compile_dewav compile program test/dewav without libburn."
echo " -libburn_1_3_2 set macro to match libburn-1.3.2"
echo " -libburn_1_3_0 set macro to match libburn-1.3.0"
echo " -libburn_svn set macro to match current libburn-SVN."
echo " -dvd_obs_64k 64 KB default size for DVD/BD writing."
echo " -use_libcdio link with -lcdio because libburn uses it."

View File

@ -1,4 +1,4 @@
AC_INIT([libburn], [1.3.2], [http://libburnia-project.org])
AC_INIT([libburn], [1.3.0], [http://libburnia-project.org])
AC_PREREQ([2.50])
dnl AC_CONFIG_HEADER([config.h])
@ -101,7 +101,6 @@ dnl 1.2.4 = libburn.so.4.77.0
dnl 1.2.6 = libburn.so.4.79.0
dnl 1.2.8 = libburn.so.4.81.0
dnl 1.3.0 = libburn.so.4.83.0
dnl 1.3.2 = libburn.so.4.85.0
dnl
dnl So LT_CURRENT, LT_REVISION and LT_AGE get set directly here.
dnl SONAME of the emerging library is LT_CURRENT - LT_AGE.
@ -127,7 +126,7 @@ dnl
dnl As said: Only copies. Original in libburn/libburn.h : burn_header_version_*
BURN_MAJOR_VERSION=1
BURN_MINOR_VERSION=3
BURN_MICRO_VERSION=2
BURN_MICRO_VERSION=0
BURN_VERSION=$BURN_MAJOR_VERSION.$BURN_MINOR_VERSION.$BURN_MICRO_VERSION
AC_SUBST(BURN_MAJOR_VERSION)
@ -138,14 +137,14 @@ AC_SUBST(BURN_VERSION)
dnl Libtool versioning
LT_RELEASE=$BURN_MAJOR_VERSION.$BURN_MINOR_VERSION.$BURN_MICRO_VERSION
dnl
dnl This is the release version libburn-1.3.2
dnl This is the release version libburn-1.3.0
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 happened meanwhile.
dnl
dnl SONAME = 89 - 85 = 4 . Linux library name = libburn.so.4.85.0
LT_CURRENT=89
LT_AGE=85
dnl SONAME = 87 - 83 = 4 . Linux library name = libburn.so.4.83.0
LT_CURRENT=87
LT_AGE=83
LT_REVISION=0
LT_CURRENT_MINUS_AGE=`expr $LT_CURRENT - $LT_AGE`
@ -222,14 +221,14 @@ CFLAGS="$LIBBURN_O_DIRECT_DEF $CFLAGS"
dnl ts A91116
AC_ARG_ENABLE(dvd-obs-64k,
[ --enable-dvd-obs-64k 64 KB default size for DVD writing, default=no],
[ --enable-dvd-obs-64k 64 KB default size for DVD/BD writing, default=no],
, enable_dvd_obs_64k=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"
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"
echo "disabled write size default 64 KB on DVD and BD"
fi
CFLAGS="$LIBBURN_DVD_OBS_64K $CFLAGS"

View File

@ -403,7 +403,7 @@ Byte :Value Meaning
-------------------------------------------------------------------------------
Overview of libburn API calls for CD-TEXT (see libburn/libburn.h for details):
libburn can retrieve the array of text packs from a CD:
libburn can retrieve the set of text packs from a CD:
int burn_disc_get_leadin_text(struct burn_drive *d,
unsigned char **text_packs, int *num_packs,
@ -418,7 +418,7 @@ This set may be attached as array of readily formatted text packs by:
unsigned char *text_packs,
int num_packs, int flag);
The array of text packs may be read from a file by
The array may be read from a file by
int burn_cdtext_from_packfile(char *path, unsigned char **text_packs,
int *num_packs, int flag);
@ -453,12 +453,6 @@ There is a reader for Sony Input Sheet Version 0.7T:
int burn_session_input_sheet_v07t(struct burn_session *session,
char *path, int block, int flag);
and a writer which converts an array of text packs to such a Sony Input Sheet:
int burn_make_input_sheet_v07t(unsigned char *text_packs, int num_packs,
int start_tno, int track_count,
char **result, int *char_code, int flag);
CD-TEXT can be read from a CDRWIN cue sheet file which defines the tracks
of a session
@ -572,8 +566,7 @@ libburn peculiarties:
libburn may read files of the described format by
burn_session_input_sheet_v07t()
after the burn_session has been establiched and all burn_track objects have
been added. It can convert an array of CD-TEXT packs into this format by
burn_make_input_sheet_v07t()
been added.
The following purpose specifiers accept byte values of the form 0xXY.
Text Code , Language Code , Genre Code , Text Data Copy Protection
@ -600,7 +593,7 @@ as empty test. (Normally empty content is ignored.)
Example cdrskin run with three tracks:
$ cdrskin dev=/dev/sr0 -v input_sheet_v07t=NIGHTCATS.TXT \
-audio -swab track_source_1 track_source_2 track_source_3
-audio track_source_1 track_source_2 track_source_3
----------------------------------------------------------
Content of file NIGHTCATS.TXT :

File diff suppressed because it is too large Load Diff

View File

@ -615,65 +615,17 @@ static int v07t_cdtext_to_track(struct burn_track *track, int block,
}
static int v07t_apply_to_session(struct burn_session *session, int block,
int char_codes[8], int copyrights[8], int languages[8],
int session_attr_seen[16], int track_attr_seen[16],
int genre_code, char *genre_text, int flag)
{
int i, ret, length;
char *line = NULL;
BURN_ALLOC_MEM(line, char, 4096);
for (i= 0x80; i <= 0x8e; i++) {
if (i > 0x85 && i != 0x8e)
continue;
if (session_attr_seen[i - 0x80] || !track_attr_seen[i - 0x80])
continue;
ret = v07t_cdtext_to_session(session, block, "",
char_codes + block, i, NULL, 0);
if (ret <= 0)
goto ex;
}
if (genre_code >= 0 && genre_text[0]) {
line[0] = (genre_code >> 8) & 0xff;
line[1] = genre_code & 0xff;
strcpy(line + 2, genre_text);
length = 2 + strlen(line + 2) + 1;
ret = burn_session_set_cdtext(session, block, 0, "GENRE",
(unsigned char *) line, length, 0);
if (ret <= 0)
goto ex;
}
ret = burn_session_set_cdtext_par(session, char_codes, copyrights,
languages, 0);
if (ret <= 0)
goto ex;
for (i = 0; i < 8; i++)
char_codes[i] = copyrights[i] = languages[i]= -1;
for (i = 0; i < 16; i++)
session_attr_seen[i] = track_attr_seen[i] = 0;
genre_text[0] = 0;
ret = 1;
ex:
BURN_FREE_MEM(line);
return ret;
}
/* ts B11215 API */
/* @param flag bit0= permission to read multiple blocks from the same sheet
bit1= do not attach CATALOG to session or ISRC to track for
/* @param flag bit1= do not attach CATALOG to session or ISRC to track for
writing to Q sub-channel
*/
int burn_session_input_sheet_v07t(struct burn_session *session,
char *path, int block, int flag)
{
int ret = 0, num_tracks, char_codes[8], copyrights[8], languages[8], i;
int genre_code = -1, track_offset = 1, pack_type, tno, tnum;
int genre_code = -1, track_offset = 1, length, pack_type, tno, tnum;
int session_attr_seen[16], track_attr_seen[16];
int int0x00 = 0x00, int0x01 = 0x01;
int additional_blocks = -1, line_count = 0, enable_multi_block = 0;
struct stat stbuf;
FILE *fp = NULL;
char *line = NULL, *eq_pos, *payload, *genre_text = NULL, track_txt[3];
@ -726,7 +678,6 @@ cannot_open:;
burn_printify(msg), 0, 0);
ret = 0; goto ex;
}
line_count++;
if (strlen(line) == 0)
continue;
eq_pos = strchr(line, '=');
@ -871,31 +822,6 @@ cannot_open:;
burn_printify(msg), 0, 0);
ret = 0; goto ex;
}
if (flag & 1)
if (line_count == 1)
enable_multi_block = 1;
if (enable_multi_block) {
if (additional_blocks >= 0) {
if (block == 7) {
libdax_msgs_submit(
libdax_messenger, -1, 0x000201a0,
LIBDAX_MSGS_SEV_WARNING, LIBDAX_MSGS_PRIO_HIGH,
"Maximum number of CD-TEXT blocks exceeded",
0, 0);
break;
}
ret = v07t_apply_to_session(
session, block, char_codes,
copyrights, languages,
session_attr_seen,
track_attr_seen,
genre_code, genre_text, 0);
if (ret <= 0)
goto ex;
block++;
}
additional_blocks++;
}
} else if (strcmp(line, "Remarks") == 0) {
;
@ -1053,16 +979,33 @@ bad_track_no:;
ret = 0; goto ex;
}
}
ret = v07t_apply_to_session(session, block,
char_codes, copyrights, languages,
session_attr_seen, track_attr_seen,
genre_code, genre_text, 0);
for (i= 0x80; i <= 0x8e; i++) {
if (i > 0x85 && i != 0x8e)
continue;
if (session_attr_seen[i - 0x80] || !track_attr_seen[i - 0x80])
continue;
ret = v07t_cdtext_to_session(session, block, "",
char_codes + block, i, NULL, 0);
if (ret <= 0)
goto ex;
}
if (genre_code >= 0 && genre_text[0]) {
line[0] = (genre_code >> 8) & 0xff;
line[1] = genre_code & 0xff;
strcpy(line + 2, genre_text);
length = 2 + strlen(line + 2) + 1;
ret = burn_session_set_cdtext(session, block, 0, "GENRE",
(unsigned char *) line, length, 0);
if (ret <= 0)
goto ex;
}
ret = burn_session_set_cdtext_par(session, char_codes, copyrights,
languages, 0);
if (ret <= 0)
goto ex;
ret = 1;
if (additional_blocks > 0)
ret += additional_blocks;;
ex:;
if(fp != NULL)
fclose(fp);
@ -1166,558 +1109,3 @@ ex:;
}
/* --------------------------------- make_v07t -------------------------- */
static int search_pack(unsigned char *text_packs, int num_packs,
int start_no, int pack_type, int block,
unsigned char **found_pack, int *found_no, int flag)
{
int i;
for (i = start_no; i < num_packs; i++) {
if (pack_type >= 0)
if (text_packs[i * 18] != pack_type)
continue;
if (block >= 0)
if (((text_packs[i * 18 + 3] >> 4) & 7) != block)
continue;
*found_pack = text_packs + i * 18;
*found_no = i;
return 1;
}
*found_pack = NULL;
*found_no = num_packs;
return 0;
}
static void write_v07t_line(char **respt, char *spec, char *value, int vlen,
int *result_len, int flag)
{
int len;
if (vlen == -1)
vlen = strlen(value);
len = strlen(spec);
if (len < 19)
len = 19;
len += 3 + vlen + 1;
if(flag & 1) {
*result_len += len;
return;
}
sprintf(*respt, "%-19s = ", spec);
if (vlen > 0)
memcpy(*respt + strlen(*respt), value, vlen);
(*respt)[len - 1] = '\n';
(*respt)[len] = 0;
*respt+= len;
}
/*
@return -1 error
0 no pack of block,pack_type found
1 packs found, delimiter is single 0-byte
2 packs found, delimiter is double 0-byte
*/
static int collect_payload(unsigned char *text_packs, int num_packs,
int pack_type, int block,
unsigned char **payload, int *payload_count,
int flag)
{
unsigned char *pack;
int pack_no, ret, double_byte = 0;
*payload_count = 0;
for (pack_no = 0; ; pack_no++) {
ret = search_pack(text_packs, num_packs, pack_no, pack_type,
block, &pack, &pack_no, 0);
if (ret <= 0)
break;
*payload_count += 12;
}
if (*payload_count == 0)
return 0;
*payload = burn_alloc_mem(*payload_count + 1, 1, 0);
if (*payload == NULL)
return -1;
*payload_count = 0;
for (pack_no = 0; ; pack_no++) {
ret = search_pack(text_packs, num_packs, pack_no, pack_type,
block, &pack, &pack_no, 0);
if (ret <= 0)
break;
memcpy(*payload + *payload_count, pack + 4, 12);
*payload_count += 12;
if (pack[4] & 128)
double_byte = 1;
}
(*payload)[*payload_count] = 0;
return 1 + double_byte;
}
/*
@param flag bit0= use double 0 as delimiter
*/
static int is_payload_text_end(unsigned char *payload, int payload_count,
int i, int flag)
{
if (i >= payload_count)
return 1;
if (payload[i])
return 0;
if (!(flag & 1))
return 1;
if (i + 1 >= payload_count)
return 1;
if (payload[i + 1] == 0)
return 1;
return 0;
}
/*
@param flag Bitfield for control purposes.
bit0= use double 0 as delimiter
bit1= replace TAB resp. TAB TAB by text of previous tno
*/
static int pick_payload_text(unsigned char *payload, int payload_count,
int tno,
unsigned char **text_start, int *text_len,
int flag)
{
int i, skipped = 0, end_found = 0;
again:;
if (tno <= 0) {
*text_start = payload;
*text_len = 0;
for (i = 0; i < payload_count; i += 1 + (flag & 1)) {
end_found = is_payload_text_end(payload, payload_count,
i, flag & 1);
if (end_found) {
*text_len = i;
break;
}
}
return 1;
}
*text_start = NULL;
*text_len = 0;
for (i = 0; i < payload_count; i += 1 + (flag & 1)) {
end_found = is_payload_text_end(payload, payload_count,
i, flag & 1);
if (end_found) {
skipped++;
if (skipped == tno) {
*text_start = payload + (i + 1 + (flag & 1));
} else if (skipped == tno + 1) {
*text_len = i - (*text_start - payload);
goto found;
}
}
}
if (*text_start == NULL)
return 0;
*text_len = payload_count - (*text_start - payload);
found:;
if (flag & 2) {
/* If TAB resp. TAB TAB, then look back */
if (flag & 1) {
if (*text_len == 2) {
if ((*text_start)[0] == '\t' &&
(*text_start)[1] == '\t') {
skipped = 0;
tno--;
goto again;
}
}
} else if (*text_len == 1) {
if ((*text_start)[0] == '\t') {
skipped = 0;
tno--;
goto again;
}
}
}
return 1;
}
static int write_v07t_textline(unsigned char *text_packs, int num_packs,
int pack_type, int block,
int tno, int first_tno, char *spec,
char **respt, int *result_len, int flag)
{
unsigned char *payload = NULL, *text_start;
int ret, payload_count = 0, text_len, tab_flag = 0;
char msg[80];
if ((pack_type >= 0x80 && pack_type <= 0x85) || pack_type == 0x8e)
tab_flag = 2;
ret = collect_payload(text_packs, num_packs, pack_type, block,
&payload, &payload_count, 0);
if(ret > 0) {
ret = pick_payload_text(payload, payload_count, tno,
&text_start, &text_len,
(ret == 2) | tab_flag);
if (ret > 0) {
if (tno > 0 && strcmp(spec, "ISRC") == 0)
sprintf(msg, "%s %-2.2d",
spec, tno + first_tno - 1);
else if (tno > 0)
sprintf(msg, "Track %-2.2d %s",
tno + first_tno - 1, spec);
else
strcpy(msg, spec);
write_v07t_line(respt, msg,
(char *) text_start, text_len,
result_len, flag & 1);
ret = 1;
}
}
BURN_FREE_MEM(payload);
return ret;
}
static int report_track(unsigned char *text_packs, int num_packs,
int block, int tno, int first_tno,
char **respt, int *result_len, int flag)
{
int ret, i;
static char *track_specs[6] = {
"Title", "Artist", "Songwriter", "Composer",
"Arranger", "Message"
};
for (i = 0; i < 6; i++) {
ret = write_v07t_textline(text_packs, num_packs, 0x80 + i,
block, tno, first_tno,
track_specs[i], respt, result_len,
flag & 1);
if (ret < 0)
return -1;
}
ret = write_v07t_textline(text_packs, num_packs, 0x8e, block,
tno, first_tno,
"ISRC", respt, result_len, flag & 1);
if (ret < 0)
return -1;
return 1;
}
/*
@param flag Bitfield for control purposes.
bit0= Do not store text in result but only determine
the minimum size for the result array.
It is permissible to submit result == NULL.
Submit the already occupied size as result_size.
@return > 0 tells the number of valid text bytes in result resp.
with flag bit0 the prediction of that number.
This does not include the trailing 0-byte.
= 0 indicates that the block is not present
< 0 indicates failure.
*/
static int report_block(unsigned char *text_packs, int num_packs,
int block, int first_tno, int last_tno, int char_code,
char *result, int result_size, int flag)
{
char *respt = NULL;
unsigned char *pack, *payload = NULL;
int result_len = 0, pack_no, ret, i, lang, payload_count = 0, genre;
char msg[80];
static char *languages[] = {
BURN_CDTEXT_LANGUAGES_0X00,
BURN_CDTEXT_FILLER,
BURN_CDTEXT_LANGUAGES_0X45
};
static char *volume_specs[7] = {
"Album Title", "Artist Name", "Songwriter", "Composer",
"Arranger", "Album Message", "Catalog Number",
};
static char *genres[BURN_CDTEXT_NUM_GENRES] = {
BURN_CDTEXT_GENRE_LIST
};
/* Search for any pack of the block. But do not accept 0x8f as first.*/
ret = search_pack(text_packs, num_packs, 0, -1, block,
&pack, &pack_no, 0);
if (ret <= 0)
return 0;
if (pack[0] == 0x8f)
return 0;
if (flag & 1) {
result_len = result_size;
} else {
respt = result + result_size;
}
write_v07t_line(&respt, "Input Sheet Version", "0.7T", -1, &result_len,
flag & 1);
sprintf(msg, "Libburn report of CD-TEXT Block %d", block);
write_v07t_line(&respt, "Remarks ", msg, -1, &result_len,
flag & 1);
write_v07t_line(&respt, "Text Code ",
char_code == 0 ? "8859" : char_code == 0x01 ? "ASCII" : "MS-JIS",
-1, &result_len, flag & 1);
pack_no = 0;
for (i = 0; i < 3; i++) {
ret = search_pack(text_packs, num_packs, pack_no, 0x8f, -1,
&pack, &pack_no, 0);
if (ret <= 0) {
libdax_msgs_submit(libdax_messenger, -1, 0x0002019f,
LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH,
"No third CD-TEXT pack 0x8f found. No language code defined",
0, 0);
goto failure;
}
pack_no++;
}
lang = pack[8 + block];
if (lang > 127) {
sprintf(msg, "CD-TEXT with unknown language code %2.2x",
(unsigned int) lang);
libdax_msgs_submit(libdax_messenger, -1, 0x0002019f,
LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH,
msg, 0, 0);
goto failure;
}
write_v07t_line(&respt, "Language Code", languages[lang], -1,
&result_len, flag & 1);
for (i = 0; i < 7; i++) {
ret = write_v07t_textline(text_packs, num_packs, 0x80 + i,
block, 0, 0, volume_specs[i],
&respt, &result_len,
flag & 1);
if (ret < 0)
goto failure;
}
ret = collect_payload(text_packs, num_packs, 0x87, block,
&payload, &payload_count, 0);
if(ret > 0) {
genre = (payload[0] << 8) | payload[1];
if (genre < BURN_CDTEXT_NUM_GENRES)
strcpy(msg, genres[genre]);
else
sprintf(msg, "0x%-4.4x", (unsigned int) genre);
write_v07t_line(&respt, "Genre Code", msg,
-1, &result_len, flag & 1);
write_v07t_line(&respt, "Genre Information",
(char *) payload + 2,
-1, &result_len, flag & 1);
BURN_FREE_MEM(payload); payload = NULL;
}
ret = collect_payload(text_packs, num_packs, 0x8d, block,
&payload, &payload_count, 0);
if(ret > 0) {
write_v07t_line(&respt, "Closed Information", (char *) payload,
-1, &result_len, flag & 1);
BURN_FREE_MEM(payload); payload = NULL;
}
ret = write_v07t_textline(text_packs, num_packs, 0x8e, block, 0, 0,
"UPC / EAN", &respt, &result_len, flag & 1);
if (ret < 0)
goto failure;
ret = search_pack(text_packs, num_packs, 0, 0x8f, -1,
&pack, &pack_no, 0);
if (ret < 0)
goto failure;
if (pack[7] == 0x00)
strcpy(msg, "OFF");
else if (pack[7] == 0x03)
strcpy(msg, "ON");
else
sprintf(msg, "0x%2.2x", (unsigned int) pack[7]);
write_v07t_line(&respt, "Text Data Copy Protection", msg,
-1, &result_len, flag & 1);
sprintf(msg, "%d", first_tno);
write_v07t_line(&respt, "First Track Number", msg,
-1, &result_len, flag & 1);
sprintf(msg, "%d", last_tno);
write_v07t_line(&respt, "Last Track Number", msg,
-1, &result_len, flag & 1);
for (i = 0; i < last_tno - first_tno + 1; i++) {
ret = report_track(text_packs, num_packs, block,
i + 1, first_tno,
&respt, &result_len, flag & 1);
if (ret < 0)
goto failure;
}
if (flag & 1)
return result_len;
return respt - result;
failure:;
BURN_FREE_MEM(payload);
return -1;
}
/*
@param result A byte buffer of sufficient size.
It will be filled by the text for the v07t sheet file
plus a trailing 0-byte. (Be aware that double-byte
characters might contain 0-bytes, too.)
@param result_size The number of bytes in result.
To be determined by a run with flag bit0 set.
@param flag Bitfield for control purposes.
bit0= Do not store text in result but only determine
the minimum size for the result array.
It is permissible to submit result == NULL and
result_size == 0.
@return > 0 tells the number of valid text bytes in result resp.
with flag bit0 the prediction of that number.
This does not include the trailing 0-byte.
<= 0 indicates failure.
*/
static int burn_make_v07t(unsigned char *text_packs, int num_packs,
int first_tno, int track_count,
char *result, int result_size,
int *char_code, int flag)
{
int pack_no = 0, ret, block, last_tno = 0;
unsigned char *pack;
char msg[80];
/* >>> ??? Verify checksums ? */;
/* Check character code, reject unknown ones */
ret = search_pack(text_packs, num_packs, 0, 0x8f, -1,
&pack, &pack_no, 0);
if (ret <= 0) {
libdax_msgs_submit(libdax_messenger, -1, 0x0002019f,
LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH,
"No CD-TEXT pack 0x8f found. No character code defined",
0, 0);
return 0;
}
*char_code = pack[4];
if (*char_code != 0x00 && *char_code != 0x01 && *char_code != 0x80) {
sprintf(msg, "CD-TEXT with unknown character code %2.2x",
(unsigned int) *char_code);
libdax_msgs_submit(libdax_messenger, -1, 0x0002019f,
LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH,
msg, 0, 0);
return 0;
}
/* Obtain first_tno and last_tno from type 0x88 if present. */
if (first_tno <= 0) {
if (pack[5] > 0 && pack[5] + pack[6] < 100 &&
pack[5] <= pack[6]) {
first_tno = pack[5];
last_tno = pack[6];
} else {
sprintf(msg,
"CD-TEXT with illegal track range %d to %d",
(int) pack[5], (int) pack[6]);
libdax_msgs_submit(libdax_messenger, -1, 0x0002019f,
LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH,
msg, 0, 0);
return 0;
}
}
if (last_tno <= 0) {
if (track_count > 0) {
last_tno = first_tno + track_count - 1;
} else {
last_tno = 99;
}
}
/* Report content */
result_size = 0;
for (block = 0; block < 8; block++) {
ret = report_block(text_packs, num_packs, block,
first_tno, last_tno, *char_code,
result, result_size, flag & 1);
if (ret < 0)
return ret;
if (ret == 0)
continue;
result_size = ret;
}
#ifdef NIX
if (flag & 1)
return result_size;
return (int) strlen((char *) result);
#else /* NIX */
return result_size;
#endif /* ! NIX */
}
/* Convert an array of CD-TEXT packs into the text format of
Sony CD-TEXT Input Sheet Version 0.7T .
@param text_packs Array of bytes which form CD-TEXT packs of 18 bytes
each. For a description of the format of the array,
see file doc/cdtext.txt.
No header of 4 bytes must be prepended which would
tell the number of pack bytes + 2.
This parameter may be NULL if the currently attached
array of packs shall be removed.
@param num_packs The number of 18 byte packs in text_packs.
@param start_tno The start number of track counting, if known from
CD table-of-content or orther sources.
Submit 0 to enable the attempt to read it and the
track_count from pack type 0x8f.
@param track_count The number of tracks, if known from CD table-of-content
or orther sources.
@param result Will return the buffer with Sheet text.
Dispose by free() when no longer needed.
It will be filled by the text for the v07t sheet file
plus a trailing 0-byte. (Be aware that double-byte
characters might contain 0-bytes, too.)
Each CD-TEXT language block starts by the line
"Input Sheet Version = 0.7T"
and a "Remarks" line that tells the block number.
@param char_code Returns the character code of the pack array:
0x00 = ISO-8859-1
0x01 = 7 bit ASCII
0x80 = MS-JIS (japanese Kanji, double byte characters)
The presence of a code value that is not in this list
will cause this function to fail.
@param flag Bitfield for control purposes. Unused yet. Submit 0.
@return > 0 tells the number of valid text bytes in result.
This does not include the trailing 0-byte.
<= 0 indicates failure.
*/
int burn_make_input_sheet_v07t(unsigned char *text_packs, int num_packs,
int start_tno, int track_count,
char **result, int *char_code, int flag)
{
int ret, result_size = 0;
ret = burn_make_v07t(text_packs, num_packs, start_tno, track_count,
NULL, 0, char_code, 1);
if (ret <= 0)
return ret;
result_size = ret + 1;
*result = burn_alloc_mem(result_size, 1, 0);
if (*result == NULL)
return -1;
ret = burn_make_v07t(text_packs, num_packs, start_tno, track_count,
*result, result_size, char_code, 0);
if (ret <= 0) {
free(*result);
return ret;
}
return result_size - 1;
}

View File

@ -133,27 +133,15 @@ static void Cleanup_handler_generic(int signum)
}
static char *Cleanup_signo_to_name(int signo)
{
int i;
for(i= 0; i < signal_list_count; i++)
if(signal_list[i] == signo)
return(signal_name_list[i]);
return("");
}
int Cleanup_set_handlers(void *handle, Cleanup_app_handler_T handler, int flag)
/*
bit0= set to default handlers
bit1= set to ignore
bit2= set cleanup_perform_app_handler_first
bit3= set SIGABRT to handler (makes sense with bits 0 or 1)
bit8= set SIGPIPE to SIGIGN
*/
{
int i,j,max_sig= -1,min_sig= 0x7fffffff;
char *sig_name;
sighandler_t sig_handler;
cleanup_msg[0]= 0;
@ -184,17 +172,8 @@ int Cleanup_set_handlers(void *handle, Cleanup_app_handler_T handler, int flag)
if(i==non_signal_list[j])
break;
if(j>=non_signal_list_count) {
/* Avoid to use particular SIG macros which might not be defined.
If they are defined, then their names are in the name list.
*/
if(flag & (8 | 256))
sig_name= Cleanup_signo_to_name(i);
else
sig_name= "";
if((flag & 8) && strcmp(sig_name, "SIGABRT") == 0)
if(i==SIGABRT && (flag&8))
signal(i,Cleanup_handler_generic);
else if((flag & 256) && strcmp(sig_name, "SIGPIPE") == 0)
signal(i, SIG_IGN);
else
signal(i,sig_handler);
}

View File

@ -27,7 +27,6 @@
#include "file.h"
#include "async.h"
#include "init.h"
#include "util.h"
#include "libdax_msgs.h"
extern struct libdax_msgs *libdax_messenger;
@ -920,161 +919,3 @@ struct burn_source *burn_offst_source_new(
return src;
}
/* -------------------- WAVE file extractor ------------------- */
/* ts B30522 */
/* API
@param flag Bitfield for control purposes:
bit0= Report about progress by UPDATE message
bit3= Enable DAP : "flaw obscuring mechanisms like
audio data mute and interpolate"
*/
int burn_drive_extract_audio(struct burn_drive *drive,
int start_sector, int sector_count,
char *target_path, int flag)
{
int fd = -1, ret, todo, sector_no, val, min, sec, fr;
int sectors_done= 0, last_reported = 0;
off_t data_size, data_count = 0;
time_t last_pacified = 0, now;
char *msg = NULL, *buf = NULL;
BURN_ALLOC_MEM(msg, char, 4096);
BURN_ALLOC_MEM(buf, char, 24 * 2352);
fd = open(target_path, O_WRONLY | O_CREAT,
S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
if (fd == -1) {
sprintf(msg, "Cannot open disk file for writing: %.4000s",
target_path);
libdax_msgs_submit(libdax_messenger, -1, 0x000201a1,
LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH,
msg, errno, 0);
ret = 0; goto ex;
}
/* WAV header */
strcpy(buf, "RIFF");
val = 4 + 8 + 16 + 8 + sector_count * 2352; /* ChunkSize */
burn_int_to_lsb(val, buf + 4);
strcpy(buf + 8, "WAVE");
strcpy(buf + 12, "fmt ");
burn_int_to_lsb(16, buf + 16); /* Subchunk1Size */
buf[20] = 1; /* AudioFormat */
buf[21] = 0;
buf[22] = 2; /* NumChannels */
buf[23] = 0;
burn_int_to_lsb(44100, buf + 24); /* SampleRate */
burn_int_to_lsb(176400, buf + 28); /* ByteRate */
buf[32] = 4; /* BlockAlign */
buf[33] = 0;
buf[34] = 16; /* BitsPerSample */
buf[35] = 0;
strcpy(buf + 36, "data");
burn_int_to_lsb(sector_count * 2352, buf + 40); /* Subchunk2Size */
ret = write(fd, buf, 44);
if (ret == -1)
goto write_error;
/* Audio data */
todo = sector_count;
sector_no = start_sector;
while (todo > 0) {
if (todo > 24)
data_size = 24 * 2352;
else
data_size = todo * 2352;
ret = burn_read_audio(drive, sector_no, buf, data_size,
&data_count, flag & 8);
if (ret <= 0) {
sprintf(msg, "Failure to read audio sectors");
libdax_msgs_submit(libdax_messenger, -1, 0x000201a4,
LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH,
msg, 0, 0);
goto ex;
}
ret = write(fd, buf, data_count);
if (ret == -1) {
write_error:;
sprintf(msg,
"Error while writing to disk file: %.4000s",
target_path);
libdax_msgs_submit(libdax_messenger, -1, 0x000201a2,
LIBDAX_MSGS_SEV_FAILURE,
LIBDAX_MSGS_PRIO_HIGH,
msg, errno, 0);
ret = 0; goto ex;
}
todo -= data_count / 2352;
sectors_done += data_count / 2352;
sector_no += data_count / 2352;
if ((flag & 1) && (now = time(NULL)) - last_pacified >= 1) {
last_pacified = now;
burn_lba_to_msf(sectors_done, &min, &sec, &fr);
sprintf(msg,
"Minutes:seconds of audio data read: %2d:%2.2d (%6.2f MB)",
min, sec,
((double) sectors_done) * 2352.0 / 1048576.0);
libdax_msgs_submit(libdax_messenger, -1, 0x000201a3,
LIBDAX_MSGS_SEV_UPDATE,
LIBDAX_MSGS_PRIO_HIGH,
msg, 0, 1);
last_reported = sectors_done;
}
}
if ((flag & 1)) {
burn_lba_to_msf(sectors_done, &min, &sec, &fr);
sprintf(msg,
"Minutes:seconds of audio data read: %2d:%2.2d (%6.2f MB)",
min, sec, ((double) sectors_done) * 2352.0 / 1048576.0);
libdax_msgs_submit(libdax_messenger, -1, 0x000201a3,
LIBDAX_MSGS_SEV_UPDATE,
LIBDAX_MSGS_PRIO_HIGH,
msg, 0, 0);
last_reported = sectors_done;
}
ret = 1;
ex:;
BURN_FREE_MEM(buf);
BURN_FREE_MEM(msg);
if (fd != -1)
close(fd);
return ret;
}
/* ts B30522 */
/* API
@param flag Bitfield for control purposes:
bit0= Report about progress by UPDATE message
bit3= Enable DAP : "flaw obscuring mechanisms like
audio data mute and interpolate"
*/
int burn_drive_extract_audio_track(struct burn_drive *drive,
struct burn_track *track,
char *target_path, int flag)
{
int ret;
struct burn_toc_entry toc_entry;
burn_track_get_entry(track, &toc_entry);
if (!(toc_entry.extensions_valid & 1)) {
/* Can only happen if burn_disc_cd_toc_extensions() is skipped
in mmc_read_toc_al().
*/
libdax_msgs_submit(libdax_messenger, -1, 0x00000004,
LIBDAX_MSGS_SEV_FATAL, LIBDAX_MSGS_PRIO_HIGH,
"Internal libburn error: Outdated burn_toc_entry format encountered",
errno, 0);
return -1;
}
ret = burn_drive_extract_audio(drive, toc_entry.start_lba,
toc_entry.track_blocks,
target_path, flag & (1 | 8));
return ret;
}

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2006 - 2012 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -31,7 +31,6 @@
#include "libburn.h"
#include "drive.h"
#include "transport.h"
#include "util.h"
/* ts A60825 : The storage location for back_hacks.h variables. */
#define BURN_BACK_HACKS_INIT 1
@ -44,9 +43,6 @@ struct libdax_msgs *libdax_messenger= NULL;
int burn_running = 0;
double lib_start_time;
/* ts A60813 : GNU/Linux: whether to use O_EXCL on open() of device files
ts B00212 : FreeBSD: whether to use flock(LOCK_EX) after open()
*/
@ -140,8 +136,6 @@ int burn_initialize(void)
if (burn_running)
return 1;
lib_start_time = burn_get_time(0);
burn_support_untested_profiles = 0;
ret = burn_msgs_initialize();
if (ret <= 0)
@ -549,7 +543,7 @@ void burn_set_signal_handling(void *handle, burn_abort_handler_t handler,
if(burn_builtin_signal_action == 0)
burn_builtin_signal_action = 1;
Cleanup_set_handlers(handle, (Cleanup_app_handler_T) handler,
(mode & 15) | 4 | (mode & 256));
(mode & 15) | 4);
burn_global_signal_handle = handle;
burn_global_signal_handler = handler;
}

View File

@ -1,17 +1,10 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
#ifndef BURN__INIT_H
#define BURN__INIT_H
extern int burn_running;
extern double lib_start_time;
/** Indicator for burn_drive_get_status() wether a signal hit parts of the
thread team.
0= all works well ,

View File

@ -1177,7 +1177,7 @@ int burn_drive_snooze(struct burn_drive *d, int flag);
/** Re-assess drive and media status. This should be done after a drive
underwent a status change and shall be further used without intermediate
burn_drive_release(), burn_drive_grab(). E.g. after blanking or burning.
@param d The already grabbed drive to re-assess.
@param drive The already grabbed drive to re-assess.
@param flag Unused yet. Submit 0.
@return 1 success , <= 0 could not determine drive and media state
@since 1.1.8
@ -1977,7 +1977,6 @@ int burn_session_set_start_tno(struct burn_session *session, int tno,
/** Inquire the CD track start number, as set by default or by
burn_session_set_start_tno().
@param session The session to be inquired
@param flag Bitfield for control purposes. Unused yet. Submit 0.
@return > 0 is the currently set CD track start number
<= 0 indicates failure
@since 1.2.0
@ -2090,7 +2089,7 @@ int burn_session_set_cdtext_par(struct burn_session *s,
@param s Session which to inquire
@param char_codes Will return Character Codes for block 0 to 7
@param copyrights Will return Copyright bytes for block 0 to 7
@param block_languages Will return Language Codes for block 0 to 7
@param languages Will return Language Codes for block 0 to 7
@param flag Bitfiled for control purposes. Unused yet. Submit 0.
@return <=0 failure, reply invalid, > 0 success, reply valid
@since 1.2.0
@ -2139,7 +2138,7 @@ int burn_session_get_cdtext_par(struct burn_session *s,
Pack type 0x8d contains ISO-8859-1 cleartext which is
not to be shown by commercial audio CD players.
Pack type 0x8e is ASCII cleartext with UPC/EAN code.
@param length Number of bytes in payload. Including terminating
@pram length Number of bytes in payload. Including terminating
0-bytes.
@param flag Bitfield for control purposes.
bit0= payload contains double byte characters
@ -2188,7 +2187,7 @@ int burn_session_set_cdtext(struct burn_session *s, int block,
If no text attribute is attached for pack type and
block, then payload is returned as NULL. The return
value will not indicate error in this case.
@param length Will return the number of bytes pointed to by payload.
@pram length Will return the number of bytes pointed to by payload.
Including terminating 0-bytes.
@param flag Bitfield for control purposes. Unused yet. Submit 0.
@return 1 single byte char, 2 double byte char, <=0 error
@ -2209,24 +2208,15 @@ int burn_session_get_cdtext(struct burn_session *s, int block,
The media catalog number from purpose specifier "UPC / EAN" gets into
effect only if burn_write_opts_set_has_mediacatalog() is set to 0.
The format of a v07t sheet file is documented in doc/cdtext.txt.
@param session Session where to attach CD-TEXT attributes
@param s Session where to attach CD-TEXT attributes
@param path Local filesystem address of the sheet file which
shall be read and interpreted.
@param block Number of the language block in which the attributes
shall appear. Possible values: 0 to 7.
@param flag Bitfield for control purposes.
bit0= Permission to read multiple blocks from the
given sheet file. Each block is supposed to begin
by a line "Input Sheet Version = 0.7T". Therefore
this permission is only valid if the input file
begins by such a line.
@since 1.3.2
bit1= Do not use media catalog string of session or ISRC
strings of tracks for writing to Q sub-channel.
@since 1.2.0
@return > 0 indicates success and the number of interpreted
blocks (1 if not flag bit0 is set).
<= 0 indicates failure
@return > 0 indicates success , <= 0 is failure
@since 1.2.0
*/
int burn_session_input_sheet_v07t(struct burn_session *session,
@ -2235,8 +2225,7 @@ int burn_session_input_sheet_v07t(struct burn_session *session,
/* ts B11210 */
/** Produce an array of CD-TEXT packs that could be submitted to
burn_write_opts_set_leadin_text(), or stored as *.cdt file,
or submitted to burn_make_input_sheet_v07t().
burn_write_opts_set_leadin_text() or stored as *.cdt file.
For a description of the format of the array, see file doc/cdtext.txt.
The input data stem from burn_session_set_cdtext_par(),
burn_session_set_cdtext(), and burn_track_set_cdtext().
@ -2261,49 +2250,6 @@ int burn_cdtext_from_session(struct burn_session *s,
int flag);
/* ts B30519 */
/** Convert an array of CD-TEXT packs into the text format of
Sony CD-TEXT Input Sheet Version 0.7T .
@param text_packs Array of bytes which form CD-TEXT packs of 18 bytes
each. For a description of the format of the array,
see file doc/cdtext.txt.
No header of 4 bytes must be prepended which would
tell the number of pack bytes + 2.
This parameter may be NULL if the currently attached
array of packs shall be removed.
@param num_packs The number of 18 byte packs in text_packs.
@param start_tno The start number of track counting, if known from
CD table-of-content or other sources.
Submit 0 to enable the attempt to read it and the
track_count from pack type 0x8f.
@param track_count The number of tracks, if known from CD table-of-content
or orther sources.
@param result Will return the buffer with Sheet text.
Dispose by free() when no longer needed.
It will be filled by the text for the v07t sheet file
plus a trailing 0-byte. (Be aware that double-byte
characters might contain 0-bytes, too.)
Each CD-TEXT language block starts by the line
"Input Sheet Version = 0.7T"
and a "Remarks" line that tells the block number.
@param char_code Returns the character code of the pack array:
0x00 = ISO-8859-1
0x01 = 7 bit ASCII
0x80 = MS-JIS (japanese Kanji, double byte characters)
The presence of a code value that is not in this list
will cause this function to fail.
@param flag Bitfield for control purposes. Unused yet. Submit 0.
@return > 0 tells the number of valid text bytes in result.
This does not include the trailing 0-byte.
<= 0 indicates failure.
@since 1.3.2
*/
int burn_make_input_sheet_v07t(unsigned char *text_packs, int num_packs,
int start_tno, int track_count,
char **result, int *char_code, int flag);
/* ts B11206 */
/** Remove all CD-TEXT attributes of the given block from the session.
They were attached by burn_session_set_cdtext().
@ -2374,7 +2320,7 @@ void burn_track_define_data(struct burn_track *t, int offset, int tail,
0x8e = "UPC_ISRC"
@param payload 0-terminated cleartext. If double byte characters
are used, then two 0-bytes terminate the cleartext.
@param length Number of bytes in payload. Including terminating
@pram length Number of bytes in payload. Including terminating
0-bytes.
@param flag Bitfield for control purposes.
bit0= payload contains double byte characters
@ -2399,7 +2345,7 @@ int burn_track_set_cdtext(struct burn_track *t, int block,
If no text attribute is attached for pack type and
block, then payload is returned as NULL. The return
value will not indicate error in this case.
@param length Will return the number of bytes pointed to by payload.
@pram length Will return the number of bytes pointed to by payload.
Including terminating 0-bytes.
@param flag Bitfield for control purposes. Unused yet. Submit 0.
@return 1=single byte char , 2= double byte char , <=0 error
@ -3539,7 +3485,7 @@ void burn_version(int *major, int *minor, int *micro);
*/
#define burn_header_version_major 1
#define burn_header_version_minor 3
#define burn_header_version_micro 2
#define burn_header_version_micro 0
/** Note:
Above version numbers are also recorded in configure.ac because libtool
wants them as parameters at build time.
@ -3760,23 +3706,18 @@ typedef int (*burn_abort_handler_t)(void *handle, int signum, int flag);
0 Same as 1 (for pre-0.7.8 backward compatibility)
@since 0.7.8
1 Catch the control thread in abort handler, call
burn_abort() with a patience value > 0 and
finally exit(1). Does not always work with FreeBSD.
2 Call burn_abort() with patience -1 and return from
handler. When the control thread calls
burn_drive_get_status(), then call burn_abort()
with patience 1 instead, and finally exit(1).
burn_abort(>0) and finally exit(1).
Does not always work with FreeBSD.
3 Call burn_abort() with patience -1, return from handler.
It is duty of the application to detect a pending abort
condition by calling burn_is_aborting() and to wait for
all drives to become idle. E.g. by calling burn_abort()
with patience >0.
4 Like 3, but without calling burn_abort() with -1. Only
the indicator of burn_is_aborting() gets set.
bit8: @since 1.3.2
try to ignore SIGPIPE (regardless of bit0 - bit3)
2 Call burn_abort(-1) and return from handler. When the
control thread calls burn_drive_get_status(), then do
burn_abort(>0) instead, and finally exit(1).
Does not always work with FreeBSD.
3 Call burn_abort(-1), return from handler. It is duty of
the application to detect a pending abort condition
by calling burn_is_aborting() and to wait for all
drives to become idle. E.g. by calling burn_abort(>0).
4 Like 3, but without calling burn_abort(-1). Only the
indicator of burn_is_aborting() gets set.
@since 0.2.6
*/
void burn_set_signal_handling(void *handle, burn_abort_handler_t handler,
@ -3928,49 +3869,6 @@ int burn_read_audio(struct burn_drive *d, int sector_no,
char data[], off_t data_size, off_t *data_count, int flag);
/* ts B30522 */
/** Extract an interval of audio sectors from CD and store it as a WAVE
audio file on hard disk.
@param drive The drive from which to read.
@param start_sector The logical block address of the first audio sector
which shall be read.
@param sector_count The number of audio sectors to be read.
Each sector consists of 2352 bytes.
@param target_path The address of the file where to store the extracted
audio data. Will be opened O_WRONLY | O_CREAT.
The file name should have suffix ".wav".
@param flag Bitfield for control purposes:
bit0= Report about progress by UPDATE messages
bit3= Enable DAP : "flaw obscuring mechanisms like
audio data mute and interpolate"
@since 1.3.2
*/
int burn_drive_extract_audio(struct burn_drive *drive,
int start_sector, int sector_count,
char *target_path, int flag);
/* ts B30522 */
/** Extract all audio sectors of a track from CD and store them as a WAVE
audio file on hard disk.
@param drive The drive from which to read.
@param track The track which shall be extracted.
@param target_path The address of the file where to store the extracted
audio data. Will be opened O_WRONLY | O_CREAT.
The file name should have suffix ".wav".
@param flag Bitfield for control purposes:
bit0= Report about progress by UPDATE messages
bit3= Enable DAP : "flaw obscuring mechanisms like
audio data mute and interpolate"
@since 1.3.2
*/
int burn_drive_extract_audio_track(struct burn_drive *drive,
struct burn_track *track,
char *target_path, int flag);
/* ts A70904 */
/** Inquire whether the drive object is a real MMC drive or a pseudo-drive
created by a stdio: address.
@ -4129,7 +4027,7 @@ int libdax_audioxtr_read(struct libdax_audioxtr *xtr,
/** Try to obtain a file descriptor which will deliver extracted data
to normal calls of read(2). This may fail because the format is
unsuitable for that, but WAVE (.wav) is ok. If this call succeeds the xtr
unsuitable for that, but ".wav" is ok. If this call succeeds the xtr
object will have forgotten its file descriptor and libdax_audioxtr_read()
will return a usage error. One may use *fd after libdax_audioxtr_destroy()
and will have to close it via close(2) when done with it.

View File

@ -44,8 +44,6 @@ burn_drive_convert_fs_adr;
burn_drive_convert_scsi_adr;
burn_drive_d_get_adr;
burn_drive_equals_adr;
burn_drive_extract_audio;
burn_drive_extract_audio_track;
burn_drive_free_speedlist;
burn_drive_get_adr;
burn_drive_get_all_profiles;
@ -91,7 +89,6 @@ burn_is_aborting;
burn_lba_to_msf;
burn_list_sev_texts;
burn_lookup_device_link;
burn_make_input_sheet_v07t;
burn_msf_to_lba;
burn_msf_to_sectors;
burn_msgs_obtain;

View File

@ -327,11 +327,6 @@ int libdax_msgs__sev_to_text(int severity, char **severity_name,
}
/*
@param flag Bitfield for control purposes
bit0= If direct output to stderr:
CarriageReturn rather than LineFeed
*/
int libdax_msgs_submit(struct libdax_msgs *m, int origin, int error_code,
int severity, int priority, char *msg_text,
int os_errno, int flag)
@ -350,8 +345,7 @@ int libdax_msgs_submit(struct libdax_msgs *m, int origin, int error_code,
if(ret>0)
sprintf(sev_text,"%s : ",sev_name);
fprintf(stderr, "%s%s%s%c", m->print_id, sev_text, textpt,
(flag & 1) ? '\r' : '\n');
fprintf(stderr,"%s%s%s\n",m->print_id,sev_text,textpt);
if(os_errno!=0) {
ret= libdax_msgs_lock(m,0);
if(ret<=0)

View File

@ -302,9 +302,7 @@ int libdax_msgs_refer(struct libdax_msgs **pt, struct libdax_msgs *o, int flag);
@param priority The LIBDAX_MSGS_PRIO_* number of the event.
@param msg_text Printable and human readable message text.
@param os_errno Eventual error code from operating system (0 if none)
@param flag Bitfield for control purposes
bit0= If direct output to stderr:
CarriageReturn rather than LineFeed
@param flag Bitfield for control purposes (unused yet, submit 0)
@return 1 on success, 0 on rejection, <0 for severe errors
*/
int libdax_msgs_submit(struct libdax_msgs *m, int origin, int error_code,
@ -600,12 +598,7 @@ Range "scdbackup" : 0x00020000 to 0x0002ffff
0x0002019c (SORRY,HIGH) = Session has no defined tracks
0x0002019d (SORRY,HIGH) = Audio read size not properly aligned
0x0002019e (NOTE,HIGH) = Drive does not support media certification
0x0002019f (FAILURE,HIGH) = CD-TEXT binary pack array faulty
0x000201a0 (WARNING,HIGH) = Maximum number of CD-TEXT blocks exceeded
0x000201a1 (FAILURE,HIGH) = Cannot open disk file for writing
0x000201a2 (FAILURE,HIGH) = Error while writing to disk file
0x000201a3 (UPDATE,HIGH) = Progress message of burn_drive_extract_audio()
0x000201a4 (FAILURE,HIGH) = Failure to read audio sectors
0x0002019f (FAILURE,HIGH) = CD-TEXT with unknown character code
libdax_audioxtr:

View File

@ -5,8 +5,7 @@
Unknown POSIX like systems
with the dummy MMC transport adapter sg-dummy.c
Copyright (C) 2009 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPLv2+
Copyright (C) 2009 Thomas Schmitt <scdbackup@gmx.net>, provided under GPLv2+
*/
@ -17,16 +16,18 @@
#define BURN_OS_SIGNAL_MACRO_LIST \
SIGHUP, SIGINT, SIGQUIT, SIGILL, SIGABRT, \
SIGFPE, SIGSEGV, SIGPIPE, SIGALRM, SIGTERM, \
SIGUSR1, SIGUSR2, SIGXCPU
SIGUSR1, SIGUSR2, SIGXCPU, SIGTSTP, SIGTTIN, \
SIGTTOU
/* Once as text 1:1 list of strings for messages and interpreters */
#define BURN_OS_SIGNAL_NAME_LIST \
"SIGHUP", "SIGINT", "SIGQUIT", "SIGILL", "SIGABRT", \
"SIGFPE", "SIGSEGV", "SIGPIPE", "SIGALRM", "SIGTERM", \
"SIGUSR1", "SIGUSR2", "SIGXCPU"
"SIGUSR1", "SIGUSR2", "SIGXCPU", "SIGTSTP", "SIGTTIN", \
"SIGTTOU"
/* The number of above list items */
#define BURN_OS_SIGNAL_COUNT 13
#define BURN_OS_SIGNAL_COUNT 16
/** The list of all signals which shall surely not be caught.
It depends on the particular signal whether it can be ignored or whether
@ -54,12 +55,11 @@
/** The combined list of all signals which shall not be caught.
*/
#define BURN_OS_NON_SIGNAL_MACRO_LIST \
SIGKILL, SIGCHLD, SIGSTOP, SIGTSTP, SIGCONT, SIGTTIN, SIGTTOU \
BURN_OS_SIG_WINCH BURN_OS_SIG_URG
SIGKILL, SIGCHLD, SIGSTOP BURN_OS_SIG_WINCH BURN_OS_SIG_URG
/* The number of above list items */
#define BURN_OS_NON_SIGNAL_COUNT \
( 7 + BURN_OS_SIG_WINCH_CNT + BURN_OS_SIG_URG_CNT )
( 3 + BURN_OS_SIG_WINCH_CNT + BURN_OS_SIG_URG_CNT )
/* The maximum size for a (SCSI) i/o transaction */

View File

@ -4,8 +4,8 @@
by os.h in case of compilation for
FreeBSD with CAM
Copyright (C) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>,
Provided under GPLv2+
Copyright (C) 2006 - 2010 Thomas Schmitt <scdbackup@gmx.net>,
provided under GPLv2+
*/
/** List of all signals which shall be caught by signal handlers and trigger
@ -15,25 +15,29 @@
#define BURN_OS_SIGNAL_MACRO_LIST \
SIGHUP, SIGINT, SIGQUIT, SIGILL, SIGABRT, \
SIGFPE, SIGSEGV, SIGPIPE, SIGALRM, SIGTERM, \
SIGUSR1, SIGUSR2, SIGXCPU, SIGBUS, SIGPROF, \
SIGSYS, SIGTRAP, SIGVTALRM, SIGXCPU, SIGXFSZ
SIGUSR1, SIGUSR2, SIGXCPU, SIGTSTP, SIGTTIN, \
SIGTTOU, \
SIGBUS, SIGPROF, SIGSYS, SIGTRAP, \
SIGVTALRM, SIGXCPU, SIGXFSZ
/* Once as text 1:1 list of strings for messages and interpreters */
#define BURN_OS_SIGNAL_NAME_LIST \
"SIGHUP", "SIGINT", "SIGQUIT", "SIGILL", "SIGABRT", \
"SIGFPE", "SIGSEGV", "SIGPIPE", "SIGALRM", "SIGTERM", \
"SIGUSR1", "SIGUSR2", "SIGXCPU", "SIGBUS", "SIGPROF", \
"SIGSYS", "SIGTRAP", "SIGVTALRM", "SIGXCPU", "SIGXFSZ"
"SIGUSR1", "SIGUSR2", "SIGXCPU", "SIGTSTP", "SIGTTIN", \
"SIGTTOU", \
"SIGBUS", "SIGPROF", "SIGSYS", "SIGTRAP", \
"SIGVTALRM", "SIGXCPU", "SIGXFSZ"
/* The number of above list items */
#define BURN_OS_SIGNAL_COUNT 20
#define BURN_OS_SIGNAL_COUNT 23
/** To list all signals which shall surely not be caught */
#define BURN_OS_NON_SIGNAL_MACRO_LIST \
SIGKILL, SIGCHLD, SIGSTOP, SIGTSTP, SIGCONT, SIGTTIN, SIGTTOU, SIGURG, SIGWINCH
SIGKILL, SIGCHLD, SIGSTOP, SIGURG, SIGWINCH
/* The number of above list items */
#define BURN_OS_NON_SIGNAL_COUNT 9
#define BURN_OS_NON_SIGNAL_COUNT 5
/* The maximum size for a (SCSI) i/o transaction */

View File

@ -5,8 +5,7 @@
Unknown X/Open-like systems
with GNU libcdio MMC transport adapter sg-libcdio.c
Copyright (C) 2009 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPLv2+
Copyright (C) 2009 Thomas Schmitt <scdbackup@gmx.net>, provided under GPLv2+
*/
@ -17,16 +16,18 @@
#define BURN_OS_SIGNAL_MACRO_LIST \
SIGHUP, SIGINT, SIGQUIT, SIGILL, SIGABRT, \
SIGFPE, SIGSEGV, SIGPIPE, SIGALRM, SIGTERM, \
SIGUSR1, SIGUSR2, SIGXCPU
SIGUSR1, SIGUSR2, SIGXCPU, SIGTSTP, SIGTTIN, \
SIGTTOU
/* Once as text 1:1 list of strings for messages and interpreters */
#define BURN_OS_SIGNAL_NAME_LIST \
"SIGHUP", "SIGINT", "SIGQUIT", "SIGILL", "SIGABRT", \
"SIGFPE", "SIGSEGV", "SIGPIPE", "SIGALRM", "SIGTERM", \
"SIGUSR1", "SIGUSR2", "SIGXCPU"
"SIGUSR1", "SIGUSR2", "SIGXCPU", "SIGTSTP", "SIGTTIN", \
"SIGTTOU"
/* The number of above list items */
#define BURN_OS_SIGNAL_COUNT 13
#define BURN_OS_SIGNAL_COUNT 16
/** The list of all signals which shall surely not be caught.
@ -55,12 +56,11 @@
/** The combined list of all signals which shall not be caught.
*/
#define BURN_OS_NON_SIGNAL_MACRO_LIST \
SIGKILL, SIGCHLD, SIGSTOP, SIGTSTP, SIGCONT, SIGTTIN, SIGTTOU \
BURN_OS_SIG_WINCH BURN_OS_SIG_URG
SIGKILL, SIGCHLD, SIGSTOP BURN_OS_SIG_WINCH BURN_OS_SIG_URG
/* The number of above list items */
#define BURN_OS_NON_SIGNAL_COUNT \
( 7 + BURN_OS_SIG_WINCH_CNT + BURN_OS_SIG_URG_CNT )
( 3 + BURN_OS_SIG_WINCH_CNT + BURN_OS_SIG_URG_CNT )
/* The maximum size for a (SCSI) i/o transaction */

View File

@ -4,7 +4,7 @@
by os.h in case of compilation for
Linux kernels 2.4 and 2.6, GNU/Linux SCSI Generic (sg)
Copyright (C) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (C) 2006 - 2010 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -16,27 +16,29 @@
#define BURN_OS_SIGNAL_MACRO_LIST \
SIGHUP, SIGINT, SIGQUIT, SIGILL, SIGABRT, \
SIGFPE, SIGSEGV, SIGPIPE, SIGALRM, SIGTERM, \
SIGUSR1, SIGUSR2, SIGXCPU, SIGBUS, SIGPOLL, \
SIGPROF, SIGSYS, SIGTRAP, SIGVTALRM, SIGXCPU, \
SIGXFSZ
SIGUSR1, SIGUSR2, SIGXCPU, SIGTSTP, SIGTTIN, \
SIGTTOU, \
SIGBUS, SIGPOLL, SIGPROF, SIGSYS, SIGTRAP, \
SIGVTALRM, SIGXCPU, SIGXFSZ
/* Once as text 1:1 list of strings for messages and interpreters */
#define BURN_OS_SIGNAL_NAME_LIST \
"SIGHUP", "SIGINT", "SIGQUIT", "SIGILL", "SIGABRT", \
"SIGFPE", "SIGSEGV", "SIGPIPE", "SIGALRM", "SIGTERM", \
"SIGUSR1", "SIGUSR2", "SIGXCPU", "SIGBUS", "SIGPOLL", \
"SIGPROF", "SIGSYS", "SIGTRAP", "SIGVTALRM", "SIGXCPU", \
"SIGXFSZ"
"SIGUSR1", "SIGUSR2", "SIGXCPU", "SIGTSTP", "SIGTTIN", \
"SIGTTOU", \
"SIGBUS", "SIGPOLL", "SIGPROF", "SIGSYS", "SIGTRAP", \
"SIGVTALRM", "SIGXCPU", "SIGXFSZ"
/* The number of above list items */
#define BURN_OS_SIGNAL_COUNT 21
#define BURN_OS_SIGNAL_COUNT 24
/** To list all signals which shall surely not be caught */
#define BURN_OS_NON_SIGNAL_MACRO_LIST \
SIGKILL, SIGCHLD, SIGSTOP, SIGTSTP, SIGCONT, SIGURG, SIGWINCH, SIGTTIN, SIGTTOU
SIGKILL, SIGCHLD, SIGSTOP, SIGURG, SIGWINCH
/* The number of above list items */
#define BURN_OS_NON_SIGNAL_COUNT 9
#define BURN_OS_NON_SIGNAL_COUNT 5
/* The maximum size for a (SCSI) i/o transaction */

View File

@ -5,8 +5,7 @@
Solaris based systems, e.g. SunOS 5.11
with Solaris uscsi MMC transport adapter sg-solaris.c
Copyright (C) 2010 - 2013 Thomas Schmitt <scdbackup@gmx.net>
provided under GPLv2+
Copyright (C) 2010 Thomas Schmitt <scdbackup@gmx.net>, provided under GPLv2+
*/
@ -17,23 +16,25 @@
#define BURN_OS_SIGNAL_MACRO_LIST \
SIGHUP, SIGINT, SIGQUIT, SIGILL, SIGABRT, \
SIGFPE, SIGSEGV, SIGPIPE, SIGALRM, SIGTERM, \
SIGUSR1, SIGUSR2, SIGXCPU
SIGUSR1, SIGUSR2, SIGXCPU, SIGTSTP, SIGTTIN, \
SIGTTOU
/* Once as text 1:1 list of strings for messages and interpreters */
#define BURN_OS_SIGNAL_NAME_LIST \
"SIGHUP", "SIGINT", "SIGQUIT", "SIGILL", "SIGABRT", \
"SIGFPE", "SIGSEGV", "SIGPIPE", "SIGALRM", "SIGTERM", \
"SIGUSR1", "SIGUSR2", "SIGXCPU"
"SIGUSR1", "SIGUSR2", "SIGXCPU", "SIGTSTP", "SIGTTIN", \
"SIGTTOU"
/* The number of above list items */
#define BURN_OS_SIGNAL_COUNT 13
#define BURN_OS_SIGNAL_COUNT 16
/** To list all signals which shall surely not be caught */
#define BURN_OS_NON_SIGNAL_MACRO_LIST \
SIGKILL, SIGCHLD, SIGSTOP, SIGTSTP, SIGCONT, SIGTTIN, SIGTTOU, SIGURG, SIGWINCH
SIGKILL, SIGCHLD, SIGSTOP, SIGURG, SIGWINCH
/* The number of above list items */
#define BURN_OS_NON_SIGNAL_COUNT 9
#define BURN_OS_NON_SIGNAL_COUNT 5
/* The maximum size for a (SCSI) i/o transaction */

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/*
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2006 - 2011 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later
and under FreeBSD license revised, i.e. without advertising clause.
*/
@ -861,11 +861,8 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
memset(&ccb->csio.sense_data, 0, sizeof(ccb->csio.sense_data));
memset(c->sense, 0, sizeof(c->sense));
c->start_time = burn_get_time(0);
err = cam_send_ccb(d->cam, ccb);
c->end_time = burn_get_time(0);
ignore_error = sense_len = 0;
/* ts B00325 : CAM_AUTOSNS_VALID advised by Alexander Motin */
if (ccb->ccb_h.status & CAM_AUTOSNS_VALID) {
@ -962,12 +959,19 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
c->sense[13] = 0x00;
done = 1;
}
}
done = scsi_eval_cmd_outcome(d, c, fp, c->sense,
sense_len, start_time,
timeout_ms, i, !!ignore_error);
if (d->cancel)
/* >>> Need own duration time measurement.
Then remove bit1 from flag.
*/
done = scsi_eval_cmd_outcome(d, c, fp, c->sense,
sense_len, 0, start_time,
timeout_ms, i,
2 | !!ignore_error);
if (d->cancel)
done = 1;
} else {
done = 1;
}
} while (!done);
ret = 1;
ex:;

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/*
Copyright (c) 2009 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2009 - 2011 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -669,12 +669,9 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
for(i = 0; !done; i++) {
memset(c->sense, 0, sizeof(c->sense));
c->start_time = burn_get_time(0);
i_status = mmc_run_cmd(p_cdio, timeout_ms, &cdb, e_direction,
dxfer_len, c->page->data);
c->end_time = burn_get_time(0);
sense_valid = mmc_last_cmd_sense(p_cdio, &sense_pt);
if (sense_valid >= 18) {
memcpy(c->sense, (unsigned char *) sense_pt,
@ -720,7 +717,7 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
else
sense_len = 0;
done = scsi_eval_cmd_outcome(d, c, fp, c->sense, sense_len,
start_time, timeout_ms, i, 0);
0, start_time, timeout_ms, i, 2);
if (d->cancel)
done = 1;

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2006 - 2011 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -404,13 +404,13 @@ static int sgio_log_cmd(unsigned char *cmd, int cmd_len, FILE *fp_in, int flag)
/* ts B11110 */
static int sgio_log_reply(unsigned char *opcode, int data_dir,
unsigned char *data, int dxfer_len,
void *fp_in, unsigned char sense[18], int sense_len,
double duration, int flag)
void *fp_in, unsigned char sense[18],
int sense_len, int duration, int flag)
{
int ret;
ret = scsi_log_reply(opcode, data_dir, data, dxfer_len, fp_in,
sense, sense_len, duration, flag);
sense, sense_len, duration, flag);
return ret;
}
@ -420,7 +420,6 @@ static int sgio_test(int fd)
unsigned char test_ops[] = { 0, 0, 0, 0, 0, 0 };
sg_io_hdr_t s;
int ret;
double c_start_time, c_end_time;
memset(&s, 0, sizeof(sg_io_hdr_t));
s.interface_id = 'S';
@ -431,12 +430,10 @@ static int sgio_test(int fd)
sgio_log_cmd(s.cmdp, s.cmd_len, NULL, 0);
c_start_time = burn_get_time(0);
ret= ioctl(fd, SG_IO, &s);
c_end_time = burn_get_time(0);
sgio_log_reply(s.cmdp, NO_TRANSFER, NULL, 0, NULL,
s.sbp, s.sb_len_wr, c_end_time - c_start_time, 0);
sgio_log_reply(s.cmdp, NO_TRANSFER, NULL, 0,
NULL, s.sbp, s.sb_len_wr, s.duration, 0);
return ret;
}
@ -449,7 +446,6 @@ static int sgio_inquiry_cd_drive(int fd, char *fname)
unsigned char *sense = NULL;
char *msg = NULL, *msg_pt;
int ret = 0, i;
double c_start_time, c_end_time;
BURN_ALLOC_MEM(buf, struct buffer, 1);
BURN_ALLOC_MEM(sense, unsigned char, 128);
@ -469,9 +465,7 @@ static int sgio_inquiry_cd_drive(int fd, char *fname)
sgio_log_cmd(s.cmdp, s.cmd_len, NULL, 0);
c_start_time = burn_get_time(0);
ret = ioctl(fd, SG_IO, &s);
c_end_time = burn_get_time(0);
if (ret == -1) {
sprintf(msg,
"INQUIRY on '%s' : ioctl(SG_IO) failed , errno= %d",
@ -482,8 +476,8 @@ static int sgio_inquiry_cd_drive(int fd, char *fname)
goto ex;
}
sgio_log_reply(s.cmdp, FROM_DRIVE, buf->data, s.dxfer_len, NULL,
s.sbp, s.sb_len_wr, c_end_time - c_start_time, 0);
sgio_log_reply(s.cmdp, FROM_DRIVE, buf->data, s.dxfer_len,
NULL, s.sbp, s.sb_len_wr, s.duration, 0);
if (s.sb_len_wr > 0 || s.host_status != Libburn_sg_host_oK ||
s.driver_status != Libburn_sg_driver_oK) {
@ -1998,12 +1992,8 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
for(i = 0; !done; i++) {
memset(c->sense, 0, sizeof(c->sense));
c->start_time = burn_get_time(0);
err = ioctl(d->fd, SG_IO, &s);
c->end_time = burn_get_time(0);
/* ts A61010 */
/* a ssert(err != -1); */
if (err == -1) {
@ -2019,7 +2009,7 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
{ret = -1; goto ex;}
}
done = scsi_eval_cmd_outcome(d, c, fp, s.sbp, s.sb_len_wr,
start_time, s.timeout, i, 0);
s.duration, start_time, s.timeout, i, 0);
if (d->cancel)
done = 1;
}

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/*
Copyright (c) 2010 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2010 - 2011 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -637,12 +637,8 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
for(i = 0; !done; i++) {
memset(c->sense, 0, sizeof(c->sense));
c->start_time = burn_get_time(0);
ret = ioctl(d->fd, USCSICMD, &cgc);
c->end_time = burn_get_time(0);
/* For cgc.uscsi_status see SAM-3 5.3.1, Table 22
0 = GOOD , 2 = CHECK CONDITION : Sense Data are delivered
8 = BUSY
@ -673,8 +669,8 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
sense_len = 18;
else
sense_len = 0;
done = scsi_eval_cmd_outcome(d, c, fp, c->sense, sense_len,
start_time, timeout_ms, i, 0);
done = scsi_eval_cmd_outcome(d, c, fp, c->sense, sense_len, 0,
start_time, timeout_ms, i, 2);
if (d->cancel)
done = 1;

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2006 - 2012 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -33,7 +33,6 @@
#include "debug.h"
#include "options.h"
#include "init.h"
#include "util.h"
#include "libdax_msgs.h"
extern struct libdax_msgs *libdax_messenger;
@ -1650,8 +1649,9 @@ int scsi_log_cmd(struct command *c, void *fp_in, int flag)
*/
int scsi_log_reply(unsigned char *opcode, int data_dir, unsigned char *data,
int dxfer_len, void *fp_in, unsigned char sense[18],
int sense_len, double duration, int flag)
int sense_len, int duration, int flag)
{
char durtxt[20];
FILE *fp = fp_in;
int key, asc, ascq, i, l;
@ -1667,18 +1667,20 @@ int scsi_log_reply(unsigned char *opcode, int data_dir, unsigned char *data,
for (i = 0 ; i < l; i++)
fprintf(fp, " %2.2X", sense[i]);
fprintf(fp, "\n");
durtxt[0] = 0;
if (!(flag & 2))
sprintf(durtxt, " (%6d ms)", duration);
spc_decode_sense(sense, 0, &key, &asc, &ascq);
fprintf(fp, "+++ key=%X asc=%2.2Xh ascq=%2.2Xh\n",
fprintf(fp, "+++ key=%X asc=%2.2Xh ascq=%2.2Xh%s\n",
(unsigned int) key, (unsigned int) asc,
(unsigned int) ascq);
(unsigned int) ascq, durtxt);
} else {
scsi_show_command_reply(opcode, data_dir, data,
dxfer_len, fp, 0);
if (!(flag & 2))
fprintf(fp,"%6d ms\n", duration);
}
if (!(flag & 2))
fprintf(fp, " %8.f us [ %.f ]\n",
duration * 1.0e6,
(burn_get_time(0) - lib_start_time) * 1.0e6);
if (burn_sg_log_scsi & 4)
fflush(fp);
}
@ -1696,19 +1698,16 @@ int scsi_log_reply(unsigned char *opcode, int data_dir, unsigned char *data,
@param flag bit0 causes an error message
bit1 do not print duration
*/
int scsi_log_err(struct burn_drive *d, struct command *c,
void *fp_in, unsigned char sense[18],
int sense_len, int flag)
int scsi_log_err(struct command *c, void *fp_in, unsigned char sense[18],
int sense_len, int duration, int flag)
{
int ret;
unsigned char *data = NULL;
if (c->page != NULL)
data = c->page->data;
ret= scsi_log_reply(c->opcode, c->dir, data, c->dxfer_len ,
fp_in, sense, sense_len,
c->end_time - c->start_time, flag);
fp_in, sense, sense_len, duration, flag);
return ret;
}
@ -1721,7 +1720,7 @@ int scsi_log_err(struct burn_drive *d, struct command *c,
*/
int scsi_eval_cmd_outcome(struct burn_drive *d, struct command *c, void *fp,
unsigned char *sense, int sense_len,
time_t start_time, int timeout_ms,
int duration, time_t start_time, int timeout_ms,
int loop_count, int flag)
{
enum response outcome;
@ -1729,7 +1728,7 @@ int scsi_eval_cmd_outcome(struct burn_drive *d, struct command *c, void *fp,
char *msg = NULL;
if (burn_sg_log_scsi & 3)
scsi_log_err(d, c, fp, sense, sense_len,
scsi_log_err(c, fp, sense, sense_len, duration,
(sense_len > 0) | (flag & 2));
if (sense_len <= 0)
{done = 1; goto ex;}

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2006 - 2012 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -87,16 +87,15 @@ int scsi_log_cmd(struct command *c, void *fp, int flag);
*/
int scsi_log_reply(unsigned char *opcode, int data_dir, unsigned char *data,
int dxfer_len, void *fp_in, unsigned char sense[18],
int sense_len, double duration, int flag);
int sense_len, int duration, int flag);
/* ts A91221 (former sg_log_err ts A91108) */
/** Legacy frontend to scsi_log_reply().
@param flag bit0 causes an error message
bit1 do not print duration
*/
int scsi_log_err(struct burn_drive *d, struct command *c,
void *fp, unsigned char sense[18],
int sense_len, int flag);
int scsi_log_err(struct command *c, void *fp, unsigned char sense[18],
int sense_len, int duration, int flag);
/* ts B00728 */
int spc_decode_sense(unsigned char *sense, int senselen,
@ -110,7 +109,7 @@ int spc_decode_sense(unsigned char *sense, int senselen,
*/
int scsi_eval_cmd_outcome(struct burn_drive *d, struct command *c, void *fp_in,
unsigned char *sense, int sense_len,
time_t start_time, int timeout_ms,
int duration, time_t start_time, int timeout_ms,
int loop_count, int flag);

View File

@ -1,7 +1,7 @@
/* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */
/* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2006 - 2012 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -65,10 +65,6 @@ struct command
int retry;
struct buffer *page;
int timeout; /* milliseconds */
double start_time;
double end_time;
};
struct burn_scsi_inquiry_data

View File

@ -1,6 +1,6 @@
/* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens
Copyright (c) 2006 - 2013 Thomas Schmitt <scdbackup@gmx.net>
Copyright (c) 2006 - 2010 Thomas Schmitt <scdbackup@gmx.net>
Provided under GPL version 2 or later.
*/
@ -15,10 +15,6 @@
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <sys/time.h>
#include <unistd.h>
/* ts A80914 : This is unneeded. Version info comes from libburn.h.
#include "v ersion.h"
@ -332,49 +328,3 @@ char *burn_printify(char *msg)
return msg;
}
/* ts B30521 */
void burn_int_to_lsb(int val, char *target)
{
unsigned char *buf;
buf = (unsigned char *) target;
buf[0] = val & 0xff;
buf[1] = (val >> 8) & 0xff;
buf[2] = (val >> 16) & 0xff;
buf[3] = (val >> 24) & 0xff;
}
/* ts B30609 */
double burn_get_time(int flag)
{
int ret;
struct timeval tv;
#ifdef Libburn_use_clock_gettime_monotoniC
#ifdef _POSIX_TIMERS
#ifdef _POSIX_MONOTONIC_CLOCK
/* Enable by
export CFLAGS=-DLibburn_use_clock_gettime_monotoniC
export LIBS=-lrt
./configure ... && make clean && make
*/
struct timespec tp;
ret = clock_gettime(CLOCK_MONOTONIC, &tp);
if (ret == 0)
return ((double) tp.tv_sec) + ((double) tp.tv_nsec) * 1.0e-9;
#endif /* _POSIX_MONOTONIC_CLOCK */
#endif /* _POSIX_TIMERS */
#endif /* Xorriso_use_clock_gettime_monotoniC */
ret = gettimeofday(&tv, NULL);
if (ret == 0)
return ((double) tv.tv_sec) + ((double) tv.tv_usec) * 1.0e-6;
return (double) time(NULL);
}

View File

@ -8,10 +8,4 @@ int burn_util_make_printable_word(char **text, int flag);
char *burn_sfile_fgets(char *line, int maxl, FILE *fp);
char *burn_printify(char *msg);
/* ts B30521 */
void burn_int_to_lsb(int val, char *target);
/* ts B30609 */
double burn_get_time(int flag);
#endif

View File

@ -76,15 +76,11 @@ extern struct libdax_msgs *libdax_messenger;
/* The size to be used with BD-RE media in normal, not streamed mode.
*/
#define Libburn_bd_re_obS (64 * 1024)
#define Libburn_bd_re_obS (32 * 1024)
/* The size to be used with BD-R media in normal, not streamed mode.
/* The size to be used with BD-RE media in streamed mode.
*/
#define Libburn_bd_r_obS (64 * 1024)
/* The size to be used with BD-RE and BD-R media in streamed mode.
*/
#define Libburn_bd_streamed_obS (64 * 1024)
#define Libburn_bd_re_streamed_obS (64 * 1024)
static int type_to_ctrl(int mode)
@ -2311,7 +2307,7 @@ int burn_dvd_write_sync(struct burn_write_opts *o,
if (o->obs_pad < 2)
o->obs_pad = 1;
if (d->current_profile == 0x43) /* BD-RE */
o->obs = Libburn_bd_streamed_obS;
o->obs = Libburn_bd_re_streamed_obS;
}
} else if (d->current_profile == 0x13) {
@ -2389,12 +2385,10 @@ int burn_dvd_write_sync(struct burn_write_opts *o,
}
/* ??? padding needed ??? cowardly doing it for now */
if (o->obs_pad < 2)
o->obs_pad = 1; /* fill-up track's last obs buffer */
if (d->current_profile == 0x41) /* BD-R */
o->obs = Libburn_bd_r_obS;
o->obs_pad = 1; /* fill-up track's last 32k buffer */
if (d->do_stream_recording) {
if (d->current_profile == 0x41) /* BD-R */
o->obs = Libburn_bd_streamed_obS;
o->obs = Libburn_bd_re_streamed_obS;
}
}
@ -2424,10 +2418,10 @@ int burn_dvd_write_sync(struct burn_write_opts *o,
if (d->do_stream_recording &&
(d->current_profile == 0x43 || d->current_profile == 0x41) &&
o->obs < Libburn_bd_streamed_obS) {
o->obs < Libburn_bd_re_streamed_obS) {
/* LG GGW-H20 writes junk with stream recording and obs=32k */
sprintf(msg,
"Stream recording disabled because of small output buffer");
"Stream recording disabled because of small OS buffer");
libdax_msgs_submit(libdax_messenger, d->global_index,
0x00020176, LIBDAX_MSGS_SEV_NOTE,
LIBDAX_MSGS_PRIO_HIGH, msg, 0, 0);

View File

@ -119,6 +119,10 @@ int telltoc_aquire_by_adr(char *drive_adr)
int ret;
char libburn_drive_adr[BURN_DRIVE_ADR_LEN];
/* <<< ts A70907 FOR TESTING ONLY !
struct burn_drive_info *test_drive_list;
*/
/* This tries to resolve links or alternative device files */
ret = burn_drive_convert_fs_adr(drive_adr, libburn_drive_adr);
if (ret<=0) {
@ -127,6 +131,10 @@ int telltoc_aquire_by_adr(char *drive_adr)
return 0;
}
/* <<< ts A70907 FOR TESTING ONLY !
ret = burn_drive_scan_and_grab(&test_drive_list, "/dev/sg2", 1);
*/
fprintf(stderr,"Aquiring drive '%s' ...\n", libburn_drive_adr);
ret = burn_drive_scan_and_grab(&drive_list, libburn_drive_adr, 1);
@ -138,6 +146,10 @@ int telltoc_aquire_by_adr(char *drive_adr)
drive_is_grabbed = 1;
}
/* <<< ts A70907 FOR TESTING ONLY !
burn_drive_info_free(test_drive_list);
*/
return ret;
}