aboutsummaryrefslogtreecommitdiff
path: root/sysutils/k3b-kde4
diff options
context:
space:
mode:
authorMarkus Brueffer <markus@FreeBSD.org>2004-03-18 17:41:41 +0000
committerMarkus Brueffer <markus@FreeBSD.org>2004-03-18 17:41:41 +0000
commit0c47e293291a978b77489b79f125fbdaa6eb4eca (patch)
tree2116f98f98cbe1d57402bcec22a3c76b5d708d37 /sysutils/k3b-kde4
parentf956563c5dbd884838792dd60bd80975fbe1ddad (diff)
downloadports-0c47e293291a978b77489b79f125fbdaa6eb4eca.tar.gz
ports-0c47e293291a978b77489b79f125fbdaa6eb4eca.zip
Notes
Diffstat (limited to 'sysutils/k3b-kde4')
-rw-r--r--sysutils/k3b-kde4/Makefile9
-rw-r--r--sysutils/k3b-kde4/distinfo2
-rw-r--r--sysutils/k3b-kde4/files/patch-src-Makefile.in14
-rw-r--r--sysutils/k3b-kde4/files/patch-src-audiodecoding-mp3-k3bmaddecoder.cpp124
-rw-r--r--sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.cpp912
-rw-r--r--sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.h50
-rw-r--r--sysutils/k3b-kde4/files/patch-src-core-device-k3bscsicommand.h51
-rw-r--r--sysutils/k3b-kde4/files/patch-src-core-k3bdefaultexternalprograms.cpp81
-rw-r--r--sysutils/k3b-kde4/files/patch-src-core-k3bglobals.cpp16
-rw-r--r--sysutils/k3b-kde4/files/patch-src-core-k3bprocess.cpp20
-rw-r--r--sysutils/k3b-kde4/files/patch-src-core-k3bprocess.h9
-rw-r--r--sysutils/k3b-kde4/files/patch-src-device-k3bdevice.cpp26
-rw-r--r--sysutils/k3b-kde4/files/patch-src-device-k3bdevice.h13
-rw-r--r--sysutils/k3b-kde4/files/patch-src-device-k3bdevicemanager.cpp (renamed from sysutils/k3b-kde4/files/patch-src-core-device-k3bdevicemanager.cpp)308
-rw-r--r--sysutils/k3b-kde4/files/patch-src-device-k3bdevicemanager.h (renamed from sysutils/k3b-kde4/files/patch-src-core-device-k3bdevicemanager.h)18
-rw-r--r--sysutils/k3b-kde4/files/patch-src-device-k3bscsicommand.cpp (renamed from sysutils/k3b-kde4/files/patch-src-core-device-k3bscsicommand.cpp)135
-rw-r--r--sysutils/k3b-kde4/files/patch-src-device-k3bscsicommand.h84
-rw-r--r--sysutils/k3b-kde4/files/patch-src-rip-k3bmovieview.cpp6
-rw-r--r--sysutils/k3b-kde4/files/patch-src-rip-k3btcwrapper.cpp30
-rw-r--r--sysutils/k3b-kde4/pkg-descr9
-rw-r--r--sysutils/k3b-kde4/pkg-message11
-rw-r--r--sysutils/k3b-kde4/pkg-plist401
22 files changed, 539 insertions, 1790 deletions
diff --git a/sysutils/k3b-kde4/Makefile b/sysutils/k3b-kde4/Makefile
index f505f3fb5659..779acd569d9f 100644
--- a/sysutils/k3b-kde4/Makefile
+++ b/sysutils/k3b-kde4/Makefile
@@ -6,8 +6,7 @@
#
PORTNAME= k3b
-PORTVERSION= 0.10.3
-PORTREVISION= 1
+PORTVERSION= 0.11.6
CATEGORIES= sysutils multimedia kde
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
@@ -19,13 +18,15 @@ RUN_DEPENDS= cdrecord:${PORTSDIR}/sysutils/cdrtools \
cdrdao:${PORTSDIR}/sysutils/cdrdao \
mkisofs:${PORTSDIR}/sysutils/mkisofs
LIB_DEPENDS= mad:${PORTSDIR}/audio/libmad \
- ogg:$(PORTSDIR)/audio/libogg
+ vorbis:${PORTSDIR}/audio/libvorbis \
+ FLAC:${PORTSDIR}/audio/flac
+USE_BZIP2= yes
GNU_CONFIGURE= yes
CONFIGURE_TARGET=--build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
CONFIGURE_ARGS= --with-k3bsetup=no
USE_GMAKE= yes
-USE_LIBTOOL_VER=13
+USE_LIBTOOL= yes
INSTALLS_SHLIB= yes
USE_KDELIBS_VER= 3
USE_REINPLACE= yes
diff --git a/sysutils/k3b-kde4/distinfo b/sysutils/k3b-kde4/distinfo
index 9b1420d69d20..e5a440541f5b 100644
--- a/sysutils/k3b-kde4/distinfo
+++ b/sysutils/k3b-kde4/distinfo
@@ -1 +1 @@
-MD5 (k3b-0.10.3.tar.gz) = 41a21815c2edaa3aaaa55bb922e71750
+MD5 (k3b-0.11.6.tar.bz2) = 0015b9ad457713425464dbdad6a15ab9
diff --git a/sysutils/k3b-kde4/files/patch-src-Makefile.in b/sysutils/k3b-kde4/files/patch-src-Makefile.in
index 42e55ed1de9d..bf6506bc152a 100644
--- a/sysutils/k3b-kde4/files/patch-src-Makefile.in
+++ b/sysutils/k3b-kde4/files/patch-src-Makefile.in
@@ -1,11 +1,11 @@
---- src/Makefile.in.orig Thu Nov 6 09:01:00 2003
-+++ src/Makefile.in Fri Nov 7 12:35:44 2003
-@@ -281,7 +281,7 @@
+--- src/Makefile.in.orig Sun Feb 29 19:38:32 2004
++++ src/Makefile.in Mon Mar 8 15:40:08 2004
+@@ -286,7 +286,7 @@
#>+ 1
- k3b_SOURCES=k3bwelcomewidget.cpp k3bapplication.cpp k3bdiroperator.cpp kdndfileview.cpp k3bfiletreeview.cpp k3bcddbmultientriesdialog.cpp k3baudioplayer.cpp k3bprojecttabbar.cpp k3bprojecttabwidget.cpp k3bsplash.cpp k3bblankingdialog.cpp k3bfileview.cpp k3bdirview.cpp k3btoolbox.cpp k3b.cpp main.cpp k3bstatusbarmanager.cpp k3bfiletreecombobox.cpp k3breadcdreader.cpp k3binterface.cpp k3bprojectinterface.cpp k3bsystemproblemdialog.cpp k3binterface_skel.cpp k3bprojectinterface_skel.cpp
+ k3b_SOURCES=k3bwelcomewidget.cpp k3bapplication.cpp k3bdiroperator.cpp kdndfileview.cpp k3bfiletreeview.cpp k3bcddbmultientriesdialog.cpp k3baudioplayer.cpp k3bprojecttabbar.cpp k3bprojecttabwidget.cpp k3bsplash.cpp k3bblankingdialog.cpp k3bfileview.cpp k3bdirview.cpp k3btoolbox.cpp k3b.cpp main.cpp k3bstatusbarmanager.cpp k3bfiletreecombobox.cpp k3breadcdreader.cpp k3binterface.cpp k3bprojectinterface.cpp k3bsystemproblemdialog.cpp k3bcdcontentsview.cpp k3bwriterspeedverificationdialog.cpp k3bdatatrackreader.cpp k3binterface_skel.cpp k3bprojectinterface_skel.cpp
--k3b_LDADD = ./cdinfo/libcdinfo.la ./option/liboption.la ./rip/librip.la ./cdcopy/libcdcopy.la ./dvdcopy/libdvdcopy.la ./cdclone/libcdclone.la ./videoEncoding/libvideoEncoding.la ./plugin/libk3bplugin.la $(ARTS_LIBS) -lkio -lkparts ./core/libk3bcore.la ./tools/libk3btools.la ./projects/libk3bproject.la ./images/libimagewriting.la
-+k3b_LDADD = ./cdinfo/libcdinfo.la ./option/liboption.la ./rip/librip.la ./cdcopy/libcdcopy.la ./dvdcopy/libdvdcopy.la ./cdclone/libcdclone.la ./videoEncoding/libvideoEncoding.la ./plugin/libk3bplugin.la $(ARTS_LIBS) -lkio -lkparts -lcam ./core/libk3bcore.la ./tools/libk3btools.la ./projects/libk3bproject.la ./images/libimagewriting.la
+-k3b_LDADD = ./cdinfo/libcdinfo.la ./option/liboption.la ./rip/librip.la ./cdcopy/libcdcopy.la ./dvdcopy/libdvdcopy.la ./videoEncoding/libvideoEncoding.la ./plugin/libk3bplugin.la $(ARTS_LIBS) -lkio -lkparts ./device/libk3bdevice.la ./core/libk3bcore.la ./tools/libk3btools.la ./projects/libk3bproject.la ./images/libimagewriting.la
++k3b_LDADD = ./cdinfo/libcdinfo.la ./option/liboption.la ./rip/librip.la ./cdcopy/libcdcopy.la ./dvdcopy/libdvdcopy.la ./videoEncoding/libvideoEncoding.la ./plugin/libk3bplugin.la $(ARTS_LIBS) -lkio -lkparts -lcam ./device/libk3bdevice.la ./core/libk3bcore.la ./tools/libk3btools.la ./projects/libk3bproject.la ./images/libimagewriting.la
- SUBDIRS = core tools plugin projects cddb cdinfo option rip cdcopy cdclone images dvdcopy videoEncoding pics icons konqi mimetypes tests audiodecoding audioencoding sounds $(K3BSETUP1_BUILD)
+ SUBDIRS = device core tools plugin projects cddb cdinfo option rip cdcopy images dvdcopy videoEncoding pics icons konqi mimetypes tests audiodecoding audioencoding sounds $(K3BSETUP1_BUILD)
diff --git a/sysutils/k3b-kde4/files/patch-src-audiodecoding-mp3-k3bmaddecoder.cpp b/sysutils/k3b-kde4/files/patch-src-audiodecoding-mp3-k3bmaddecoder.cpp
deleted file mode 100644
index ab64d2773e8c..000000000000
--- a/sysutils/k3b-kde4/files/patch-src-audiodecoding-mp3-k3bmaddecoder.cpp
+++ /dev/null
@@ -1,124 +0,0 @@
---- src/audiodecoding/mp3/k3bmaddecoder.cpp.orig Mon Sep 1 12:14:10 2003
-+++ src/audiodecoding/mp3/k3bmaddecoder.cpp Fri Nov 7 12:35:44 2003
-@@ -37,6 +37,8 @@
- #include <stdlib.h>
- #include <cmath>
- #include <cstdlib>
-+#include <sys/types.h>
-+#include <sys/mman.h>
-
- #include <config.h>
-
-@@ -716,23 +718,24 @@
- return false;
- }
-
-- // there seem to be mp3 files starting with a lot of zeros
-- // we try to skip these.
-- // there might still be files with more than bufLen zeros...
-- const int bufLen = 4096;
-- char buf[bufLen];
-- if( f.readBlock( buf, bufLen ) < bufLen ) {
-- kdDebug() << "(K3bMadDecoder) unable to read " << bufLen << " bytes from " << url.path() << endl;
-+ // EXPERIMENTAL!!!!!!!!
-+
-+ const int bufLen = f.size();
-+ const char * buf = (const char *)mmap(0, bufLen, PROT_READ, MAP_SHARED, f.handle(), 0);
-+ if (buf == MAP_FAILED)
-+ {
-+ kdDebug() << "(K3bMp3Module) unable to read from " << url.path() << endl;
- f.close();
- return false;
- }
-- f.close();
-
- // skip any 0
- int i = 0;
- while( i < bufLen && buf[i] == '\0' ) i++;
- if( i == bufLen ) {
- kdDebug() << "(K3bMadDecoder) only zeros found in the beginning of " << url.path() << endl;
-+ munmap((void *)buf, bufLen);
-+ f.close();
- return false;
- }
-
-@@ -744,6 +747,8 @@
- ( (unsigned short)buf[i+3] < 0xff && (unsigned short)buf[i+4] < 0xff ) ) {
- kdDebug() << "(K3bMadDecoder) found id3 magic: ID3 "
- << (unsigned short)buf[i+3] << "." << (unsigned short)buf[i+4] << endl;
-+ munmap((void *)buf, bufLen);
-+ f.close();
- return true;
- }
-
-@@ -756,15 +761,22 @@
- short m = (short)( buf[i+20] | (buf[i+21]<<8) );
- if( m == 80 ) {
- kdDebug() << "(K3bMadDecoder) found RIFF MPEG magic." << endl;
-+ munmap((void *)buf, bufLen);
-+ f.close();
- return true;
- }
- else if( m == 85 ) {
- kdDebug() << "(K3bMadDecoder) found RIFF MPEG III magic." << endl;
-+ munmap((void *)buf, bufLen);
-+ f.close();
- return true;
- }
-- else
-+ else {
-+ munmap((void *)buf, bufLen);
-+ f.close();
- return false;
- }
-+ }
-
-
-
-@@ -775,16 +787,41 @@
- mad_stream_init( &stream );
- mad_header_init( &header );
-
-- mad_stream_buffer( &stream, (unsigned char*)&buf[i], bufLen-i );
-- stream.error = MAD_ERROR_NONE;
-+ mad_stream_buffer( &stream, (unsigned char*)buf, bufLen );
-+ unsigned long bitrate, kbps, count;
-+ int vbr;
-+ bitrate = kbps = count = vbr = 0;
-+ mad_timer_t duration = mad_timer_zero;
- bool success = true;
-- if( mad_header_decode( &header, &stream ) ) {
-+ while (1) {
-+ if (mad_header_decode(&header, &stream) == -1) {
-+ if (MAD_RECOVERABLE(stream.error))
-+ continue;
-+ else
-+ {
-+ break;
-+ }
-+ }
-+ if (bitrate && header.bitrate != bitrate)
-+ vbr = 1;
-+
-+ bitrate = header.bitrate;
-+
-+ kbps += bitrate / 1000;
-+ ++count;
-+
-+ mad_timer_add(&duration, header.duration);
-+ }
-+ kbps = count?((kbps * 2) / count + 1) / 2 * (vbr ? -1 : 1):0;
-+ kdDebug() << "(K3bMp3Module) File: " << url.path() << ", bitrate: " << kbps << ", duration: " << duration.seconds << "." << duration.fraction << endl;
-+ if (duration.seconds == 0 || kbps == 0)
-+ {
- kdDebug() << "(K3bMadDecoder) could not find mpeg header." << endl;
- success = false;
- }
-
-- mad_header_finish( &header );
-- mad_stream_finish( &stream );
-+ munmap((void *)buf, bufLen);
-+ f.close();
-
- return success;
- }
diff --git a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.cpp b/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.cpp
deleted file mode 100644
index 449a87e89484..000000000000
--- a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.cpp
+++ /dev/null
@@ -1,912 +0,0 @@
---- src/core/device/k3bdevice.cpp.orig Thu Oct 30 11:53:35 2003
-+++ src/core/device/k3bdevice.cpp Sat Nov 8 12:15:01 2003
-@@ -32,7 +32,9 @@
- #include <sys/ioctl.h>
-
- #include <fstab.h>
-+#ifndef __FreeBSD__
- #include <mntent.h>
-+#endif
- #include <stdio.h>
- #include <stdlib.h>
- #include <fcntl.h>
-@@ -40,6 +42,7 @@
- #include <errno.h>
- #include <sys/stat.h>
-
-+#ifndef __FreeBSD__
- #include <linux/version.h>
- #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,70)
- typedef unsigned char u8;
-@@ -48,6 +51,18 @@
- #include <linux/cdrom.h>
- #define __STRICT_ANSI__
- #include <linux/major.h>
-+#else
-+#include <sys/cdio.h>
-+#include <sys/dvdio.h>
-+#include <ktempfile.h>
-+#define __BYTE_ORDER BYTE_ORDER
-+#define __BIG_ENDIAN BIG_ENDIAN
-+//#define CDROMEJECT CDIOCEJECT
-+//#define CDROMCLOSETRAY CDIOCCLOSE
-+#define CD_FRAMESIZE_RAW 2352
-+#include <cam/scsi/scsi_message.h>
-+int bsd_open_close_device(int bus, int target, int lun, bool eject);
-+#endif
-
-
-
-@@ -167,6 +182,7 @@
- {
- kdDebug() << "(K3bCdDevice) " << blockDeviceName() << ": init()" << endl;
-
-+#ifndef __FreeBSD__
- if(open() < 0)
- return false;
-
-@@ -175,10 +191,18 @@
- // we also query the mode page 2A and use the cdrom.h stuff to get as much information as possible
- //
-
-+ // On BSD the device capabilities are already set by the devicemanager. So this code may
-+ // find more capabilities -- if it works
- d->deviceType = 0;
-+#endif
- d->supportedProfiles = 0;
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+ d->deviceType |= CDROM;
-+#endif
- unsigned char header[8];
- ::memset( header, 0, 8 );
- cmd[0] = 0x46; // GET CONFIGURATION
-@@ -580,8 +604,16 @@
- int mm_cap_len = 0;
- if( modeSense( &mm_cap_buffer, mm_cap_len, 0x2A ) ) {
- mm_cap_page_2A* mm_p = (mm_cap_page_2A*)(mm_cap_buffer+8);
-- if( mm_p->BUF ) d->burnfree = true;
-- if( mm_p->cd_rw_write ) d->deviceType |= CDRW;
-+ if( mm_p->BUF )
-+ {
-+ kdDebug() << "(K3bCdDevice) ModeSense: burnfree." << endl;
-+ d->burnfree = true;
-+ }
-+ if( mm_p->cd_rw_write )
-+ {
-+ kdDebug() << "(K3bCdDevice) ModeSense: CDRW." << endl;
-+ d->deviceType |= CDRW;
-+ }
- m_maxWriteSpeed = (int)( from2Byte(mm_p->max_write_speed) * 1024.0 / ( 2352.0 * 75.0 ) );
- m_maxReadSpeed = (int)( from2Byte(mm_p->max_read_speed) * 1024.0 / ( 2352.0 * 75.0 ) );
-
-@@ -592,6 +624,7 @@
- }
-
-
-+#ifndef __FreeBSD__
-
- //
- // This is the backup if the drive does not support the GET CONFIGURATION command
-@@ -619,6 +652,7 @@
- if (drivetype & CDC_DVD)
- d->deviceType |= DVD;
-
-+#endif
-
- if( writesCd() )
- checkWriteModes();
-@@ -642,10 +676,11 @@
- m_version = QString::fromLocal8Bit( (char*)(inq+32), 4 ).stripWhiteSpace();
- }
-
-+#ifndef __FreeBSD__
- close();
-+#endif
-
- d->interfaceType = interfaceType();
--
- return furtherInit();
- }
-
-@@ -649,6 +684,23 @@
- return furtherInit();
- }
-
-+void K3bCdDevice::CdDevice::guessProfiles()
-+{
-+ if (!d->supportedProfiles)
-+ {
-+ kdDebug() << "(K3bCdDevice): no profiles found; setting them from device type = " << d->deviceType << endl;
-+ if (d->deviceType & CDROM) d->supportedProfiles |= MEDIA_CD_ROM;
-+ if (d->deviceType & CDR) d->supportedProfiles |= MEDIA_CD_R;
-+ if (d->deviceType & CDRW) d->supportedProfiles |= MEDIA_CD_RW;
-+ if (d->deviceType & DVDR) d->supportedProfiles |= MEDIA_DVD_R_SEQ;
-+ if (d->deviceType & DVDRAM) d->supportedProfiles |= MEDIA_DVD_RAM;
-+ if (d->deviceType & DVD) d->supportedProfiles |= MEDIA_DVD_ROM;
-+ if (d->deviceType & DVDRW) d->supportedProfiles |= MEDIA_DVD_RW_OVWR | MEDIA_DVD_RW_SEQ;// ???
-+ if (d->deviceType & DVDPR) d->supportedProfiles |= MEDIA_DVD_PLUS_R;
-+ if (d->deviceType & DVDPRW) d->supportedProfiles |= MEDIA_DVD_PLUS_RW;
-+ }
-+// case 0x11: d->supportedProfiles |= MEDIA_DVD_R_SEQ;
-+}
-
- bool K3bCdDevice::CdDevice::furtherInit()
- {
-@@ -658,6 +710,7 @@
-
- K3bCdDevice::CdDevice::interface K3bCdDevice::CdDevice::interfaceType()
- {
-+#ifndef __FreeBSD__
- if (d->interfaceType == OTHER)
- {
- // if the device is already opened we do not close it
-@@ -680,6 +733,9 @@
- if( needToClose )
- close();
- }
-+#else
-+ d->interfaceType = SCSI;
-+#endif
- return d->interfaceType;
- }
-
-@@ -826,7 +882,11 @@
-
- unsigned char dvdheader[20];
- ::memset( dvdheader, 0, 20 );
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0xad; // GPCMD_READ_DVD_STRUCTURE;
- cmd[9] = 20;
- if( cmd.transport( TR_DIR_READ, dvdheader, 20 ) ) {
-@@ -846,6 +906,7 @@
-
- int K3bCdDevice::CdDevice::isReady() const
- {
-+#ifndef __FreeBSD__
- // if the device is already opened we do not close it
- // to allow fast multible method calls in a row
- bool needToClose = !isOpen();
-@@ -905,6 +966,10 @@
- }
- else
- return 2;
-+#else
-+ ((CdDevice *)this)->refreshDeviceData();
-+ return m_driveReady;
-+#endif
- }
-
-
-@@ -941,6 +1006,7 @@
- delete [] data;
- }
- else {
-+#ifndef __FreeBSD__
- kdDebug() << "(K3bCdDevice::CdDevice) " << blockDeviceName()
- << ": READ DISC INFORMATION failed. falling back to cdrom.h" << endl;
- int drive_status = ::ioctl(d->deviceFd,CDROM_DRIVE_STATUS);
-@@ -953,6 +1019,10 @@
- kdDebug() << "(K3bCdDevice::CdDevice) " << blockDeviceName() << ": No disk in drive" << endl;
- ret = NO_DISK;
- }
-+#else
-+ ((CdDevice *)this)->refreshDeviceData();
-+ ret = m_deviceStatus;
-+#endif
- }
-
- if( needToClose )
-@@ -1013,7 +1083,11 @@
- unsigned char header[2];
- ::memset( header, 0, 2 );
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x51; // READ DISC INFORMATION
- cmd[8] = 2;
-
-@@ -1199,6 +1273,7 @@
- bool readSuccess = true;
-
- if( !readSectorsRaw( data, lba, 1 ) ) {
-+#ifndef __FreeBSD__
- kdDebug() << "(K3bCdDevice::CdDevice) " << blockDeviceName()
- << ": MMC RAW READ failed. falling back to cdrom.h." << endl;
-
-@@ -1209,8 +1284,11 @@
- if( ::ioctl(d->deviceFd,CDROMREADRAW,data) == -1 ) {
- kdDebug() << "(K3bCdDevice::CdDevice) " << blockDeviceName()
- << ": could not get track header, (lba " << lba << ") ! " << strerror(errno) << endl;
-+#endif
- readSuccess = false;
-+#ifndef __FreeBSD__
- }
-+#endif
- }
-
- if( readSuccess ) {
-@@ -1556,7 +1634,7 @@
- bool success = true;
-
- toc.clear();
--
-+#ifndef __FreeBSD__
- struct cdrom_tochdr tochdr;
- struct cdrom_tocentry tocentry;
-
-@@ -1642,6 +1720,10 @@
- else
- success = false;
-
-+#else
-+ ((CdDevice *)this)->refreshDeviceData();
-+ toc = m_toc;
-+#endif
- return success;
- }
-
-@@ -1653,7 +1735,7 @@
- bool needToClose = !isOpen();
-
- bool success = false;
--
-+#ifndef __FreeBSD__
- if( open() != -1 ) {
- //
- // we probaly need to fixup the toc for multisession mixed-mode cds
-@@ -1681,7 +1763,7 @@
- kdDebug() << "(K3bCdDevice::CdDevice) CDROMMULTISESSION failed." << endl;
- }
- }
--
-+#endif
- if( needToClose )
- close();
-
-@@ -1692,17 +1774,25 @@
- bool K3bCdDevice::CdDevice::block( bool b ) const
- {
- if( open() != -1 ) {
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x1E; // ALLOW MEDIA REMOVAL
- cmd[4] = b ? 0x1 : 0x0;
- int r = cmd.transport();
- if( r ) {
- kdDebug() << "(K3bCdDevice::CdDevice) MMC ALLOW MEDIA REMOVAL failed. Falling back to cdrom.h." << endl;
-+#ifndef __FreeBSD__
- r = ::ioctl(d->deviceFd,CDROM_LOCKDOOR, b ? 1 : 0 );
-+#else
-+ r = ::ioctl(d->deviceFd,b ? CDIOCPREVENT : CDIOCALLOW);
-+#endif
- }
-
- if( r )
-- kdDebug() << "(K3bCdDevice) Cannot block/unblock device " << devicename() << endl;
-+ kdDebug() << "(K3bCdDevice) Cannot block/unblock device " << devicename() << ", errno: " << errno << endl;
-
- close();
- return ( r == 0 );
-@@ -1724,22 +1814,36 @@
-
- return e;
- }
-+#ifndef __FreeBSD__
- else
- return false;
-+#else
-+ ((CdDevice *)this)->refreshDeviceData();
-+ return m_rewritableCd;
-+#endif
- }
-
- bool K3bCdDevice::CdDevice::eject() const
- {
- block(false);
-
-+#ifndef __FreeBSD__
- if( open() != -1 ) {
- ScsiCommand cmd( open() );
-+#else
-+ if( true ) {
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x1B; // START/STOP UNIT
- cmd[4] = 0x2; // LoEj = 1, Start = 0
- int r = cmd.transport();
- if( r ) {
- kdDebug() << "(K3bCdDevice::CdDevice) MMC START/STOP UNIT failed. Falling back to cdrom.h." << endl;
-+#ifndef __FreeBSD__
- r = ::ioctl( d->deviceFd, CDROMEJECT );
-+#else
-+ r = bsd_open_close_device(m_bus, m_target, m_lun, true);
-+#endif
- }
-
- close();
-@@ -1752,14 +1856,23 @@
-
- bool K3bCdDevice::CdDevice::load() const
- {
-+#ifndef __FreeBSD__
- if( open() != -1 ) {
- ScsiCommand cmd( open() );
-+#else
-+ if( true ) {
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x1B; // START/STOP UNIT
- cmd[4] = 0x3; // LoEj = 1, Start = 1
- int r = cmd.transport();
- if( r ) {
- kdDebug() << "(K3bCdDevice::CdDevice) MMC START/STOP UNIT failed. Falling back to cdrom.h." << endl;
-+#ifndef __FreeBSD__
- r = ::ioctl( d->deviceFd, CDROMCLOSETRAY );
-+#else
-+ r = bsd_open_close_device(m_bus, m_target, m_lun, false);
-+#endif
- }
- close();
- return (r == 0);
-@@ -1793,7 +1906,7 @@
- d->deviceFd = openDevice( QFile::encodeName(devicename()) );
- if (d->deviceFd < 0)
- {
-- kdDebug() << "(K3bCdDevice) Error: could not open device." << endl;
-+ kdDebug() << "(K3bCdDevice) Error: could not open device: " << QFile::encodeName(devicename()) << endl;
- d->deviceFd = -1;
- }
-
-@@ -1915,7 +2028,11 @@
- unsigned char profileBuf[8];
- ::memset( profileBuf, 0, 8 );
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x46; // GET CONFIGURATION
- cmd[1] = 1;
- cmd[8] = 8;
-@@ -1974,7 +2091,11 @@
- }
- inf.m_currentProfile = profile;
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
-
- if( inf.diskState() != STATE_NO_MEDIA ) {
-
-@@ -2037,6 +2158,33 @@
-
- delete [] data;
- }
-+#ifdef __FreeBSD__
-+ else
-+ {
-+ ((CdDevice *)this)->refreshDeviceData();
-+ inf.m_rewritable = m_rewritableCd;
-+ inf.m_numSessions = m_toc.size();
-+ inf.m_capacity = m_discSize;
-+ inf.m_remaining = m_remainingSize;
-+ inf.m_diskState = STATE_UNKNOWN;
-+ inf.m_lastSessionState = STATE_UNKNOWN;
-+ if (m_deviceStatus == EMPTY)
-+ {
-+ inf.m_diskState = STATE_EMPTY;
-+ inf.m_lastSessionState = STATE_EMPTY;
-+ }
-+ else if (m_deviceStatus == APPENDABLE)
-+ {
-+ inf.m_diskState = STATE_INCOMPLETE;
-+ inf.m_lastSessionState = STATE_INCOMPLETE;
-+ }
-+ else if (m_deviceStatus == COMPLETE)
-+ {
-+ inf.m_diskState = STATE_COMPLETE;
-+ inf.m_lastSessionState = STATE_COMPLETE;
-+ }
-+ }
-+#endif
-
- //
- // Now we determine the size:
-@@ -2085,7 +2233,7 @@
- if( cmd.transport( TR_DIR_READ, trackHeader, 32 ) ) {
- kdDebug() << "(K3bCdDevice) READ_TRACK_INFORMATION failed." << endl;
- kdDebug() << "(K3bCdDevice) getting disk size via toc." << endl;
--
-+#ifndef __FreeBSD__
- // TODO: use readToc!
-
- struct cdrom_tocentry tocentry;
-@@ -2097,6 +2245,11 @@
- inf.m_capacity = tocentry.cdte_addr.lba;
- inf.m_capacity -= 1; // we need the last sector of the last track, not the first from the lead-out
- }
-+#else
-+ ((CdDevice *)this)->refreshDeviceData();
-+ inf.m_capacity = m_discSize;
-+ inf.m_capacity -= 1;
-+#endif
- }
- else {
- // not sure about this....
-@@ -2160,7 +2313,11 @@
-
- unsigned char dvdheader[20];
- ::memset( dvdheader, 0, 20 );
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0xad; // GPCMD_READ_DVD_STRUCTURE;
- cmd[9] = 20;
- if( cmd.transport( TR_DIR_READ, dvdheader, 20 ) ) {
-@@ -2199,7 +2356,11 @@
-
- bool success = true;
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x25; // READ CAPACITY
- unsigned char buf[8];
- ::memset( buf, 0, 8 );
-@@ -2236,7 +2397,11 @@
- unsigned char header[4]; // for reading the size of the returned data
- ::memset( header, 0, 4 );
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x23; // GPCMD_READ_FORMAT_CAPACITIES;
- cmd[8] = 4;
- if( cmd.transport( TR_DIR_READ, header, 4 ) == 0 ) {
-@@ -2324,7 +2489,11 @@
- unsigned char header[8];
- ::memset( header, 0, 8 );
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x5A; // MODE SENSE
- cmd[1] = 0x08; // Disable Block Descriptors
- cmd[2] = page;
-@@ -2362,7 +2531,11 @@
-
- bool ret = false;
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x55; // MODE SELECT
- cmd[1] = ( sp ? 1 : 0 ) | ( pf ? 0x10 : 0 );
- cmd[7] = pageLen>>8;
-@@ -2486,7 +2659,11 @@
- unsigned char header[2];
- ::memset( header, 0, 2 );
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0x43; // READ TOC/PMA/ATIP
- cmd[1] = ( time ? 0x2 : 0x0 );
- cmd[2] = format & 0x0F;
-@@ -2536,7 +2713,11 @@
- unsigned char header[8];
- ::memset( header, 0, 8 );
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0xbd; // MECHANISM STATUS
- cmd[8] = 8; // first we read the header
- if( cmd.transport( TR_DIR_READ, header, 8 ) == 0 ) {
-@@ -2640,7 +2821,11 @@
-
- ::memset( data, 0, dataLen );
-
-+#ifndef __FreeBSD__
- ScsiCommand cmd( open() );
-+#else
-+ ScsiCommand cmd(m_passDevice);
-+#endif
- cmd[0] = 0xbe; // READ CD
- cmd[1] = (sectorType<<2 & 0x1c) | ( dap ? 0x2 : 0x0 );
- cmd[2] = startAdress>>24;
-@@ -2668,3 +2853,363 @@
-
- return ret;
- }
-+#ifdef __FreeBSD__
-+void K3bDevice::CdDevice::refreshDeviceData()
-+{
-+ // was it called within the last 3 seconds?
-+ QDateTime now = QDateTime::currentDateTime();
-+ if (m_lastRefresh.isValid() && m_lastRefresh.secsTo(now) < 3)
-+ return; // yes: use previous values
-+
-+ m_driveReady = 0;
-+ m_rewritableCd = 0;
-+ m_discSize = 0;
-+ m_remainingSize = 0;
-+ m_deviceStatus = NO_INFO;
-+ m_toc.clear();
-+
-+ KTempFile tmpfile;
-+ tmpfile.setAutoDelete(true);
-+
-+ // call cdrecord -toc to get the toc and to detect empty disks
-+ QString call = "/bin/sh -c \"cdrecord -toc " + QString("dev=%1").arg( busTargetLun() ) + " > " + tmpfile.name() + " 2>&1 \"";
-+ kdDebug() << "(K3bCdDevice) Reading Toc : " << call << endl;
-+ system(call.latin1());
-+
-+ // read tmp file line by line
-+ K3bTrack lastTrack;
-+ bool firstEntry = true;
-+ QFile tmp (tmpfile.name());
-+ if ( tmp.open( IO_ReadOnly ) )
-+ {
-+ QTextStream stream( &tmp );
-+ bool done = false;
-+ while ( !stream.eof() )
-+ {
-+ QString str = stream.readLine();
-+ kdDebug() << "(K3bCdDevice): " << str << endl;
-+ if (done)
-+ continue;
-+ // no disk inserted?
-+ if ( str.startsWith( "cdrecord: No disk" ) )
-+ {
-+ m_driveReady = NO_DISK;
-+ kdDebug() << "(K3bCdDevice) No Toc Data!" << endl;
-+ // close and delete tmp file
-+ tmp.close();
-+ done = true;
-+ continue;
-+ }
-+ // emoty disk inserted?
-+ else if (str.startsWith("cdrecord: Cannot read TOC header"))
-+ {
-+ kdDebug() << "(K3bCdDevice) cd is empty" << endl;
-+ m_driveReady = EMPTY;
-+ }
-+ // track data available?
-+ if( str.startsWith("track:") )
-+ {
-+ // cdrecord produces the following outout:
-+ // <tracknumber> lba: <startSector> (<...>) <startTime> adr: 1 control: <trackType> mode: <trackMode>
-+ // the last tracknumber will always be "lout", the leadout of the cd which we only use to determine the
-+ // length of the last track
-+
-+ // we just want the startSector, the trackType, and the trackMode
-+ int start = 6; // skip the "track:"
-+ start = str.find(":", start )+1;
-+ int end = str.find( "(", start );
-+
-+ bool ok;
-+ int startSec = str.mid( start, end-start ).toInt(&ok);
-+ if( ok )
-+ {
-+ start = str.find( "control:", start )+8; // skip the "control:"
-+ end = str.find("mode:", start );
-+ int control = str.mid( start, end-start ).toInt(&ok);
-+ if( ok )
-+ {
-+ start = end + 6;
-+ int mode = str.mid( start ).toInt(&ok);
-+ if( ok )
-+ {
-+ // all values have been determined
-+ // since we need the start of the next track to determine the length we save the values
-+ // in lastTrack and append the current lastTrack to the toc
-+
-+ if( !firstEntry )
-+ {
-+ m_toc.append( K3bTrack( lastTrack.firstSector(), startSec-1, lastTrack.type(), lastTrack.mode() ) );
-+ kdDebug() << "(K3bCDDevice) Found track: first sector: " << lastTrack.firstSector().toString()
-+ << ", last sector: " << startSec-1 << ", type: " << lastTrack.type()
-+ << ", mode: " << lastTrack.mode() << endl;
-+ if (m_deviceStatus == EMPTY)
-+ m_deviceStatus = APPENDABLE;
-+ if( lastTrack.mode() == K3bTrack::MODE1 )
-+ m_deviceStatus = COMPLETE;
-+ }
-+ // now this is the meaning of control and mode:
-+ // control (combination of the following)
-+ // 0x01 - Audio with preemp
-+ // 0x02 - Audio copy permitted
-+ // 0x04 - Data track
-+ // 0x08 - 4 channel audio
-+
-+ // mode (only for data tracks)
-+ // 1 - Mode 1
-+ // 2 - Mode 2
-+
-+ int trackType = 0;
-+ int trackMode = K3bTrack::UNKNOWN;
-+ if( control & 0x04 )
-+ {
-+ trackType = K3bTrack::DATA;
-+ if( mode == 1 )
-+ trackMode = K3bTrack::MODE1;
-+ else if( mode == 2 )
-+ trackMode = K3bTrack::MODE2;
-+ }
-+ else
-+ trackType = K3bTrack::AUDIO;
-+
-+ lastTrack = K3bTrack( startSec, startSec, trackType, trackMode );
-+ firstEntry = false;
-+ }
-+ else
-+ {
-+ kdDebug() << "(K3bCdDevice) Could not parse mode of track: " << str.mid( start ) << endl;
-+ }
-+ }
-+ else
-+ {
-+ kdDebug() << "(K3bCdDevice) Could not parse control of track: " << str.mid( start, end-start ) << endl;
-+ }
-+ }
-+ else
-+ {
-+ kdDebug() << "(K3bCdDevice) Could not parse start sector of track: " << str.mid( start, end-start) << endl;
-+ }
-+ }
-+
-+ }
-+ // close and delete tmp file
-+ tmp.close();
-+
-+ }
-+ // skip further tests if there is no disk
-+ if (m_driveReady != NO_DISK && m_driveReady != NO_INFO)
-+ {
-+
-+ KTempFile tmpfile2;
-+ tmpfile2.setAutoDelete(true);
-+
-+ // call cdrdao disk-info to get disk capacities, device status, and dsik type
-+ call = "/bin/sh -c \"cdrdao disk-info --device " + QString("%1").arg( busTargetLun() ) + " --driver " + cdrdaoDriver() + " > " + tmpfile2.name() + " 2>&1 \"";
-+ kdDebug() << "(K3bCdDevice) Reading remaining disk size : " << call << endl;
-+ system(call.latin1());
-+
-+ // read tmp file line by line
-+ QFile tmp2(tmpfile2.name());
-+ if ( tmp2.open( IO_ReadOnly ) )
-+ {
-+ QTextStream stream( &tmp2 );
-+ while ( !stream.eof() )
-+ {
-+ QString str = stream.readLine();
-+ kdDebug() << "(K3bCdDevice): " << str << endl;
-+
-+ // remaining capacity available?
-+ if ( str.contains( "Remaining Capacity :" ) )
-+ {
-+ // cdrdao produces the following outout:
-+ // <remaining time> ( <remaining blocks> blocks, <remaining size> MB)
-+
-+ int start = str.find("(" )+1;
-+ int end = str.find( " ", start );
-+
-+ bool ok;
-+ int remaining = str.mid( start, end-start ).toInt(&ok);
-+ if( ok )
-+ {
-+ m_remainingSize = remaining-1;
-+ }
-+ else
-+ kdDebug() << "(K3bCdDevice) Could not parse remaining time: " << str.mid( start, end-start) << endl;
-+ }
-+
-+ // total capacity available?
-+ else if ( str.contains( "Total Capacity :" ) )
-+ {
-+ // cdrdao produces the following outout:
-+ // <time> ( <blocks> blocks, <size> MB)
-+
-+ int start = str.find("(" )+1;
-+ int end = str.find( " ", start );
-+
-+ bool ok;
-+ int total = str.mid( start, end-start ).toInt(&ok);
-+ if( ok )
-+ {
-+ m_discSize = total-1;
-+ }
-+ else
-+ kdDebug() << "(K3bCdDevice) Could not parse total time: " << str.mid( start, end-start) << endl;
-+ }
-+
-+ // is it an empty CD?
-+ else if (str.startsWith("CD-R empty : yes"))
-+ {
-+ m_deviceStatus = EMPTY;
-+ kdDebug() << "(K3bCdDevice) device status: empty" << endl;
-+ }
-+
-+ // is the last session closed?
-+ else if (str.startsWith("Appendable : no"))
-+ {
-+ m_deviceStatus = COMPLETE;
-+ kdDebug() << "(K3bCdDevice) device status: complete" << endl;
-+ }
-+
-+ // is the last session open?
-+ else if (str.startsWith("Appendable : yes"))
-+ {
-+ m_deviceStatus = APPENDABLE;
-+ kdDebug() << "(K3bCdDevice) device status: appendable" << endl;
-+ }
-+
-+ // is it a cd-rw?
-+ else if (str.startsWith("CD-RW : yes"))
-+ {
-+ kdDebug() << "(K3bCdDevice) cd is erasable" << endl;
-+ m_rewritableCd = 1;
-+ }
-+
-+ }
-+ // close and delete tmp2 file
-+ tmp2.close();
-+ }
-+
-+ if (m_discSize.toString() == "00:00:00") // cdrdao failed somehow
-+ {
-+
-+ KTempFile tmpfile3;
-+ tmpfile3.setAutoDelete(true);
-+
-+ //create call
-+ QString call = "/bin/sh -c \"cdrecord -atip " + QString("dev=%1").arg( busTargetLun() ) + " > " + tmpfile3.name() + " 2>&1 \"";
-+ kdDebug() << "(K3bCdDevice) Reading disk size : " << call << endl;
-+ system(call.latin1());
-+
-+ // read tmp file line by line
-+ K3bTrack lastTrack;
-+ QFile tmp3(tmpfile3.name());
-+ if ( tmp3.open( IO_ReadOnly ) )
-+ {
-+ QTextStream stream( &tmp3 );
-+ while ( !stream.eof() )
-+ {
-+ QString str = stream.readLine();
-+ if (str.startsWith(" Is erasable"))
-+ {
-+ m_rewritableCd = 1;
-+ }
-+ else if( str.startsWith(" ATIP start of lead out:") )
-+ {
-+ // cdrecord produces the following outout:
-+ // <tracknumber> lba: <startSector> (<...>) <startTime> adr: 1 control: <trackType> mode: <trackMode>
-+ // the last tracknumber will always be "lout", the leadout of the cd which we only use to determine the
-+ // length of the last track
-+
-+ // we just want the startSector, the trackType, and the trackMode
-+ int start = 6; // skip the "track:"
-+ start = str.find(":", start )+1;
-+ int end = str.find( "(", start )-1;
-+
-+ bool ok;
-+ int leadOut = str.mid( start, end-start ).toInt(&ok);
-+ if( ok )
-+ m_discSize = leadOut;
-+ else
-+ kdDebug() << "(K3bCdDevice) Could not parse lead out: " << str.mid( start, end-start) << endl;
-+ }
-+
-+ }
-+ // close and delete tmp3 file
-+ tmp3.close();
-+ }
-+ }
-+
-+ }
-+
-+ // print out cd data
-+ kdDebug() << "(K3bCdDevice) disk size: " << m_discSize.toString() << endl;
-+ kdDebug() << "(K3bCdDevice) remaining size: " << m_remainingSize.toString() << endl;
-+ kdDebug() << "(K3bCdDevice) total size: " << m_discSize.toString() << endl;
-+ kdDebug() << "(K3bCdDevice) drive ready: " << m_driveReady << endl;
-+
-+ if (m_deviceStatus == EMPTY)
-+ kdDebug() << "(K3bCdDevice) device status: empty" << endl;
-+ else if (m_deviceStatus == APPENDABLE)
-+ kdDebug() << "(K3bCdDevice) device status: appendable" << endl;
-+ else if (m_deviceStatus == COMPLETE)
-+ kdDebug() << "(K3bCdDevice) device status: complete" << endl;
-+ else if (m_deviceStatus == NO_DISK)
-+ kdDebug() << "(K3bCdDevice) device status: no disk" << endl;
-+ else if (m_deviceStatus == NO_INFO)
-+ kdDebug() << "(K3bCdDevice) device status: no info" << endl;
-+ if (m_rewritableCd)
-+ kdDebug() << "(K3bCdDevice) cd is erasable" << endl;
-+ else
-+ kdDebug() << "(K3bCdDevice) cd is not erasable" << endl;
-+
-+ // reset timer
-+ m_lastRefresh = QDateTime::currentDateTime();
-+}
-+
-+void K3bDevice::CdDevice::addDeviceType(DeviceType type)
-+{
-+ d->deviceType |= type;
-+}
-+
-+int bsd_open_close_device(int bus, int target, int lun, bool eject)
-+{
-+ union ccb *ccb;
-+ int error = 0;
-+ struct cam_device *cam_dev = cam_open_btl(bus, target, lun, O_RDWR, NULL);
-+ ccb = cam_getccb(cam_dev);
-+ bool startstop = false;
-+ scsi_start_stop(&ccb->csio, 1, NULL, startstop ? MSG_SIMPLE_Q_TAG :MSG_ORDERED_Q_TAG, startstop,
-+ eject, 0, SSD_FULL_SIZE, 120000);
-+ ccb->ccb_h.flags |= CAM_DEV_QFRZDIS;
-+ if (cam_send_ccb(cam_dev, ccb) < 0) {
-+ perror("error sending start unit");
-+
-+ cam_freeccb(ccb);
-+ return(1);
-+ }
-+
-+ if ((ccb->ccb_h.status & CAM_STATUS_MASK) == CAM_REQ_CMP)
-+ if (startstop)
-+ {
-+ kdDebug() << "(K3bCdDevice) bsd_open_close_device: Unit started successfully" << endl;
-+ if (eject)
-+ kdDebug() << "(K3bCdDevice) bsd_open_close_device: Media loaded" << endl;
-+ }
-+ else
-+ {
-+ kdDebug() << "(K3bCdDevice) bsd_open_close_device: Unit stopped successfully" << endl;
-+ if (eject)
-+ kdDebug() << "(K3bCdDevice) bsd_open_close_device: Media ejected" << endl;
-+ }
-+ else
-+ {
-+ error = 1;
-+ if (startstop)
-+ kdDebug() << "(K3bCdDevice) bsd_open_close_device: Error received from start unit command" << endl;
-+ else
-+ kdDebug() << "(K3bCdDevice) bsd_open_close_device: Error received from stop unit command" << endl;
-+ }
-+ cam_freeccb(ccb);
-+ return error;
-+}
-+
-+#endif
diff --git a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.h b/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.h
deleted file mode 100644
index 7ec39a99dbdb..000000000000
--- a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevice.h
+++ /dev/null
@@ -1,50 +0,0 @@
---- src/core/device/k3bdevice.h.orig Thu Oct 23 10:37:05 2003
-+++ src/core/device/k3bdevice.h Fri Nov 7 12:35:44 2003
-@@ -21,6 +21,10 @@
- #include <k3bdiskinfo.h>
- #include <k3bcdtext.h>
- #include <k3bmsf.h>
-+#ifdef __FreeBSD__
-+#include "k3btoc.h"
-+#include <qdatetime.h>
-+#endif
-
-
- namespace K3bCdDevice
-@@ -43,10 +47,10 @@
- CDROM = 4,
- DVD = 8,
- DVDRAM = 16,
-- DVDR = 32,
-- DVDRW = 64,
-- DVDPR = 128,
-- DVDPRW = 256 };
-+ DVDR = 32, // "minus"
-+ DVDRW = 64, // "minus"
-+ DVDPR = 128, // "plus"
-+ DVDPRW = 256 }; // "plus"
- enum DiskStatus { EMPTY = 0,
- APPENDABLE = 1,
- COMPLETE = 2,
-@@ -420,6 +424,21 @@
- private:
- class Private;
- Private* d;
-+#ifdef __FreeBSD__
-+ // allow K3bDeviceManager::initializeScsiDevice to set the device types
-+ void addDeviceType(CdDevice::DeviceType type);
-+
-+ // allow K3bDeviceManager::initializeScsiDevice to guess the profiles, if none where found so far
-+ void guessProfiles();
-+
-+ Toc m_toc;
-+ int m_driveReady, m_rewritableCd;
-+ K3b::Msf m_discSize, m_remainingSize;
-+ void refreshDeviceData();
-+ QDateTime m_lastRefresh;
-+ int m_deviceStatus;
-+ QString m_passDevice;
-+#endif
- friend class DeviceManager;
- };
-
diff --git a/sysutils/k3b-kde4/files/patch-src-core-device-k3bscsicommand.h b/sysutils/k3b-kde4/files/patch-src-core-device-k3bscsicommand.h
deleted file mode 100644
index be3979b107a4..000000000000
--- a/sysutils/k3b-kde4/files/patch-src-core-device-k3bscsicommand.h
+++ /dev/null
@@ -1,51 +0,0 @@
---- src/core/device/k3bscsicommand.h.orig Mon Oct 20 22:29:12 2003
-+++ src/core/device/k3bscsicommand.h Fri Nov 7 12:35:44 2003
-@@ -17,9 +17,9 @@
- #define _K3B_SCSI_COMMAND_H_
-
- #include <sys/types.h>
--#undef __STRICT_ANSI__
--#include <linux/cdrom.h>
--#define __STRICT_ANSI__
-+#include <stdio.h>
-+#include <camlib.h>
-+#include <qstring.h>
-
-
- namespace K3bCdDevice
-@@ -29,15 +29,17 @@
- // see transport.hxx for a BSD version
-
- enum TransportDirection {
-- TR_DIR_NONE,
-- TR_DIR_READ,
-- TR_DIR_WRITE
-+ TR_DIR_NONE = 0,
-+ TR_DIR_READ = CAM_DIR_IN,
-+ TR_DIR_WRITE = CAM_DIR_OUT
- };
-
- class ScsiCommand
- {
- public:
-- ScsiCommand( int fd );
-+ ScsiCommand( const QString & passDevice );
-+
-+ ~ScsiCommand();
-
- void clear();
-
-@@ -48,10 +50,9 @@
- size_t len = 0 );
-
- private:
-- struct cdrom_generic_command m_cmd;
-- struct request_sense m_sense;
--
-- int m_fd;
-+ struct cam_device *cam;
-+ union ccb ccb;
-+ QString m_passDevice;
- };
- }
-
diff --git a/sysutils/k3b-kde4/files/patch-src-core-k3bdefaultexternalprograms.cpp b/sysutils/k3b-kde4/files/patch-src-core-k3bdefaultexternalprograms.cpp
index 81c20927545b..008a58d004fe 100644
--- a/sysutils/k3b-kde4/files/patch-src-core-k3bdefaultexternalprograms.cpp
+++ b/sysutils/k3b-kde4/files/patch-src-core-k3bdefaultexternalprograms.cpp
@@ -1,24 +1,23 @@
---- src/core/k3bdefaultexternalprograms.cpp.orig Fri Sep 26 14:04:36 2003
-+++ src/core/k3bdefaultexternalprograms.cpp Fri Nov 7 12:35:44 2003
-@@ -28,7 +28,7 @@
+--- src/core/k3bdefaultexternalprograms.cpp.orig Wed Jan 21 11:20:10 2004
++++ src/core/k3bdefaultexternalprograms.cpp Fri Feb 13 21:03:38 2004
+@@ -28,6 +28,7 @@
#include <unistd.h>
#include <sys/stat.h>
#include <stdlib.h>
--
+#include "k3bprocess.h"
- void K3b::addDefaultPrograms( K3bExternalBinManager* m )
-@@ -89,7 +89,7 @@
+
+@@ -89,7 +90,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
vp << path << "-version";
-@@ -128,7 +128,7 @@
+@@ -128,7 +129,7 @@
// probe features
@@ -27,16 +26,16 @@
out.setProcess( &fp );
fp << path << "-help";
if( fp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -200,7 +200,7 @@
+@@ -200,7 +201,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
vp << path << "-version";
-@@ -229,7 +229,7 @@
+@@ -229,7 +230,7 @@
// probe features
@@ -45,16 +44,16 @@
out.setProcess( &fp );
fp << path << "-help";
if( fp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -285,7 +285,7 @@
+@@ -285,7 +286,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
vp << path << "-version";
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
if( vp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -313,7 +313,7 @@
+@@ -313,7 +314,7 @@
// probe features
@@ -63,16 +62,16 @@
fp << path << "-help";
out.setProcess( &fp );
if( fp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -374,7 +374,7 @@
+@@ -374,7 +375,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
vp << path << "-version";
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
if( vp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -402,7 +402,7 @@
+@@ -402,7 +403,7 @@
// probe features
@@ -81,16 +80,16 @@
fp << path << "-help";
out.setProcess( &fp );
if( fp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -462,7 +462,7 @@
+@@ -462,7 +463,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
vp << path ;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
if( vp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -490,7 +490,7 @@
+@@ -490,7 +491,7 @@
// probe features
@@ -99,75 +98,57 @@
fp << path << "write" << "-h";
out.setProcess( &fp );
if( fp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -554,7 +554,7 @@
+@@ -556,7 +557,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
vp << path ;
- OutputCollector out( &vp );
- if( vp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -604,7 +604,7 @@
- K3bExternalBin* bin = 0;
-
- // probe version
-- KProcess vp;
-+ MyKProcess vp;
- vp << path;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
if( vp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -631,7 +631,7 @@
- return false;
- }
-
-- KProcess cp;
-+ MyKProcess cp;
- cp << path;
- out.setProcess( &cp );
- if( cp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -694,7 +694,7 @@
+@@ -610,7 +611,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
vp << path << "-V";
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
if( vp.start( KProcess::Block, KProcess::AllOutput ) ) {
-@@ -751,7 +751,7 @@
+@@ -667,7 +668,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
vp << path << "--version";
-@@ -810,7 +810,7 @@
+@@ -726,7 +727,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
vp << path << "-version";
-@@ -879,7 +879,7 @@
+@@ -795,7 +796,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
vp << path;
-@@ -952,7 +952,7 @@
+@@ -868,7 +869,7 @@
K3bExternalBin* bin = 0;
// probe version
- KProcess vp;
+ MyKProcess vp;
- OutputCollector out( &vp );
+ K3bProcess::OutputCollector out( &vp );
vp << path << "-h";
diff --git a/sysutils/k3b-kde4/files/patch-src-core-k3bglobals.cpp b/sysutils/k3b-kde4/files/patch-src-core-k3bglobals.cpp
deleted file mode 100644
index 711480a51930..000000000000
--- a/sysutils/k3b-kde4/files/patch-src-core-k3bglobals.cpp
+++ /dev/null
@@ -1,16 +0,0 @@
---- src/core/k3bglobals.cpp.orig Mon Sep 29 13:16:55 2003
-+++ src/core/k3bglobals.cpp Fri Nov 7 12:35:44 2003
-@@ -30,8 +30,12 @@
-
- #include <cmath>
- #include <sys/utsname.h>
-+#ifdef __FreeBSD__
-+#include <sys/param.h>
-+#include <sys/mount.h>
-+#else
- #include <sys/vfs.h>
--
-+#endif
-
-
- struct Sample {
diff --git a/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.cpp b/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.cpp
index 2453710cd98f..14543eb14ea8 100644
--- a/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.cpp
+++ b/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.cpp
@@ -1,6 +1,6 @@
---- src/core/k3bprocess.cpp.orig Thu Sep 25 13:34:51 2003
-+++ src/core/k3bprocess.cpp Fri Nov 7 12:35:44 2003
-@@ -27,7 +27,60 @@
+--- src/core/k3bprocess.cpp.orig Sun Feb 1 09:18:58 2004
++++ src/core/k3bprocess.cpp Fri Feb 13 21:03:38 2004
+@@ -28,6 +28,60 @@
#include <unistd.h>
#include <stdio.h>
#include <fcntl.h>
@@ -12,7 +12,7 @@
+ m_args += " " + arg;
+ return *this;
+}
-
++
+MyKProcess &MyKProcess::operator<<(const char * arg)
+{
+ m_args += " ";
@@ -31,14 +31,14 @@
+ // create temp file
+ KTempFile tmpfile;
+ tmpfile.setAutoDelete(true);
-+
++
+ // create call
+ QString call = "/bin/sh -c \"" + m_args + " > " + tmpfile.name() + " 2>&1 \"";
+ printf("MyKProcess call: %s\n", call.latin1());
-+
++
+ // execute it
+ system(call.latin1());
-+
++
+ // read tmp file line by line
+ QFile tmp (tmpfile.name());
+ if ( tmp.open( IO_ReadOnly ) )
@@ -48,11 +48,11 @@
+ {
+ QString s = stream.readLine() + "\n";
+ printf("MyKProcess reponse: %s", s.latin1());
-+
++
+ // send line to receivedStdout signal
+ receivedStdout(this, (char *)s.latin1(), strlen(s.latin1()));
+ }
-+
++
+ // close and delete tmp file
+ tmp.close();
+ }
@@ -60,4 +60,4 @@
+}
- class K3bProcess::Private
+
diff --git a/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.h b/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.h
index 23f15634e044..f4f96946d694 100644
--- a/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.h
+++ b/sysutils/k3b-kde4/files/patch-src-core-k3bprocess.h
@@ -1,7 +1,7 @@
---- src/core/k3bprocess.h.orig Fri Aug 29 17:32:44 2003
-+++ src/core/k3bprocess.h Fri Nov 7 12:35:44 2003
-@@ -126,5 +126,22 @@
- bool m_suppressEmptyLines;
+--- src/core/k3bprocess.h.orig Tue Jan 27 09:19:13 2004
++++ src/core/k3bprocess.h Fri Feb 13 21:03:38 2004
+@@ -194,4 +194,21 @@
+ KProcess* m_process;
};
+/** This is a KProcess fake class. It uses system() to call the process
@@ -21,5 +21,4 @@
+ MyKProcess &operator<<(const QCString & arg);
+ bool start(RunMode runmode = NotifyOnExit, Communication comm = NoCommunication);
+};
-
#endif
diff --git a/sysutils/k3b-kde4/files/patch-src-device-k3bdevice.cpp b/sysutils/k3b-kde4/files/patch-src-device-k3bdevice.cpp
new file mode 100644
index 000000000000..c3e8d0ce63d7
--- /dev/null
+++ b/sysutils/k3b-kde4/files/patch-src-device-k3bdevice.cpp
@@ -0,0 +1,26 @@
+--- src/device/k3bdevice.cpp.orig Thu Feb 12 11:21:15 2004
++++ src/device/k3bdevice.cpp Fri Feb 13 21:03:38 2004
+@@ -56,6 +56,12 @@
+
+ #endif // Q_OS_LINUX
+
++#ifdef __FreeBSD__
++#define __BYTE_ORDER BYTE_ORDER
++#define __BIG_ENDIAN BIG_ENDIAN
++#define CD_FRAMESIZE_RAW 2352
++#endif
++
+
+ #ifdef HAVE_RESMGR
+ extern "C" {
+@@ -152,8 +158,10 @@
+
+ d->supportedProfiles = 0;
+
++#ifndef __FreeBSD__
+ if(open() < 0)
+ return false;
++#endif
+
+
+ //
diff --git a/sysutils/k3b-kde4/files/patch-src-device-k3bdevice.h b/sysutils/k3b-kde4/files/patch-src-device-k3bdevice.h
new file mode 100644
index 000000000000..ecb893f0d514
--- /dev/null
+++ b/sysutils/k3b-kde4/files/patch-src-device-k3bdevice.h
@@ -0,0 +1,13 @@
+--- src/device/k3bdevice.h.orig Fri Jan 30 11:28:15 2004
++++ src/device/k3bdevice.h Fri Feb 13 21:03:38 2004
+@@ -654,6 +654,10 @@
+
+ class Private;
+ Private* d;
++#ifdef __FreeBSD__
++ QString m_passDevice;
++ friend class ScsiCommand;
++#endif
+ friend class DeviceManager;
+ };
+
diff --git a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevicemanager.cpp b/sysutils/k3b-kde4/files/patch-src-device-k3bdevicemanager.cpp
index 3f2d5de115e2..75ba9c14b38f 100644
--- a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevicemanager.cpp
+++ b/sysutils/k3b-kde4/files/patch-src-device-k3bdevicemanager.cpp
@@ -1,47 +1,26 @@
---- src/core/device/k3bdevicemanager.cpp.orig Sun Nov 2 15:42:06 2003
-+++ src/core/device/k3bdevicemanager.cpp Fri Nov 7 12:35:44 2003
-@@ -33,7 +33,13 @@
-
- #include <iostream>
- #include <fstab.h>
-+#ifndef __FreeBSD__
- #include <mntent.h>
-+#else
-+#include <sys/param.h>
-+#include <sys/ucred.h>
-+#include <sys/mount.h>
-+#endif
- #include <stdio.h>
- #include <stdlib.h>
- #include <fcntl.h>
-@@ -42,6 +48,11 @@
+--- src/device/k3bdevicemanager.cpp.orig Wed Jan 21 11:20:10 2004
++++ src/device/k3bdevicemanager.cpp Fri Feb 13 21:03:38 2004
+@@ -49,6 +49,12 @@
#include <sys/stat.h>
#include <sys/ioctl.h>
- #include <limits.h>
+
+#ifdef __FreeBSD__
+#include <osreldate.h>
+#include <ktempfile.h>
+#include <sys/param.h>
-+#else
-
- /* Fix definitions for 2.5 kernels */
- #include <linux/version.h>
-@@ -80,6 +91,7 @@
- (SCSI_DISK_MAJOR(M) \
- || (M) == SCSI_CDROM_MAJOR)
- #endif /* #ifndef SCSI_BLK_MAJOR */
+#endif
++
- class K3bCdDevice::DeviceManager::Private
- {
-@@ -194,6 +206,22 @@
+ #ifdef Q_OS_LINUX
+
+@@ -196,6 +202,22 @@
{
m_foundDevices = 0;
+#ifdef __FreeBSD__
+// What k3b does here is the following: it takes a list of device point, which are good candidates for cd drives
-+// and asks their properties. If they are indeed cd drives, they are added to a device list. This does not work
-+// on FreeBSD (no corresponding ioctls). Here cdrecord is asked for a list of scsi device, which work as cd
++// and asks their properties. If they are indeed cd drives, they are added to a device list. This does not work
++// on FreeBSD (no corresponding ioctls). Here cdrecord is asked for a list of scsi device, which work as cd
+// drives. The device points of those devices are added to the device list.
+ bsd_scan_devices(false);
+ kdDebug() << "(K3bDeviceManager) analyze found device" << endl;
@@ -57,7 +36,7 @@
QFile info("/proc/sys/dev/cdrom/info");
QString line,devstring;
info.open(IO_ReadOnly);
-@@ -284,6 +312,7 @@
+@@ -286,6 +308,7 @@
// m_foundDevices++;
// }
@@ -65,153 +44,7 @@
scanFstab();
return m_foundDevices;
-@@ -426,10 +455,11 @@
-
- void K3bCdDevice::DeviceManager::determineCapabilities(K3bDevice *dev)
- {
-+#ifndef __FreeBSD__
- // we just need to do this for writers since we use it to determine the writing modes
- if( !dev->burner() )
- return;
--
-+#endif
-
- // we do not use the user configured cdrecord here since we want to make sure
- // to get all the capabilities of the system
-@@ -480,9 +510,17 @@
- dev->m_burner = true;
- dev->m_writeModes = 0;
- QStringList lines = QStringList::split( "\n", m_processOutput );
-+#ifdef __FreeBSD__
-+ bool done = false;
-+#endif
- for( QStringList::const_iterator it = lines.begin(); it != lines.end(); ++it )
- {
- const QString& line = *it;
-+#ifdef __FreeBSD__
-+ kdDebug() << "(K3bDeviceManager): " << line << endl;
-+ if (done)
-+ continue;
-+#endif
-
- // no info in cdrecord <= 1.10 !!!!!
- if( line.startsWith( "Supported modes" ) )
-@@ -504,7 +542,11 @@
- dev->m_writeModes |= K3bDevice::RAW_R96R;
- if( modes.contains( "RAW/R96P" ) )
- dev->m_writeModes |= K3bDevice::RAW_R96P;
-+#ifdef __FreeBSD__
-+ done = true;
-+#else
- break;
-+#endif
- }
- }
- }
-@@ -515,12 +557,110 @@
- if( dev->m_writeModes == 0 )
- dev->m_writeModes = K3bDevice::SAO|K3bDevice::TAO;
- }
-+#ifdef __FreeBSD__
-+// For some unknown reason KDE stdout redirection fails on cdrecord -prcap (FreeBSD) :-(
-+// See http://www.FreeBSD.org/cgi/query-pr.cgi?pr=ports/51651
-+// So it is written to a temp file here
-+ KTempFile tmpfile;
-+ tmpfile.setAutoDelete(true);
-+ QString call = cdrecordBin->path + " " + QString("dev=%1").arg(dev->busTargetLun()) + " -prcap > " + tmpfile.name();
-+ kdDebug() << "(K3bDeviceManager) calling: " << call << endl;
-+ int result = system(call.latin1());
-+ if (!result)
-+ kdDebug() << "(K3bDeviceManager) call failed: " << result << endl;
-+ QFile tmp (tmpfile.name());
-+ if ( tmp.open( IO_ReadOnly ) )
-+ {
-+ QTextStream stream( &tmp );
-+ while ( !stream.eof() )
-+ {
-+ QString line = stream.readLine();
-+ kdDebug() << "(K3bDeviceManager): " << line << endl;
-+ if( line.startsWith(" ") )
-+ {
-+ if( line.contains("write CD-R media") )
-+ {
-+ bool b = !line.contains( "not" );
-+ dev->m_burner = b;
-+ kdDebug() << "(K3bDeviceManager) is burner: " << b << endl;
-+ if (b)
-+ {
-+ dev->addDeviceType(K3bDevice::CDR);
-+ kdDebug() << "(K3bDeviceManager) device type: CDR" << endl;
-+ }
-+ }
-+
-+ else if( line.contains("write CD-RW media") )
-+ {
-+ bool b = !line.contains( "not" );
-+ dev->m_bWritesCdrw = b;
-+ kdDebug() << "(K3bDeviceManager) writes cdr: " << b << endl;
-+ if (b)
-+ {
-+ dev->addDeviceType(K3bDevice::CDRW);
-+ kdDebug() << "(K3bDeviceManager) device type: CDRW" << endl;
-+ }
-+ }
-+
-+ else if( line.contains("Buffer-Underrun-Free recording") ||
-+ line.contains("support BURN-Proof") )
-+ {
-+ bool b = !line.contains( "not" );
-+ dev->setBurnproof(b);
-+ kdDebug() << "(K3bDeviceManager) burn proof: " << b << endl;
-+ }
-+
-+ else if( line.contains( "Maximum read speed" ) ) //lukas: are there really two spaces? trueg: Yes, there are! ;)
-+ dev->m_maxReadSpeed = K3b::round( line.mid( line.find(":")+1 ).toDouble() * 1000.0 / ( 2352.0 * 75.0 ) );
-+
-+ else if( line.contains( "Maximum write speed" ) )
-+{
-+ dev->m_maxWriteSpeed = K3b::round( line.mid( line.find(":")+1 ).toDouble() * 1000.0 / ( 2352.0 * 75.0 ) );
-+}
-+ else if( line.contains( "Does read CD-R media" ) )
-+ {
-+ dev->addDeviceType(K3bDevice::CDROM);
-+ kdDebug() << "(K3bDeviceManager) device type: CDROM" << endl;
-+ }
-+ else if( line.contains( "Does write DVD-R media" ) )
-+ {
-+ dev->addDeviceType(K3bDevice::DVDR);
-+ kdDebug() << "(K3bDeviceManager) device type: DVDR" << endl;
-+ }
-+ else if( line.contains( "Does write DVD-RAM media" ) )
-+ {
-+ dev->addDeviceType(K3bDevice::DVDRAM);
-+ kdDebug() << "(K3bDeviceManager) device type: DVDRAM" << endl;
-+ }
-+ else if( line.contains( "Does read DVD-ROM media" ) )
-+ {
-+ dev->addDeviceType(K3bDevice::DVD);
-+ kdDebug() << "(K3bDeviceManager) device type: DVD" << endl;
-+ }
-+ else if( line.contains( "Buffer size" ) )
-+ dev->m_bufferSize = line.mid( line.find(":")+1 ).toInt();
-+ }
-+ else if( line.startsWith("Vendor_info") )
-+ dev->m_vendor = line.mid( line.find(":")+3, 8 ).stripWhiteSpace();
-+ else if( line.startsWith("Identifikation") )
-+ dev->m_description = line.mid( line.find(":")+3, 16 ).stripWhiteSpace();
-+ else if( line.startsWith("Revision") )
-+ dev->m_version = line.mid( line.find(":")+3, 4 ).stripWhiteSpace();
-+ else
-+ kdDebug() << "(K3bDeviceManager) unused cdrecord output: " << line << endl;
-+
-+ }
-+ tmp.close();
-+ }
-+ dev->guessProfiles();
-+#endif
- }
-
-
+@@ -427,6 +450,7 @@
bool K3bCdDevice::DeviceManager::testForCdrom(const QString& devicename)
{
bool ret = false;
@@ -219,9 +52,9 @@
int cdromfd = K3bCdDevice::openDevice( devicename.ascii() );
if (cdromfd < 0) {
kdDebug() << "could not open device " << devicename << " (" << strerror(errno) << ")" << endl;
-@@ -549,11 +689,51 @@
- }
+@@ -467,11 +491,51 @@
}
+
::close( cdromfd );
+#endif
return ret;
@@ -239,7 +72,7 @@
+ bool found = false;
+ for ( QValueList<BSDDevice>::iterator it = m_devices.begin(); it != m_devices.end(); ++it )
+ {
-+ if( (*it).m_name == devicename )
++ if( (*it).m_name == devicename )
+ {
+ device = new K3bDevice((*it).m_name.latin1());
+ device->m_bus = (*it).m_bus;
@@ -271,79 +104,28 @@
K3bDevice* device = 0;
// resolve all symlinks
-@@ -586,6 +766,7 @@
+@@ -503,6 +567,7 @@
+ device->m_target = target;
device->m_lun = lun;
}
-
+#endif
+
if( !device->init() ) {
kdDebug() << "Could not initialize device " << devicename << endl;
- delete device;
-@@ -623,13 +804,14 @@
-
- void K3bCdDevice::DeviceManager::scanFstab()
- {
-+#ifndef __FreeBSD__
- FILE* fstabFile = setmntent( _PATH_FSTAB, "r" );
- if( !fstabFile )
- {
- kdDebug() << "(K3bDeviceManager) could not open " << _PATH_FSTAB << endl;
- return;
- }
--
-+#endif
-
- // clear all mount-Infos
- for( QPtrListIterator<K3bDevice> it( d->allDevices ); it.current(); ++it )
-@@ -639,12 +821,22 @@
- }
-
-
-+#ifndef __FreeBSD__
- struct mntent* mountInfo = 0;
- while( (mountInfo = ::getmntent( fstabFile )) )
-+#else
-+ struct fstab * mountInfo = 0;
-+ while( (mountInfo = ::getfsent()) )
-+#endif
- {
- // check if the entry corresponds to a device
-+#ifndef __FreeBSD__
- QString md = QFile::decodeName( mountInfo->mnt_fsname );
- QString type = QFile::decodeName( mountInfo->mnt_type );
-+#else
-+ QString md = QFile::decodeName( mountInfo->fs_spec );
-+ QString type = QFile::decodeName( mountInfo->fs_vfstype );
-+#endif
-
- bool supermount = false;
-
-@@ -652,7 +844,11 @@
- supermount = true;
-
- // parse the device
-+#ifndef __FreeBSD__
- QStringList opts = QStringList::split( ",", QString::fromLocal8Bit(mountInfo->mnt_opts) );
-+#else
-+ QStringList opts = QStringList::split( ",", QString::fromLocal8Bit(mountInfo->fs_mntops) );
-+#endif
- for( QStringList::const_iterator it = opts.begin(); it != opts.end(); ++it ) {
- if( (*it).startsWith("dev=") ) {
- md = (*it).mid( 4 );
-@@ -668,9 +864,20 @@
+@@ -578,9 +643,20 @@
if( K3bDevice* dev = findDevice( resolveSymLink(md) ) )
{
+#ifndef __FreeBSD__
kdDebug() << "(K3bDeviceManager) found device for " << md << ": " << resolveSymLink(md) << endl;
if( dev->mountDevice().isEmpty() ) {
- dev->setMountPoint( mountInfo->mnt_dir );
+ dev->setMountPoint( mountInfo->fs_file );
+#else
+ kdDebug() << "(K3bDeviceManager) found device for " << md << " (" << resolveSymLink(md) << "): " << mountInfo->fs_file << endl;
+// Several mount points for one device might exist. If more than one are found, the one with
+// user permission should have a higher priority.
+ struct stat filestat;
-+ if( dev->mountDevice().isEmpty() || (mountInfo->fs_file && !stat(mountInfo->fs_file, &filestat) && filestat.st_uid == geteuid()))
++ if( dev->mountDevice().isEmpty() || (mountInfo->fs_file && !stat(mountInfo->fs_file, &filestat) && filestat.st_uid == geteuid()))
+ {
+ kdDebug() << "(K3bDeviceManager) setting mount point for device " << md << ": " << mountInfo->fs_file << endl;
+ dev->setMountPoint( mountInfo->fs_file );
@@ -351,16 +133,16 @@
dev->setMountDevice( md );
dev->m_supermount = supermount;
}
-@@ -679,6 +886,8 @@
+@@ -589,6 +665,8 @@
{
// compare bus, id, lun since the same device can for example be
// determined as /dev/srX or /dev/scdX
+#ifndef __FreeBSD__
+// On FreeBSD scsi parameters can not be extracted from a file handle
int bus = -1, id = -1, lun = -1;
- if( determineBusIdLun( mountInfo->mnt_fsname, bus, id, lun ) ) {
+ if( determineBusIdLun( mountInfo->fs_spec, bus, id, lun ) ) {
if( K3bDevice* dev = findDevice( bus, id, lun ) ) {
-@@ -689,12 +898,27 @@
+@@ -599,6 +677,17 @@
}
}
}
@@ -378,45 +160,10 @@
}
- } // while mountInfo
-
-+#ifndef __FreeBSD__
- endmntent( fstabFile );
-+#else
-+ endfsent();
-+#endif
+@@ -673,5 +762,126 @@
+ return QString::fromLatin1( resolved );
}
-
-@@ -707,6 +931,8 @@
- bool K3bCdDevice::DeviceManager::determineBusIdLun( const QString& dev, int& bus, int& id, int& lun )
- {
- int ret = false;
-+#ifndef __FreeBSD__
-+// On FreeBSD scsi parameters can not be extracted from a file handle
- int cdromfd = K3bCdDevice::openDevice( dev.ascii() );
- if (cdromfd < 0) {
- kdDebug() << "could not open device " << dev << " (" << strerror(errno) << ")" << endl;
-@@ -743,6 +969,7 @@
-
-
- ::close(cdromfd);
-+#endif
- return ret;
- }
-
-@@ -750,6 +977,7 @@
- QString K3bCdDevice::DeviceManager::resolveSymLink( const QString& path )
- {
- char resolved[PATH_MAX];
-+ kdDebug() << "(K3bDeviceManager) resolveSymLink: \"" << path << "\"" << endl;
- if( !realpath( QFile::encodeName(path), resolved ) )
- {
- kdDebug() << "Could not resolve " << path << endl;
-@@ -784,5 +1012,125 @@
- else
- return QString("ATAPI:%1").arg(dev->blockDeviceName());
- }
+
+#ifdef __FreeBSD__
+// Calls "camcontrol devlist" to get a list of all available cd devices.
@@ -525,6 +272,8 @@
+ details.pop_back();
+ if (details.count() > 0)
+ vendor = details.join(" ");
++ if (!name.startsWith("cd"))
++ continue;
+ kdDebug() << "(K3bDeviceManager) Found device " << name << ", pass = " << pass << ", bus = " << bus << ", target = " << target << ", lun = " << lun << endl;
+ kdDebug() << "(K3bDeviceManager) vendor: " << vendor << ", product: " << product << ", revision: " << revision << ", target = " << target << ", lun = " << lun << endl;
+#if __FreeBSD_version >= 500100
@@ -536,6 +285,5 @@
+ }
+}
+#endif
-+
#include "k3bdevicemanager.moc"
diff --git a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevicemanager.h b/sysutils/k3b-kde4/files/patch-src-device-k3bdevicemanager.h
index 2ffbb976a1ed..8d285e3ec035 100644
--- a/sysutils/k3b-kde4/files/patch-src-core-device-k3bdevicemanager.h
+++ b/sysutils/k3b-kde4/files/patch-src-device-k3bdevicemanager.h
@@ -1,5 +1,5 @@
---- src/core/device/k3bdevicemanager.h.orig Thu Aug 7 18:52:05 2003
-+++ src/core/device/k3bdevicemanager.h Fri Nov 7 12:35:44 2003
+--- src/device/k3bdevicemanager.h.orig Wed Jan 21 11:20:11 2004
++++ src/device/k3bdevicemanager.h Fri Feb 13 21:03:38 2004
@@ -24,6 +24,10 @@
#include <qptrlist.h>
@@ -11,7 +11,7 @@
class KProcess;
class KConfig;
-@@ -116,6 +120,29 @@
+@@ -112,6 +116,29 @@
class Private;
Private* d;
@@ -22,16 +22,16 @@
+ {
+ public:
+ BSDDevice() : m_bus(-1), m_target(-1), m_lun(-1) {}
-+ BSDDevice(const QString & name, const QString & passDevice, const QString & vendor,
++ BSDDevice(const QString & name, const QString & passDevice, const QString & vendor,
+ const QString & product, const QString & revision, int bus, int target, int lun) :
-+ m_name(name), m_passDevice(passDevice), m_vendor(vendor), m_product(product),
++ m_name(name), m_passDevice(passDevice), m_vendor(vendor), m_product(product),
+ m_revision(revision), m_bus(bus), m_target(target), m_lun(lun) {}
+ BSDDevice(const BSDDevice & src) :
-+ m_name(src.m_name), m_passDevice(src.m_passDevice), m_vendor(src.m_vendor), m_product(src.m_product),
++ m_name(src.m_name), m_passDevice(src.m_passDevice), m_vendor(src.m_vendor), m_product(src.m_product),
+ m_revision(src.m_revision), m_bus(src.m_bus), m_target(src.m_target), m_lun(src.m_lun) {}
+ const BSDDevice & operator= (const BSDDevice & src)
-+ { m_name = src.m_name; m_passDevice = src.m_passDevice; m_vendor = src.m_vendor;
-+ m_product = src.m_product; m_revision = src.m_revision; m_bus = src.m_bus; m_target = src.m_target;
++ { m_name = src.m_name; m_passDevice = src.m_passDevice; m_vendor = src.m_vendor;
++ m_product = src.m_product; m_revision = src.m_revision; m_bus = src.m_bus; m_target = src.m_target;
+ m_lun = src.m_lun; return *this; }
+ QString m_name, m_passDevice, m_vendor, m_product, m_revision;
+ int m_bus, m_target, m_lun;
@@ -39,5 +39,5 @@
+ QValueList<BSDDevice> m_devices;
+#endif
};
+ }
- /**
diff --git a/sysutils/k3b-kde4/files/patch-src-core-device-k3bscsicommand.cpp b/sysutils/k3b-kde4/files/patch-src-device-k3bscsicommand.cpp
index f11d2fc0ff38..6c11e8f5307f 100644
--- a/sysutils/k3b-kde4/files/patch-src-core-device-k3bscsicommand.cpp
+++ b/sysutils/k3b-kde4/files/patch-src-device-k3bscsicommand.cpp
@@ -1,10 +1,45 @@
---- src/core/device/k3bscsicommand.cpp.orig Mon Sep 1 12:20:02 2003
-+++ src/core/device/k3bscsicommand.cpp Fri Nov 7 12:35:44 2003
-@@ -14,33 +14,70 @@
- */
+--- src/device/k3bscsicommand.cpp.orig Wed Jan 21 11:20:11 2004
++++ src/device/k3bscsicommand.cpp Fri Feb 13 21:03:38 2004
+@@ -1,10 +1,10 @@
+ /*
+ *
+- * $Id: k3bscsicommand.cpp,v 1.4 2004/01/21 10:20:11 trueg Exp $
++ * $Id: k3bscsicommand.cpp,v 1.3 2003/12/31 14:15:17 trueg Exp $
+ * Copyright (C) 2003 Sebastian Trueg <trueg@k3b.org>
+ *
+ * This file is part of the K3b project.
+- * Copyright (C) 1998-2004 Sebastian Trueg <trueg@k3b.org>
++ * Copyright (C) 1998-2003 Sebastian Trueg <trueg@k3b.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+@@ -58,13 +58,14 @@
- #include "k3bscsicommand.h"
--
+
+
+-K3bCdDevice::ScsiCommand::ScsiCommand( int fd )
+- : m_fd(fd),
+- m_device(0)
+-{
+- clear();
+-}
++//K3bCdDevice::ScsiCommand::ScsiCommand( int fd )
++// : m_fd(fd),
++// m_device(0)
++//{
++// clear();
++//}
+
++#ifndef __FreeBSD__
+
+ K3bCdDevice::ScsiCommand::ScsiCommand( const K3bCdDevice::CdDevice* dev )
+ : m_device(dev)
+@@ -135,6 +136,105 @@
+ return 0;
+ }
+
++#else
++
+#include <fcntl.h>
+#include <cam/scsi/scsi_message.h>
+#include <cam/scsi/scsi_pass.h>
@@ -24,20 +59,17 @@
+ } \
+} while(0)
+#include <unistd.h>
- #include <kdebug.h>
-
- #include <string.h>
- #include <sys/ioctl.h>
-
-
--K3bCdDevice::ScsiCommand::ScsiCommand( int fd )
-- : m_fd(fd)
-+K3bCdDevice::ScsiCommand::ScsiCommand( const QString & passDevice )
-+ : m_passDevice(passDevice)
- {
- clear();
- }
-
++#include <kdebug.h>
++
++#include <string.h>
++#include <sys/ioctl.h>
++
++K3bCdDevice::ScsiCommand::ScsiCommand( const K3bCdDevice::CdDevice* dev )
++ : m_device(dev)
++{
++ clear();
++}
++
+K3bCdDevice::ScsiCommand::~ScsiCommand()
+{
+ if(cam)
@@ -46,28 +78,21 @@
+// close(m_fd);
+}
+
-
- void K3bCdDevice::ScsiCommand::clear()
- {
-- ::memset( &m_cmd, 0, sizeof(struct cdrom_generic_command) );
-- ::memset( &m_sense, 0, sizeof(struct request_sense) );
--
-- m_cmd.quiet = 1;
-- m_cmd.sense = &m_sense;
++
++void K3bCdDevice::ScsiCommand::clear()
++{
+// char pass[32];
+ cam=NULL;
+ memset (&ccb,0,sizeof(ccb));
+ ccb.ccb_h.func_code = XPT_GDEVLIST;
+// if (ioctl (m_fd,CAMGETPASSTHRU,&ccb) < 0) return;
+// sprintf (pass,"/dev/%.15s%u",ccb.cgdl.periph_name,ccb.cgdl.unit_number);
-+ cam = cam_open_pass (m_passDevice.latin1(),O_RDWR,NULL);
-+ kdDebug() << "(K3bCdDevice::ScsiCommand) open device " << m_passDevice << ((cam)?" succeeded.":" failed.") << endl;
- }
-
--
- unsigned char& K3bCdDevice::ScsiCommand::operator[]( size_t i )
- {
-- return m_cmd.cmd[i];
++ cam = cam_open_pass (m_device->m_passDevice.latin1(),O_RDWR,NULL);
++ kdDebug() << "(K3bCdDevice::ScsiCommand) open device " << m_device->m_passDevice << ((cam)?" succeeded.":" failed.") << endl;
++}
++
++unsigned char& K3bCdDevice::ScsiCommand::operator[]( size_t i )
++{
+ if (!i && cam)
+ {
+ memset(&ccb,0,sizeof(ccb));
@@ -78,26 +103,13 @@
+ }
+ ccb.csio.cdb_len = i+1;
+ return ccb.csio.cdb_io.cdb_bytes[i];
- }
-
-
-@@ -48,20 +85,29 @@
- void* data,
- size_t len )
- {
-- m_cmd.buffer = (unsigned char*)data;
-- m_cmd.buflen = len;
-- if( dir == TR_DIR_READ )
-- m_cmd.data_direction = CGC_DATA_READ;
-- else if( dir == TR_DIR_WRITE )
-- m_cmd.data_direction = CGC_DATA_WRITE;
-- else
-- m_cmd.data_direction = CGC_DATA_NONE;
--
-- if( ::ioctl( m_fd, CDROM_SEND_PACKET, &m_cmd ) ) {
-- kdDebug() << "(K3bCdDevice::ScsiCommand) failed: fd: " << m_fd
-- << " errorcode: " << m_sense.error_code << endl;
-- return ( m_sense.error_code != 0 ? m_sense.error_code : -1 );
++}
++
++
++int K3bCdDevice::ScsiCommand::transport( TransportDirection dir,
++ void* data,
++ size_t len )
++{
+ if (!cam)
+ return -1;
+ kdDebug() << "(K3bCdDevice::ScsiCommand) transport command " << QString::number((int)ccb.csio.cdb_io.cdb_bytes[0], 16) << ", length: " << (int)ccb.csio.cdb_len << endl;
@@ -109,12 +121,11 @@
+ {
+ kdDebug() << "(K3bCdDevice::ScsiCommand) transport failed: " << ret << endl;
+ return -1;
- }
-- else
++ }
+ if ((ccb.ccb_h.status & CAM_STATUS_MASK) == CAM_REQ_CMP)
+ {
+ kdDebug() << "(K3bCdDevice::ScsiCommand) transport succeeded" << endl;
- return 0;
++ return 0;
+ }
+ errno = EIO;
+ ret = ERRCODE(((unsigned char *)&ccb.csio.sense_data));
@@ -124,4 +135,8 @@
+ CREAM_ON_ERRNO(((unsigned char *)&ccb.csio.sense_data));
+ kdDebug() << "(K3bCdDevice::ScsiCommand) transport failed (2): " << ret << endl;
+ return ret;
- }
++}
++#endif
+
+ QString K3bCdDevice::MMC::commandString( const unsigned char& command )
+ {
diff --git a/sysutils/k3b-kde4/files/patch-src-device-k3bscsicommand.h b/sysutils/k3b-kde4/files/patch-src-device-k3bscsicommand.h
new file mode 100644
index 000000000000..06cebf91dd79
--- /dev/null
+++ b/sysutils/k3b-kde4/files/patch-src-device-k3bscsicommand.h
@@ -0,0 +1,84 @@
+--- src/device/k3bscsicommand.h.orig Wed Jan 21 11:20:11 2004
++++ src/device/k3bscsicommand.h Fri Feb 13 21:03:38 2004
+@@ -1,10 +1,10 @@
+ /*
+ *
+- * $Id: k3bscsicommand.h,v 1.3 2004/01/21 10:20:11 trueg Exp $
++ * $Id: k3bscsicommand.h,v 1.2 2003/12/19 19:40:40 trueg Exp $
+ * Copyright (C) 2003 Sebastian Trueg <trueg@k3b.org>
+ *
+ * This file is part of the K3b project.
+- * Copyright (C) 1998-2004 Sebastian Trueg <trueg@k3b.org>
++ * Copyright (C) 1998-2003 Sebastian Trueg <trueg@k3b.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+@@ -17,9 +17,27 @@
+ #define _K3B_SCSI_COMMAND_H_
+
+ #include <sys/types.h>
++#ifndef __FreeBSD__
+ #undef __STRICT_ANSI__
+ #include <linux/cdrom.h>
+ #define __STRICT_ANSI__
++#else
++#include <sys/types.h>
++#include <stdio.h>
++#include <camlib.h>
++#undef INQUIRY
++#undef READ_10
++#undef READ_12
++#undef READ_BUFFER
++#undef READ_CAPACITY
++#undef REQUEST_SENSE
++#undef START_STOP_UNIT
++#undef SYNCHRONIZE_CACHE
++#undef TEST_UNIT_READY
++#undef WRITE_10
++#undef WRITE_12
++#undef WRITE_BUFFER
++#endif
+
+
+ #include <qstring.h>
+@@ -87,16 +105,24 @@
+ }
+
+
++#ifndef __FreeBSD__
+ enum TransportDirection {
+ TR_DIR_NONE,
+ TR_DIR_READ,
+ TR_DIR_WRITE
+ };
++#else
++ enum TransportDirection {
++ TR_DIR_NONE = 0,
++ TR_DIR_READ = CAM_DIR_IN,
++ TR_DIR_WRITE = CAM_DIR_OUT
++ };
++#endif
+
+ class ScsiCommand
+ {
+ public:
+- ScsiCommand( int fd );
++// ScsiCommand( int fd );
+ ScsiCommand( const CdDevice* );
+ ~ScsiCommand();
+
+@@ -109,9 +135,13 @@
+ size_t len = 0 );
+
+ private:
++#ifndef __FreeBSD__
+ struct cdrom_generic_command m_cmd;
+ struct request_sense m_sense;
+-
++#else
++ struct cam_device *cam;
++ union ccb ccb;
++#endif
+ int m_fd;
+ const CdDevice* m_device;
+ bool m_needToCloseDevice;
diff --git a/sysutils/k3b-kde4/files/patch-src-rip-k3bmovieview.cpp b/sysutils/k3b-kde4/files/patch-src-rip-k3bmovieview.cpp
index d4f06f94b84d..cfd8f4e7c79a 100644
--- a/sysutils/k3b-kde4/files/patch-src-rip-k3bmovieview.cpp
+++ b/sysutils/k3b-kde4/files/patch-src-rip-k3bmovieview.cpp
@@ -1,6 +1,6 @@
---- src/rip/k3bmovieview.cpp.orig Thu Jun 12 16:07:42 2003
-+++ src/rip/k3bmovieview.cpp Fri Nov 7 12:35:44 2003
-@@ -248,8 +248,11 @@
+--- src/rip/k3bmovieview.cpp.orig Fri Feb 6 12:08:51 2004
++++ src/rip/k3bmovieview.cpp Fri Feb 13 21:03:38 2004
+@@ -223,8 +223,11 @@
}
QWidget::show();
diff --git a/sysutils/k3b-kde4/files/patch-src-rip-k3btcwrapper.cpp b/sysutils/k3b-kde4/files/patch-src-rip-k3btcwrapper.cpp
index 968abbd3ad20..9ef70edca96a 100644
--- a/sysutils/k3b-kde4/files/patch-src-rip-k3btcwrapper.cpp
+++ b/sysutils/k3b-kde4/files/patch-src-rip-k3btcwrapper.cpp
@@ -1,35 +1,15 @@
---- src/rip/k3btcwrapper.cpp.orig Thu Jun 12 16:07:42 2003
-+++ src/rip/k3btcwrapper.cpp Fri Nov 7 12:35:44 2003
-@@ -27,7 +27,7 @@
- //#include <kprocess.h>
- #include <klocale.h>
- #include <kdebug.h>
--
-+#include <stdlib.h>
-
- K3bTcWrapper::K3bTcWrapper( QObject* parent )
- : QObject( parent )
-@@ -65,7 +65,14 @@
+--- src/rip/k3btcwrapper.cpp.orig Wed Jan 21 11:20:20 2004
++++ src/rip/k3btcwrapper.cpp Fri Feb 13 21:03:38 2004
+@@ -65,7 +65,12 @@
//K3bProcess *p = new K3bProcess();
emit tcprobeTitleParsed( m_currentTitle );
+#ifndef __FreeBSD__
- *p << bin->path << "-i" << m_device->ioctlDevice() << "-T" << QString::number(m_currentTitle);
+ *p << bin->path << "-i" << m_device->blockDeviceName() << "-T" << QString::number(m_currentTitle);
+#else
-+ QString s = "mount " + m_device->mountPoint();
-+ system(s.latin1());
-+ kdDebug() << "(K3bDirView) executing: " << bin->path << " -i " << m_device->mountPoint() << " -T " << QString::number(m_currentTitle) << endl;
++ kdDebug() << "(K3bTcWrapper) executing: " << bin->path << " -i " << m_device->mountPoint() << " -T " << QString::number(m_currentTitle) << endl;
+ *p << bin->path << "-i" << m_device->mountPoint() << "-T" << QString::number(m_currentTitle);
+#endif
//p->setSplitStdout( true );
connect( p, SIGNAL(receivedStderr(KProcess*, char*, int)), this, SLOT(slotParseTcprobeError(KProcess*, char*, int)) );
connect( p, SIGNAL(receivedStdout(KProcess*, char*, int)), this, SLOT(slotParseTcprobeOutput(KProcess*, char*, int)) );
-@@ -115,7 +122,7 @@
- // check dvd
- for( QStringList::Iterator str = errorLines.begin(); str != errorLines.end(); str++ ) {
- kdDebug() << (*str) << endl;
-- if( !(*str).contains("tcprobe") && !(*str).contains("DVD image/device") ) {
-+ if( !(*str).contains("tcprobe") || !(*str).contains("DVD image/device") ) {
- continue;
- } else{
- isDvd = true;
diff --git a/sysutils/k3b-kde4/pkg-descr b/sysutils/k3b-kde4/pkg-descr
index b8d32e498502..81633d0d9f00 100644
--- a/sysutils/k3b-kde4/pkg-descr
+++ b/sysutils/k3b-kde4/pkg-descr
@@ -4,20 +4,21 @@ come with cd recording.
Features so far:
* Creating data cds (on-the-fly, rockridge, joliet, El-Torito)
- * Creating audio cds (WAV, MP3, OGG, CD-TEXT)
+ * Creating audio cds (WAV, MP3, OGG, CD-TEXT; normalization and on-the fly)
* Creating Video CDs (VCD 1.1, 2.0, SVCD, CD-i support (Version 4))
* Creating mixed-mode cds (CD-Extra (CD-Plus, Enhanced Audio CD))
* Creating eMovix CDs
+ * CD Copy (single + multi session, audio, enghanced audio, cloning)
* DVD burning (DVD-R(W), DVD+R(W), eMovix, Formatting DVD-RWs and DVD+RWs)
- * CD Ripping (CDDB, CD-TEXT reading)
+ * CD Ripping (CDDB support, CD-TEXT reading, several formats)
* DVD Ripping and DivX/XviD encoding
* Save/load projects.
* Blanking of CDRWs.
* Retrieving Table of contents and cdr information.
* Writing existing iso images to CD and DVD.
* Writing cue/bin files created for CDRWIN
- * CD Copy, CD Cloning
* DVD copy (no video transcoding yet)
- * Enhanced cd decive handling (max. writing and reading speed, BURN-PROOF)
+ * Enhanced cd decive handling (burnfree and justlink support)
+ * KParts plugin
WWW: http://www.k3b.org/
WWW: http://k3b.sourceforge.net/
diff --git a/sysutils/k3b-kde4/pkg-message b/sysutils/k3b-kde4/pkg-message
index 50e225c6e348..fb5f51307cac 100644
--- a/sysutils/k3b-kde4/pkg-message
+++ b/sysutils/k3b-kde4/pkg-message
@@ -4,16 +4,16 @@ Notes:
(http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/creating-cds.html#ATAPICAM)
2. Your CD and DVD drives must have a mount point in /etc/fstab. They have
to be accessed through their atapicam device. I.e. the drives
- have to be adressed by /dev/cd0c instead of /dev/acd0c.
+ have to be adressed by e.g. /dev/cd0c instead of /dev/acd0c.
3. k3b has to be started from a root console, which is not recommended.
- Alternatively do the following:
+ Alternatively do all of the following:
3a. set the suid flag on cdrecord and cdrdao. The 'Notes' the chapter of
'man cdrecord' discusses this.
3b. - install sudo (security/sudo) and add the following line or similar to
sudoers (usually in /usr/local/etc/sudoers):
ALL ALL = NOPASSWD: /sbin/camcontrol devlist
- - or execute 'camcontrol devlist' For every user who should be able to use
- k3b. Resolve all errors e.g by giving him/her access rights to /dev/xpt0.
+ - or execute 'camcontrol devlist'. For every user who should be able to use
+ k3b. Resolve all errors e.g. by giving him/her access rights to /dev/xpt0.
'camcontrol devlist' must run without error for all these users!
Note that giving access rights to /dev/xpt* might be a security leak!
- or give camcontrol the suid flag, which is a security leak as well.
@@ -50,5 +50,4 @@ Notes:
10. To normalize the volumes of audio cds, install the port audio/normalize.
11. To rip into more audio formats, install the port audio/sox.
-To read these instructions again, type 'make showinfo' in the k3b port
-directory.
+To read this instructions again, type 'make showinfo' in the k3b port directory
diff --git a/sysutils/k3b-kde4/pkg-plist b/sysutils/k3b-kde4/pkg-plist
index e1506a4a2c54..ee921880d623 100644
--- a/sysutils/k3b-kde4/pkg-plist
+++ b/sysutils/k3b-kde4/pkg-plist
@@ -1,173 +1,228 @@
-bin/k3b
-include/k3baudiodecoder.h
-include/k3baudiodoc.h
-include/k3baudioencoder.h
-include/k3baudiojob.h
-include/k3baudioview.h
-include/k3bblankingjob.h
-include/k3bbootitem.h
-include/k3bburnprogressdialog.h
-include/k3bbusywidget.h
-include/k3bcdtext.h
-include/k3bcore.h
-include/k3bcutcombobox.h
-include/k3bdatadoc.h
-include/k3bdataitem.h
-include/k3bdatajob.h
-include/k3bdataview.h
-include/k3bdefaultexternalprograms.h
-include/k3bdevice.h
-include/k3bdevicecombobox.h
-include/k3bdeviceglobals.h
-include/k3bdevicehandler.h
-include/k3bdevicemanager.h
-include/k3bdeviceselectiondialog.h
-include/k3bdevicewidget.h
-include/k3bdiritem.h
-include/k3bdiskinfo.h
-include/k3bdoc.h
-include/k3bdvddoc.h
-include/k3bdvdformattingjob.h
-include/k3bdvdjob.h
-include/k3bdvdview.h
-include/k3bemptydiscwaiter.h
-include/k3bexternalbinmanager.h
-include/k3bexternalbinwidget.h
-include/k3bfileitem.h
-include/k3bglobals.h
-include/k3binteractiondialog.h
-include/k3biso9660.h
-include/k3bisooptions.h
-include/k3bjob.h
-include/k3bjobprogressdialog.h
-include/k3blistview.h
-include/k3bmd5job.h
-include/k3bmixeddoc.h
-include/k3bmixedjob.h
-include/k3bmixedview.h
-include/k3bmovixdoc.h
-include/k3bmovixdvddoc.h
-include/k3bmovixdvdjob.h
-include/k3bmovixdvdview.h
-include/k3bmovixfileitem.h
-include/k3bmovixjob.h
-include/k3bmovixview.h
-include/k3bmsf.h
-include/k3bmsfedit.h
-include/k3bplugin.h
-include/k3bpluginfactory.h
-include/k3bpluginmanager.h
-include/k3bprocess.h
-include/k3bprojectmanager.h
-include/k3bstdguiitems.h
-include/k3bstringutils.h
-include/k3bthread.h
-include/k3bthreadjob.h
-include/k3bthroughputestimator.h
-include/k3btoc.h
-include/k3btrack.h
-include/k3bvalidators.h
-include/k3bvcddoc.h
-include/k3bvcdjob.h
-include/k3bvcdoptions.h
-include/k3bvcdview.h
-include/k3bversion.h
-include/k3bview.h
-include/k3bwavefilewriter.h
-include/k3bwriterselectionwidget.h
-include/kcutlabel.h
-lib/libk3baudiometainforenamerplugin.la
-lib/libk3baudiometainforenamerplugin.so
-lib/libk3bcore.la
-lib/libk3bcore.so
-lib/libk3bcore.so.2
-lib/libk3bexternalencoder.la
-lib/libk3bexternalencoder.so
-lib/libk3bmaddecoder.la
-lib/libk3bmaddecoder.so
-lib/libk3bplugin.la
-lib/libk3bplugin.so
-lib/libk3bplugin.so.1
-lib/libk3bproject.la
-lib/libk3bproject.so
-lib/libk3bproject.so.1
-lib/libk3bsoxencoder.la
-lib/libk3bsoxencoder.so
-lib/libk3btools.la
-lib/libk3btools.so
-lib/libk3btools.so.1
-lib/libk3bwavedecoder.la
-lib/libk3bwavedecoder.so
-share/applnk/.hidden/k3b-cue.desktop
-share/applnk/.hidden/k3b-iso.desktop
-share/applnk/Multimedia/k3b.desktop
-share/apps/k3b/cdi/cdi_imag.rtf
-share/apps/k3b/cdi/cdi_text.fnt
-share/apps/k3b/cdi/cdi_vcd.app
-share/apps/k3b/cdi/cdi_vcd.cfg
-share/apps/k3b/cdi/icdia.htm
-share/apps/k3b/cdi/vcd_on_cdi_41.pdf
-share/apps/k3b/eventsrc
-share/apps/k3b/icons/hicolor/16x16/actions/cdinfo.png
-share/apps/k3b/icons/hicolor/16x16/actions/cdrwblank.png
-share/apps/k3b/icons/hicolor/16x16/actions/greenled.png
-share/apps/k3b/icons/hicolor/16x16/actions/redled.png
-share/apps/k3b/icons/hicolor/16x16/actions/yellowled.png
-share/apps/k3b/icons/hicolor/22x22/actions/cdcopy.png
-share/apps/k3b/icons/hicolor/22x22/actions/cdinfo.png
-share/apps/k3b/icons/hicolor/22x22/actions/cdrwblank.png
-share/apps/k3b/icons/hicolor/32x32/actions/cdcopy.png
-share/apps/k3b/k3bui.rc
-share/apps/k3b/kpartplugins/k3baudiometainforenamerplugin.rc
-share/apps/k3b/pics/diskinfo_audio.png
-share/apps/k3b/pics/diskinfo_data.png
-share/apps/k3b/pics/diskinfo_dvd.png
-share/apps/k3b/pics/diskinfo_empty.png
-share/apps/k3b/pics/diskinfo_left.png
-share/apps/k3b/pics/diskinfo_mixed.png
-share/apps/k3b/pics/diskinfo_right.png
-share/apps/k3b/pics/k3b_3d_logo.png
-share/apps/k3b/pics/k3b_cd_copy.png
-share/apps/k3b/pics/k3b_probing_cd.png
-share/apps/k3b/pics/k3b_progress_dialog_failed.png
-share/apps/k3b/pics/k3b_progress_dialog_success.png
-share/apps/k3b/pics/k3b_splash.png
-share/apps/k3b/pics/k3bprojectview_left.png
-share/apps/k3b/pics/k3bprojectview_left_short.png
-share/apps/k3b/pics/k3bprojectview_right.png
-share/apps/k3b/pics/k3bsetup2_guy.png
-share/apps/k3b/plugins/k3bexternalencoder.plugin
-share/apps/k3b/plugins/k3bmaddecoder.plugin
-share/apps/k3b/plugins/k3bsoxencoder.plugin
-share/apps/k3b/plugins/k3bwavedecoder.plugin
-share/apps/k3b/plugins/k3boggvorbisdecoder.plugin
-share/apps/k3b/plugins/k3boggvorbisencoder.plugin
-share/apps/k3b/tips
-share/apps/konqueror/servicemenus/k3b_create_audio_cd.desktop
-share/apps/konqueror/servicemenus/k3b_create_data_cd.desktop
-share/apps/konqueror/servicemenus/k3b_create_video_cd.desktop
-share/apps/konqueror/servicemenus/k3b_write_bin_image.desktop
-share/apps/konqueror/servicemenus/k3b_write_iso_image.desktop
-share/icons/hicolor/16x16/apps/k3b.png
-share/icons/hicolor/32x32/apps/k3b.png
-share/icons/hicolor/48x48/apps/k3b.png
-share/icons/hicolor/64x64/apps/k3b.png
-share/mimelnk/application/x-cue.desktop
-share/mimelnk/application/x-iso.desktop
-share/mimelnk/application/x-k3b.desktop
-share/sounds/k3b_error1.wav
-share/sounds/k3b_success1.wav
-share/sounds/k3b_wait_media1.wav
-@dirrm share/apps/k3b/plugins
-@dirrm share/apps/k3b/pics
-@dirrm share/apps/k3b/kpartplugins
-@dirrm share/apps/k3b/icons/hicolor/32x32/actions
-@dirrm share/apps/k3b/icons/hicolor/32x32
-@dirrm share/apps/k3b/icons/hicolor/22x22/actions
-@dirrm share/apps/k3b/icons/hicolor/22x22
-@dirrm share/apps/k3b/icons/hicolor/16x16/actions
-@dirrm share/apps/k3b/icons/hicolor/16x16
-@dirrm share/apps/k3b/icons/hicolor
-@dirrm share/apps/k3b/icons
-@dirrm share/apps/k3b/cdi
-@dirrm share/apps/k3b
+bin/k3b
+include/k3baudiodecoder.h
+include/k3baudiodoc.h
+include/k3baudioencoder.h
+include/k3baudiojob.h
+include/k3baudioview.h
+include/k3bblankingjob.h
+include/k3bbootitem.h
+include/k3bburnprogressdialog.h
+include/k3bbusywidget.h
+include/k3bcdparanoialib.h
+include/k3bcdtext.h
+include/k3bcore.h
+include/k3bcutcombobox.h
+include/k3bdatadoc.h
+include/k3bdataitem.h
+include/k3bdatajob.h
+include/k3bdataview.h
+include/k3bdefaultexternalprograms.h
+include/k3bdevice.h
+include/k3bdevicecombobox.h
+include/k3bdeviceglobals.h
+include/k3bdevicehandler.h
+include/k3bdevicemanager.h
+include/k3bdeviceselectiondialog.h
+include/k3bdiritem.h
+include/k3bdiskinfo.h
+include/k3bdoc.h
+include/k3bdvddoc.h
+include/k3bdvdformattingjob.h
+include/k3bdvdjob.h
+include/k3bdvdview.h
+include/k3bemptydiscwaiter.h
+include/k3bexternalbinmanager.h
+include/k3bfileitem.h
+include/k3bglobals.h
+include/k3binteractiondialog.h
+include/k3biso9660.h
+include/k3bisooptions.h
+include/k3bjob.h
+include/k3bjobprogressdialog.h
+include/k3blistview.h
+include/k3bmd5job.h
+include/k3bmixeddoc.h
+include/k3bmixedjob.h
+include/k3bmixedview.h
+include/k3bmovixdoc.h
+include/k3bmovixdvddoc.h
+include/k3bmovixdvdjob.h
+include/k3bmovixdvdview.h
+include/k3bmovixfileitem.h
+include/k3bmovixjob.h
+include/k3bmovixview.h
+include/k3bmsf.h
+include/k3bmsfedit.h
+include/k3bmultichoicedialog.h
+include/k3bplugin.h
+include/k3bpluginconfigwidget.h
+include/k3bpluginfactory.h
+include/k3bpluginmanager.h
+include/k3bprocess.h
+include/k3bprojectmanager.h
+include/k3bstdguiitems.h
+include/k3bstringutils.h
+include/k3bthread.h
+include/k3bthreadjob.h
+include/k3bthroughputestimator.h
+include/k3btoc.h
+include/k3btrack.h
+include/k3bvalidators.h
+include/k3bvcddoc.h
+include/k3bvcdjob.h
+include/k3bvcdoptions.h
+include/k3bvcdview.h
+include/k3bversion.h
+include/k3bvideodvddoc.h
+include/k3bvideodvdjob.h
+include/k3bview.h
+include/k3bwavefilewriter.h
+include/k3bwriterselectionwidget.h
+include/kcutlabel.h
+lib/kde3/libk3bexternalencoder.la
+lib/kde3/libk3bexternalencoder.so
+lib/kde3/libk3bflacdecoder.la
+lib/kde3/libk3bflacdecoder.so
+lib/kde3/libk3bmaddecoder.la
+lib/kde3/libk3bmaddecoder.so
+lib/kde3/libk3boggvorbisdecoder.la
+lib/kde3/libk3boggvorbisdecoder.so
+lib/kde3/libk3boggvorbisencoder.la
+lib/kde3/libk3boggvorbisencoder.so
+lib/kde3/libk3bsoxencoder.la
+lib/kde3/libk3bsoxencoder.so
+lib/kde3/libk3bwavedecoder.la
+lib/kde3/libk3bwavedecoder.so
+lib/libk3baudiometainforenamerplugin.la
+lib/libk3baudiometainforenamerplugin.so
+lib/libk3bcore.la
+lib/libk3bcore.so
+lib/libk3bcore.so.2
+lib/libk3bdevice.la
+lib/libk3bdevice.so
+lib/libk3bdevice.so.2
+lib/libk3bplugin.la
+lib/libk3bplugin.so
+lib/libk3bplugin.so.2
+lib/libk3bproject.la
+lib/libk3bproject.so
+lib/libk3bproject.so.2
+lib/libk3btools.la
+lib/libk3btools.so
+lib/libk3btools.so.2
+share/applnk/.hidden/k3b-cue.desktop
+share/applnk/.hidden/k3b-iso.desktop
+share/applnk/Multimedia/k3b.desktop
+share/apps/k3b/cdi/cdi_imag.rtf
+share/apps/k3b/cdi/cdi_text.fnt
+share/apps/k3b/cdi/cdi_vcd.app
+share/apps/k3b/cdi/cdi_vcd.cfg
+share/apps/k3b/cdi/icdia.htm
+share/apps/k3b/cdi/vcd_on_cdi_41.pdf
+share/apps/k3b/eventsrc
+share/apps/k3b/icons/crystalsvg/16x16/actions/cdburn.png
+share/apps/k3b/icons/crystalsvg/16x16/actions/cdinfo.png
+share/apps/k3b/icons/crystalsvg/16x16/actions/cdrwblank.png
+share/apps/k3b/icons/crystalsvg/16x16/actions/greenled.png
+share/apps/k3b/icons/crystalsvg/16x16/actions/redled.png
+share/apps/k3b/icons/crystalsvg/16x16/actions/yellowinfo.png
+share/apps/k3b/icons/crystalsvg/16x16/actions/yellowled.png
+share/apps/k3b/icons/crystalsvg/22x22/actions/cdcopy.png
+share/apps/k3b/icons/crystalsvg/22x22/actions/cdinfo.png
+share/apps/k3b/icons/crystalsvg/22x22/actions/cdrwblank.png
+share/apps/k3b/icons/crystalsvg/32x32/actions/cdburn.png
+share/apps/k3b/icons/crystalsvg/32x32/actions/cdcopy.png
+share/apps/k3b/k3bui.rc
+share/apps/k3b/kpartplugins/k3baudiometainforenamerplugin.rc
+share/apps/k3b/pics/73lab/diskinfo_audio.png
+share/apps/k3b/pics/73lab/diskinfo_data.png
+share/apps/k3b/pics/73lab/diskinfo_dvd.png
+share/apps/k3b/pics/73lab/diskinfo_empty.png
+share/apps/k3b/pics/73lab/diskinfo_left.png
+share/apps/k3b/pics/73lab/diskinfo_mixed.png
+share/apps/k3b/pics/73lab/diskinfo_right.png
+share/apps/k3b/pics/73lab/k3b.theme
+share/apps/k3b/pics/73lab/k3b_3d_logo.png
+share/apps/k3b/pics/73lab/k3b_cd_copy.png
+share/apps/k3b/pics/73lab/k3b_probing_cd.png
+share/apps/k3b/pics/73lab/k3b_progress_dialog_failed.png
+share/apps/k3b/pics/73lab/k3b_progress_dialog_success.png
+share/apps/k3b/pics/73lab/k3b_splash.png
+share/apps/k3b/pics/73lab/k3bprojectview_left.png
+share/apps/k3b/pics/73lab/k3bprojectview_left_short.png
+share/apps/k3b/pics/73lab/k3bprojectview_right.png
+share/apps/k3b/pics/73lab/k3bsetup2_guy.png
+share/apps/k3b/pics/crystal/diskinfo_audio.png
+share/apps/k3b/pics/crystal/diskinfo_data.png
+share/apps/k3b/pics/crystal/diskinfo_dvd.png
+share/apps/k3b/pics/crystal/diskinfo_empty.png
+share/apps/k3b/pics/crystal/diskinfo_left.png
+share/apps/k3b/pics/crystal/diskinfo_mixed.png
+share/apps/k3b/pics/crystal/diskinfo_right.png
+share/apps/k3b/pics/crystal/k3b.theme
+share/apps/k3b/pics/crystal/k3b_3d_logo.png
+share/apps/k3b/pics/crystal/k3b_cd_copy.png
+share/apps/k3b/pics/crystal/k3b_probing_cd.png
+share/apps/k3b/pics/crystal/k3b_progress_dialog_failed.png
+share/apps/k3b/pics/crystal/k3b_progress_dialog_success.png
+share/apps/k3b/pics/crystal/k3b_splash.png
+share/apps/k3b/pics/crystal/k3bprojectview_left.png
+share/apps/k3b/pics/crystal/k3bprojectview_left_short.png
+share/apps/k3b/pics/crystal/k3bprojectview_right.png
+share/apps/k3b/pics/crystal/k3bsetup2_guy.png
+share/apps/k3b/plugins/k3bexternalencoder.plugin
+share/apps/k3b/plugins/k3bflacdecoder.plugin
+share/apps/k3b/plugins/k3bmaddecoder.plugin
+share/apps/k3b/plugins/k3boggvorbisdecoder.plugin
+share/apps/k3b/plugins/k3boggvorbisencoder.plugin
+share/apps/k3b/plugins/k3bsoxencoder.plugin
+share/apps/k3b/plugins/k3bwavedecoder.plugin
+share/apps/k3b/tips
+share/apps/konqueror/servicemenus/k3b_create_audio_cd.desktop
+share/apps/konqueror/servicemenus/k3b_create_data_cd.desktop
+share/apps/konqueror/servicemenus/k3b_create_video_cd.desktop
+share/apps/konqueror/servicemenus/k3b_write_bin_image.desktop
+share/apps/konqueror/servicemenus/k3b_write_iso_image.desktop
+share/doc/HTML/en/k3b/audiocd-howto.docbook
+share/doc/HTML/en/k3b/burndialog_audio.png
+share/doc/HTML/en/k3b/burndialog_progress.png
+share/doc/HTML/en/k3b/cdcloning_dialog.png
+share/doc/HTML/en/k3b/cdcloning_reading.png
+share/doc/HTML/en/k3b/cdcopy-howto.docbook
+share/doc/HTML/en/k3b/cdcopy_done.png
+share/doc/HTML/en/k3b/cdcopy_reading.png
+share/doc/HTML/en/k3b/cdcopy_settings.png
+share/doc/HTML/en/k3b/cdcopy_writing.png
+share/doc/HTML/en/k3b/commands.docbook
+share/doc/HTML/en/k3b/common
+share/doc/HTML/en/k3b/dcop.docbook
+share/doc/HTML/en/k3b/index.cache.bz2
+share/doc/HTML/en/k3b/index.docbook
+share/doc/HTML/en/k3b/select_audiofiles.png
+share/doc/HTML/en/k3b/select_project.png
+share/doc/HTML/en/k3b/video-encoding.docbook
+share/icons/crystalsvg/128x128/apps/k3b.png
+share/icons/crystalsvg/16x16/apps/k3b.png
+share/icons/crystalsvg/32x32/apps/k3b.png
+share/icons/crystalsvg/48x48/apps/k3b.png
+share/icons/crystalsvg/64x64/apps/k3b.png
+share/mimelnk/application/x-k3b.desktop
+share/sounds/k3b_error1.wav
+share/sounds/k3b_success1.wav
+share/sounds/k3b_wait_media1.wav
+@dirrm share/doc/HTML/en/k3b
+@dirrm share/apps/k3b/plugins
+@dirrm share/apps/k3b/pics/crystal
+@dirrm share/apps/k3b/pics/73lab
+@dirrm share/apps/k3b/pics
+@dirrm share/apps/k3b/kpartplugins
+@dirrm share/apps/k3b/icons/crystalsvg/32x32/actions
+@dirrm share/apps/k3b/icons/crystalsvg/32x32
+@dirrm share/apps/k3b/icons/crystalsvg/22x22/actions
+@dirrm share/apps/k3b/icons/crystalsvg/22x22
+@dirrm share/apps/k3b/icons/crystalsvg/16x16/actions
+@dirrm share/apps/k3b/icons/crystalsvg/16x16
+@dirrm share/apps/k3b/icons/crystalsvg
+@dirrm share/apps/k3b/icons
+@dirrm share/apps/k3b/cdi
+@dirrm share/apps/k3b