Compare commits

..

3 commits

Author SHA1 Message Date
Fedora Release Engineering
a8b461855b dist-git conversion 2010-07-29 15:34:41 +00:00
Bill Nottingham
9d2c3699e0 Fix typo that causes a failure to update the common directory. (releng
#2781)
2009-11-26 01:29:41 +00:00
Jesse Keating
3409c7a497 Initialize branch F-9 for xcdroast 2008-04-22 01:55:59 +00:00
26 changed files with 3041 additions and 1 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
xcdroast-0.98alpha15.tar.gz

View file

@ -1 +0,0 @@
Orphaned for 6+ weeks

1
sources Normal file
View file

@ -0,0 +1 @@
2a9c1d9f2ef58713c453e674b989be3e xcdroast-0.98alpha15.tar.gz

View file

@ -0,0 +1,92 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 01_upstream_configure.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/configure trunk/configure
--- trunk~/configure 2006-01-20 13:34:14.000000000 +0100
+++ trunk/configure 2006-01-20 13:51:55.000000000 +0100
@@ -4361,55 +4361,6 @@
LIBS="$LIBS $PKGCONFIG_LIBS"
CFLAGS="$CFLAGS $PKGCONFIG_CFLAGS"
- # Extract the first word of "pcre-config", so it can be a program name with args.
-set dummy pcre-config; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_path_PCRE_CONFIG+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- case $PCRE_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PCRE_CONFIG="$PCRE_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_PCRE_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
-done
-
- test -z "$ac_cv_path_PCRE_CONFIG" && ac_cv_path_PCRE_CONFIG="no"
- ;;
-esac
-fi
-PCRE_CONFIG=$ac_cv_path_PCRE_CONFIG
-
-if test -n "$PCRE_CONFIG"; then
- echo "$as_me:$LINENO: result: $PCRE_CONFIG" >&5
-echo "${ECHO_T}$PCRE_CONFIG" >&6
-else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
- if test "x$PCRE_CONFIG" = "xno" ; then
- { { echo "$as_me:$LINENO: error: pcre-config not found please install libpcre3-dev or similar" >&5
-echo "$as_me: error: pcre-config not found please install libpcre3-dev or similar" >&2;}
- { (exit 1); exit 1; }; }
- else
- LIBS="$LIBS `$PCRE_CONFIG --libs`"
- CFLAGS="$CFLAGS `$PCRE_CONFIG --cflags`"
- fi
-
else
@@ -9249,7 +9200,6 @@
s,@PKG_CONFIG@,$PKG_CONFIG,;t t
s,@PKGCONFIG_CFLAGS@,$PKGCONFIG_CFLAGS,;t t
s,@PKGCONFIG_LIBS@,$PKGCONFIG_LIBS,;t t
-s,@PCRE_CONFIG@,$PCRE_CONFIG,;t t
s,@GLIB_CONFIG@,$GLIB_CONFIG,;t t
s,@GLIB_CFLAGS@,$GLIB_CFLAGS,;t t
s,@GLIB_LIBS@,$GLIB_LIBS,;t t
diff -urNad trunk~/configure.in trunk/configure.in
--- trunk~/configure.in 2006-01-20 13:34:14.000000000 +0100
+++ trunk/configure.in 2006-01-20 13:51:58.000000000 +0100
@@ -105,14 +105,6 @@
LIBS="$LIBS $PKGCONFIG_LIBS"
CFLAGS="$CFLAGS $PKGCONFIG_CFLAGS"
- AC_PATH_PROG(PCRE_CONFIG, pcre-config, no)
- if test "x$PCRE_CONFIG" = "xno" ; then
- AC_MSG_ERROR(pcre-config not found please install libpcre3-dev or similar)
- else
- LIBS="$LIBS `$PCRE_CONFIG --libs`"
- CFLAGS="$CFLAGS `$PCRE_CONFIG --cflags`"
- fi
-
else
dnl pure plain GTK+-1.2.x support

View file

@ -0,0 +1,26 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 02_upstream_gtk2locale.patch.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/src/xtools.c trunk/src/xtools.c
--- trunk~/src/xtools.c 2006-01-20 16:07:46.000000000 +0100
+++ trunk/src/xtools.c 2006-01-20 16:08:06.000000000 +0100
@@ -3662,9 +3662,13 @@
if (c_locale_is_utf8)
return str;
- /* should be logical to use g_filename_from_utf8() here, but
- somehow this works not correctly on my testsystem */
+#ifdef BROKEN_GTK2_LOCALE
+ /* on my redhat 7.3 system it does only work that way, but
+ on other systems the correct way is in the #else branch */
locstr = g_locale_from_utf8(str, strlen(str), &in, &out, NULL);
+#else
+ locstr = g_filename_from_utf8(str, strlen(str), &in, &out, NULL);
+#endif
if (locstr) {
strncpy(str, locstr, MAXLINE);
}

View file

@ -0,0 +1,28 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 03_upstream_64bit_gsize.patch.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/src/xtools.c trunk/src/xtools.c
--- trunk~/src/xtools.c 2006-01-20 16:07:46.000000000 +0100
+++ trunk/src/xtools.c 2006-01-20 16:10:23.000000000 +0100
@@ -3635,7 +3635,7 @@
return str;
#else
gchar *locstr;
-gint in, out;
+gsize in, out;
locstr = g_locale_from_utf8(str, strlen(str), &in, &out, NULL);
if (locstr) {
@@ -3655,7 +3655,7 @@
return str;
#else
gchar *locstr;
-gint in, out;
+gsize in, out;
/* ok, if your filesystem is already UTF8 we are not
allowed to change the filenames here. */

View file

@ -0,0 +1,53 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 04_upstream_read_eagain.patch.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/src/tools.c trunk/src/tools.c
--- trunk~/src/tools.c 2006-01-20 16:15:30.000000000 +0100
+++ trunk/src/tools.c 2006-01-20 16:25:51.000000000 +0100
@@ -559,6 +559,33 @@
}
+/* read a single char from a file descriptor. If the descriptor
+ says that it is not available, then try again up to 5 times,
+ before giving up.
+ Required for Mac OS 10.3
+*/
+
+static gint read_char(gint fd, gchar *c) {
+gint rc;
+gint retries;
+
+ retries = 5;
+
+ while (retries) {
+ rc = read(fd, c, 1);
+
+ /* all ok, read one char or EOF */
+ if (rc != -1) {
+ return rc;
+ }
+
+ /* error code, try again after a little while */
+ usleep(100);
+ retries--;
+ }
+ return rc;
+}
+
/*
* Read a line from a descriptor. Read the line one byte at a time,
* looking for the newline. Works fine in nonblocking mode..here
@@ -576,7 +603,7 @@
str = ptr;
for (n = 1; n < maxlen; n++) {
- if ( (rc = read(fd, &c, 1)) == 1) {
+ if ( (rc = read_char(fd, &c)) == 1) {
*ptr++ = c;
if (c == '\n') {
break;

View file

@ -0,0 +1,356 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 05_upstream_wav.patch.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/src/main.h trunk/src/main.h
--- trunk~/src/main.h 2006-01-20 16:26:51.000000000 +0100
+++ trunk/src/main.h 2006-01-20 16:29:30.000000000 +0100
@@ -175,8 +175,7 @@
void wavplay_frontend(GtkWidget *widget);
void wavplay_dodouble();
-gint is_std_wav_file(guchar *hdr);
-gint is_in_cd_quality(guchar *hdr);
+off_t is_std_wav_file(int f, off_t *offset);
void dodebug(gint debuglevel, gchar *fmt, ...);
void dolog(gint loglevel, gchar *fmt, ...);
diff -urNad trunk~/src/wav_id.c trunk/src/wav_id.c
--- trunk~/src/wav_id.c 2006-01-20 16:29:11.000000000 +0100
+++ trunk/src/wav_id.c 2006-01-20 16:29:30.000000000 +0100
@@ -5,6 +5,11 @@
machine-independent (work both on big and little endian)
code to check if we have valid wavheader that is configured
for cd-quality (16 bit, stereo, 44.1kHz)
+
+ 01.04.04 steve wahl
+
+ Do correct RIFF parsing, don't assume a static header style.
+ Code borrowed from cdrecord.
*/
#ifdef HAVE_CONFIG_H
@@ -13,62 +18,147 @@
#include "largefile.h"
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <unistd.h>
#include <string.h>
#include <glib.h>
#include "xcdroast.h"
-/* check if valid wav-header */
-/* endian independent version */
-/* return 1 if true, 0 if not */
+typedef struct {
+ guchar ckid[4];
+ guchar cksize[4];
+} chunk_t;
-gint is_std_wav_file(guchar *hdr) {
-gchar tmp[MAXLINE];
-guint wFormatTag;
-guint fmtOffset;
+typedef struct {
+ guchar wave[4];
+} riff_chunk;
- strncpy(tmp,(char *) hdr+0,4);
- if (strncmp(tmp,"RIFF",4) != 0)
- return 0;
+typedef struct {
+ guchar fmt_tag[2];
+ guchar channels[2];
+ guchar sample_rate[4];
+ guchar av_byte_rate[4];
+ guchar block_size[2];
+ guchar bits_per_sample[2];
+} fmt_chunk;
- strncpy(tmp,(char *) hdr+8,4);
- if (strncmp(tmp,(char *)"WAVE",4) != 0)
- return 0;
+#define WAV_RIFF_MAGIC "RIFF" /* Magic for file format */
+#define WAV_WAVE_MAGIC "WAVE" /* Magic for Waveform Audio */
+#define WAV_FMT_MAGIC "fmt " /* Start of Waveform format */
+#define WAV_DATA_MAGIC "data" /* Start of data chunk */
+#define WAV_FORMAT_PCM 0x0001 /* Linear PCM format */
+#define WAV_FORMAT_ULAW 0x0101 /* American ISDN Telephonie */
+#define WAV_FORMAT_ALAW 0x0102 /* International ISDN Tel. */
+#define WAV_FORMAT_ADPCM 0x0103 /* ADPCM format */
- strncpy(tmp,(char *) hdr+12,4);
- if (strncmp(tmp,(char *)"fmt ",4) != 0)
- return 0;
+#define le_a_to_u_short(a) ((unsigned short) \
+ ((((unsigned char*) a)[0] & 0xFF) | \
+ (((unsigned char*) a)[1] << 8 & 0xFF00)))
- fmtOffset = (hdr[19]<<24) + (hdr[18]<<16) + (hdr[17]<<8) + hdr[16];
- strncpy(tmp,(char *) hdr+20+fmtOffset,4);
- if (strncmp(tmp,(char *)"data",4) != 0)
- return 0;
+#ifdef __STDC__
+#define le_a_to_u_long(a) ((unsigned long) \
+ ((((unsigned char*) a)[0] & 0xFF) | \
+ (((unsigned char*) a)[1] << 8 & 0xFF00) | \
+ (((unsigned char*) a)[2] << 16 & 0xFF0000) | \
+ (((unsigned char*) a)[3] << 24 & 0xFF000000UL)))
+#else
+#define le_a_to_u_long(a) ((unsigned long) \
+ ((((unsigned char*) a)[0] & 0xFF) | \
+ (((unsigned char*) a)[1] << 8 & 0xFF00) | \
+ (((unsigned char*) a)[2] << 16 & 0xFF0000) | \
+ (((unsigned char*) a)[3] << 24 & 0xFF000000)))
+#endif
- wFormatTag = (hdr[21] << 8) + hdr[20];
- if (wFormatTag != 1)
- return 0;
+/* check if valid wav-header */
+/* endian independent version */
+/* return number of bytes if valid, 0 if not */
+/* if offset is non NULL, place offset in file to base of wave data there */
+/* leaves file pointer at begining of wave data if valid */
- return 1;
-}
+off_t is_std_wav_file(gint f, off_t *offset)
+{
+ chunk_t chunk;
+ riff_chunk riff;
+ fmt_chunk fmt;
+ struct stat sb;
+ off_t cursor;
+ gint gotFormat;
+ mode_t mode;
+ off_t size;
+ /*
+ * First check if a bad guy tries to call wavsize()
+ * with an unappropriate file descriptor.
+ * return 0 in this case.
+ */
-/* check if wav-file is in cd-quality */
-/* endian independent version */
-/* return 1 if true, 0 if not */
+ if (isatty(f))
+ return (0);
+ if (fstat(f, &sb) < 0)
+ return (0);
+ mode = sb.st_mode & S_IFMT;
+ if (!S_ISREG(mode) && !S_ISBLK(mode) && !S_ISCHR(mode))
+ return (0);
-gint is_in_cd_quality(guchar *hdr) {
-guint nChannels;
-guint wBitsPerSample;
-guint nSamplesPerSec;
+ cursor = (off_t)0;
+ lseek(f, cursor, SEEK_SET);
+ gotFormat = FALSE;
- nChannels = (hdr[23] << 8) + hdr[22];
- wBitsPerSample = (hdr[35] << 8) + hdr[34];
- nSamplesPerSec = (hdr[27]<<24) + (hdr[26]<<16) + (hdr[25]<<8) + hdr[24];
+ for (;;) {
+ if (read(f, &chunk, sizeof (chunk)) != sizeof (chunk))
+ goto err;
+ size = (off_t)le_a_to_u_long(chunk.cksize);
- if (nChannels != 2 || wBitsPerSample != 16 ||
- nSamplesPerSec != 44100)
- return 0;
+ if (strncmp((char *)chunk.ckid, WAV_RIFF_MAGIC, 4) == 0) {
+ /*
+ * We found (first) RIFF header. Check if a WAVE
+ * magic follows. Set up size to be able to skip
+ * past this header.
+ */
+ if (read(f, &riff, sizeof (riff)) != sizeof (riff))
+ goto err;
+ if (strncmp((char *)riff.wave, WAV_WAVE_MAGIC, 4) != 0)
+ goto err;
+ size = (off_t)sizeof (riff);
- return 1;
+ } else if (strncmp((char *)chunk.ckid, WAV_FMT_MAGIC, 4) == 0) {
+ /*
+ * We found WAVE "fmt " header. Check size (if it is
+ * valid for a WAVE file) and coding whether it is
+ * useable for a CD.
+ */
+ if (size < (off_t)sizeof (fmt)) goto err;
+ if (sizeof (fmt) != read(f, &fmt, sizeof (fmt))) goto err;
+ if (le_a_to_u_short(fmt.channels) != 2 ||
+ le_a_to_u_long(fmt.sample_rate) != 44100 ||
+ le_a_to_u_short(fmt.bits_per_sample) != 16) {
+ goto err;
+ }
+ gotFormat = TRUE;
+
+ } else if (strncmp((char *)chunk.ckid, WAV_DATA_MAGIC, 4) == 0) {
+ /*
+ * We found WAVE "data" header. This contains the
+ * size value of the audio part.
+ */
+ if (!gotFormat) {
+ goto err;
+ }
+ if ((cursor + size + sizeof (chunk)) > sb.st_size)
+ size = sb.st_size - (cursor + sizeof (chunk));
+ if (offset)
+ *offset = cursor + sizeof (chunk) ;
+ return (size);
+ }
+ cursor += size + sizeof (chunk);
+ lseek(f, cursor, SEEK_SET); /* Skip over current chunk */
+ }
+err:
+ lseek(f, (off_t)0L, SEEK_SET);
+ return (0);
}
+
+
diff -urNad trunk~/src/wavplay.c trunk/src/wavplay.c
--- trunk~/src/wavplay.c 2006-01-20 16:27:15.000000000 +0100
+++ trunk/src/wavplay.c 2006-01-20 16:29:30.000000000 +0100
@@ -64,13 +64,12 @@
#include <dmedia/audio.h>
#endif
-static guchar waveHdr[44];
+static off_t waveBase ;
static gint abuf_size;
static guchar *audiobuf;
gint read_line(gint fd, gchar *ptr, gint maxlen);
-gint is_std_wav_file(guchar *hdr);
-gint is_in_cd_quality(guchar *hdr);
+off_t is_std_wav_file(int f, off_t *offset);
#if defined(linux) || defined(__FreeBSD__)
@@ -747,7 +746,6 @@
gint oldtick = 0;
off_t bytessofar = 0;
off_t totalbytes;
-struct stat stat_buf;
gint min,sec;
gchar keybuffer[MAXLINE];
#if !(defined(linux))
@@ -830,20 +828,11 @@
}
/* get filesize */
- fstat(fd, &stat_buf);
- totalbytes = (off_t) (stat_buf.st_size - (off_t)sizeof(waveHdr));
-
- read(fd, &waveHdr, sizeof(waveHdr));
+ totalbytes = is_std_wav_file(fd, &waveBase) ;
/* is it a wav-file? */
- if (!is_std_wav_file(waveHdr)) {
- g_warning("No valid wavfile\n");
- exit(0);
- }
-
- /* is it in cd-quality? */
- if (!is_in_cd_quality(waveHdr)) {
- g_warning("wavfile not in cd-quality\n");
+ if (totalbytes == 0) {
+ g_warning("No valid wavfile, or not in cd-quality\n");
exit(0);
}
@@ -871,7 +860,7 @@
if (guimode && (read_line(STDIN_FILENO,keybuffer,MAXLINE) > 0)) {
/* stop command */
if (g_strncasecmp(keybuffer,"stop",4) == 0) {
- lseek(fd, sizeof(waveHdr), SEEK_SET);
+ lseek(fd, waveBase, SEEK_SET);
bytessofar = 0;
tick = 0;
doplay = 0;
@@ -895,7 +884,7 @@
if (g_strncasecmp(keybuffer,"set",3) == 0) {
tick = atoi(keybuffer+3);
bytessofar = (off_t)tick *CDDAFRAME*75;
- lseek(fd, (off_t)sizeof(waveHdr)+bytessofar,
+ lseek(fd, waveBase+bytessofar,
SEEK_SET);
g_print("%s%d\n",doplay?"play":"stop",tick);
fflush(stdout);
@@ -911,7 +900,15 @@
if (doplay) {
/* read from wav-file */
- l = read(fd, audiobuf, abuf_size);
+ /* but only up until we reach totalbytes */
+ l = totalbytes - bytessofar ;
+ if (l > abuf_size)
+ l = abuf_size ;
+ if (l < 0)
+ l = 0 ;
+
+ if (l > 0)
+ l = read(fd, audiobuf, l);
if (l > 0) {
#if !(defined(linux))
/* turn byte order only on non linux platforms */
@@ -945,7 +942,7 @@
exit(-1);
}
#endif
- bytessofar+=(off_t)abuf_size;
+ bytessofar+=(off_t)l;
} else {
/* read error on wav-file */
@@ -958,7 +955,7 @@
doplay = 0;
if (guimode) {
/* roll back */
- lseek(fd, sizeof(waveHdr), SEEK_SET);
+ lseek(fd, waveBase, SEEK_SET);
bytessofar = 0;
tick = 0;
g_print("done%d\n",tick);
diff -urNad trunk~/src/xtools.c trunk/src/xtools.c
--- trunk~/src/xtools.c 2006-01-20 16:27:42.000000000 +0100
+++ trunk/src/xtools.c 2006-01-20 16:29:30.000000000 +0100
@@ -1851,7 +1851,6 @@
/* return 1 if, 0 if not */
gint check_wav_file(gchar *wavname) {
-guchar waveHdr[44];
gint fd;
fd = open (wavname, O_RDONLY, 0);
@@ -1859,16 +1858,8 @@
return 0;
}
- read(fd, &waveHdr, sizeof(waveHdr));
-
- if (!is_std_wav_file(waveHdr)) {
- /* no wav at all */
- close(fd);
- return 0;
- }
-
- /* is it in cd-quality? */
- if (!is_in_cd_quality(waveHdr)) {
+ if (!is_std_wav_file(fd, NULL)) {
+ /* no wav at all or not cd-quality */
close(fd);
return 0;
}

View file

@ -0,0 +1,19 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 06_man.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/man/xcdroast.1 trunk/man/xcdroast.1
--- trunk~/man/xcdroast.1 2006-01-20 17:39:36.000000000 +0100
+++ trunk/man/xcdroast.1 2006-01-20 17:40:40.000000000 +0100
@@ -84,7 +84,7 @@
fine.)
.SH BUGS
-This 'man' page is to short. Really useable information can be found
+This 'man' page is too short. Really useable information can be found
in the documentation included with X-CD-Roast, in the FAQ
on
.IR http://www.xcdroast.org/faq

View file

@ -0,0 +1,31 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 07_case_cmp.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/src/xtools.c trunk/src/xtools.c
--- trunk~/src/xtools.c 2006-01-20 17:09:43.000000000 +0100
+++ trunk/src/xtools.c 2006-01-20 18:28:52.000000000 +0100
@@ -974,9 +974,9 @@
isosize = 0;
/* now do some tests about file-contents */
- if (strncmp(file+strlen(file)-4,".toc",4) == 0) {
+ if (strncasecmp(file+strlen(file)-4,".toc",4) == 0) {
type = 4;
- } else if (strncmp(file+strlen(file)-4,".wav",4) == 0) {
+ } else if (strncasecmp(file+strlen(file)-4,".wav",4) == 0) {
/* wav-file */
if (check_wav_file(tmp) == 0) {
/* invalid wav */
@@ -1052,7 +1052,7 @@
/* skip to short filenames */
if (len2 < len) continue;
- if (strncmp((ent->d_name)+len2-len,img_ext[i],len) == 0) {
+ if (strncasecmp((ent->d_name)+len2-len,img_ext[i],len) == 0) {
/* we found a match */
analyze_imgfile(path,ent->d_name,retlist);
}

View file

@ -0,0 +1,22 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 08_desktop.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/extra/xcdroast.desktop trunk/extra/xcdroast.desktop
--- trunk~/extra/xcdroast.desktop 2006-01-20 13:34:14.000000000 +0100
+++ trunk/extra/xcdroast.desktop 2006-02-26 18:33:05.000000000 +0100
@@ -1,6 +1,8 @@
[Desktop Entry]
+Encoding=UTF-8
Name=X-CD-Roast
+Comment=Create a CD
+Exec=xcdroast
+Icon=xcdroast.xpm
Type=Application
-Exec=/usr/bin/xcdroast
-Comment=CD creation tool
-Icon=/usr/lib/xcdroast-0.98/icons/xcdricon.png
+Categories=Application;AudioVideo;

View file

@ -0,0 +1,512 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 09_share_dir.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: Patch to provide different paths to /usr/lib and /usr/share.
@DPATCH@
diff -urNad trunk~/Makefile.in trunk/Makefile.in
--- trunk~/Makefile.in 2006-05-06 15:54:43.000000000 +0200
+++ trunk/Makefile.in 2006-05-06 15:55:04.000000000 +0200
@@ -108,6 +108,7 @@
USE_NONROOTMODE = @USE_NONROOTMODE@
VERSION = @VERSION@
XCDRLIB_PREFIX = @XCDRLIB_PREFIX@
+XCDRSHARE_PREFIX = @XCDRSHARE_PREFIX@
am__include = @am__include@
am__quote = @am__quote@
install_sh = @install_sh@
diff -urNad trunk~/acinclude.m4 trunk/acinclude.m4
--- trunk~/acinclude.m4 2006-05-06 15:18:20.000000000 +0200
+++ trunk/acinclude.m4 2006-05-06 15:54:54.000000000 +0200
@@ -24,7 +24,7 @@
AC_DEFUN(AM_PATH_XCDRLIBDIR,
[ AC_ARG_WITH(xcdroast-libdir-prefix,
AC_HELP_STRING([--with-xcdroast-libdir-prefix=PFX],
- [set where the utils/images of xcdroast should be installed - default: PREFIX/lib/xcdroast-0.98]),
+ [set where the utils of xcdroast should be installed - default: PREFIX/lib/xcdroast-0.98]),
xcdrlibdir_config_prefix="$withval", xcdrlibdir_config_prefix="")
if test "x$xcdrlibdir_config_prefix" = "x"; then
@@ -38,6 +38,26 @@
AC_SUBST(XCDRLIB_PREFIX)
])
+dnl AM_PATH_XCDRSHAREDIR([MINIMUM-VERSION,
+dnl [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
+dnl
+AC_DEFUN(AM_PATH_XCDRSHAREDIR,
+[ AC_ARG_WITH(xcdroast-sharedir-prefix,
+ AC_HELP_STRING([--with-xcdroast-sharedir-prefix=PFX],
+ [set where the images of xcdroast should be installed - default: PREFIX/share/xcdroast-0.98]),
+ xcdrsharedir_config_prefix="$withval", xcdrsharedir_config_prefix="")
+
+ if test "x$xcdrsharedir_config_prefix" = "x"; then
+ XCDRSHARE_PREFIX="$prefix/share/xcdroast-0.98"
+ else
+ XCDRSHARE_PREFIX=$xcdrsharedir_config_prefix
+ fi
+ if test "X$XCDRSHARE_PREFIX" = "XNONE/share/xcdroast-0.98"; then
+ XCDRSHARE_PREFIX="$ac_default_prefix/share/xcdroast-0.98"
+ fi
+ AC_SUBST(XCDRSHARE_PREFIX)
+])
+
dnl AM_DEP_NONROOTMODE([MINIMUM-VERSION,
dnl [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
dnl
diff -urNad trunk~/aclocal.m4 trunk/aclocal.m4
--- trunk~/aclocal.m4 2006-05-06 15:18:20.000000000 +0200
+++ trunk/aclocal.m4 2006-05-06 15:54:54.000000000 +0200
@@ -51,6 +51,26 @@
AC_SUBST(XCDRLIB_PREFIX)
])
+dnl AM_PATH_XCDRSHAREDIR([MINIMUM-VERSION,
+dnl [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
+dnl
+AC_DEFUN(AM_PATH_XCDRSHAREDIR,
+[ AC_ARG_WITH(xcdroast-sharedir-prefix,
+ AC_HELP_STRING([--with-xcdroast-sharedir-prefix=PFX],
+ [set where the images of xcdroast should be installed - default: PREFIX/share/xcdroast-0.98]),
+ xcdrsharedir_config_prefix="$withval", xcdrsharedir_config_prefix="")
+
+ if test "x$xcdrsharedir_config_prefix" = "x"; then
+ XCDRSHARE_PREFIX="$prefix/share/xcdroast-0.98"
+ else
+ XCDRSHARE_PREFIX=$xcdrsharedir_config_prefix
+ fi
+ if test "X$XCDRSHARE_PREFIX" = "XNONE/share/xcdroast-0.98"; then
+ XCDRSHARE_PREFIX="$ac_default_prefix/share/xcdroast-0.98"
+ fi
+ AC_SUBST(XCDRSHARE_PREFIX)
+])
+
dnl AM_DEP_NONROOTMODE([MINIMUM-VERSION,
dnl [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
dnl
diff -urNad trunk~/configure.in trunk/configure.in
--- trunk~/configure.in 2006-05-06 15:54:54.000000000 +0200
+++ trunk/configure.in 2006-05-06 15:54:54.000000000 +0200
@@ -96,6 +96,7 @@
AM_PATH_CDRTOOLS
AM_PATH_XCDRLIBDIR
+AM_PATH_XCDRSHAREDIR
AM_DEP_NONROOTMODE
AM_DEP_ENABLEGTK2
diff -urNad trunk~/src/Makefile.am trunk/src/Makefile.am
--- trunk~/src/Makefile.am 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/Makefile.am 2006-05-06 15:54:54.000000000 +0200
@@ -23,7 +23,7 @@
setup.c io.c duplicate.c wav_frontend.c wav_id.c create.c \
largefile.h language.h main.h xcdrdata.h xcdroast.h gettext.h
-xcdroast_CFLAGS = $(GNUCFLAGS) $(GDK_PIXBUF_CFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
+xcdroast_CFLAGS = $(GNUCFLAGS) $(GDK_PIXBUF_CFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DPRE_SHAREDIR="\"$(XCDRSHARE_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
xcdroast_LDFLAGS = $(EXTRA_LDFLAGS)
xcdroast_LDADD = @LIBINTL@ @ALLOCA@ $(GTK_LIBS) $(GDK_PIXBUF_LIBS) $(AUDIO_LIBS)
@@ -48,5 +48,5 @@
cddbtool_LDADD = $(GLIB_LIBS)
xcdrwrap_SOURCES = xcdrwrap.c largefile.h xcdroast.h
-xcdrwrap_CFLAGS = $(GNUCFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
+xcdrwrap_CFLAGS = $(GNUCFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DPRE_SHAREDIR="\"$(XCDRSHARE_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
diff -urNad trunk~/src/Makefile.in trunk/src/Makefile.in
--- trunk~/src/Makefile.in 2006-05-06 15:54:37.000000000 +0200
+++ trunk/src/Makefile.in 2006-05-06 15:55:04.000000000 +0200
@@ -108,6 +108,7 @@
USE_NONROOTMODE = @USE_NONROOTMODE@
VERSION = @VERSION@
XCDRLIB_PREFIX = @XCDRLIB_PREFIX@
+XCDRSHARE_PREFIX = @XCDRSHARE_PREFIX@
am__include = @am__include@
am__quote = @am__quote@
install_sh = @install_sh@
@@ -134,7 +135,7 @@
largefile.h language.h main.h xcdrdata.h xcdroast.h gettext.h
-xcdroast_CFLAGS = $(GNUCFLAGS) $(GDK_PIXBUF_CFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
+xcdroast_CFLAGS = $(GNUCFLAGS) $(GDK_PIXBUF_CFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DPRE_SHAREDIR="\"$(XCDRSHARE_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
xcdroast_LDFLAGS = $(EXTRA_LDFLAGS)
xcdroast_LDADD = @LIBINTL@ @ALLOCA@ $(GTK_LIBS) $(GDK_PIXBUF_LIBS) $(AUDIO_LIBS)
@@ -159,7 +160,7 @@
cddbtool_LDADD = $(GLIB_LIBS)
xcdrwrap_SOURCES = xcdrwrap.c largefile.h xcdroast.h
-xcdrwrap_CFLAGS = $(GNUCFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
+xcdrwrap_CFLAGS = $(GNUCFLAGS) $(EXTRA_CFLAGS) $(AM_CFLAGS) -DPRE_PREFIX="\"$(prefix)\"" -DPRE_LIBDIR="\"$(XCDRLIB_PREFIX)\"" -DPRE_SHAREDIR="\"$(XCDRSHARE_PREFIX)\"" -DCDRTOOLS_PREFIX="\"$(CDRTOOLS_PREFIX)\"" -DSYSCONFDIR="\"$(sysconfdir)\"" -DUSE_NONROOTMODE="$(USE_NONROOTMODE)"
subdir = src
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = $(top_builddir)/config.h
diff -urNad trunk~/src/init.c trunk/src/init.c
--- trunk~/src/init.c 2006-05-06 15:52:32.000000000 +0200
+++ trunk/src/init.c 2006-05-06 15:54:54.000000000 +0200
@@ -73,6 +73,7 @@
gchar username[MAXLINE];
gchar configdir[MAXLINE];
gchar sharedir[MAXLINE];
+gchar libdir[MAXLINE];
gchar rootconfig[MAXLINE];
gchar prefixdir[MAXLINE];
gint support_ontheflyaudio;
@@ -499,13 +500,13 @@
gtk_exit(1);
}
- g_snprintf(tmp,MAXLINE,"%s/%s", sharedir, WAVPLAY);
+ g_snprintf(tmp,MAXLINE,"%s/%s", libdir, WAVPLAY);
check_executable(tmp,NULL,1);
- g_snprintf(tmp,MAXLINE,"%s/%s", sharedir, RMTOOL);
+ g_snprintf(tmp,MAXLINE,"%s/%s", libdir, RMTOOL);
check_executable(tmp,NULL,1);
- g_snprintf(tmp,MAXLINE,"%s/%s", sharedir, VRFYTOOL);
+ g_snprintf(tmp,MAXLINE,"%s/%s", libdir, VRFYTOOL);
check_executable(tmp,NULL,1);
- g_snprintf(tmp,MAXLINE,"%s/%s", sharedir, CDDBTOOL);
+ g_snprintf(tmp,MAXLINE,"%s/%s", libdir, CDDBTOOL);
check_executable(tmp,NULL,1);
return isProDVD;
@@ -520,7 +521,7 @@
gchar tmp[MAXLINE];
gint stat;
- g_snprintf(tmp,MAXLINE,"%s/%s", sharedir, WRAPPER);
+ g_snprintf(tmp,MAXLINE,"%s/%s", libdir, WRAPPER);
check_executable(tmp,NULL,1);
/* security check. If this fails then the wrapper is wrong */
@@ -662,7 +663,7 @@
nofail = 1;
/* first check if the wrapper got the correct permissions */
- g_snprintf(tmp,MAXLINE,"%s/%s", sharedir, WRAPPER);
+ g_snprintf(tmp,MAXLINE,"%s/%s", libdir, WRAPPER);
wrap_uid = get_file_owner(tmp);
wrap_gid = sgid_set(tmp);
@@ -764,7 +765,7 @@
g_print("Options:\n");
g_print("\t-d <debug level>\n");
g_print("\t-c <config directory> (currently: %s)\n", configdir);
- g_print("\t-l <lib directory> (currently: %s)\n", sharedir);
+ g_print("\t-l <lib directory> (currently: %s)\n", libdir);
/* g_print("\t-r <root config-file> (currently: %s)\n", rootconfig); */
g_print("\t-o : Disable multibyte font support\n");
g_print("\t-n : Disable cdrtools version check (use at own risk)\n");
@@ -813,11 +814,17 @@
writerreaderdevs = NULL;
#ifdef PRE_LIBDIR
- /* use prefix as sharedir as it came from the makefile-option */
- strncpy(sharedir, PRE_LIBDIR, MAXLINE);
+ /* use prefix as libdir as it came from the makefile-option */
+ strncpy(libdir, PRE_LIBDIR, MAXLINE);
#else
/* otherwise install our default prefix */
- strncpy(sharedir, LIBDIR, MAXLINE);
+ strncpy(libdir, LIBDIR, MAXLINE);
+#endif
+
+#ifdef PRE_SHAREDIR
+ strncpy(sharedir, PRE_SHAREDIR, MAXLINE);
+#else
+ strncpy(sharedir, SHAREDIR, MAXLINE);
#endif
#ifdef CDRTOOLS_PREFIX
@@ -851,7 +858,7 @@
break;
*/
case 'l':
- strncpy(sharedir, optarg, MAXLINE);
+ strncpy(libdir, optarg, MAXLINE);
break;
case 'a':
@@ -908,7 +915,7 @@
dodebug(1, "debug level: %d\n", debug);
dodebug(1, "configdir: %s\n", configdir);
dodebug(1, "rootconfig: %s\n", rootconfig);
- dodebug(1, "libdir: %s\n",sharedir);
+ dodebug(1, "libdir: %s\n",libdir);
dodebug(1, "checking large file support: sizeof(off_t) = %d\n", sizeof(off_t));
/* gettext stuff */
diff -urNad trunk~/src/io.c trunk/src/io.c
--- trunk~/src/io.c 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/io.c 2006-05-06 15:54:54.000000000 +0200
@@ -114,6 +114,7 @@
extern gchar hostname[MAXLINE];
extern gchar username[MAXLINE];
extern gchar sharedir[MAXLINE];
+extern gchar libdir[MAXLINE];
extern gchar configdir[MAXLINE];
extern gchar prefixdir[MAXLINE];
extern GtkWidget *cddb_info_label;
@@ -7863,7 +7864,7 @@
gtk_label_set_text(GTK_LABEL(readtrack_info_label), _("Deleting tracks..."));
/* build of command line */
- g_snprintf(orgcmd,MAXLINE,"%s/%s ", sharedir, RMTOOL);
+ g_snprintf(orgcmd,MAXLINE,"%s/%s ", libdir, RMTOOL);
strcpy(cmd,orgcmd);
length = g_list_length(delfiles);
@@ -8094,7 +8095,7 @@
/* always verify in 512 bytes blocks */
g_snprintf(cmd2,MAXLINE,"%s/%s -b \"%s\" -",
- sharedir, VRFYTOOL, convert_escape(tmptmp));
+ libdir, VRFYTOOL, convert_escape(tmptmp));
dodebug(1, "spawning: %s | %s\n",cmd,cmd2);
dolog(2, "Verify data track %s\n", fname);
@@ -8224,7 +8225,7 @@
strcpy(tmptmp,fname);
g_snprintf(cmd2,MAXLINE,"%s/%s -a \"%s\" -",
- sharedir, VRFYTOOL, convert_escape(tmptmp));
+ libdir, VRFYTOOL, convert_escape(tmptmp));
dodebug(1, "spawning: %s | %s\n",cmd,cmd2);
dolog(2, "Verify audio track %s\n", fname);
@@ -8521,7 +8522,7 @@
if (setupdata.cddb_use_http == 0) {
g_snprintf(cmd,MAXLINE,
"%s/%s -s \"%s\" -p %d -u \"%s\" -h \"%s\" -q \"%s\"",
- sharedir, CDDBTOOL, tmp_cddbhost, setupdata.cddb_port,
+ libdir, CDDBTOOL, tmp_cddbhost, setupdata.cddb_port,
username, hostname, tmp);
} else {
/* we want to use http */
@@ -8529,13 +8530,13 @@
/* but no proxy */
g_snprintf(cmd,MAXLINE,
"%s/%s -s \"%s\" -u \"%s\" -h \"%s\" -H -q \"%s\"",
- sharedir, CDDBTOOL, tmp_cddbhost,
+ libdir, CDDBTOOL, tmp_cddbhost,
username, hostname, tmp);
} else {
/* http with proxy */
g_snprintf(cmd,MAXLINE,
"%s/%s -s \"%s\" -u \"%s\" -h \"%s\" -U \"%s\" -P %d -q \"%s\"",
- sharedir, CDDBTOOL, tmp_cddbhost,
+ libdir, CDDBTOOL, tmp_cddbhost,
username, hostname, tmp_cddbproxy,
setupdata.cddb_proxy_port, tmp);
}
@@ -8593,8 +8594,8 @@
FILE *fpin;
/* allocate memory */
- g_snprintf(line,MAXLINE,"%s/%s -d \"%s\" \"%s/%s\" 2>&1", sharedir,
- WAVPLAY, setupdata.dsp_device, sharedir, DSPTESTSOUND);
+ g_snprintf(line,MAXLINE,"%s/%s -d \"%s\" \"%s/%s\" 2>&1", libdir,
+ WAVPLAY, setupdata.dsp_device, libdir, DSPTESTSOUND);
dodebug(1, "calling: %s\n", line);
@@ -10224,8 +10225,8 @@
if (strncmp(line,"X-CD-Roast ", 11) == 0) {
strcpy(xcdrver,line+11);
}
- if (strncmp(line,"sharedir: ", 10) == 0) {
- strcpy(sharever,line+10);
+ if (strncmp(line,"libdir: ", 8) == 0) {
+ strcpy(sharever,line+8);
}
if (strncmp(line,"prefixdir: ", 11) == 0) {
strcpy(prefixver,line+11);
@@ -10254,9 +10255,9 @@
tmp, xcdrver, XCDROAST_VERSION);
ret = 1;
}
- if (strcmp(sharever,sharedir) != 0) {
- fprintf(stderr, "WARNING: Wrapper %s configured\n\tsharedir %s instead of %s\n",
- tmp, sharever, sharedir);
+ if (strcmp(sharever,libdir) != 0) {
+ fprintf(stderr, "WARNING: Wrapper %s configured\n\tlibdir %s instead of %s\n",
+ tmp, sharever, libdir);
ret = 0;
}
if (strcmp(prefixver,prefixdir) != 0) {
@@ -10370,7 +10371,7 @@
#endif
/* set the correct permissions to the wrapper */
- g_snprintf(bin,MAXLINE,"%s/%s", sharedir, WRAPPER);
+ g_snprintf(bin,MAXLINE,"%s/%s", libdir, WRAPPER);
g_snprintf(tmp,MAXLINE,"%s root %s\n", cmd_chown, bin);
strcat(ret,tmp);
#if 0
@@ -10456,7 +10457,7 @@
}
free_nonrootvalues(&nrs_vals);
#endif
- g_snprintf(bin,MAXLINE,"%s/%s", sharedir, WRAPPER);
+ g_snprintf(bin,MAXLINE,"%s/%s", libdir, WRAPPER);
g_snprintf(tmp,MAXLINE,"%s 755 %s\n", cmd_chmod, bin);
strcat(ret,tmp);
}
diff -urNad trunk~/src/main.c trunk/src/main.c
--- trunk~/src/main.c 2006-05-06 15:52:28.000000000 +0200
+++ trunk/src/main.c 2006-05-06 15:54:54.000000000 +0200
@@ -57,6 +57,7 @@
static gint lastxsize, lastysize;
extern gchar sharedir[MAXLINE];
+extern gchar libdir[MAXLINE];
extern gchar rootconfig[MAXLINE];
extern gchar xcdroast_version_loaded[MAXLINE];
diff -urNad trunk~/src/menus.c trunk/src/menus.c
--- trunk~/src/menus.c 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/menus.c 2006-05-06 15:54:54.000000000 +0200
@@ -72,6 +72,7 @@
extern GList *tocfiles;
extern gint read_abort_mark;
extern gchar sharedir[MAXLINE];
+extern gchar libdir[MAXLINE];
extern GtkWidget *cdlist_l1, *imglist_l2;
extern GtkCList *cdlist, *imglist2;
extern gchar configdir[MAXLINE];
diff -urNad trunk~/src/setup.c trunk/src/setup.c
--- trunk~/src/setup.c 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/setup.c 2006-05-06 15:54:54.000000000 +0200
@@ -61,6 +61,7 @@
extern gchar rootconfig[MAXLINE];
extern gchar xcdroast_version_loaded[MAXLINE];
extern gchar sharedir[MAXLINE];
+extern gchar libdir[MAXLINE];
extern gint altdevscan;
extern gchar security_key[MAXLINE];
diff -urNad trunk~/src/wav_frontend.c trunk/src/wav_frontend.c
--- trunk~/src/wav_frontend.c 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/wav_frontend.c 2006-05-06 15:54:54.000000000 +0200
@@ -50,6 +50,7 @@
extern setup_data_t setupdata;
extern GList *imagelist;
extern gchar sharedir[MAXLINE];
+extern gchar libdir[MAXLINE];
gint wav_in, wavplay_quit;
GtkWidget *wav_quit_button;
@@ -157,7 +158,7 @@
}
strcpy(tmptmp,filename);
- g_snprintf(cmd,MAXLINE,"%s/%s -g -d \"%s\" \"%s\" 2>&1", sharedir, WAVPLAY,
+ g_snprintf(cmd,MAXLINE,"%s/%s -g -d \"%s\" \"%s\" 2>&1", libdir, WAVPLAY,
setupdata.dsp_device, convert_escape(tmptmp));
dodebug(1, "spawning shell: %s\n",cmd);
diff -urNad trunk~/src/xcdroast.h trunk/src/xcdroast.h
--- trunk~/src/xcdroast.h 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/xcdroast.h 2006-05-06 15:54:54.000000000 +0200
@@ -174,6 +174,7 @@
/* default paths/configfile */
#define PREFIX "/usr/local"
#define LIBDIR "lib/xcdroast-0.98"
+#define SHAREDIR "share/xcdroast-0.98"
#define CONFIGDIR "~/.xcdroast"
#define CONFFILE "xcdr098.cfg"
#define LOGFILE "xcdr098.log"
diff -urNad trunk~/src/xcdrwrap.c trunk/src/xcdrwrap.c
--- trunk~/src/xcdrwrap.c 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/xcdrwrap.c 2006-05-06 15:54:54.000000000 +0200
@@ -91,6 +91,7 @@
static char sharedir[MAXLINE];
+static char libdir[MAXLINE];
static char prefixdir[MAXLINE];
static char rootconfig[MAXLINE];
static char username[MAXLINE];
@@ -298,6 +299,7 @@
}
if (strncmp(cmd,"-V",MAXLINE) == 0) {
printf("X-CD-Roast %s\n", XCDROAST_VERSION);
+ printf("libdir: %s\n", libdir);
printf("sharedir: %s\n", sharedir);
printf("prefixdir: %s\n", prefixdir);
@@ -359,8 +361,8 @@
return;
}
- /* otherwise its relative - add sharedir first */
- snprintf(ret,MAXLINE,"%s/%s", sharedir, app);
+ /* otherwise its relative - add libdir first */
+ snprintf(ret,MAXLINE,"%s/%s", libdir, app);
/* now check if this file does exist */
if (stat(ret,&buf) != 0) {
@@ -613,11 +615,13 @@
seen_device_spec = 0;
#ifdef PRE_LIBDIR
- /* use prefix as sharedir as it came from the makefile-option */
- strncpy(sharedir, PRE_LIBDIR, MAXLINE);
+ /* use prefix as libdir as it came from the makefile-option */
+ strncpy(libdir, PRE_LIBDIR, MAXLINE);
+ strncpy(sharedir, PRE_SHAREDIR, MAXLINE);
#else
/* otherwise install our default prefix */
- strncpy(sharedir, LIBDIR, MAXLINE);
+ strncpy(libdir, LIBDIR, MAXLINE);
+ strncpy(sharedir, SHAREDIR, MAXLINE);
#endif
#ifdef CDRTOOLS_PREFIX
diff -urNad trunk~/src/xtools.c trunk/src/xtools.c
--- trunk~/src/xtools.c 2006-05-06 15:54:54.000000000 +0200
+++ trunk/src/xtools.c 2006-05-06 15:54:54.000000000 +0200
@@ -58,6 +58,7 @@
extern gint bigfonts;
extern gint oldfontcode;
extern gchar sharedir[MAXLINE];
+extern gchar libdir[MAXLINE];
extern gchar prefixdir[MAXLINE];
extern gint c_locale_is_utf8;
@@ -2361,8 +2362,8 @@
return;
}
- /* otherwise its relative - add sharedir first */
- g_snprintf(ret,MAXLINE,"%s/%s", sharedir, app);
+ /* otherwise its relative - add libdir first */
+ g_snprintf(ret,MAXLINE,"%s/%s", libdir, app);
/* now check if this file does exist */
if (stat(ret,&buf) != 0) {
@@ -2380,7 +2381,7 @@
gchar *get_wrap_path(gchar *cmd, gchar *ret) {
gchar tmp[MAXLINE];
- g_snprintf(tmp,MAXLINE,"%s/%s %s", sharedir, WRAPPER, cmd);
+ g_snprintf(tmp,MAXLINE,"%s/%s %s", libdir, WRAPPER, cmd);
strncpy(ret, tmp, MAXLINE);
return ret;
@@ -2394,10 +2395,10 @@
/* use DVD version if installed and media type > 1GB */
if (curset.isProDVD && curset.cdrtype > 1000) {
- g_snprintf(tmp,MAXLINE,"%s/%s %s", sharedir, WRAPPER,
+ g_snprintf(tmp,MAXLINE,"%s/%s %s", libdir, WRAPPER,
"CDRECORDPRODVD");
} else {
- g_snprintf(tmp,MAXLINE,"%s/%s %s", sharedir, WRAPPER,
+ g_snprintf(tmp,MAXLINE,"%s/%s %s", libdir, WRAPPER,
"CDRECORD");
}
strncpy(ret, tmp, MAXLINE);

View file

@ -0,0 +1,56 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 10_cddbtool.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: Patch to suppor sending utf8 char when using gtk2.
## DP: Provided by Robert Grimm. #336202
@DPATCH@
diff -urNad trunk~/src/cddbtool.c trunk/src/cddbtool.c
--- trunk~/src/cddbtool.c 2006-05-04 13:39:56.000000000 +0200
+++ trunk/src/cddbtool.c 2006-05-04 13:40:52.000000000 +0200
@@ -46,7 +46,11 @@
#define CDDB_HTTP_CMD "GET http://%s/~cddb/cddb.cgi?cmd="
#define CDDB_HTTP_KEEP " HTTP/1.0\r\nHost: %s\r\nConnection: Keep-Alive\r\nProxy-Connection: Keep-Alive\r\n%s\r\n"
+#if GTK_MAJOR_VERSION < 2
#define CDDB_HTTP_HELLO "hello=%s+%s+xcdroast+%s&proto=1"CDDB_HTTP_KEEP
+#else
+#define CDDB_HTTP_HELLO "hello=%s+%s+xcdroast+%s&proto=6"CDDB_HTTP_KEEP
+#endif
#define CDDB_HTTP_STAT CDDB_HTTP_CMD"stat&"CDDB_HTTP_HELLO
#define CDDB_HTTP_MOTD CDDB_HTTP_CMD"motd&"CDDB_HTTP_HELLO
#define CDDB_HTTP_QUERY CDDB_HTTP_CMD"cddb+query+%s&"CDDB_HTTP_HELLO
@@ -240,11 +244,30 @@
fflush(stdout);
return 1;
}
-
+
+#if GTK_MAJOR_VERSION > 1
+
+ g_snprintf(tmp,MAXLINE,"%s %d\r\n", "proto", 6);
+ if (writen(sockfd,tmp,strlen(tmp), 1) != strlen(tmp)) {
+ g_print("Error: write error on socket when setting protocol\n");
+ fflush(stdout);
+ return 1;
+ }
+ n = read_line2(sockfd, tmp, MAXLINE, 1);
+ if (n < 0) {
+ g_print("Error: read error on socket when setting protocol\n");
+ fflush(stdout);
+ return 1;
+ }
+#endif
code = get_cddb_code(tmp);
switch(code) {
- /* all ok */
+ /* all ok */
+#if GTK_MAJOR_VERSION < 2
case 200:
+#else
+ case 201:
+#endif
return 0;
/* handshake failed */

View file

@ -0,0 +1,29 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 11_mkisofs_options.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: Support for changes on mkisofs.
@DPATCH@
Index: src/io.c
===================================================================
--- src/io.c.orig 2006-11-05 12:52:46.000000000 +0100
+++ src/io.c 2006-11-05 12:52:55.000000000 +0100
@@ -9027,7 +9027,7 @@
strcat(tmp2,"-D ");
}
if (masterparam.opt[7]) {
- strcat(tmp2,"-L ");
+ strcat(tmp2,"-allow-leading-dots ");
}
if (masterparam.opt[8]) {
strcat(tmp2,"-d ");
@@ -9161,7 +9161,7 @@
}
if (masterparam.publisher) {
strcpy(tmptmp, masterparam.publisher);
- g_snprintf(tmp5,MAXLINE,"-P \"%s\" ",
+ g_snprintf(tmp5,MAXLINE,"-publisher \"%s\" ",
convert_escape(tmptmp));
strcat(tmp4,tmp5);
}

View file

@ -0,0 +1,21 @@
#! /bin/sh /usr/share/dpatch/dpatch-run
## 12_cdrecord_versions.dpatch by <Hector Garcia <hector@debian.org>>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad trunk~/src/xcdroast.h trunk/src/xcdroast.h
--- trunk~/src/xcdroast.h 2006-05-06 15:18:20.000000000 +0200
+++ trunk/src/xcdroast.h 2006-05-08 11:47:57.000000000 +0200
@@ -124,8 +124,8 @@
IT WONT WORK WITH LOWER VERSIONS, EVEN WHEN YOU THINK IT DOES! */
#define CDRECORD_VERSION "1.11a34"
-#define CDRECORD_PRODVD_VERSION "2.01a11"
-#define CDRECORD_VERSION_WITH_ONTHFLYAUDIO "2.01a13"
+#define CDRECORD_PRODVD_VERSION "2.01.01"
+#define CDRECORD_VERSION_WITH_ONTHFLYAUDIO "2.01.01"
#define MKISOFS_VERSION "1.15a17"
#define CDDA2WAV_VERSION "1.11a34"
#define READCD_VERSION "1.11a34"

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,17 @@
Index: src/io.c
===================================================================
--- src/io.c.orig 2006-12-19 13:02:15.000000000 +0100
+++ src/io.c 2006-12-19 13:18:53.000000000 +0100
@@ -985,7 +985,11 @@
/* add the found devices to the writerreader structure */
count = 0;
- g_snprintf(tmp,MAXLINE,"%s:", transport);
+ if (strstr(transport,"ATAPI")) {
+ g_snprintf(tmp,MAXLINE,"OLD%s:", transport);
+ } else {
+ g_snprintf(tmp,MAXLINE,"%s:", transport);
+ }
while(scsidevices[count] != NULL) {
add_writerreader(scsidevices[count], tmp, txt);
g_free(scsidevices[count]);

View file

@ -0,0 +1,22 @@
diff -urip xcdroast-0.98+0alpha15/src/io.c xcdroast-0.98+0alpha15-fixed/src/io.c
--- xcdroast-0.98+0alpha15/src/io.c 2003-10-26 15:24:48.000000000 +0100
+++ xcdroast-0.98+0alpha15-fixed/src/io.c 2007-01-17 23:04:29.000000000 +0100
@@ -10143,6 +10143,10 @@ gchar *p;
g_error("popen error\n");
}
+ /* all versions of readom is good enough! */
+ return 0;
+
+#if 0
strcpy(line,"");
for (;;) {
if (fgets(line,MAXLINE,fpin) == NULL)
@@ -10185,6 +10189,7 @@ gchar *p;
strcpy(found,ver);
return 1;
}
+#endif
}

View file

@ -0,0 +1,84 @@
diff -ur xcdroast-0.98alpha15/src/main.h xcdroast-0.98alpha15.new/src/main.h
--- xcdroast-0.98alpha15/src/main.h 2003-10-30 13:49:04.000000000 +0100
+++ xcdroast-0.98alpha15.new/src/main.h 2004-12-15 10:21:34.000000000 +0100
@@ -137,6 +137,7 @@
gint determine_cd_type(gchar *ret, gint mode);
gint determine_free_space(gint *biggestfree);
gint read_line(gint fd, gchar *ptr, gint maxlen);
+gint read_line_wait(gint fd, gchar *ptr, gint maxlen);
gint allocate_track_filenames(gint *overwrite, gint *overwritebiggest);
gint scan_for_toc_files();
void print_trackreadset();
diff -ur xcdroast-0.98alpha15/src/tools.c xcdroast-0.98alpha15.new/src/tools.c
--- xcdroast-0.98alpha15/src/tools.c 2004-12-15 10:28:52.612444656 +0100
+++ xcdroast-0.98alpha15.new/src/tools.c 2004-12-15 10:24:35.000000000 +0100
@@ -596,6 +596,69 @@
if (rc == -1 && errno == EAGAIN) {
if (n == 1)
return(-1);
+ else
+ break;
+ }
+ return(-1); /* error */
+ }
+ }
+
+ /* terminate the string */
+ *ptr = 0;
+
+ /* strip of some trailing chars - yes..we need both levels */
+ ptr--;
+ if ((*ptr == '\n') || (*ptr == '\r') ) {
+ *ptr = 0;
+ }
+ ptr--;
+ if ((*ptr == '\n') || (*ptr == '\r') ) {
+ *ptr = 0;
+ }
+
+ if (strlen(str) == 0) {
+ /* if we read an empty string, but are NOT on EOF return 1 */
+ return 1;
+ } else {
+ return(strlen(str));
+ }
+}
+
+
+/*
+ * Use this version to work around some of the critical races
+ * such as bz 127658. This issue should be solved on a case by case basis.
+ * Expected side effects: GUI freezes (e.g. if called from read_write_out() in io.c).
+ */
+
+gint read_line_wait(gint fd, gchar *ptr, gint maxlen) {
+gint n, rc;
+gchar c;
+gchar *str;
+
+ str = ptr;
+
+ for (n = 1; n < maxlen; n++) {
+ if ( (rc = read(fd, &c, 1)) == 1) {
+ *ptr++ = c;
+ if (c == '\n') {
+ break;
+ }
+
+ } else if (rc == 0) {
+ /* EOF */
+ if (n == 1)
+ return(0); /* EOF, no data read */
+ else
+ break; /* EOF, some data was read */
+ } else if (rc == -2) {
+ /* timeout while reading string */
+ return(-2);
+ } else {
+ /* nonblocking mode an nothing to read? */
+ if (rc == -1 && errno == EAGAIN) {
+ if (n == 1)
+ return(-1);
else {
/* Partial line read. Wait a
* bit longer in case there's

View file

@ -0,0 +1,29 @@
--- xcdroast-0.98alpha15/src/tools.c.linebuffer 2003-10-26 22:28:57.000000000 +0000
+++ xcdroast-0.98alpha15/src/tools.c 2004-07-12 12:24:36.134850404 +0100
@@ -596,8 +596,25 @@
if (rc == -1 && errno == EAGAIN) {
if (n == 1)
return(-1);
- else
+ else {
+ /* Partial line read. Wait a
+ * bit longer in case there's
+ * more. This does not fix
+ * all the races in the
+ * parsing code, but works
+ * around them somewhat. */
+ struct timeval t;
+ fd_set set;
+ FD_ZERO(&set);
+ FD_SET(fd,&set);
+ t.tv_sec = 1;
+ t.tv_usec = 0;
+ if (select (fd+1, &set, NULL,
+ NULL, &t) > 0)
+ continue;
+
break;
+ }
}
return(-1); /* error */
}

View file

@ -0,0 +1,31 @@
--- xcdroast-0.98alpha15/configure.in.nogtk1 2005-04-21 18:11:47.000000000 +0200
+++ xcdroast-0.98alpha15/configure.in 2005-04-21 18:12:05.000000000 +0200
@@ -99,25 +99,9 @@
AM_DEP_NONROOTMODE
AM_DEP_ENABLEGTK2
-if test "$ENABLE_GTK2" = "TRUE"; then
-
- PKG_CHECK_MODULES(PKGCONFIG, gtk+-2.0 >= 2.0.6)
- LIBS="$LIBS $PKGCONFIG_LIBS"
- CFLAGS="$CFLAGS $PKGCONFIG_CFLAGS"
-
-else
- dnl pure plain GTK+-1.2.x support
-
- dnl Check for GLIB
- AM_PATH_GLIB(1.2.3,, AC_MSG_ERROR(Test for GLIB failed. See the file 'INSTALL' for help.))
-
- dnl Check for GTK+
- AM_PATH_GTK(1.2.3,, AC_MSG_ERROR(Test for GTK failed. See the file 'INSTALL' for help.))
-
- dnl Check for GDK-Pixbuf
- AM_PATH_GDK_PIXBUF(0.8.0,, AC_MSG_ERROR(Test for gdk_pixbuf failed. See the file 'INSTALL' for help.))
-fi
-
+PKG_CHECK_MODULES(PKGCONFIG, gtk+-2.0 >= 2.0.6)
+LIBS="$LIBS $PKGCONFIG_LIBS"
+CFLAGS="$CFLAGS $PKGCONFIG_CFLAGS"
dnl internationalization macros
AM_GNU_GETTEXT

View file

@ -0,0 +1,22 @@
--- xcdroast-0.98alpha15/src/init.c.nowarn 2003-10-30 12:58:26.000000000 +0100
+++ xcdroast-0.98alpha15/src/init.c 2004-09-09 16:50:31.651482768 +0200
@@ -736,7 +736,7 @@
#if (defined(__MACH__) && defined(__APPLE__)) || (USE_NONROOTMODE == 0)
dodebug(1,"-- X-CD-Roast compiled with disabled non-root-mode.\n");
-#if !(defined(__MACH__) && defined(__APPLE__))
+#if !(defined(__MACH__) && defined(__APPLE__)) && 0
if (!isroot()) {
g_print("\nWARNING: Using X-CD-Roast as non-root and was compiled without non-root-support.\n");
}
@@ -1125,7 +1125,10 @@
if (isroot()) {
show_fancy_dialog(_("Warning:"), _("This copy of X-CD-Roast has been compiled without\nnon-root-support. If you want to use X-CD-Roast without entering\nthe root-password, you have to install a fully enabled version.\n\nVisit http://www.xcdroast.org for more information."), T_OK);
} else {
+#if 0
show_fancy_dialog(_("Warning:"), _("This copy of X-CD-Roast has been compiled without\nnon-root-support. Therefore you will not be able to use it as\nnon-root user unless you have take special precautions. It is\nrecommended that you install a fully enabled version.\n\nVisit http://www.xcdroast.org for more information."), T_OK);
+#endif
+;
}
gtk_widget_destroy(toplevel);
}

View file

@ -0,0 +1,113 @@
--- xcdroast-0.98alpha15/src/io.c.cdrkit 2007-08-13 16:52:35.000000000 +0200
+++ xcdroast-0.98alpha15/src/io.c 2007-08-13 16:53:28.000000000 +0200
@@ -4736,7 +4736,7 @@
dolog(3, "Saving extended output to %s\n", fname);
/* write to file */
- fd = open(fname,O_WRONLY | O_CREAT);
+ fd = open(fname,O_WRONLY | O_CREAT, 0600);
if (fd < 0) {
g_warning("Can't open file %s for writing\n",fname);
return 1;
@@ -10041,6 +10041,7 @@
gint check_version_mkisofs(gchar *match, gchar *found) {
gchar line[MAXLINE];
+gchar vline[MAXLINE];
gchar ver[MAXLINE];
FILE *fpin;
gchar *p;
@@ -10055,17 +10056,22 @@
}
strcpy(line,"");
+ strcpy(vline,"");
for (;;) {
if (fgets(line,MAXLINE,fpin) == NULL)
break;
dodebug(10,"got: %s",line);
+ /* only get first line */
+ if (strcmp(vline,"") == 0) {
+ strncpy(vline, line, MAXLINE);
+ }
}
if (pclose(fpin) == -1) {
g_error("pclose error\n");
}
- if (strcmp(line,"") == 0 || strstr(line,"sh:") != NULL) {
+ if (strcmp(vline,"") == 0 || strstr(vline,"sh:") != NULL) {
/* failed to open - permission denied */
return 2;
}
@@ -10107,7 +10113,7 @@
gchar ver[MAXLINE];
FILE *fpin;
gchar *p;
-
+ int icedax=0;
strcpy(ver,"");
get_wrap_path("CDDA2WAV",line);
strcat(line," -h 2>&1");
@@ -10126,6 +10132,9 @@
if (fgets(line,MAXLINE,fpin) == NULL)
break;
dodebug(11,"got: %s",line);
+ if (strstr(line, "icedax") != NULL) {
+ icedax=1;
+ }
if (strncmp(line, "Version", 7) == 0) {
strcpy(line2, line);
dodebug(10,"got version: %s",line);
@@ -10141,6 +10150,10 @@
return 2;
}
+ if (icedax) {
+ strcpy(found, CDDA2WAV_VERSION);
+ return 0;
+ }
/* now line2 contains the version string of cdda2wav */
/* try to extract the version number */
@@ -10176,13 +10189,14 @@
gint check_version_readcd(gchar *match, gchar *found) {
gchar line[MAXLINE];
+gchar vline[MAXLINE];
gchar ver[MAXLINE];
FILE *fpin;
gchar *p;
strcpy(ver,"");
get_wrap_path("READCD",line);
- strcat(line," -version 2>/dev/null | head -n 1");
+ strcat(line," -version 2>/dev/null | fgrep " READCD_NAME);
dodebug(1, "calling: %s\n", line);
if ((fpin = popen(line,"r")) == NULL) {
@@ -10190,17 +10204,22 @@
}
strcpy(line,"");
+ strcpy(vline,"");
for (;;) {
if (fgets(line,MAXLINE,fpin) == NULL)
break;
dodebug(10,"got: %s",line);
+ /* only get first line */
+ if (strcmp(vline,"") == 0) {
+ strncpy(vline, line, MAXLINE);
+ }
}
if (pclose(fpin) == -1) {
g_error("pclose error\n");
}
- if (strcmp(line,"") == 0 || strstr(line,"sh:") != NULL) {
+ if (strcmp(vline,"") == 0 || strstr(vline,"sh:") != NULL) {
/* failed to open - permission denied */
return 2;
}

View file

@ -0,0 +1,81 @@
--- xcdroast-0.98alpha15/src/io.c.scan 2003-10-26 15:24:48.000000000 +0100
+++ xcdroast-0.98alpha15/src/io.c 2004-09-20 16:36:03.841108264 +0200
@@ -330,16 +330,26 @@
if (strncmp(line,"Cdrecord",8) == 0) {
return;
}
-
- if (strncmp(line,"scsibus",7) == 0 ) {
+#if 0
+ if (strncmp(line,"devname",7) == 0 ) {
/* set current scsibus nr */
strcpy(tmp,line+7);
p1=strtok(tmp,":");
- strcpy(tmp2,p1);
/* now tmp2 contains the current busnr as string */
- busnr = atoi(tmp2);
+ devname = strdup(p1);
return;
}
+#endif
+ if (strncmp(line,"scsibus",7) == 0 ) {
+ /* set current scsibus nr */
+ strcpy(tmp,line+7);
+ p1=strtok(tmp,":");
+ strcpy(tmp2,p1);
+ /* now tmp2 contains the current busnr as string */
+ busnr = atoi(tmp2);
+ return;
+ }
+
/* a line with an error message? */
/* get_spawn_path(CDRECORD,tmp); */
@@ -1061,17 +1071,18 @@
if (doscanbus) {
/* scan for scsi devices */
+ scan_other("ATA", 1, txt);
scan_traditional(txt);
/* scan for alternatives */
#if defined(linux)
if (scanparam) {
- scan_other("ATAPI", 1, txt);
+ scan_other("ATAPI", 2, txt);
}
#endif
#if defined(sun)
if (scanparam) {
- scan_other("USCSI", 2, txt);
+ scan_other("USCSI", 3, txt);
}
#endif
}
--- xcdroast-0.98alpha15/src/setup.c.scan 2003-10-30 12:50:25.000000000 +0100
+++ xcdroast-0.98alpha15/src/setup.c 2004-09-20 16:37:12.290702344 +0200
@@ -22,6 +22,8 @@
#include <sys/types.h>
#include <sys/stat.h>
+#include <glob.h>
+
/*
#ifdef HAVE_LOCALE_H
#include <locale.h>
@@ -4036,7 +4038,14 @@
/* fill textbox and do the actual scanning */
if (!manual) {
- scanbus_new(txt, scanparam);
+ glob_t globbuf;
+ int i;
+ if (glob("/dev/cdrom*", GLOB_NOSORT, NULL, &globbuf) == 0) {
+ for (i = 0; globbuf.gl_pathv && globbuf.gl_pathv[i] != NULL ; i
+++) {
+ scanbus_new_single(globbuf.gl_pathv[i], txt);
+ }
+ globfree(&globbuf); }
} else {
/* the syntax used to scan for REMOTE scsi devices */
if (strncmp(devicestr,"REMOTE:", 7) == 0 &&

7
xcdroast.desktop Normal file
View file

@ -0,0 +1,7 @@
[Desktop Entry]
Encoding=UTF-8
Name=CD Writer
Type=Application
Exec=/usr/bin/xcdroast
Comment=CD creation tool
Icon=/usr/lib/xcdroast-0.98/icons/xcdricon.png

363
xcdroast.spec Normal file
View file

@ -0,0 +1,363 @@
Summary: An X Window System based tool for creating CDs.
Name: xcdroast
Version: 0.98a15
Release: 17%{?dist}
License: LGPLv2+
Group: Applications/Multimedia
Source: http://xcdroast.sourceforge.net/RPMS/a15/src/xcdroast-0.98alpha15.tar.gz
Source1: xcdroast.desktop
Patch1: xcdroast-0.98alpha15-linebuffer.patch
Patch2: xcdroast-0.98alpha15-nowarn.patch
Patch3: xcdroast-0.98alpha15-scan.patch
Patch11: xcdroast-0.98alpha15-01_upstream_configure.patch
Patch12: xcdroast-0.98alpha15-02_upstream_gtk2locale.patch
Patch13: xcdroast-0.98alpha15-03_upstream_64bit_gsize.patch
Patch14: xcdroast-0.98alpha15-04_upstream_read_eagain.patch
Patch15: xcdroast-0.98alpha15-05_upstream_wav.patch
Patch16: xcdroast-0.98alpha15-06_man.patch
Patch17: xcdroast-0.98alpha15-07_case_cmp.patch
Patch18: xcdroast-0.98alpha15-08_desktop.patch
Patch19: xcdroast-0.98alpha15-09_share_dir.patch
Patch20: xcdroast-0.98alpha15-10_cddbtool.patch
Patch21: xcdroast-0.98alpha15-11_mkisofs_options.patch
Patch22: xcdroast-0.98alpha15-12_cdrecord_versions.patch
Patch23: xcdroast-0.98alpha15-13_cdrecord_to_wodim.patch
Patch24: xcdroast-0.98alpha15-14_atapi_to_oldatapi.patch
Patch25: xcdroast-0.98alpha15-15_no_readcd_version.patch
Patch30: xcdroast-0.98alpha15-prodvd.patch
Patch31: xcdroast-0.98alpha15-frozen_gui.patch
Patch32: xcdroast-0.98alpha15-nogtk1.patch
Url: http://www.xcdroast.org/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires: cdrecord >= 2.0, mkisofs >= 2.0
Requires(hint): cdda2wav >= 2.0
BuildRequires: gtk2-devel >= 2.0.6
BuildRequires: desktop-file-utils >= 0.2.92
%description
X-CD-Roast provides a GUI interface for commands like cdrecord and
mkisofs. X-CD-Roast includes a self-explanatory X11 user interface,
automatic SCSI and IDE hardware setup, support for mastering of new
ISO9660 data CDs, support for production of new audio CDs, fast
copying of CDs without hard disk buffering, and a logfile option.
%prep
%setup -q -n xcdroast-0.98alpha15
%patch1 -p1 -b .linebuffer
%patch2 -p1 -b .nowarn
%patch3 -p1 -b .scan
%patch11 -p1 -b .p11
%patch12 -p1 -b .p12
%patch13 -p1 -b .p13
%patch14 -p1 -b .p14
%patch15 -p1 -b .p15
%patch16 -p1 -b .p16
%patch17 -p1 -b .p17
%patch18 -p1 -b .p18
%patch19 -p1 -b .p19
%patch20 -p1 -b .p20
%patch21 -p0 -b .p21
%patch22 -p1 -b .p22
%patch23 -p1 -b .p23
%patch24 -p0 -b .p24
%patch25 -p1 -b .p25
%patch30 -p1 -b .cdrkit
%patch31 -p1 -b .frozen
%patch32 -p1 -b .nogtk1
%build
export CFLAGS="$RPM_OPT_FLAGS -g"
%configure --enable-gtk2 --disable-nonrootmode
make
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/{etc/{X11/applnk/Multimedia,pam.d,security/console.apps},usr/sbin}
make install PREFIX=/usr DESTDIR=$RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications
desktop-file-install --vendor xcdroast \
--dir $RPM_BUILD_ROOT%{_datadir}/applications \
--add-category X-Red-Hat-Base \
--add-category System \
%{SOURCE1}
%find_lang %name
%clean
rm -rf $RPM_BUILD_ROOT
%files -f %{name}.lang
%defattr(-,root,root)
%doc ChangeLog doc/DOCUMENTATION doc/FAQ doc/README* doc/TRANSLATION.HOWTO
%dir /usr/lib/xcdroast-0.98
%dir /usr/lib/xcdroast-0.98/bin
%dir /usr/lib/xcdroast-0.98/icons
%dir /usr/lib/xcdroast-0.98/sound
%{_mandir}/man?/xcdroast*
/usr/bin/*
/usr/lib/xcdroast-0.98/*/*
%{_datadir}/applications/*
%changelog
* Mon Feb 18 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 0.98a15-17
- Autorebuild for GCC 4.3
* Thu Aug 23 2007 Harald Hoyer <harald@redhat.com> - 0.98a15-16
- changed license tag
* Mon Aug 13 2007 Harald Hoyer <harald@redhat.com> - 0.98a15-15
- more cdrkit compat patches
- changed desktop category
- changed build root path
- added mode to open(2) in io.c
* Wed Jun 20 2007 Harald Hoyer <harald@redhat.com> - 0.98a15-13.1
- added cdrkit compat patches
* Thu Mar 15 2007 Karsten Hopp <karsten@redhat.com> 0.98a15-13
- rebuild with current gtk2 to add png support (#232013)
* Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 0.98a15-12.2.2
- rebuild
* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 0.98a15-12.2.1
- bump again for double-long bug on ppc(64)
* Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 0.98a15-12.2
- rebuilt for new gcc4.1 snapshot and glibc changes
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
- rebuilt
* Thu Apr 21 2005 Harald Hoyer <harald@redhat.com> - 0.98a15-12
- removed gtk1 build requirement
* Mon Apr 18 2005 Harald Hoyer <harald@redhat.com> - 0.98a15-11
- fixed frozen progress bars with patch from Didier Heyden (bug #134334)
* Thu Mar 03 2005 Harald Hoyer <harald@redhat.com>
- rebuilt
* Wed Feb 09 2005 Harald Hoyer <harald@redhat.com>
- rebuilt
* Mon Sep 20 2004 Harald Hoyer <harald@redhat.com> - 0.98a15-7
- only add /dev/cdrom*
- enable prodvd mode for our cdrecord
* Fri Sep 10 2004 Harald Hoyer <harald@redhat.com> - 0.98a15-6
- improved scanning and removed warnings
* Sun Aug 29 2004 Tim Waugh <twaugh@redhat.com> - 0.98a15-5
- Actually apply the patch.
* Tue Jul 13 2004 Harald Hoyer <harald@redhat.com> - 0.98a15-4
- added xcdroast-0.98alpha15-linebuffer.patch (Tim Waugh, bz 127658)
- corrected buildrequires (bz 127300)
* Tue Jun 15 2004 Elliot Lee <sopwith@redhat.com>
- rebuilt
* Wed Feb 25 2004 Harald Hoyer <harald@redhat.com> - 0.98a15-2
- 64bit patch added
- configure patch removing pcre req added
* Tue Feb 24 2004 Harald Hoyer <harald@redhat.com> - 0.98a15-1
- version 0.98alpha15
* Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
- rebuilt
* Mon Oct 13 2003 Harald Hoyer <harald@redhat.de> 0.98a14-2
- added patches from xcdroast.org to work again
with the cdrtools-2.01a17 or newer.
* Tue Sep 01 2003 Harald Hoyer <harald@redhat.com> 0.98a14-1
- new version
* Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
- rebuilt
* Wed Jan 22 2003 Tim Powers <timp@redhat.com>
- rebuilt
* Tue Jan 07 2003 Harald Hoyer <harald@redhat.com> 0.98a13-2
- removed the old patches
- point the .desktop to an icon
* Tue Jan 07 2003 Harald Hoyer <harald@redhat.com> 0.98a13-2
- --disable-nonrootmode
* Tue Jan 07 2003 Harald Hoyer <harald@redhat.com> 0.98a13-1
- bump version
* Tue Nov 12 2002 Nalin Dahyabhai <nalin@redhat.com> 0.98a9-21
- Remove absolute paths from PAM configuration, ensuring that the right set
of modules gets used regardless of arch on multilib systems.
* Tue Oct 22 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-20
- Fix POSIX locale patch (bug #76341).
* Sun Oct 20 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-19
- Use POSIX locale for df (bug #76341).
* Tue Aug 13 2002 Havoc Pennington <hp@redhat.com> 0.98a9-18
- rebuild with new imlib soname
* Tue Aug 13 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-17
- Another go at fixing bug #70280.
* Mon Aug 5 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-16
- Convert translation files to UTF-8 (bug #70280).
* Fri Jul 26 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-15
- Use pam_timestamp.so (bug #69884).
* Tue Jul 23 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-14
- Desktop file fixes (bug #69537).
* Mon Jul 15 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-13
- Use desktop-file-install.
* Fri Jun 21 2002 Tim Powers <timp@redhat.com> 0.98a9-12
- automated rebuild
* Thu Jun 20 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-11
- Set SESSION=true in the console.apps file (bug #62369).
* Thu May 23 2002 Tim Powers <timp@redhat.com> 0.98a9-10
- automated rebuild
* Thu Apr 25 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-9
- Don't explicitly strip binaries (bug #62571).
* Mon Apr 15 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-8
- Chicken out of change to fix bug #56844. Better solution needed.
* Wed Mar 20 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-7
- Better desktop file comment (bug #61427).
* Tue Feb 26 2002 Tim Waugh <twaugh@redhat.com> 0.98a9-6
- Rebuild in new environment.
* Thu Jan 24 2002 Karsten Hopp <karsten@redhat.de>
- Fix Requires:
* Wed Jan 09 2002 Tim Powers <timp@redhat.com>
- automated rebuild
* Thu Nov 29 2001 Tim Waugh <twaugh@redhat.com> 0.98a9-3
- Fix console.apps file (bug #56844).
* Mon Jul 30 2001 Tim Waugh <twaugh@redhat.com> 0.98a9-2
- Put .desktop file in Multimedia, not Applications (bug #50290).
* Mon Jul 23 2001 Karsten Hopp <karsten@redhat.de> 0.98a9-1
- 0.98a9
- give hint how to setup nonroot-mode (we don't ship the sgid binaries)
* Wed Jul 19 2001 Karsten Hopp <karsten@redhat.de>
- remove workaround for older GTK
* Wed Jul 4 2001 Tim Waugh <twaugh@redhat.com> 0.98a8-5
- Change Copyright: to License:.
- Change version check for cdrecord to accept 1.10 instead of 1.9.
- ... and require newer cdrecord.
* Tue Jun 19 2001 Karsten Hopp <karsten@redhat.de>
- add ExcludeArch: s390 s390x
- add BuildRequires
* Tue May 22 2001 Karsten Hopp <karsten@redhat.de>
- fix #41802, needs some testing if cdrecord 1.10
is compatible with 1.9
* Tue Feb 27 2001 Karsten Hopp <karsten@redhat.de>
- symlink should be relative
- fix strip
* Mon Feb 12 2001 Karsten Hopp <karsten@redhat.de>
- update to alpha8 (security bug in alpha7)
- use consolehelper
- fix bugzilla #26870
* Fri Dec 01 2000 Karsten Hopp <karsten@redhat.de>
- rebuild to fix /usr/share/doc permissions
* Mon Nov 13 2000 Karsten Hopp <karsten@redhat.de>
- update to 0.98alpha7, which has a new menu to configure non-root mode
- added README.nonroot, README.atapi to documentation
* Thu Aug 24 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- Fix interoperability with mkisofs 1.13
* Wed Aug 23 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- Update to current, this fixes the "crashes on startup" bug (#16055)
(and the maintainer confirms the "alpha" is more stable than the lastest
"release").
* Mon Aug 7 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- remove another insistence on Tcl 8.0
* Thu Jul 13 2000 Prospector <bugzilla@redhat.com>
- automatic rebuild
* Thu Jun 15 2000 Bill Nottingham <notting@redhat.com>
- fix dependencies
* Sun Jun 11 2000 Bill Nottingham <notting@redhat.com>
- build on ia64
* Fri Jun 9 2000 Jakub Jelinek <jakub@redhat.com>
- Remove patch for gcc 2.96 breakages, there were none
- Add patch to make et2c work with recent Tcl/Tk headers
* Thu Jun 8 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- get rid of the ExclusiveArch: line; it compiles on sparc and it might
even work there...
- Exclude ia64 for now; cdrecord isn't available there.
* Thu Jun 8 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- rebuild for main distribution
- fix build with TCL/Tk 8.3
- remove cdrecord and mkisofs from the package, add
dependencies on the cdrecord and mkisofs packages instead
- fix up the code to find cdrecord where it belongs.
- put man pages in FHS locations
- fix build with kernel 2.4 headers
- work around gcc 2.96 breakages
* Sun May 28 2000 Ngo Than <than@redhat.de>
- rebuild for 7.0
- put man page in correct place
- fix xcdroast to build with tcltk8.2
- add cdrecord-1.8 in xcdroast
* Tue Apr 04 2000 Ngo Than <than@redhat.de>
- include needed devices in the package (Bug #9997)
* Fri Feb 11 2000 Ngo Than <than@redhat.de>
- fix Bug 8564 and 8563
* Mon Jul 26 1999 Tim Powers <timp@redhat.com>
- rebuilt for 6.1
* Wed Apr 15 1999 Michael Maher <mike@redhat.com>
- built package for 6.0
- updated source
* Tue Oct 13 1998 Michael Maher <mike@redhat.com>
- rushed by wanger.. not updated
* Wed May 20 1998 Michael Maher <mike@redhat.com>
- built and updated package
- added changelog
- edited paths