* Fix a problem where track progress would not be updated when playing a

CD [1]
* Convert to new libtool scheme

Adapted from:	gnome-cd's linux-cdrom.c
This commit is contained in:
Joe Marcus Clarke 2004-08-22 04:58:43 +00:00
parent bfe8bdb874
commit 8e8bb40025
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=117001
4 changed files with 82 additions and 6 deletions

View File

@ -7,7 +7,7 @@
PORTNAME= gnomemedia2
PORTVERSION= 2.6.2
PORTREVISION= 3
PORTREVISION= 4
CATEGORIES= audio gnome
MASTER_SITES= ${MASTER_SITE_GNOME}
MASTER_SITE_SUBDIR= sources/gnome-media/2.6
@ -20,11 +20,11 @@ COMMENT= Multimedia applications for the GNOME 2 desktop
USE_BZIP2= yes
USE_X_PREFIX= yes
USE_GMAKE= yes
USE_INC_LIBTOOL_VER=13
USE_LIBTOOL_VER=15
INSTALLS_SHLIB= yes
USE_REINPLACE= yes
GNOME_DESKTOP_VERSION=2
USE_GNOME= gnomeprefix gnomehack intlhack lthack gnomehier gnomedesktop \
USE_GNOME= gnomeprefix gnomehack intlhack gnomehier gnomedesktop \
gail gstreamerplugins
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib"

View File

@ -0,0 +1,38 @@
--- gnome-cd/freebsd-cdrom.c.orig Sun Aug 22 00:42:31 2004
+++ gnome-cd/freebsd-cdrom.c Sun Aug 22 00:48:36 2004
@@ -903,6 +903,11 @@
ASSIGN_MSF (realstatus->relative, subchnl.data->what.position.reladdr.msf);
ASSIGN_MSF (realstatus->absolute, subchnl.data->what.position.absaddr.msf);
realstatus->track = subchnl.data->what.position.track_number;
+ if(priv && realstatus->track>0 &&
+ realstatus->track<=priv->number_tracks){
+ /* track_info may not be initialized */
+ ASSIGN_MSF (realstatus->length, priv->track_info[realstatus->track-1].length);
+ }
break;
case CD_AS_PLAY_PAUSED:
@@ -910,6 +915,11 @@
ASSIGN_MSF (realstatus->relative, subchnl.data->what.position.reladdr.msf);
ASSIGN_MSF (realstatus->absolute, subchnl.data->what.position.absaddr.msf);
realstatus->track = subchnl.data->what.position.track_number;
+ if(priv && realstatus->track>0 &&
+ realstatus->track<=priv->number_tracks){
+ /* track_info may not be initialized */
+ ASSIGN_MSF (realstatus->length, priv->track_info[realstatus->track-1].length);
+ }
break;
case CD_AS_PLAY_COMPLETED:
@@ -917,6 +927,11 @@
ASSIGN_MSF (realstatus->relative, subchnl.data->what.position.reladdr.msf);
ASSIGN_MSF (realstatus->absolute, subchnl.data->what.position.absaddr.msf);
realstatus->track = subchnl.data->what.position.track_number;
+ if(priv && realstatus->track>0 &&
+ realstatus->track<=priv->number_tracks){
+ /* track_info may not be initialized */
+ ASSIGN_MSF (realstatus->length, priv->track_info[realstatus->track-1].length);
+ }
break;
case CD_AS_AUDIO_INVALID:

View File

@ -7,7 +7,7 @@
PORTNAME= gnomemedia2
PORTVERSION= 2.6.2
PORTREVISION= 3
PORTREVISION= 4
CATEGORIES= audio gnome
MASTER_SITES= ${MASTER_SITE_GNOME}
MASTER_SITE_SUBDIR= sources/gnome-media/2.6
@ -20,11 +20,11 @@ COMMENT= Multimedia applications for the GNOME 2 desktop
USE_BZIP2= yes
USE_X_PREFIX= yes
USE_GMAKE= yes
USE_INC_LIBTOOL_VER=13
USE_LIBTOOL_VER=15
INSTALLS_SHLIB= yes
USE_REINPLACE= yes
GNOME_DESKTOP_VERSION=2
USE_GNOME= gnomeprefix gnomehack intlhack lthack gnomehier gnomedesktop \
USE_GNOME= gnomeprefix gnomehack intlhack gnomehier gnomedesktop \
gail gstreamerplugins
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib"

View File

@ -0,0 +1,38 @@
--- gnome-cd/freebsd-cdrom.c.orig Sun Aug 22 00:42:31 2004
+++ gnome-cd/freebsd-cdrom.c Sun Aug 22 00:48:36 2004
@@ -903,6 +903,11 @@
ASSIGN_MSF (realstatus->relative, subchnl.data->what.position.reladdr.msf);
ASSIGN_MSF (realstatus->absolute, subchnl.data->what.position.absaddr.msf);
realstatus->track = subchnl.data->what.position.track_number;
+ if(priv && realstatus->track>0 &&
+ realstatus->track<=priv->number_tracks){
+ /* track_info may not be initialized */
+ ASSIGN_MSF (realstatus->length, priv->track_info[realstatus->track-1].length);
+ }
break;
case CD_AS_PLAY_PAUSED:
@@ -910,6 +915,11 @@
ASSIGN_MSF (realstatus->relative, subchnl.data->what.position.reladdr.msf);
ASSIGN_MSF (realstatus->absolute, subchnl.data->what.position.absaddr.msf);
realstatus->track = subchnl.data->what.position.track_number;
+ if(priv && realstatus->track>0 &&
+ realstatus->track<=priv->number_tracks){
+ /* track_info may not be initialized */
+ ASSIGN_MSF (realstatus->length, priv->track_info[realstatus->track-1].length);
+ }
break;
case CD_AS_PLAY_COMPLETED:
@@ -917,6 +927,11 @@
ASSIGN_MSF (realstatus->relative, subchnl.data->what.position.reladdr.msf);
ASSIGN_MSF (realstatus->absolute, subchnl.data->what.position.absaddr.msf);
realstatus->track = subchnl.data->what.position.track_number;
+ if(priv && realstatus->track>0 &&
+ realstatus->track<=priv->number_tracks){
+ /* track_info may not be initialized */
+ ASSIGN_MSF (realstatus->length, priv->track_info[realstatus->track-1].length);
+ }
break;
case CD_AS_AUDIO_INVALID: