[meego-commits] 6003: Changes to Trunk:Testing/alsa-utils
Lisa Yue
ling.yue at intel.com
Tue Jul 27 07:58:40 UTC 2010
Hi,
I have made the following changes to alsa-utils in project Trunk:Testing. Please review and accept ASAP.
Thank You,
Lisa Yue
[This message was auto-generated]
---
Request #6003:
submit: home:lisayue:branches:Trunk:Testing/alsa-utils(r4)(cleanup) -> Trunk:Testing/alsa-utils
Message:
Upgrade to 1.0.23 and upgrade alsa-info.sh to 0.4.59
* Mon Jul 26 2010 Ling Yue <ling.yue at intel.com> - 1.0.23
- Upgrade to 1.0.23
- Upgrade alsa-info.sh to 0.4.59
State: new 2010-07-26T19:51:55 lisayue
Comment: None
changes files:
--------------
--- alsa-utils.changes
+++ alsa-utils.changes
@@ -0,0 +1,4 @@
+* Mon Jul 26 2010 Ling Yue <ling.yue at intel.com> - 1.0.23
+- Upgrade to 1.0.23
+- Upgrade alsa-info.sh to 0.4.59
+
old:
----
alsa-utils-1.0.22.tar.bz2
new:
----
alsa-utils-1.0.23.tar.bz2
alsa-utils.yaml
alsaunmute.1
spec files:
-----------
--- alsa-utils.spec
+++ alsa-utils.spec
@@ -1,48 +1,73 @@
-#specfile originally created for Fedora, modified for Moblin Linux
-#define prever rc1
-#define prever_dot .rc1
+#
+# Do not Edit! Generated by:
+# spectacle version 0.18
+#
+# >> macros
+# << macros
-Summary: Advanced Linux Sound Architecture (ALSA) utilities
Name: alsa-utils
-Version: 1.0.22
+Summary: Advanced Linux Sound Architecture (ALSA) utilities
+Version: 1.0.23
Release: 1
-License: GPLv2+
Group: Applications/Multimedia
+License: GPLv2+
URL: http://www.alsa-project.org/
-Source: ftp://ftp.alsa-project.org/pub/utils/alsa-utils-%{version}.tar.bz2
-Source4: alsaunmute
-Source6: alsa-info.sh
-Source10: alsa.rules
-Source11: alsactl.conf
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+Source0: ftp://ftp.alsa-project.org/pub/utils/alsa-utils-%{version}.tar.bz2
+Source1: alsaunmute
+Source2: alsaunmute.1
+Source3: alsa-info.sh
+Source4: alsa.rules
+Source5: alsactl.conf
+Source100: alsa-utils.yaml
+Requires: alsa-lib >= %{version}
+Requires: dialog
BuildRequires: alsa-lib-devel >= %{version}
BuildRequires: ncurses-devel
-BuildRequires: gettext-devel, xmlto
+BuildRequires: gettext-devel
+BuildRequires: xmlto
+Conflicts: udev < 062
%description
This package contains command line utilities for the Advanced Linux Sound
Architecture (ALSA).
%prep
-%setup -q -n %{name}-%{version}%{?prever}
+%setup -q -n %{name}-%{version}
+
+# >> setup
+# << setup
%build
+# >> build pre
+# << build pre
+
+# >> build post
%configure CFLAGS="$RPM_OPT_FLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" --sbindir=/sbin --disable-alsaconf
%{__make} %{?_smp_mflags}
-%{__cp} %{SOURCE4} .
+%{__cp} %{SOURCE1} .
+# << build post
%install
+rm -rf %{buildroot}
+# >> install pre
+# << install pre
+
+# >> install post
%{__rm} -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
%find_lang %{name}
# Install ALSA udev rules
mkdir -p -m 755 $RPM_BUILD_ROOT/lib/udev/rules.d
-install -p -m 644 %{SOURCE10} $RPM_BUILD_ROOT/lib/udev/rules.d/90-alsa.rules
+install -p -m 644 %{SOURCE4} $RPM_BUILD_ROOT/lib/udev/rules.d/90-alsa.rules
# Install support utilities
mkdir -p -m755 $RPM_BUILD_ROOT/bin
install -p -m 755 alsaunmute %{buildroot}/bin/
+mkdir -p -m755 $RPM_BUILD_ROOT/%{_mandir}/man1
+gzip -9 -c %{SOURCE2} > $RPM_BUILD_ROOT/alsaunmute.1.gz
+install -p -m 644 $RPM_BUILD_ROOT/alsaunmute.1.gz %{buildroot}/%{_mandir}/man1
+rm $RPM_BUILD_ROOT/alsaunmute.1.gz
# Link alsactl to /usr/sbin
mkdir -p $RPM_BUILD_ROOT/%{_sbindir}
@@ -58,18 +83,25 @@
# Create a place for global configuration
mkdir -p -m 755 %{buildroot}/etc/alsa
-install -p -m 644 %{SOURCE11} %{buildroot}/etc/alsa
+install -p -m 644 %{SOURCE5} %{buildroot}/etc/alsa
touch %{buildroot}/etc/asound.state
# Install alsa-info.sh script
-install -p -m 755 %{SOURCE6} %{buildroot}/usr/bin/alsa-info
+install -p -m 755 %{SOURCE3} %{buildroot}/usr/bin/alsa-info
ln -s alsa-info %{buildroot}/usr/bin/alsa-info.sh
-%clean
-%{__rm} -rf $RPM_BUILD_ROOT
+# << install post
+
+%post
+# >> post
+if [ -s /etc/alsa/asound.state -a ! -s /etc/asound.state ] ; then
+ mv /etc/alsa/asound.state /etc/asound.state
+fi
+# << post
%files -f %{name}.lang
%defattr(-,root,root,-)
+# >> files
%doc COPYING README
%config /lib/udev/rules.d/*
%config /etc/alsa/*
@@ -82,10 +114,9 @@
%{_datadir}/sounds/
%doc %{_mandir}/man?/*
%dir /etc/alsa/
+%dir /lib/alsa/
+%dir /lib/alsa/init/
%ghost /etc/asound.state
+# << files
-%post
-if [ -s /etc/alsa/asound.state -a ! -s /etc/asound.state ] ; then
- mv /etc/alsa/asound.state /etc/asound.state
-fi
other changes:
--------------
++++++ alsa-info.sh
--- alsa-info.sh
+++ alsa-info.sh
@@ -1,6 +1,6 @@
#!/bin/bash
-SCRIPT_VERSION=0.4.58
+SCRIPT_VERSION=0.4.59
CHANGELOG="http://www.alsa-project.org/alsa-info.sh.changelog"
#################################################################################
@@ -439,6 +439,9 @@
cat /proc/asound/card*/codec97\#0/ac97\#0-0 > $TEMPDIR/alsa-ac97.tmp 2> /dev/null
cat /proc/asound/card*/codec97\#0/ac97\#0-0+regs > $TEMPDIR/alsa-ac97-regs.tmp 2> /dev/null
+#Check for USB mixer setup
+cat /proc/asound/card*/usbmixer > $TEMPDIR/alsa-usbmixer.tmp 2> /dev/null
+
#Fetch the info, and put it in $FILE in a nice readable format.
if [[ -z $PASTEBIN ]]; then
echo "upload=true&script=true&cardinfo=" > $FILE
@@ -596,6 +599,17 @@
echo "" >> $FILE
fi
+if [ -s "$TEMPDIR/alsa-usbmixer.tmp" ]
+then
+ echo "!!USB Mixer information" >> $FILE
+ echo "!!---------------------------" >> $FILE
+ echo "--startcollapse--" >> $FILE
+ echo "" >> $FILE
+ cat $TEMPDIR/alsa-usbmixer.tmp >> $FILE
+ echo "--endcollapse--" >> $FILE
+ echo "" >> $FILE
+ echo "" >> $FILE
+fi
#If no command line options are specified, then run as though --with-all was specified
if [[ -z "$1" ]]
++++++ alsa-utils-1.0.22.tar.bz2 -> alsa-utils-1.0.23.tar.bz2
--- alsactl/alsactl.c
+++ alsactl/alsactl.c
@@ -189,5 +189,5 @@
}
snd_config_update_free_global();
- return res < 0 ? res : 0;
+ return res < 0 ? -res : 0;
}
--- alsactl/alsactl.h
+++ alsactl/alsactl.h
@@ -34,16 +34,16 @@
#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
#define cerror(cond, ...) do {\
- if (cond) { \
- fprintf(stderr, "%s: %s:%d: ", command, __FUNCTION__, __LINE__); \
+ if (cond || debugflag) { \
+ fprintf(stderr, "%s%s: %s:%d: ", debugflag ? "WARNING: " : "", command, __FUNCTION__, __LINE__); \
fprintf(stderr, __VA_ARGS__); \
putc('\n', stderr); \
} \
} while (0)
#else
#define cerror(cond, args...) do {\
- if (cond) { \
- fprintf(stderr, "%s: %s:%d: ", command, __FUNCTION__, __LINE__); \
+ if (cond || debugflag) { \
+ fprintf(stderr, "%s%s: %s:%d: ", debugflag ? "WARNING: " : "", command, __FUNCTION__, __LINE__); \
fprintf(stderr, ##args); \
putc('\n', stderr); \
} \
@@ -78,7 +78,7 @@
int file_map(const char *filename, char **buf, size_t *bufsize);
void file_unmap(void *buf, size_t bufsize);
size_t line_width(const char *buf, size_t bufsize, size_t pos);
-void initfailed(int cardnumber, const char *reason);
+void initfailed(int cardnumber, const char *reason, int exitcode);
static inline int hextodigit(int c)
{
--- alsactl/state.c
+++ alsactl/state.c
@@ -1117,7 +1117,6 @@
}
snd_ctl_elem_value_set_byte(ctl, idx, val);
return 1;
- break;
default:
break;
}
@@ -1404,6 +1403,7 @@
snd_ctl_card_info_alloca(&info);
sprintf(name, "hw:%d", card);
+ dbg("device='%s', doit=%i", name, doit);
err = snd_ctl_open(&handle, name, 0);
if (err < 0) {
error("snd_ctl_open error: %s", snd_strerror(err));
@@ -1415,6 +1415,7 @@
goto _close;
}
id = snd_ctl_card_info_get_id(info);
+ dbg("card-info-id: '%s'", id);
err = snd_config_searchv(top, &control, "state", id, "control", 0);
if (err < 0) {
if (force_restore) {
@@ -1440,24 +1441,25 @@
goto _close;
}
+ dbg("maxnumid=%i", maxnumid);
/* check if we have additional controls in driver */
/* in this case we should go through init procedure */
if (!doit && maxnumid >= 0) {
- snd_ctl_elem_id_t *id;
snd_ctl_elem_info_t *info;
- snd_ctl_elem_id_alloca(&id);
snd_ctl_elem_info_alloca(&info);
snd_ctl_elem_info_set_numid(info, maxnumid+1);
if (snd_ctl_elem_info(handle, info) == 0) {
/* not very informative */
/* but value is used for check only */
err = -EAGAIN;
+ dbg("more controls than maxnumid?");
goto _close;
}
}
_close:
snd_ctl_close(handle);
+ dbg("result code: %i", err);
return err;
}
@@ -1582,9 +1584,9 @@
err = init(initfile, cardname1);
if (err < 0) {
finalerr = err;
- initfailed(card, "init");
+ initfailed(card, "init", err);
}
- initfailed(card, "restore");
+ initfailed(card, "restore", -ENOENT);
}
if (first)
finalerr = 0; /* no cards, no error code */
@@ -1617,14 +1619,14 @@
sprintf(cardname1, "%i", card);
err = init(initfile, cardname1);
if (err < 0) {
- initfailed(card, "init");
+ initfailed(card, "init", err);
finalerr = err;
}
}
if ((err = set_controls(card, config, 1))) {
if (!force_restore)
finalerr = err;
- initfailed(card, "restore");
+ initfailed(card, "restore", err);
}
}
} else {
@@ -1639,12 +1641,12 @@
if (do_init && set_controls(cardno, config, 0)) {
err = init(initfile, cardname);
if (err < 0) {
- initfailed(cardno, "init");
- return err;
+ initfailed(cardno, "init", err);
+ finalerr = err;
}
}
if ((err = set_controls(cardno, config, 1))) {
- initfailed(cardno, "restore");
+ initfailed(cardno, "restore", err);
if (!force_restore)
return err;
}
--- alsactl/utils.c
+++ alsactl/utils.c
@@ -79,19 +79,23 @@
return count - pos;
}
-void initfailed(int cardnumber, const char *reason)
+void initfailed(int cardnumber, const char *reason, int exitcode)
{
int fp;
char *str;
+ char sexitcode[16];
if (statefile == NULL)
return;
if (snd_card_get_name(cardnumber, &str) < 0)
return;
+ sprintf(sexitcode, "%i", exitcode);
fp = open(statefile, O_WRONLY|O_CREAT|O_APPEND, 0644);
write(fp, str, strlen(str));
write(fp, ":", 1);
write(fp, reason, strlen(reason));
+ write(fp, ":", 1);
+ write(fp, sexitcode, strlen(sexitcode));
write(fp, "\n", 1);
close(fp);
free(str);
--- alsamixer/mixer_display.c
+++ alsamixer/mixer_display.c
@@ -390,6 +390,15 @@
display_string_in_field(y, x, s, width, ALIGN_CENTER);
}
+static long clamp(long value, long min, long max)
+{
+ if (value < min)
+ return min;
+ if (value > max)
+ return max;
+ return value;
+}
+
static void display_control(unsigned int control_index)
{
struct control *control;
@@ -462,6 +471,10 @@
err = snd_mixer_selem_get_capture_volume_range(control->elem, &min, &max);
if (err < 0)
return;
+ if (min >= max)
+ max = min + 1;
+ volumes[0] = clamp(volumes[0], min, max);
+ volumes[1] = clamp(volumes[1], min, max);
if (control->flags & IS_ACTIVE)
wattrset(mixer_widget.window, 0);
--- amidi/amidi.c
+++ amidi/amidi.c
@@ -95,122 +95,63 @@
return p;
}
-static int is_input(snd_ctl_t *ctl, int card, int device, int sub)
-{
- snd_rawmidi_info_t *info;
- int err;
-
- snd_rawmidi_info_alloca(&info);
- snd_rawmidi_info_set_device(info, device);
- snd_rawmidi_info_set_subdevice(info, sub);
- snd_rawmidi_info_set_stream(info, SND_RAWMIDI_STREAM_INPUT);
-
- if ((err = snd_ctl_rawmidi_info(ctl, info)) < 0 && err != -ENXIO)
- return err;
- else if (err == 0)
- return 1;
-
- return 0;
-}
-
-static int is_output(snd_ctl_t *ctl, int card, int device, int sub)
-{
- snd_rawmidi_info_t *info;
- int err;
-
- snd_rawmidi_info_alloca(&info);
- snd_rawmidi_info_set_device(info, device);
- snd_rawmidi_info_set_subdevice(info, sub);
- snd_rawmidi_info_set_stream(info, SND_RAWMIDI_STREAM_OUTPUT);
-
- if ((err = snd_ctl_rawmidi_info(ctl, info)) < 0 && err != -ENXIO)
- return err;
- else if (err == 0)
- return 1;
-
- return 0;
-}
-
static void list_device(snd_ctl_t *ctl, int card, int device)
{
snd_rawmidi_info_t *info;
const char *name;
const char *sub_name;
int subs, subs_in, subs_out;
- int sub, in, out;
+ int sub;
int err;
snd_rawmidi_info_alloca(&info);
snd_rawmidi_info_set_device(info, device);
snd_rawmidi_info_set_stream(info, SND_RAWMIDI_STREAM_INPUT);
- snd_ctl_rawmidi_info(ctl, info);
- subs_in = snd_rawmidi_info_get_subdevices_count(info);
+ err = snd_ctl_rawmidi_info(ctl, info);
+ if (err >= 0)
+ subs_in = snd_rawmidi_info_get_subdevices_count(info);
+ else
+ subs_in = 0;
+
snd_rawmidi_info_set_stream(info, SND_RAWMIDI_STREAM_OUTPUT);
- snd_ctl_rawmidi_info(ctl, info);
- subs_out = snd_rawmidi_info_get_subdevices_count(info);
- subs = subs_in > subs_out ? subs_in : subs_out;
+ err = snd_ctl_rawmidi_info(ctl, info);
+ if (err >= 0)
+ subs_out = snd_rawmidi_info_get_subdevices_count(info);
+ else
+ subs_out = 0;
- sub = 0;
- in = out = 0;
- if ((err = is_output(ctl, card, device, sub)) < 0) {
- error("cannot get rawmidi information %d:%d: %s",
- card, device, snd_strerror(err));
+ subs = subs_in > subs_out ? subs_in : subs_out;
+ if (!subs)
return;
- } else if (err)
- out = 1;
- if (err == 0) {
- if ((err = is_input(ctl, card, device, sub)) < 0) {
- error("cannot get rawmidi information %d:%d: %s",
- card, device, snd_strerror(err));
+ for (sub = 0; sub < subs; ++sub) {
+ snd_rawmidi_info_set_stream(info, sub < subs_in ?
+ SND_RAWMIDI_STREAM_INPUT :
+ SND_RAWMIDI_STREAM_OUTPUT);
+ snd_rawmidi_info_set_subdevice(info, sub);
+ err = snd_ctl_rawmidi_info(ctl, info);
+ if (err < 0) {
+ error("cannot get rawmidi information %d:%d:%d: %s\n",
+ card, device, sub, snd_strerror(err));
return;
}
- } else if (err)
- in = 1;
-
- if (err == 0)
- return;
-
- name = snd_rawmidi_info_get_name(info);
- sub_name = snd_rawmidi_info_get_subdevice_name(info);
- if (sub_name[0] == '\0') {
- if (subs == 1) {
- printf("%c%c hw:%d,%d %s\n",
- in ? 'I' : ' ', out ? 'O' : ' ',
+ name = snd_rawmidi_info_get_name(info);
+ sub_name = snd_rawmidi_info_get_subdevice_name(info);
+ if (sub == 0 && sub_name[0] == '\0') {
+ printf("%c%c hw:%d,%d %s",
+ sub < subs_in ? 'I' : ' ',
+ sub < subs_out ? 'O' : ' ',
card, device, name);
- } else
- printf("%c%c hw:%d,%d %s (%d subdevices)\n",
- in ? 'I' : ' ', out ? 'O' : ' ',
- card, device, name, subs);
- } else {
- sub = 0;
- for (;;) {
+ if (subs > 1)
+ printf(" (%d subdevices)", subs);
+ putchar('\n');
+ break;
+ } else {
printf("%c%c hw:%d,%d,%d %s\n",
- in ? 'I' : ' ', out ? 'O' : ' ',
+ sub < subs_in ? 'I' : ' ',
+ sub < subs_out ? 'O' : ' ',
card, device, sub, sub_name);
- if (++sub >= subs)
- break;
-
- in = is_input(ctl, card, device, sub);
- out = is_output(ctl, card, device, sub);
- snd_rawmidi_info_set_subdevice(info, sub);
- if (out) {
- snd_rawmidi_info_set_stream(info, SND_RAWMIDI_STREAM_OUTPUT);
- if ((err = snd_ctl_rawmidi_info(ctl, info)) < 0) {
- error("cannot get rawmidi information %d:%d:%d: %s",
- card, device, sub, snd_strerror(err));
- break;
- }
- } else {
- snd_rawmidi_info_set_stream(info, SND_RAWMIDI_STREAM_INPUT);
- if ((err = snd_ctl_rawmidi_info(ctl, info)) < 0) {
- error("cannot get rawmidi information %d:%d:%d: %s",
- card, device, sub, snd_strerror(err));
- break;
- }
- }
- sub_name = snd_rawmidi_info_get_subdevice_name(info);
}
}
}
--- amixer/amixer.c
+++ amixer/amixer.c
@@ -534,6 +534,26 @@
}
break;
#endif
+#ifdef SND_CTL_TLVT_DB_MINMAX
+ case SND_CTL_TLVT_DB_MINMAX:
+ case SND_CTL_TLVT_DB_MINMAX_MUTE:
+ if (type == SND_CTL_TLVT_DB_MINMAX_MUTE)
+ printf("dBminmaxmute-");
+ else
+ printf("dBminmax-");
+ if (size != 2 * sizeof(unsigned int)) {
+ while (size > 0) {
+ printf("0x%08x,", tlv[idx++]);
+ size -= sizeof(unsigned int);
+ }
+ } else {
+ printf("min=");
+ print_dB(tlv[2]);
+ printf(",max=");
+ print_dB(tlv[3]);
+ }
+ break;
+#endif
default:
printf("unk-%i-", type);
while (size > 0) {
@@ -602,6 +622,8 @@
break;
}
if (level & LEVEL_BASIC) {
+ if (!snd_ctl_elem_info_is_readable(info))
+ goto __skip_read;
if ((err = snd_hctl_elem_read(elem, control)) < 0) {
error("Control %s element read error: %s\n", card, snd_strerror(err));
return err;
@@ -638,6 +660,7 @@
}
}
printf("\n");
+ __skip_read:
if (!snd_ctl_elem_info_is_tlv_readable(info))
goto __skip_tlv;
tlv = malloc(4096);
--- aplay/aplay.1
+++ aplay/aplay.1
@@ -1,4 +1,4 @@
-.TH APLAY 1 "2 August 2001"
+.TH APLAY 1 "1 January 2010"
.SH NAME
arecord, aplay \- command-line sound recorder and player for ALSA
soundcard driver
@@ -46,6 +46,7 @@
\fI\-c, \-\-channels=#\fP
The number of channels.
The default is one channel.
+Valid values are 1 through 32.
.TP
\fI\-f \-\-format=FORMAT\fP
Sample format
@@ -53,19 +54,23 @@
Recognized sample formats are: S8 U8 S16_LE S16_BE U16_LE U16_BE S24_LE
S24_BE U24_LE U24_BE S32_LE S32_BE U32_LE U32_BE FLOAT_LE FLOAT_BE
FLOAT64_LE FLOAT64_BE IEC958_SUBFRAME_LE IEC958_SUBFRAME_BE MU_LAW
-A_LAW IMA_ADPCM MPEG GSM
+A_LAW IMA_ADPCM MPEG GSM SPECIAL S24_3LE S24_3BE U24_3LE U24_3BE S20_3LE
+S20_3BE U20_3LE U20_3BE S18_3LE S18_3BE U18_3LE
.br
Some of these may not be available on selected hardware
.br
-There are also two format shortcuts available:
+The available format shortcuts are:
.nf
-\-f cd (16 bit little endian, 44100, stereo [\-f S16_LE \-c2 \-r44100]
+\-f cd (16 bit little endian, 44100, stereo) [\-f S16_LE \-c2 \-r44100]
+\-f cdr (16 bit big endian, 44100, stereo) [\-f S16_BE \-c2 \-f44100]
\-f dat (16 bit little endian, 48000, stereo) [\-f S16_LE \-c2 \-r48000]
.fi
If no format is given U8 is used.
.TP
\fI\-r, \-\-rate=#<Hz>\fP
Sampling rate in Hertz. The default rate is 8000 Hertz.
+If the value specified is less than 300, it is taken as the rate in kilohertz.
+Valid values are 2000 through 192000 Hertz.
.TP
\fI\-d, \-\-duration=#\fP
Interrupt after # seconds.
@@ -120,10 +125,69 @@
with interleaved format.
.TP
\fI\-I, \-\-separate\-channels\fP
-One file for each channel
+One file for each channel. This option disables max\-file\-time
+and use\-strftime, and ignores SIGUSR1. The stereo VU meter is
+not available with separate channels.
+.TP
+\fI\-P\fP
+Playback. This is the default if the program is invoked
+by typing aplay.
+.TP
+\fI\-C\fP
+Record. This is the default if the program is invoked
+by typing arecord.
+.TP
+\fI\-\-disable\-resample\fP
+Disable automatic rate resample.
+.TP
+\fI\-\-disable\-channels\fP
+Disable automatic channel conversions.
+.TP
+\fI\-\-disable\-format\fP
+Disable automatic format conversions.
+.TP
+\fI\-\-disable\-softvol\fP
+Disable software volume control (softvol).
+.TP
+\fI\-\-test\-position\fP
+Test ring buffer position.
+.TP
+\fI\-\-test\-coef=<coef>\fP
+Test coefficient for ring buffer position; default is 8.
+Expression for validation is: coef * (buffer_size / 2).
+Minimum value is 1.
+.TP
+\fI\-\-test\-nowait\fP
+Do not wait for the ring buffer--eats the whole CPU.
+.TP
+\fI\-\-max\-file\-time\fP
+While recording, when the output file has been accumulating
+sound for this long,
+close it and open a new output file. Default is the maximum
+size supported by the file format: 2 GiB for WAV files.
+This option has no effect if \-\-separate\-channels is
+specified.
+.TP
+\fI\-\-process\-id\-file <file name>\fP
+aplay writes its process ID here, so other programs can
+send signals to it.
+.TP
+\fI\-\-use\-strftime\fP
+When recording, interpret %-codes in the file name parameter using
+the strftime facility whenever the output file is opened. The
+important strftime codes are: %Y is the year, %m month, %d day of
+the month, %H hour, %M minute and %S second. In addition, %v is
+the file number, starting at 1. When this option is specified,
+intermediate directories for the output file are created automatically.
+This option has no effect if \-\-separate\-channels is specified.
+
+.SH SIGNALS
+When recording, SIGINT, SIGTERM and SIGABRT will close the output
+file and exit. SIGUSR1 will close the output file, open a new one,
+and continue recording. However, SIGUSR1 does not work with
+\-\-separate\-channels.
-.SS
-Example:
+.SH EXAMPLES
.TP
\fBaplay \-c 1 \-t raw \-r 22050 \-f mu_law foobar\fR
@@ -144,6 +208,19 @@
}
.fi
+.TP
+\fBarecord \-t wav \-max-file_time 30 mon.wav\fP
+Record from the default audio source in monaural, 8,000 samples
+per second, 8 bits per sample. Start a new file every
+30 seconds. File names are mon-nn.wav, where nn increases
+from 01. The file after mon-99.wav is mon-100.wav.
+
+.TP
+\fBarecord \-f cd \-t wav \-max-file-time 3600 --use-strftime %Y/%m/%d/listen-%H-%M-%v.wav\fP
+Record in stereo from the default audio source. Create a new file
+every hour. The files are placed in directories based on their start dates
+and have names which include their start times and file numbers.
+
.SH SEE ALSO
\fB
alsamixer(1),
--- aplay/aplay.c
+++ aplay/aplay.c
@@ -111,11 +111,19 @@
static int test_coef = 8;
static int test_nowait = 0;
static snd_output_t *log;
+static long long max_file_size = 0;
+static int max_file_time = 0;
+static int use_strftime = 0;
+volatile static int recycle_capture_file = 0;
static int fd = -1;
static off64_t pbrec_count = LLONG_MAX, fdcount;
static int vocmajor, vocminor;
+static char *pidfile_name = NULL;
+FILE *pidf = NULL;
+static int pidfile_written = 0;
+
/* needed prototypes */
static void playback(char *filename);
@@ -194,7 +202,11 @@
" --test-position test ring buffer position\n"
" --test-coef=# test coeficient for ring buffer position (default 8)\n"
" expression for validation is: coef * (buffer_size / 2)\n"
-" --test-nowait do not wait for ring buffer - eats whole CPU\n")
+" --test-nowait do not wait for ring buffer - eats whole CPU\n"
+" --max-file-time=# start another output file when the old file has recorded\n"
+" for this many seconds\n"
+" --process-id-file write the process ID here\n"
+" --use-strftime apply the strftime facility to the output file name\n")
, command);
printf(_("Recognized sample formats are:"));
for (k = 0; k < SND_PCM_FORMAT_LAST; ++k) {
@@ -324,6 +336,18 @@
printf("%s: version " SND_UTIL_VERSION_STR " by Jaroslav Kysela <perex at perex.cz>\n", command);
}
+/*
+ * Subroutine to clean up before exit.
+ */
+static void prg_exit(int code)
+{
+ if (handle)
+ snd_pcm_close(handle);
+ if (pidfile_written)
+ remove (pidfile_name);
+ exit(code);
+}
+
static void signal_handler(int sig)
{
if (verbose==2)
@@ -345,7 +369,14 @@
snd_pcm_close(handle);
handle = NULL;
}
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
+}
+
+/* call on SIGUSR1 signal. */
+static void signal_handler_recycle (int sig)
+{
+ /* flag the capture loop to start a new output file */
+ recycle_capture_file = 1;
}
enum {
@@ -358,7 +389,10 @@
OPT_DISABLE_SOFTVOL,
OPT_TEST_POSITION,
OPT_TEST_COEF,
- OPT_TEST_NOWAIT
+ OPT_TEST_NOWAIT,
+ OPT_MAX_FILE_TIME,
+ OPT_PROCESS_ID_FILE,
+ OPT_USE_STRFTIME
};
int main(int argc, char *argv[])
@@ -399,6 +433,9 @@
{"test-position", 0, 0, OPT_TEST_POSITION},
{"test-coef", 1, 0, OPT_TEST_COEF},
{"test-nowait", 0, 0, OPT_TEST_NOWAIT},
+ {"max-file-time", 1, 0, OPT_MAX_FILE_TIME},
+ {"process-id-file", 1, 0, OPT_PROCESS_ID_FILE},
+ {"use-strftime", 0, 0, OPT_USE_STRFTIME},
{0, 0, 0, 0}
};
char *pcm_name = "default";
@@ -493,7 +530,7 @@
rhwparams.format = snd_pcm_format_value(optarg);
if (rhwparams.format == SND_PCM_FORMAT_UNKNOWN) {
error(_("wrong extended format '%s'"), optarg);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
break;
@@ -588,6 +625,15 @@
case OPT_TEST_NOWAIT:
test_nowait = 1;
break;
+ case OPT_MAX_FILE_TIME:
+ max_file_time = strtol(optarg, NULL, 0);
+ break;
+ case OPT_PROCESS_ID_FILE:
+ pidfile_name = optarg;
+ break;
+ case OPT_USE_STRFTIME:
+ use_strftime = 1;
+ break;
default:
fprintf(stderr, _("Try `%s --help' for more information.\n"), command);
return 1;
@@ -643,10 +689,24 @@
readn_func = snd_pcm_readn;
}
+ if (pidfile_name) {
+ errno = 0;
+ pidf = fopen (pidfile_name, "w");
+ if (pidf) {
+ (void)fprintf (pidf, "%d\n", getpid());
+ fclose(pidf);
+ pidfile_written = 1;
+ } else {
+ error(_("Cannot create process ID file %s: %s"),
+ pidfile_name, strerror (errno));
+ return 1;
+ }
+ }
signal(SIGINT, signal_handler);
signal(SIGTERM, signal_handler);
signal(SIGABRT, signal_handler);
+ signal(SIGUSR1, signal_handler_recycle);
if (interleaved) {
if (optind > argc - 1) {
if (stream == SND_PCM_STREAM_PLAYBACK)
@@ -670,10 +730,13 @@
if (verbose==2)
putchar('\n');
snd_pcm_close(handle);
+ handle = NULL;
free(audiobuf);
__end:
snd_output_close(log);
snd_config_update_free_global();
+ prg_exit(EXIT_SUCCESS);
+ /* avoid warning */
return EXIT_SUCCESS;
}
@@ -725,7 +788,7 @@
return *size;
if ((size_t)safe_read(fd, buffer + *size, reqsize - *size) != reqsize - *size) {
error(_("read error (called from line %i)"), line);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
return *size = reqsize;
}
@@ -735,7 +798,7 @@
blimit = len; \
if ((buffer = realloc(buffer, blimit)) == NULL) { \
error(_("not enough memory")); \
- exit(EXIT_FAILURE); \
+ prg_exit(EXIT_FAILURE); \
} \
}
@@ -784,7 +847,7 @@
if (len < sizeof(WaveFmtBody)) {
error(_("unknown length of 'fmt ' chunk (read %u, should be %u at least)"),
len, (u_int)sizeof(WaveFmtBody));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
check_wavefile_space(buffer, len, blimit);
test_wavefile_read(fd, buffer, &size, len, __LINE__);
@@ -794,22 +857,22 @@
if (len < sizeof(WaveFmtExtensibleBody)) {
error(_("unknown length of extensible 'fmt ' chunk (read %u, should be %u at least)"),
len, (u_int)sizeof(WaveFmtExtensibleBody));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (memcmp(fe->guid_tag, WAV_GUID_TAG, 14) != 0) {
error(_("wrong format tag in extensible 'fmt ' chunk"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
f->format = fe->guid_format;
}
if (LE_SHORT(f->format) != WAV_FMT_PCM &&
LE_SHORT(f->format) != WAV_FMT_IEEE_FLOAT) {
error(_("can't play WAVE-file format 0x%04x which is not PCM or FLOAT encoded"), LE_SHORT(f->format));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (LE_SHORT(f->channels) < 1) {
error(_("can't play WAVE-files with %d tracks"), LE_SHORT(f->channels));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
hwparams.channels = LE_SHORT(f->channels);
switch (LE_SHORT(f->bit_p_spl)) {
@@ -842,7 +905,7 @@
default:
error(_(" can't play WAVE-files with sample %d bits in %d bytes wide (%d channels)"),
LE_SHORT(f->bit_p_spl), LE_SHORT(f->byte_p_spl), hwparams.channels);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
break;
case 32:
@@ -854,7 +917,7 @@
default:
error(_(" can't play WAVE-files with sample %d bits wide"),
LE_SHORT(f->bit_p_spl));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
hwparams.rate = LE_INT(f->sample_fq);
@@ -936,7 +999,7 @@
return -1;
if ((size_t)safe_read(fd, buffer + sizeof(AuHeader), BE_INT(ap->hdr_size) - sizeof(AuHeader)) != BE_INT(ap->hdr_size) - sizeof(AuHeader)) {
error(_("read error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
return 0;
}
@@ -966,7 +1029,7 @@
err = snd_pcm_hw_params_any(handle, params);
if (err < 0) {
error(_("Broken configuration for this PCM: no configurations available"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (mmap_flag) {
snd_pcm_access_mask_t *mask = alloca(snd_pcm_access_mask_sizeof());
@@ -983,18 +1046,18 @@
SND_PCM_ACCESS_RW_NONINTERLEAVED);
if (err < 0) {
error(_("Access type not available"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
err = snd_pcm_hw_params_set_format(handle, params, hwparams.format);
if (err < 0) {
error(_("Sample format non available"));
show_available_sample_formats(params);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
err = snd_pcm_hw_params_set_channels(handle, params, hwparams.channels);
if (err < 0) {
error(_("Channels count non available"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
#if 0
@@ -1052,14 +1115,14 @@
if (err < 0) {
error(_("Unable to install hw params:"));
snd_pcm_hw_params_dump(params, log);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
snd_pcm_hw_params_get_period_size(params, &chunk_size, 0);
snd_pcm_hw_params_get_buffer_size(params, &buffer_size);
if (chunk_size == buffer_size) {
error(_("Can't use period equal to buffer size (%lu == %lu)"),
chunk_size, buffer_size);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
snd_pcm_sw_params_current(handle, swparams);
if (avail_min < 0)
@@ -1090,7 +1153,7 @@
if (snd_pcm_sw_params(handle, swparams) < 0) {
error(_("unable to install sw params:"));
snd_pcm_sw_params_dump(swparams, log);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (verbose)
@@ -1102,7 +1165,7 @@
audiobuf = realloc(audiobuf, chunk_bytes);
if (audiobuf == NULL) {
error(_("not enough memory"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
// fprintf(stderr, "real chunk_size = %i, frags = %i, total = %i\n", chunk_size, setup.buf.block.frags, setup.buf.block.frags * chunk_size);
@@ -1120,7 +1183,7 @@
err = snd_pcm_mmap_begin(handle, &areas, &offset, &size);
if (err < 0) {
error("snd_pcm_mmap_begin problem: %s", snd_strerror(err));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
for (i = 0; i < hwparams.channels; i++)
fprintf(stderr, "mmap_area[%i] = %p,%u,%u (%u)\n", i, areas[i].addr, areas[i].first, areas[i].step, snd_pcm_format_physical_width(hwparams.format));
@@ -1164,7 +1227,7 @@
snd_pcm_status_alloca(&status);
if ((res = snd_pcm_status(handle, status))<0) {
error(_("status error: %s"), snd_strerror(res));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (snd_pcm_status_get_state(status) == SND_PCM_STATE_XRUN) {
if (monotonic) {
@@ -1194,7 +1257,7 @@
}
if ((res = snd_pcm_prepare(handle))<0) {
error(_("xrun: prepare error: %s"), snd_strerror(res));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
return; /* ok, data should be accepted again */
} if (snd_pcm_status_get_state(status) == SND_PCM_STATE_DRAINING) {
@@ -1206,7 +1269,7 @@
fprintf(stderr, _("capture stream format change? attempting recover...\n"));
if ((res = snd_pcm_prepare(handle))<0) {
error(_("xrun(DRAINING): prepare error: %s"), snd_strerror(res));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
return;
}
@@ -1216,7 +1279,7 @@
snd_pcm_status_dump(status, log);
}
error(_("read/write error, state = %s"), snd_pcm_state_name(snd_pcm_status_get_state(status)));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
/* I/O suspend handler */
@@ -1233,7 +1296,7 @@
fprintf(stderr, _("Failed. Restarting stream. ")); fflush(stderr);
if ((res = snd_pcm_prepare(handle)) < 0) {
error(_("suspend: prepare error: %s"), snd_strerror(res));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
if (!quiet_mode)
@@ -1538,7 +1601,7 @@
suspend();
} else if (r < 0) {
error(_("write error: %s"), snd_strerror(r));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (r > 0) {
if (vumeter)
@@ -1584,7 +1647,7 @@
suspend();
} else if (r < 0) {
error(_("writev error: %s"), snd_strerror(r));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (r > 0) {
if (vumeter) {
@@ -1627,7 +1690,7 @@
suspend();
} else if (r < 0) {
error(_("read error: %s"), snd_strerror(r));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (r > 0) {
if (vumeter)
@@ -1670,7 +1733,7 @@
suspend();
} else if (r < 0) {
error(_("readv error: %s"), snd_strerror(r));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (r > 0) {
if (vumeter) {
@@ -1727,7 +1790,7 @@
l = chunk_size;
if (voc_pcm_write(buf, l) != (ssize_t)l) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
x -= l;
}
@@ -1769,7 +1832,7 @@
buffer_pos = 0;
if (data == NULL) {
error(_("malloc error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (!quiet_mode) {
fprintf(stderr, _("Playing Creative Labs Channel file '%s'...\n"), name);
@@ -1778,14 +1841,14 @@
while (ofs > (ssize_t)chunk_bytes) {
if ((size_t)safe_read(fd, buf, chunk_bytes) != chunk_bytes) {
error(_("read error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
ofs -= chunk_bytes;
}
if (ofs) {
if (safe_read(fd, buf, ofs) != ofs) {
error(_("read error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
hwparams.format = DEFAULT_FORMAT;
@@ -1809,7 +1872,7 @@
nextblock = buf[0] = 0;
if (l == -1) {
perror(name);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
}
@@ -1953,12 +2016,12 @@
if (output && !quiet_mode) {
if (write(2, data, l) != l) { /* to stderr */
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
} else {
if (voc_pcm_write(data, l) != l) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
COUNT(l);
@@ -2005,7 +2068,7 @@
if (write(fd, &vh, sizeof(VocHeader)) != sizeof(VocHeader)) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (hwparams.channels > 1) {
/* write an extended block */
@@ -2014,14 +2077,14 @@
bt.datalen_m = bt.datalen_h = 0;
if (write(fd, &bt, sizeof(VocBlockType)) != sizeof(VocBlockType)) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
eb.tc = LE_SHORT(65536 - 256000000L / (hwparams.rate << 1));
eb.pack = 0;
eb.mode = 1;
if (write(fd, &eb, sizeof(VocExtBlock)) != sizeof(VocExtBlock)) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
bt.type = 1;
@@ -2031,13 +2094,13 @@
bt.datalen_h = (u_char) ((cnt & 0xFF0000) >> 16);
if (write(fd, &bt, sizeof(VocBlockType)) != sizeof(VocBlockType)) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
vd.tc = (u_char) (256 - (1000000 / hwparams.rate));
vd.pack = 0;
if (write(fd, &vd, sizeof(VocVoiceData)) != sizeof(VocVoiceData)) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
@@ -2073,7 +2136,7 @@
break;
default:
error(_("Wave doesn't support %s format..."), snd_pcm_format_name(hwparams.format));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
h.magic = WAV_RIFF;
tmp = cnt + sizeof(WaveHeader) + sizeof(WaveChunkHeader) + sizeof(WaveFmtBody) + sizeof(WaveChunkHeader) - 8;
@@ -2109,7 +2172,7 @@
write(fd, &f, sizeof(WaveFmtBody)) != sizeof(WaveFmtBody) ||
write(fd, &cd, sizeof(WaveChunkHeader)) != sizeof(WaveChunkHeader)) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
@@ -2133,13 +2196,13 @@
break;
default:
error(_("Sparc Audio doesn't support %s format..."), snd_pcm_format_name(hwparams.format));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
ah.sample_rate = BE_INT(hwparams.rate);
ah.channels = BE_INT(hwparams.channels);
if (write(fd, &ah, sizeof(AuHeader)) != sizeof(AuHeader)) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
@@ -2153,7 +2216,7 @@
if (write(fd, &dummy, 1) != 1) {
error(_("write error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
length_seek = sizeof(VocHeader);
if (hwparams.channels > 1)
@@ -2261,7 +2324,7 @@
r = safe_read(fd, audiobuf + l, c);
if (r < 0) {
perror(name);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
fdcount += r;
if (r == 0)
@@ -2300,14 +2363,14 @@
} else {
if ((fd = open64(name, O_RDONLY, 0)) == -1) {
perror(name);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
/* read the file header */
dta = sizeof(AuHeader);
if ((size_t)safe_read(fd, audiobuf, dta) != dta) {
error(_("read error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
if (test_au(fd, audiobuf) >= 0) {
rhwparams.format = hwparams.format;
@@ -2319,7 +2382,7 @@
if ((size_t)safe_read(fd, audiobuf + sizeof(AuHeader),
dta - sizeof(AuHeader)) != dta - sizeof(AuHeader)) {
error(_("read error"));
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);;
}
if ((ofs = test_vocfile(audiobuf)) >= 0) {
pbrec_count = calc_count();
@@ -2341,13 +2404,98 @@
close(fd);
}
+/**
+ * mystrftime
+ *
+ * Variant of strftime(3) that supports additional format
+ * specifiers in the format string.
+ *
+ * Parameters:
+ *
+ * s - destination string
+ * max - max number of bytes to write
+ * userformat - format string
+ * tm - time information
+ * filenumber - the number of the file, starting at 1
+ *
+ * Returns: number of bytes written to the string s
+ */
+size_t mystrftime(char *s, size_t max, const char *userformat,
+ const struct tm *tm, const int filenumber)
+{
+ char formatstring[PATH_MAX] = "";
+ char tempstring[PATH_MAX] = "";
+ char *format, *tempstr;
+ const char *pos_userformat;
+
+ format = formatstring;
+
+ /* if mystrftime is called with userformat = NULL we return a zero length string */
+ if (userformat == NULL) {
+ *s = '\0';
+ return 0;
+ }
+
+ for (pos_userformat = userformat; *pos_userformat; ++pos_userformat) {
+ if (*pos_userformat == '%') {
+ tempstr = tempstring;
+ tempstr[0] = '\0';
+ switch (*++pos_userformat) {
+
+ case '\0': // end of string
+ --pos_userformat;
+ break;
+
+ case 'v': // file number
+ sprintf(tempstr, "%02d", filenumber);
+ break;
+
+ default: // All other codes will be handled by strftime
+ *format++ = '%';
+ *format++ = *pos_userformat;
+ continue;
+ }
+
+ /* If a format specifier was found and used, copy the result. */
+ if (tempstr[0]) {
+ while ((*format = *tempstr++) != '\0')
+ ++format;
+ continue;
+ }
+ }
+
+ /* For any other character than % we simply copy the character */
+ *format++ = *pos_userformat;
+ }
+
+ *format = '\0';
+ format = formatstring;
+ return strftime(s, max, format, tm);
+}
+
static int new_capture_file(char *name, char *namebuf, size_t namelen,
int filecount)
{
- /* get a copy of the original filename */
char *s;
char buf[PATH_MAX+1];
+ time_t t;
+ struct tm *tmp;
+ if (use_strftime) {
+ t = time(NULL);
+ tmp = localtime(&t);
+ if (tmp == NULL) {
+ perror("localtime");
+ prg_exit(EXIT_FAILURE);
+ }
+ if (mystrftime(namebuf, namelen, name, tmp, filecount+1) == 0) {
+ fprintf(stderr, "mystrftime returned 0");
+ prg_exit(EXIT_FAILURE);
+ }
+ return filecount;
+ }
+
+ /* get a copy of the original filename */
strncpy(buf, name, sizeof(buf));
/* separate extension from filename */
@@ -2379,6 +2527,58 @@
return filecount;
}
+/**
+ * create_path
+ *
+ * This function creates a file path, like mkdir -p.
+ *
+ * Parameters:
+ *
+ * path - the path to create
+ *
+ * Returns: 0 on success, -1 on failure
+ * On failure, a message has been printed to stderr.
+ */
+int create_path(const char *path)
+{
+ char *start;
+ mode_t mode = S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH;
+
+ if (path[0] == '/')
+ start = strchr(path + 1, '/');
+ else
+ start = strchr(path, '/');
+
+ while (start) {
+ char *buffer = strdup(path);
+ buffer[start-path] = 0x00;
+
+ if (mkdir(buffer, mode) == -1 && errno != EEXIST) {
+ fprintf(stderr, "Problem creating directory %s", buffer);
+ perror(" ");
+ free(buffer);
+ return -1;
+ }
+ free(buffer);
+ start = strchr(start + 1, '/');
+ }
+ return 0;
+}
+
+static int safe_open(const char *name)
+{
+ int fd;
+
+ fd = open64(name, O_WRONLY | O_CREAT, 0644);
+ if (fd == -1) {
+ if (errno != ENOENT || !use_strftime)
+ return -1;
+ if (create_path(name) == 0)
+ fd = open64(name, O_WRONLY | O_CREAT, 0644);
+ }
+ return fd;
+}
+
static void capture(char *orig_name)
{
int tostdout=0; /* boolean which describes output stream */
@@ -2391,6 +2591,10 @@
count = calc_count();
if (count == 0)
count = LLONG_MAX;
+ /* compute the number of bytes per file */
+ max_file_size = max_file_time *
+ snd_pcm_format_size(hwparams.format,
+ hwparams.rate * hwparams.channels);
/* WAVE-file should be even (I'm not sure), but wasting one byte
isn't a problem (this can only be in 8 bit mono) */
if (count < LLONG_MAX)
@@ -2417,7 +2621,7 @@
/* open a file to write */
if(!tostdout) {
/* upon the second file we start the numbering scheme */
- if (filecount) {
+ if (filecount || use_strftime) {
filecount = new_capture_file(orig_name, namebuf,
sizeof(namebuf),
filecount);
@@ -2426,9 +2630,10 @@
/* open a new file */
remove(name);
- if ((fd = open64(name, O_WRONLY | O_CREAT, 0644)) == -1) {
+ fd = safe_open(name);
+ if (fd < 0) {
perror(name);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
filecount++;
}
@@ -2436,6 +2641,8 @@
rest = count;
if (rest > fmt_rec_table[file_type].max_filesize)
rest = fmt_rec_table[file_type].max_filesize;
+ if (max_file_size && (rest > max_file_size))
+ rest = max_file_size;
/* setup sample header */
if (fmt_rec_table[file_type].start)
@@ -2443,7 +2650,7 @@
/* capture */
fdcount = 0;
- while (rest > 0) {
+ while (rest > 0 && recycle_capture_file == 0) {
size_t c = (rest <= (off64_t)chunk_bytes) ?
(size_t)rest : chunk_bytes;
size_t f = c * 8 / bits_per_frame;
@@ -2451,13 +2658,19 @@
break;
if (write(fd, audiobuf, c) != c) {
perror(name);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
count -= c;
rest -= c;
fdcount += c;
}
+ /* re-enable SIGUSR1 signal */
+ if (recycle_capture_file) {
+ recycle_capture_file = 0;
+ signal(SIGUSR1, signal_handler_recycle);
+ }
+
/* finish sample container */
if (fmt_rec_table[file_type].end && !tostdout) {
fmt_rec_table[file_type].end(fd);
@@ -2498,12 +2711,12 @@
r = safe_read(fds[0], bufs[0], expected);
if (r < 0) {
perror(names[channel]);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
for (channel = 1; channel < channels; ++channel) {
if (safe_read(fds[channel], bufs[channel], r) != r) {
perror(names[channel]);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
if (r == 0)
@@ -2550,7 +2763,7 @@
for (channel = 0; channel < channels; ++channel) {
if ((size_t)write(fds[channel], bufs[channel], rv) != rv) {
perror(names[channel]);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
}
r = r * bits_per_frame / 8;
@@ -2583,7 +2796,7 @@
alloced = 1;
} else if (count != channels) {
error(_("You need to specify %d files"), channels);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
for (channel = 0; channel < channels; ++channel) {
@@ -2609,7 +2822,7 @@
if (alloced)
free(names);
if (ret)
- exit(ret);
+ prg_exit(ret);
}
static void capturev(char **names, unsigned int count)
@@ -2636,7 +2849,7 @@
alloced = 1;
} else if (count != channels) {
error(_("You need to specify %d files"), channels);
- exit(EXIT_FAILURE);
+ prg_exit(EXIT_FAILURE);
}
for (channel = 0; channel < channels; ++channel) {
@@ -2662,5 +2875,5 @@
if (alloced)
free(names);
if (ret)
- exit(ret);
+ prg_exit(ret);
}
--- aplay/arecord.1
+++ aplay/arecord.1
@@ -1,4 +1,4 @@
-.TH APLAY 1 "2 August 2001"
+.TH APLAY 1 "1 January 2010"
.SH NAME
arecord, aplay \- command-line sound recorder and player for ALSA
soundcard driver
@@ -46,6 +46,7 @@
\fI\-c, \-\-channels=#\fP
The number of channels.
The default is one channel.
+Valid values are 1 through 32.
.TP
\fI\-f \-\-format=FORMAT\fP
Sample format
@@ -53,19 +54,23 @@
Recognized sample formats are: S8 U8 S16_LE S16_BE U16_LE U16_BE S24_LE
S24_BE U24_LE U24_BE S32_LE S32_BE U32_LE U32_BE FLOAT_LE FLOAT_BE
FLOAT64_LE FLOAT64_BE IEC958_SUBFRAME_LE IEC958_SUBFRAME_BE MU_LAW
-A_LAW IMA_ADPCM MPEG GSM
+A_LAW IMA_ADPCM MPEG GSM SPECIAL S24_3LE S24_3BE U24_3LE U24_3BE S20_3LE
+S20_3BE U20_3LE U20_3BE S18_3LE S18_3BE U18_3LE
.br
Some of these may not be available on selected hardware
.br
-There are also two format shortcuts available:
+The available format shortcuts are:
.nf
-\-f cd (16 bit little endian, 44100, stereo [\-f S16_LE \-c2 \-r44100]
+\-f cd (16 bit little endian, 44100, stereo) [\-f S16_LE \-c2 \-r44100]
+\-f cdr (16 bit big endian, 44100, stereo) [\-f S16_BE \-c2 \-f44100]
\-f dat (16 bit little endian, 48000, stereo) [\-f S16_LE \-c2 \-r48000]
.fi
If no format is given U8 is used.
.TP
\fI\-r, \-\-rate=#<Hz>\fP
Sampling rate in Hertz. The default rate is 8000 Hertz.
+If the value specified is less than 300, it is taken as the rate in kilohertz.
+Valid values are 2000 through 192000 Hertz.
.TP
\fI\-d, \-\-duration=#\fP
Interrupt after # seconds.
@@ -120,10 +125,69 @@
with interleaved format.
.TP
\fI\-I, \-\-separate\-channels\fP
-One file for each channel
+One file for each channel. This option disables max\-file\-time
+and use\-strftime, and ignores SIGUSR1. The stereo VU meter is
+not available with separate channels.
+.TP
+\fI\-P\fP
+Playback. This is the default if the program is invoked
+by typing aplay.
+.TP
+\fI\-C\fP
+Record. This is the default if the program is invoked
+by typing arecord.
+.TP
+\fI\-\-disable\-resample\fP
+Disable automatic rate resample.
+.TP
+\fI\-\-disable\-channels\fP
+Disable automatic channel conversions.
+.TP
+\fI\-\-disable\-format\fP
+Disable automatic format conversions.
+.TP
+\fI\-\-disable\-softvol\fP
+Disable software volume control (softvol).
+.TP
+\fI\-\-test\-position\fP
+Test ring buffer position.
+.TP
+\fI\-\-test\-coef=<coef>\fP
+Test coefficient for ring buffer position; default is 8.
+Expression for validation is: coef * (buffer_size / 2).
+Minimum value is 1.
+.TP
+\fI\-\-test\-nowait\fP
+Do not wait for the ring buffer--eats the whole CPU.
+.TP
+\fI\-\-max\-file\-time\fP
+While recording, when the output file has been accumulating
+sound for this long,
+close it and open a new output file. Default is the maximum
+size supported by the file format: 2 GiB for WAV files.
+This option has no effect if \-\-separate\-channels is
+specified.
+.TP
+\fI\-\-process\-id\-file <file name>\fP
+aplay writes its process ID here, so other programs can
+send signals to it.
+.TP
+\fI\-\-use\-strftime\fP
+When recording, interpret %-codes in the file name parameter using
+the strftime facility whenever the output file is opened. The
+important strftime codes are: %Y is the year, %m month, %d day of
+the month, %H hour, %M minute and %S second. In addition, %v is
+the file number, starting at 1. When this option is specified,
+intermediate directories for the output file are created automatically.
+This option has no effect if \-\-separate\-channels is specified.
+
+.SH SIGNALS
+When recording, SIGINT, SIGTERM and SIGABRT will close the output
+file and exit. SIGUSR1 will close the output file, open a new one,
+and continue recording. However, SIGUSR1 does not work with
+\-\-separate\-channels.
-.SS
-Example:
+.SH EXAMPLES
.TP
\fBaplay \-c 1 \-t raw \-r 22050 \-f mu_law foobar\fR
@@ -144,6 +208,19 @@
}
.fi
+.TP
+\fBarecord \-t wav \-max-file_time 30 mon.wav\fP
+Record from the default audio source in monaural, 8,000 samples
+per second, 8 bits per sample. Start a new file every
+30 seconds. File names are mon-nn.wav, where nn increases
+from 01. The file after mon-99.wav is mon-100.wav.
+
+.TP
+\fBarecord \-f cd \-t wav \-max-file-time 3600 --use-strftime %Y/%m/%d/listen-%H-%M-%v.wav\fP
+Record in stereo from the default audio source. Create a new file
+every hour. The files are placed in directories based on their start dates
+and have names which include their start times and file numbers.
+
.SH SEE ALSO
\fB
alsamixer(1),
--- configure
+++ configure
@@ -2089,7 +2089,7 @@
# Define the identity of the package.
PACKAGE=alsa-utils
- VERSION=1.0.22
+ VERSION=1.0.23
cat >>confdefs.h <<_ACEOF
--- configure.in
+++ configure.in
@@ -2,7 +2,7 @@
AC_PREREQ(2.59)
AC_INIT(aplay/aplay.c)
AC_PREFIX_DEFAULT(/usr)
-AM_INIT_AUTOMAKE(alsa-utils, 1.0.22)
+AM_INIT_AUTOMAKE(alsa-utils, 1.0.23)
AM_GNU_GETTEXT([external])
AM_GNU_GETTEXT_VERSION([0.15])
--- include/version.h
+++ include/version.h
@@ -4,9 +4,9 @@
#define SND_UTIL_MAJOR 1
#define SND_UTIL_MINOR 0
-#define SND_UTIL_SUBMINOR 22
+#define SND_UTIL_SUBMINOR 23
#define SND_UTIL_VERSION ((SND_UTIL_MAJOR<<16)|\
(SND_UTIL_MINOR<<8)|\
SND_UTIL_SUBMINOR)
-#define SND_UTIL_VERSION_STR "1.0.22"
+#define SND_UTIL_VERSION_STR "1.0.23"
--- po/alsa-utils.pot
+++ po/alsa-utils.pot
@@ -8,7 +8,7 @@
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-12-16 16:28+0100\n"
+"POT-Creation-Date: 2010-04-16 13:19+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL at ADDRESS>\n"
"Language-Team: LANGUAGE <LL at li.org>\n"
@@ -171,47 +171,47 @@
msgstr ""
#. TRANSLATORS: playback on; one character
-#: alsamixer/mixer_display.c:524 alsamixer/mixer_display.c:529
+#: alsamixer/mixer_display.c:537 alsamixer/mixer_display.c:542
msgid "O"
msgstr ""
#. TRANSLATORS: playback muted; one character
-#: alsamixer/mixer_display.c:526 alsamixer/mixer_display.c:530
+#: alsamixer/mixer_display.c:539 alsamixer/mixer_display.c:543
msgid "M"
msgstr ""
#. TRANSLATORS: "left"; no more than two characters
-#: alsamixer/mixer_display.c:544
+#: alsamixer/mixer_display.c:557
msgid "L"
msgstr ""
#. TRANSLATORS: "right"; no more than two characters
-#: alsamixer/mixer_display.c:548
+#: alsamixer/mixer_display.c:561
msgid "R"
msgstr ""
#. TRANSLATORS: no more than eight characters
-#: alsamixer/mixer_display.c:550
+#: alsamixer/mixer_display.c:563
msgid "CAPTURE"
msgstr ""
-#: alsamixer/mixer_display.c:600
+#: alsamixer/mixer_display.c:613
msgid "Front"
msgstr ""
-#: alsamixer/mixer_display.c:603
+#: alsamixer/mixer_display.c:616
msgid "Rear"
msgstr ""
-#: alsamixer/mixer_display.c:606 speaker-test/speaker-test.c:107
+#: alsamixer/mixer_display.c:619 speaker-test/speaker-test.c:107
msgid "Center"
msgstr ""
-#: alsamixer/mixer_display.c:609
+#: alsamixer/mixer_display.c:622
msgid "Woofer"
msgstr ""
-#: alsamixer/mixer_display.c:612
+#: alsamixer/mixer_display.c:625
msgid "Side"
msgstr ""
@@ -356,23 +356,23 @@
msgid "Cannot open file \"%s\"."
msgstr ""
-#: aplay/aplay.c:139
+#: aplay/aplay.c:147
msgid "raw data"
msgstr ""
-#: aplay/aplay.c:140
+#: aplay/aplay.c:148
msgid "VOC"
msgstr ""
-#: aplay/aplay.c:142
+#: aplay/aplay.c:150
msgid "WAVE"
msgstr ""
-#: aplay/aplay.c:143
+#: aplay/aplay.c:151
msgid "Sparc Audio"
msgstr ""
-#: aplay/aplay.c:164
+#: aplay/aplay.c:172
#, c-format
msgid ""
"Usage: %s [OPTION]... [FILE]...\n"
@@ -411,428 +411,438 @@
" expression for validation is: coef * (buffer_size / "
"2)\n"
" --test-nowait do not wait for ring buffer - eats whole CPU\n"
+" --max-file-time=# start another output file when the old file has "
+"recorded\n"
+" for this many seconds\n"
+" --process-id-file write the process ID here\n"
+" --use-strftime apply the strftime facility to the output file name\n"
msgstr ""
-#: aplay/aplay.c:199 speaker-test/speaker-test.c:749
+#: aplay/aplay.c:211 speaker-test/speaker-test.c:750
#, c-format
msgid "Recognized sample formats are:"
msgstr ""
-#: aplay/aplay.c:205
+#: aplay/aplay.c:217
#, c-format
msgid ""
"\n"
"Some of these may not be available on selected hardware\n"
msgstr ""
-#: aplay/aplay.c:206
+#: aplay/aplay.c:218
#, c-format
msgid "The availabled format shortcuts are:\n"
msgstr ""
-#: aplay/aplay.c:207
+#: aplay/aplay.c:219
#, c-format
msgid "-f cd (16 bit little endian, 44100, stereo)\n"
msgstr ""
-#: aplay/aplay.c:208
+#: aplay/aplay.c:220
#, c-format
msgid "-f cdr (16 bit big endian, 44100, stereo)\n"
msgstr ""
-#: aplay/aplay.c:209
+#: aplay/aplay.c:221
#, c-format
msgid "-f dat (16 bit little endian, 48000, stereo)\n"
msgstr ""
-#: aplay/aplay.c:223
+#: aplay/aplay.c:235
msgid "no soundcards found..."
msgstr ""
-#: aplay/aplay.c:226
+#: aplay/aplay.c:238
#, c-format
msgid "**** List of %s Hardware Devices ****\n"
msgstr ""
-#: aplay/aplay.c:255
+#: aplay/aplay.c:267
#, c-format
msgid "card %i: %s [%s], device %i: %s [%s]\n"
msgstr ""
-#: aplay/aplay.c:261
+#: aplay/aplay.c:273
#, c-format
msgid " Subdevices: %i/%i\n"
msgstr ""
-#: aplay/aplay.c:268
+#: aplay/aplay.c:280
#, c-format
msgid " Subdevice #%i: %s\n"
msgstr ""
-#: aplay/aplay.c:332
+#: aplay/aplay.c:356
#, c-format
msgid "Aborted by signal %s...\n"
msgstr ""
-#: aplay/aplay.c:430
+#: aplay/aplay.c:467
msgid "command should be named either arecord or aplay"
msgstr ""
-#: aplay/aplay.c:469
+#: aplay/aplay.c:506
#, c-format
msgid "unrecognized file format %s"
msgstr ""
-#: aplay/aplay.c:476
+#: aplay/aplay.c:513
#, c-format
msgid "value %i for channels is invalid"
msgstr ""
-#: aplay/aplay.c:495
+#: aplay/aplay.c:532
#, c-format
msgid "wrong extended format '%s'"
msgstr ""
-#: aplay/aplay.c:506
+#: aplay/aplay.c:543
#, c-format
msgid "bad speed value %i"
msgstr ""
-#: aplay/aplay.c:592
+#: aplay/aplay.c:638
#, c-format
msgid "Try `%s --help' for more information.\n"
msgstr ""
-#: aplay/aplay.c:608
+#: aplay/aplay.c:654
#, c-format
msgid "audio open error: %s"
msgstr ""
-#: aplay/aplay.c:613
+#: aplay/aplay.c:659
#, c-format
msgid "info error: %s"
msgstr ""
-#: aplay/aplay.c:620
+#: aplay/aplay.c:666
#, c-format
msgid "nonblock setting error: %s"
msgstr ""
-#: aplay/aplay.c:630 aplay/aplay.c:737 aplay/aplay.c:1104
+#: aplay/aplay.c:676 aplay/aplay.c:800 aplay/aplay.c:1167
msgid "not enough memory"
msgstr ""
-#: aplay/aplay.c:727
+#: aplay/aplay.c:700
+#, c-format
+msgid "Cannot create process ID file %s: %s"
+msgstr ""
+
+#: aplay/aplay.c:790
#, c-format
msgid "read error (called from line %i)"
msgstr ""
-#: aplay/aplay.c:785
+#: aplay/aplay.c:848
#, c-format
msgid "unknown length of 'fmt ' chunk (read %u, should be %u at least)"
msgstr ""
-#: aplay/aplay.c:795
+#: aplay/aplay.c:858
#, c-format
msgid ""
"unknown length of extensible 'fmt ' chunk (read %u, should be %u at least)"
msgstr ""
-#: aplay/aplay.c:800
+#: aplay/aplay.c:863
msgid "wrong format tag in extensible 'fmt ' chunk"
msgstr ""
-#: aplay/aplay.c:807
+#: aplay/aplay.c:870
#, c-format
msgid "can't play WAVE-file format 0x%04x which is not PCM or FLOAT encoded"
msgstr ""
-#: aplay/aplay.c:811
+#: aplay/aplay.c:874
#, c-format
msgid "can't play WAVE-files with %d tracks"
msgstr ""
-#: aplay/aplay.c:819 aplay/aplay.c:919
+#: aplay/aplay.c:882 aplay/aplay.c:982
#, c-format
msgid "Warning: format is changed to U8\n"
msgstr ""
-#: aplay/aplay.c:825
+#: aplay/aplay.c:888
#, c-format
msgid "Warning: format is changed to S16_LE\n"
msgstr ""
-#: aplay/aplay.c:833
+#: aplay/aplay.c:896
#, c-format
msgid "Warning: format is changed to S24_3LE\n"
msgstr ""
-#: aplay/aplay.c:839
+#: aplay/aplay.c:902
#, c-format
msgid "Warning: format is changed to S24_LE\n"
msgstr ""
-#: aplay/aplay.c:843
+#: aplay/aplay.c:906
#, c-format
msgid ""
" can't play WAVE-files with sample %d bits in %d bytes wide (%d channels)"
msgstr ""
-#: aplay/aplay.c:855
+#: aplay/aplay.c:918
#, c-format
msgid " can't play WAVE-files with sample %d bits wide"
msgstr ""
-#: aplay/aplay.c:913
+#: aplay/aplay.c:976
#, c-format
msgid "Warning: format is changed to MU_LAW\n"
msgstr ""
-#: aplay/aplay.c:925
+#: aplay/aplay.c:988
#, c-format
msgid "Warning: format is changed to S16_BE\n"
msgstr ""
-#: aplay/aplay.c:938 aplay/aplay.c:1780 aplay/aplay.c:1787 aplay/aplay.c:2309
-#: aplay/aplay.c:2321
+#: aplay/aplay.c:1001 aplay/aplay.c:1843 aplay/aplay.c:1850 aplay/aplay.c:2372
+#: aplay/aplay.c:2384
msgid "read error"
msgstr ""
-#: aplay/aplay.c:968
+#: aplay/aplay.c:1031
msgid "Broken configuration for this PCM: no configurations available"
msgstr ""
-#: aplay/aplay.c:985
+#: aplay/aplay.c:1048
msgid "Access type not available"
msgstr ""
-#: aplay/aplay.c:990
+#: aplay/aplay.c:1053
msgid "Sample format non available"
msgstr ""
-#: aplay/aplay.c:996
+#: aplay/aplay.c:1059
msgid "Channels count non available"
msgstr ""
-#: aplay/aplay.c:1011
+#: aplay/aplay.c:1074
#, c-format
msgid "Warning: rate is not accurate (requested = %iHz, got = %iHz)\n"
msgstr ""
-#: aplay/aplay.c:1017
+#: aplay/aplay.c:1080
#, c-format
msgid " please, try the plug plugin %s\n"
msgstr ""
-#: aplay/aplay.c:1053
+#: aplay/aplay.c:1116
msgid "Unable to install hw params:"
msgstr ""
-#: aplay/aplay.c:1060
+#: aplay/aplay.c:1123
#, c-format
msgid "Can't use period equal to buffer size (%lu == %lu)"
msgstr ""
-#: aplay/aplay.c:1091
+#: aplay/aplay.c:1154
msgid "unable to install sw params:"
msgstr ""
-#: aplay/aplay.c:1166
+#: aplay/aplay.c:1229
#, c-format
msgid "status error: %s"
msgstr ""
-#: aplay/aplay.c:1176 aplay/aplay.c:1187
+#: aplay/aplay.c:1239 aplay/aplay.c:1250
#, c-format
msgid "%s!!! (at least %.3f ms long)\n"
msgstr ""
-#: aplay/aplay.c:1177 aplay/aplay.c:1180 aplay/aplay.c:1188
+#: aplay/aplay.c:1240 aplay/aplay.c:1243 aplay/aplay.c:1251
msgid "underrun"
msgstr ""
-#: aplay/aplay.c:1177 aplay/aplay.c:1188
+#: aplay/aplay.c:1240 aplay/aplay.c:1251
msgid "overrun"
msgstr ""
-#: aplay/aplay.c:1192
+#: aplay/aplay.c:1255
#, c-format
msgid "Status:\n"
msgstr ""
-#: aplay/aplay.c:1196
+#: aplay/aplay.c:1259
#, c-format
msgid "xrun: prepare error: %s"
msgstr ""
-#: aplay/aplay.c:1202
+#: aplay/aplay.c:1265
#, c-format
msgid "Status(DRAINING):\n"
msgstr ""
-#: aplay/aplay.c:1206
+#: aplay/aplay.c:1269
#, c-format
msgid "capture stream format change? attempting recover...\n"
msgstr ""
-#: aplay/aplay.c:1208
+#: aplay/aplay.c:1271
#, c-format
msgid "xrun(DRAINING): prepare error: %s"
msgstr ""
-#: aplay/aplay.c:1215
+#: aplay/aplay.c:1278
#, c-format
msgid "Status(R/W):\n"
msgstr ""
-#: aplay/aplay.c:1218
+#: aplay/aplay.c:1281
#, c-format
msgid "read/write error, state = %s"
msgstr ""
-#: aplay/aplay.c:1228
+#: aplay/aplay.c:1291
#, c-format
msgid "Suspended. Trying resume. "
msgstr ""
-#: aplay/aplay.c:1233
+#: aplay/aplay.c:1296
#, c-format
msgid "Failed. Restarting stream. "
msgstr ""
-#: aplay/aplay.c:1235
+#: aplay/aplay.c:1298
#, c-format
msgid "suspend: prepare error: %s"
msgstr ""
-#: aplay/aplay.c:1240
+#: aplay/aplay.c:1303
#, c-format
msgid "Done.\n"
msgstr ""
-#: aplay/aplay.c:1262
+#: aplay/aplay.c:1325
#, c-format
msgid " !clip "
msgstr ""
-#: aplay/aplay.c:1409
+#: aplay/aplay.c:1472
#, c-format
msgid "Unsupported bit size %d.\n"
msgstr ""
-#: aplay/aplay.c:1443
+#: aplay/aplay.c:1506
#, c-format
msgid "Max peak (%li samples): 0x%08x "
msgstr ""
-#: aplay/aplay.c:1477
+#: aplay/aplay.c:1540
#, c-format
msgid ""
"Suspicious buffer position (%li total): avail = %li, delay = %li, buffer = %"
"li\n"
msgstr ""
-#: aplay/aplay.c:1540
+#: aplay/aplay.c:1603
#, c-format
msgid "write error: %s"
msgstr ""
-#: aplay/aplay.c:1586
+#: aplay/aplay.c:1649
#, c-format
msgid "writev error: %s"
msgstr ""
-#: aplay/aplay.c:1629
+#: aplay/aplay.c:1692
#, c-format
msgid "read error: %s"
msgstr ""
-#: aplay/aplay.c:1672
+#: aplay/aplay.c:1735
#, c-format
msgid "readv error: %s"
msgstr ""
-#: aplay/aplay.c:1720
+#: aplay/aplay.c:1783
msgid "can't allocate buffer for silence"
msgstr ""
-#: aplay/aplay.c:1729 aplay/aplay.c:1955 aplay/aplay.c:1960 aplay/aplay.c:2007
-#: aplay/aplay.c:2016 aplay/aplay.c:2023 aplay/aplay.c:2033 aplay/aplay.c:2039
-#: aplay/aplay.c:2111 aplay/aplay.c:2141 aplay/aplay.c:2155
+#: aplay/aplay.c:1792 aplay/aplay.c:2018 aplay/aplay.c:2023 aplay/aplay.c:2070
+#: aplay/aplay.c:2079 aplay/aplay.c:2086 aplay/aplay.c:2096 aplay/aplay.c:2102
+#: aplay/aplay.c:2174 aplay/aplay.c:2204 aplay/aplay.c:2218
msgid "write error"
msgstr ""
-#: aplay/aplay.c:1742
+#: aplay/aplay.c:1805
#, c-format
msgid "voc_pcm_flush - silence error"
msgstr ""
-#: aplay/aplay.c:1745
+#: aplay/aplay.c:1808
msgid "voc_pcm_flush error"
msgstr ""
-#: aplay/aplay.c:1771
+#: aplay/aplay.c:1834
msgid "malloc error"
msgstr ""
-#: aplay/aplay.c:1775
+#: aplay/aplay.c:1838
#, c-format
msgid "Playing Creative Labs Channel file '%s'...\n"
msgstr ""
-#: aplay/aplay.c:1843 aplay/aplay.c:1935
+#: aplay/aplay.c:1906 aplay/aplay.c:1998
msgid "can't play packed .voc files"
msgstr ""
-#: aplay/aplay.c:1895
+#: aplay/aplay.c:1958
#, c-format
msgid "can't play loops; %s isn't seekable\n"
msgstr ""
-#: aplay/aplay.c:1944
+#: aplay/aplay.c:2007
#, c-format
msgid "unknown blocktype %d. terminate."
msgstr ""
-#: aplay/aplay.c:2075
+#: aplay/aplay.c:2138
#, c-format
msgid "Wave doesn't support %s format..."
msgstr ""
-#: aplay/aplay.c:2135
+#: aplay/aplay.c:2198
#, c-format
msgid "Sparc Audio doesn't support %s format..."
msgstr ""
-#: aplay/aplay.c:2216
+#: aplay/aplay.c:2279
msgid "Playing"
msgstr ""
-#: aplay/aplay.c:2216
+#: aplay/aplay.c:2279
msgid "Recording"
msgstr ""
-#: aplay/aplay.c:2220
+#: aplay/aplay.c:2283
#, c-format
msgid "Rate %d Hz, "
msgstr ""
-#: aplay/aplay.c:2222
+#: aplay/aplay.c:2285
#, c-format
msgid "Mono"
msgstr ""
-#: aplay/aplay.c:2224
+#: aplay/aplay.c:2287
#, c-format
msgid "Stereo"
msgstr ""
-#: aplay/aplay.c:2226
+#: aplay/aplay.c:2289
#, c-format
msgid "Channels %i"
msgstr ""
-#: aplay/aplay.c:2585 aplay/aplay.c:2638
+#: aplay/aplay.c:2798 aplay/aplay.c:2851
#, c-format
msgid "You need to specify %d files"
msgstr ""
@@ -943,47 +953,47 @@
msgid "kernel"
msgstr ""
-#: seq/aconnect/aconnect.c:326
+#: seq/aconnect/aconnect.c:307
#, c-format
msgid "can't open sequencer\n"
msgstr ""
-#: seq/aconnect/aconnect.c:354
+#: seq/aconnect/aconnect.c:335
#, c-format
msgid "can't get client id\n"
msgstr ""
-#: seq/aconnect/aconnect.c:361
+#: seq/aconnect/aconnect.c:342
#, c-format
msgid "can't set client info\n"
msgstr ""
-#: seq/aconnect/aconnect.c:368
+#: seq/aconnect/aconnect.c:349
#, c-format
msgid "invalid sender address %s\n"
msgstr ""
-#: seq/aconnect/aconnect.c:373 seq/aseqnet/aseqnet.c:290
+#: seq/aconnect/aconnect.c:354 seq/aseqnet/aseqnet.c:290
#, c-format
msgid "invalid destination address %s\n"
msgstr ""
-#: seq/aconnect/aconnect.c:387
+#: seq/aconnect/aconnect.c:368
#, c-format
msgid "No subscription is found\n"
msgstr ""
-#: seq/aconnect/aconnect.c:392
+#: seq/aconnect/aconnect.c:373
#, c-format
msgid "Disconnection failed (%s)\n"
msgstr ""
-#: seq/aconnect/aconnect.c:398
+#: seq/aconnect/aconnect.c:379
#, c-format
msgid "Connection is already subscribed\n"
msgstr ""
-#: seq/aconnect/aconnect.c:403
+#: seq/aconnect/aconnect.c:384
#, c-format
msgid "Connection failed (%s)\n"
msgstr ""
@@ -1308,7 +1318,7 @@
msgid "Can't recovery from suspend, prepare failed: %s\n"
msgstr ""
-#: speaker-test/speaker-test.c:539 speaker-test/speaker-test.c:953
+#: speaker-test/speaker-test.c:539 speaker-test/speaker-test.c:954
#, c-format
msgid "No enough memory\n"
msgstr ""
@@ -1363,7 +1373,7 @@
msgid "xrun_recovery failed: %d,%s\n"
msgstr ""
-#: speaker-test/speaker-test.c:733
+#: speaker-test/speaker-test.c:734
#, c-format
msgid ""
"Usage: speaker-test [OPTION]... \n"
@@ -1384,72 +1394,72 @@
"\n"
msgstr ""
-#: speaker-test/speaker-test.c:851
+#: speaker-test/speaker-test.c:852
#, c-format
msgid "Invalid number of periods %d\n"
msgstr ""
-#: speaker-test/speaker-test.c:865 speaker-test/speaker-test.c:869
+#: speaker-test/speaker-test.c:866 speaker-test/speaker-test.c:870
#, c-format
msgid "Invalid test type %s\n"
msgstr ""
-#: speaker-test/speaker-test.c:881
+#: speaker-test/speaker-test.c:882
#, c-format
msgid "Invalid parameter for -s option.\n"
msgstr ""
-#: speaker-test/speaker-test.c:895
+#: speaker-test/speaker-test.c:896
#, c-format
msgid "Unknown option '%c'\n"
msgstr ""
-#: speaker-test/speaker-test.c:909
+#: speaker-test/speaker-test.c:910
#, c-format
msgid "Playback device is %s\n"
msgstr ""
-#: speaker-test/speaker-test.c:910
+#: speaker-test/speaker-test.c:911
#, c-format
msgid "Stream parameters are %iHz, %s, %i channels\n"
msgstr ""
-#: speaker-test/speaker-test.c:913
+#: speaker-test/speaker-test.c:914
#, c-format
msgid "Using 16 octaves of pink noise\n"
msgstr ""
-#: speaker-test/speaker-test.c:916
+#: speaker-test/speaker-test.c:917
#, c-format
msgid "Sine wave rate is %.4fHz\n"
msgstr ""
-#: speaker-test/speaker-test.c:919
+#: speaker-test/speaker-test.c:920
#, c-format
msgid "WAV file(s)\n"
msgstr ""
-#: speaker-test/speaker-test.c:925
+#: speaker-test/speaker-test.c:926
#, c-format
msgid "Playback open error: %d,%s\n"
msgstr ""
-#: speaker-test/speaker-test.c:930
+#: speaker-test/speaker-test.c:931
#, c-format
msgid "Setting of hwparams failed: %s\n"
msgstr ""
-#: speaker-test/speaker-test.c:935
+#: speaker-test/speaker-test.c:936
#, c-format
msgid "Setting of swparams failed: %s\n"
msgstr ""
-#: speaker-test/speaker-test.c:984 speaker-test/speaker-test.c:1006
+#: speaker-test/speaker-test.c:985 speaker-test/speaker-test.c:1007
#, c-format
msgid "Transfer failed: %s\n"
msgstr ""
-#: speaker-test/speaker-test.c:994
+#: speaker-test/speaker-test.c:995
#, c-format
msgid "Time per period = %lf\n"
msgstr ""
!!! po/de.gmo and po/de.gmo differ
--- po/de.po
+++ po/de.po
@@ -7,7 +7,7 @@
msgstr ""
"Project-Id-Version: alsa-utils 1.0.20\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-12-16 16:28+0100\n"
+"POT-Creation-Date: 2010-04-16 13:19+0200\n"
"PO-Revision-Date: 2009-05-24 12:34+0200\n"
"Last-Translator: Clemens Ladisch <clemens at ladisch.de>\n"
"Language-Team: German\n"
@@ -179,47 +179,47 @@
msgstr "Dieses Gerät hat keine Regler."
#. TRANSLATORS: playback on; one character
-#: alsamixer/mixer_display.c:524 alsamixer/mixer_display.c:529
+#: alsamixer/mixer_display.c:537 alsamixer/mixer_display.c:542
msgid "O"
msgstr "O"
#. TRANSLATORS: playback muted; one character
-#: alsamixer/mixer_display.c:526 alsamixer/mixer_display.c:530
+#: alsamixer/mixer_display.c:539 alsamixer/mixer_display.c:543
msgid "M"
msgstr "M"
#. TRANSLATORS: "left"; no more than two characters
-#: alsamixer/mixer_display.c:544
+#: alsamixer/mixer_display.c:557
msgid "L"
msgstr "L"
#. TRANSLATORS: "right"; no more than two characters
-#: alsamixer/mixer_display.c:548
+#: alsamixer/mixer_display.c:561
msgid "R"
msgstr "R"
#. TRANSLATORS: no more than eight characters
-#: alsamixer/mixer_display.c:550
+#: alsamixer/mixer_display.c:563
msgid "CAPTURE"
msgstr "AUFNAHME"
-#: alsamixer/mixer_display.c:600
+#: alsamixer/mixer_display.c:613
msgid "Front"
msgstr "Vorne"
-#: alsamixer/mixer_display.c:603
+#: alsamixer/mixer_display.c:616
msgid "Rear"
msgstr "Hinten"
-#: alsamixer/mixer_display.c:606 speaker-test/speaker-test.c:107
+#: alsamixer/mixer_display.c:619 speaker-test/speaker-test.c:107
msgid "Center"
msgstr "Mitte"
-#: alsamixer/mixer_display.c:609
+#: alsamixer/mixer_display.c:622
msgid "Woofer"
msgstr "Bass"
-#: alsamixer/mixer_display.c:612
+#: alsamixer/mixer_display.c:625
msgid "Side"
msgstr "Seiten"
@@ -364,24 +364,24 @@
msgid "Cannot open file \"%s\"."
msgstr "Fehler beim Öffnen der Datei \"%s\"."
-#: aplay/aplay.c:139
+#: aplay/aplay.c:147
msgid "raw data"
msgstr "Rohdaten"
-#: aplay/aplay.c:140
+#: aplay/aplay.c:148
msgid "VOC"
msgstr "VOC"
-#: aplay/aplay.c:142
+#: aplay/aplay.c:150
msgid "WAVE"
msgstr "WAVE"
-#: aplay/aplay.c:143
+#: aplay/aplay.c:151
msgid "Sparc Audio"
msgstr "Sparc-Audio"
-#: aplay/aplay.c:164
-#, c-format
+#: aplay/aplay.c:172
+#, fuzzy, c-format
msgid ""
"Usage: %s [OPTION]... [FILE]...\n"
"\n"
@@ -419,6 +419,11 @@
" expression for validation is: coef * (buffer_size / "
"2)\n"
" --test-nowait do not wait for ring buffer - eats whole CPU\n"
+" --max-file-time=# start another output file when the old file has "
+"recorded\n"
+" for this many seconds\n"
+" --process-id-file write the process ID here\n"
+" --use-strftime apply the strftime facility to the output file name\n"
msgstr ""
"Verwendung: %s [Option]... [Datei]...\n"
"\n"
@@ -457,12 +462,12 @@
" --test-nowait kein Warten auf Ringpuffer; beansprucht volle CPU-"
"Leistung\n"
-#: aplay/aplay.c:199 speaker-test/speaker-test.c:749
+#: aplay/aplay.c:211 speaker-test/speaker-test.c:750
#, c-format
msgid "Recognized sample formats are:"
msgstr "Unterstützte Sample-Formate:"
-#: aplay/aplay.c:205
+#: aplay/aplay.c:217
#, c-format
msgid ""
"\n"
@@ -471,115 +476,120 @@
"\n"
"Nicht alle davon sind auf jeder Hardware verfügbar.\n"
-#: aplay/aplay.c:206
+#: aplay/aplay.c:218
#, c-format
msgid "The availabled format shortcuts are:\n"
msgstr "Unterstütze Format-Abkürzungen:\n"
-#: aplay/aplay.c:207
+#: aplay/aplay.c:219
#, c-format
msgid "-f cd (16 bit little endian, 44100, stereo)\n"
msgstr "-f cd (16 Bits, Little Endian, 44100 Hz, stereo)\n"
-#: aplay/aplay.c:208
+#: aplay/aplay.c:220
#, c-format
msgid "-f cdr (16 bit big endian, 44100, stereo)\n"
msgstr "-f cdr (16 Bits, Big Endian, 44100 Hz, stereo)\n"
-#: aplay/aplay.c:209
+#: aplay/aplay.c:221
#, c-format
msgid "-f dat (16 bit little endian, 48000, stereo)\n"
msgstr "-f dat (16 Bits, Little Endian, 48000 Hz, stereo)\n"
-#: aplay/aplay.c:223
+#: aplay/aplay.c:235
msgid "no soundcards found..."
msgstr "keine Soundkarten gefunden ..."
-#: aplay/aplay.c:226
+#: aplay/aplay.c:238
#, c-format
msgid "**** List of %s Hardware Devices ****\n"
msgstr "**** Liste der Hardware-Geräte (%s) ****\n"
-#: aplay/aplay.c:255
+#: aplay/aplay.c:267
#, c-format
msgid "card %i: %s [%s], device %i: %s [%s]\n"
msgstr "Karte %i: %s [%s], Gerät %i: %s [%s]\n"
-#: aplay/aplay.c:261
+#: aplay/aplay.c:273
#, c-format
msgid " Subdevices: %i/%i\n"
msgstr " Sub-Geräte: %i/%i\n"
-#: aplay/aplay.c:268
+#: aplay/aplay.c:280
#, c-format
msgid " Subdevice #%i: %s\n"
msgstr " Sub-Gerät #%i: %s\n"
-#: aplay/aplay.c:332
+#: aplay/aplay.c:356
#, c-format
msgid "Aborted by signal %s...\n"
msgstr "Abbruch durch Signal %s ...\n"
-#: aplay/aplay.c:430
+#: aplay/aplay.c:467
msgid "command should be named either arecord or aplay"
msgstr "Befehl sollte arecord oder aplay sein"
-#: aplay/aplay.c:469
+#: aplay/aplay.c:506
#, c-format
msgid "unrecognized file format %s"
msgstr "unbekanntes Dateiformat %s"
-#: aplay/aplay.c:476
+#: aplay/aplay.c:513
#, c-format
msgid "value %i for channels is invalid"
msgstr "Kanalanzahl %i ist ungültig"
-#: aplay/aplay.c:495
+#: aplay/aplay.c:532
#, c-format
msgid "wrong extended format '%s'"
msgstr "erweitertes Format '%s' ist ungültig"
-#: aplay/aplay.c:506
+#: aplay/aplay.c:543
#, c-format
msgid "bad speed value %i"
msgstr "ungültige Rate %i"
-#: aplay/aplay.c:592
+#: aplay/aplay.c:638
#, c-format
msgid "Try `%s --help' for more information.\n"
msgstr "Siehe `%s --help' für mehr Informationen.\n"
-#: aplay/aplay.c:608
+#: aplay/aplay.c:654
#, c-format
msgid "audio open error: %s"
msgstr "Fehler beim Öffnen des Gerätes: %s"
-#: aplay/aplay.c:613
+#: aplay/aplay.c:659
#, c-format
msgid "info error: %s"
msgstr "Fehler beim Lesen der Geräteinformationen: %s"
-#: aplay/aplay.c:620
+#: aplay/aplay.c:666
#, c-format
msgid "nonblock setting error: %s"
msgstr "Fehler beim Setzen des nonblock-Modus: %s"
-#: aplay/aplay.c:630 aplay/aplay.c:737 aplay/aplay.c:1104
+#: aplay/aplay.c:676 aplay/aplay.c:800 aplay/aplay.c:1167
msgid "not enough memory"
msgstr "nicht genug Speicher"
-#: aplay/aplay.c:727
+#: aplay/aplay.c:700
+#, fuzzy, c-format
+msgid "Cannot create process ID file %s: %s"
+msgstr "Kann WAV-Datei %s nicht öffnen\n"
+
+#: aplay/aplay.c:790
#, c-format
msgid "read error (called from line %i)"
msgstr "Lesefehler (aufgerufen von Zeile %i)"
-#: aplay/aplay.c:785
+#: aplay/aplay.c:848
#, c-format
msgid "unknown length of 'fmt ' chunk (read %u, should be %u at least)"
msgstr ""
"unbekannte Länge des 'fmt '-Blocks (gelesen: %u, sollte mindestens %u sein)"
-#: aplay/aplay.c:795
+#: aplay/aplay.c:858
#, c-format
msgid ""
"unknown length of extensible 'fmt ' chunk (read %u, should be %u at least)"
@@ -587,198 +597,198 @@
"unbekannte Länge des erweiterten 'fmt '-Blocks (gelesen: %u, sollte "
"mindestens %u sein)"
-#: aplay/aplay.c:800
+#: aplay/aplay.c:863
msgid "wrong format tag in extensible 'fmt ' chunk"
msgstr "ungültiger Format-Wert im erweiterten 'fmt '-Block"
-#: aplay/aplay.c:807
+#: aplay/aplay.c:870
#, c-format
msgid "can't play WAVE-file format 0x%04x which is not PCM or FLOAT encoded"
msgstr ""
"kann WAVE-Datei-Format 0x%04x nicht abspielen; ist weder PCM noch FLOAT"
-#: aplay/aplay.c:811
+#: aplay/aplay.c:874
#, c-format
msgid "can't play WAVE-files with %d tracks"
msgstr "kann WAVE-Datei mit %d Kanälen nicht abspielen"
-#: aplay/aplay.c:819 aplay/aplay.c:919
+#: aplay/aplay.c:882 aplay/aplay.c:982
#, c-format
msgid "Warning: format is changed to U8\n"
msgstr "Warnung: benutztes Format ist U8\n"
-#: aplay/aplay.c:825
+#: aplay/aplay.c:888
#, c-format
msgid "Warning: format is changed to S16_LE\n"
msgstr "Warnung: benutztes Format ist S16_LE\n"
-#: aplay/aplay.c:833
+#: aplay/aplay.c:896
#, c-format
msgid "Warning: format is changed to S24_3LE\n"
msgstr "Warnung: benutztes Format ist S24_3LE\n"
-#: aplay/aplay.c:839
+#: aplay/aplay.c:902
#, c-format
msgid "Warning: format is changed to S24_LE\n"
msgstr "Warnung: benutztes Format ist S24_LE\n"
-#: aplay/aplay.c:843
+#: aplay/aplay.c:906
#, c-format
msgid ""
" can't play WAVE-files with sample %d bits in %d bytes wide (%d channels)"
msgstr ""
"kann WAVE-Datei mit %d-Bit-Samples in %d Bytes (%d Kanäle) nicht abspielen"
-#: aplay/aplay.c:855
+#: aplay/aplay.c:918
#, c-format
msgid " can't play WAVE-files with sample %d bits wide"
msgstr "kann WAVE-Datei mit %d-Bit-Samples nicht abspielen"
-#: aplay/aplay.c:913
+#: aplay/aplay.c:976
#, c-format
msgid "Warning: format is changed to MU_LAW\n"
msgstr "Warnung: benutztes Format ist MU_LAW\n"
-#: aplay/aplay.c:925
+#: aplay/aplay.c:988
#, c-format
msgid "Warning: format is changed to S16_BE\n"
msgstr "Warnung: benutztes Format ist S16_BE\n"
-#: aplay/aplay.c:938 aplay/aplay.c:1780 aplay/aplay.c:1787 aplay/aplay.c:2309
-#: aplay/aplay.c:2321
+#: aplay/aplay.c:1001 aplay/aplay.c:1843 aplay/aplay.c:1850 aplay/aplay.c:2372
+#: aplay/aplay.c:2384
msgid "read error"
msgstr "Lesefehler"
-#: aplay/aplay.c:968
+#: aplay/aplay.c:1031
msgid "Broken configuration for this PCM: no configurations available"
msgstr ""
"ungültige Konfiguration für dieses Gerät: keine unterstützte Konfiguration"
-#: aplay/aplay.c:985
+#: aplay/aplay.c:1048
msgid "Access type not available"
msgstr "Zugriffs-Modus nicht unterstützt"
-#: aplay/aplay.c:990
+#: aplay/aplay.c:1053
msgid "Sample format non available"
msgstr "Sample-Format nicht unterstützt"
-#: aplay/aplay.c:996
+#: aplay/aplay.c:1059
msgid "Channels count non available"
msgstr "Kanalanzahl nicht unterstützt"
-#: aplay/aplay.c:1011
+#: aplay/aplay.c:1074
#, c-format
msgid "Warning: rate is not accurate (requested = %iHz, got = %iHz)\n"
msgstr ""
"Warnung: Rate ist nicht exakt (angefordert: %i Hz, unterstützt: %i Hz)\n"
-#: aplay/aplay.c:1017
+#: aplay/aplay.c:1080
#, c-format
msgid " please, try the plug plugin %s\n"
msgstr " probieren Sie bitte das plug-Plugin: %s\n"
-#: aplay/aplay.c:1053
+#: aplay/aplay.c:1116
msgid "Unable to install hw params:"
msgstr "Fehler beim Setzen der Hardware-Parameter:"
-#: aplay/aplay.c:1060
+#: aplay/aplay.c:1123
#, c-format
msgid "Can't use period equal to buffer size (%lu == %lu)"
msgstr "Periode gleich der Puffer-Größe wird nicht unterstützt (%lu == %lu)"
-#: aplay/aplay.c:1091
+#: aplay/aplay.c:1154
msgid "unable to install sw params:"
msgstr "Fehler beim Setzen der Software-Parameter:"
-#: aplay/aplay.c:1166
+#: aplay/aplay.c:1229
#, c-format
msgid "status error: %s"
msgstr "Status-Fehler: %s"
-#: aplay/aplay.c:1176 aplay/aplay.c:1187
+#: aplay/aplay.c:1239 aplay/aplay.c:1250
#, c-format
msgid "%s!!! (at least %.3f ms long)\n"
msgstr "%s!!! (mindestens %.3f ms)\n"
-#: aplay/aplay.c:1177 aplay/aplay.c:1180 aplay/aplay.c:1188
+#: aplay/aplay.c:1240 aplay/aplay.c:1243 aplay/aplay.c:1251
msgid "underrun"
msgstr "Unterlauf"
-#: aplay/aplay.c:1177 aplay/aplay.c:1188
+#: aplay/aplay.c:1240 aplay/aplay.c:1251
msgid "overrun"
msgstr "Überlauf"
-#: aplay/aplay.c:1192
+#: aplay/aplay.c:1255
#, c-format
msgid "Status:\n"
msgstr "Status:\n"
-#: aplay/aplay.c:1196
+#: aplay/aplay.c:1259
#, c-format
msgid "xrun: prepare error: %s"
msgstr "Unter-/Überlauf: Fehler beim Re-Initialisieren des Gerätes: %s"
-#: aplay/aplay.c:1202
+#: aplay/aplay.c:1265
#, c-format
msgid "Status(DRAINING):\n"
msgstr "Status (DRAINING):\n"
-#: aplay/aplay.c:1206
+#: aplay/aplay.c:1269
#, c-format
msgid "capture stream format change? attempting recover...\n"
msgstr "Format-Wechsel der Aufnahme-Daten? Versuche Wiederherstellung ...\n"
-#: aplay/aplay.c:1208
+#: aplay/aplay.c:1271
#, c-format
msgid "xrun(DRAINING): prepare error: %s"
msgstr "XRUN (DRAINING): Fehler beim Re-Initialisieren des Gerätes: %s"
-#: aplay/aplay.c:1215
+#: aplay/aplay.c:1278
#, c-format
msgid "Status(R/W):\n"
msgstr "Status (R/W):\n"
-#: aplay/aplay.c:1218
+#: aplay/aplay.c:1281
#, c-format
msgid "read/write error, state = %s"
msgstr "Lese-/Schreibfehler, Status = %s"
-#: aplay/aplay.c:1228
+#: aplay/aplay.c:1291
#, c-format
msgid "Suspended. Trying resume. "
msgstr "Ruhezustand. Versuche, aufzuwecken. "
-#: aplay/aplay.c:1233
+#: aplay/aplay.c:1296
#, c-format
msgid "Failed. Restarting stream. "
msgstr "Fehlgeschlagen. Re-Initialisierung. "
-#: aplay/aplay.c:1235
+#: aplay/aplay.c:1298
#, c-format
msgid "suspend: prepare error: %s"
msgstr "Ruhezustand: Fehler beim Re-Initialisieren: %s"
-#: aplay/aplay.c:1240
+#: aplay/aplay.c:1303
#, c-format
msgid "Done.\n"
msgstr "Fertig.\n"
-#: aplay/aplay.c:1262
+#: aplay/aplay.c:1325
#, c-format
msgid " !clip "
msgstr " !clip "
-#: aplay/aplay.c:1409
+#: aplay/aplay.c:1472
#, c-format
msgid "Unsupported bit size %d.\n"
msgstr "%d-Bit-Samples werden nicht unterstützt.\n"
-#: aplay/aplay.c:1443
+#: aplay/aplay.c:1506
#, c-format
msgid "Max peak (%li samples): 0x%08x "
msgstr "Höchstwert (%li Samples): 0x%08x "
-#: aplay/aplay.c:1477
+#: aplay/aplay.c:1540
#, c-format
msgid ""
"Suspicious buffer position (%li total): avail = %li, delay = %li, buffer = %"
@@ -787,108 +797,108 @@
"verdächtige Puffer-Position (total %li): avail = %li, delay = %li, buffer = %"
"li\n"
-#: aplay/aplay.c:1540
+#: aplay/aplay.c:1603
#, c-format
msgid "write error: %s"
msgstr "Schreibfehler: %s"
-#: aplay/aplay.c:1586
+#: aplay/aplay.c:1649
#, c-format
msgid "writev error: %s"
msgstr "Vektor-Schreib-Fehler: %s"
-#: aplay/aplay.c:1629
+#: aplay/aplay.c:1692
#, c-format
msgid "read error: %s"
msgstr "Lesefehler: %s"
-#: aplay/aplay.c:1672
+#: aplay/aplay.c:1735
#, c-format
msgid "readv error: %s"
msgstr "Vektor-Lese-Fehler: %s"
-#: aplay/aplay.c:1720
+#: aplay/aplay.c:1783
msgid "can't allocate buffer for silence"
msgstr "nicht genug Speicher für Stille-Block"
-#: aplay/aplay.c:1729 aplay/aplay.c:1955 aplay/aplay.c:1960 aplay/aplay.c:2007
-#: aplay/aplay.c:2016 aplay/aplay.c:2023 aplay/aplay.c:2033 aplay/aplay.c:2039
-#: aplay/aplay.c:2111 aplay/aplay.c:2141 aplay/aplay.c:2155
+#: aplay/aplay.c:1792 aplay/aplay.c:2018 aplay/aplay.c:2023 aplay/aplay.c:2070
+#: aplay/aplay.c:2079 aplay/aplay.c:2086 aplay/aplay.c:2096 aplay/aplay.c:2102
+#: aplay/aplay.c:2174 aplay/aplay.c:2204 aplay/aplay.c:2218
msgid "write error"
msgstr "Schreibfehler"
-#: aplay/aplay.c:1742
+#: aplay/aplay.c:1805
#, c-format
msgid "voc_pcm_flush - silence error"
msgstr "voc_pcm_flush - Fehler in set_silence"
-#: aplay/aplay.c:1745
+#: aplay/aplay.c:1808
msgid "voc_pcm_flush error"
msgstr "Schreibfehler"
-#: aplay/aplay.c:1771
+#: aplay/aplay.c:1834
msgid "malloc error"
msgstr "nicht genug Speicher"
-#: aplay/aplay.c:1775
+#: aplay/aplay.c:1838
#, c-format
msgid "Playing Creative Labs Channel file '%s'...\n"
msgstr "Spiele Creative Labs Channel-Datei '%s'...\n"
-#: aplay/aplay.c:1843 aplay/aplay.c:1935
+#: aplay/aplay.c:1906 aplay/aplay.c:1998
msgid "can't play packed .voc files"
msgstr "kann komprimierte .voc-Dateien nicht abspielen"
-#: aplay/aplay.c:1895
+#: aplay/aplay.c:1958
#, c-format
msgid "can't play loops; %s isn't seekable\n"
msgstr ""
"kann Schleife nicht abspielen; Dateiposition in %s ist nicht änderbar\n"
-#: aplay/aplay.c:1944
+#: aplay/aplay.c:2007
#, c-format
msgid "unknown blocktype %d. terminate."
msgstr "Unbekannter Block-Typ %d. Abbruch."
-#: aplay/aplay.c:2075
+#: aplay/aplay.c:2138
#, c-format
msgid "Wave doesn't support %s format..."
msgstr "Format %s wird in WAVE nicht unterstützt ..."
-#: aplay/aplay.c:2135
+#: aplay/aplay.c:2198
#, c-format
msgid "Sparc Audio doesn't support %s format..."
msgstr "Format %s wird in Sparc-Audio nicht unterstützt ..."
-#: aplay/aplay.c:2216
+#: aplay/aplay.c:2279
msgid "Playing"
msgstr "Wiedergabe:"
-#: aplay/aplay.c:2216
+#: aplay/aplay.c:2279
msgid "Recording"
msgstr "Aufnahme:"
-#: aplay/aplay.c:2220
+#: aplay/aplay.c:2283
#, c-format
msgid "Rate %d Hz, "
msgstr "Rate: %d Hz, "
-#: aplay/aplay.c:2222
+#: aplay/aplay.c:2285
#, c-format
msgid "Mono"
msgstr "mono"
-#: aplay/aplay.c:2224
+#: aplay/aplay.c:2287
#, c-format
msgid "Stereo"
msgstr "stereo"
-#: aplay/aplay.c:2226
+#: aplay/aplay.c:2289
#, c-format
msgid "Channels %i"
msgstr "%i Kanäle"
-#: aplay/aplay.c:2585 aplay/aplay.c:2638
+#: aplay/aplay.c:2798 aplay/aplay.c:2851
#, c-format
msgid "You need to specify %d files"
msgstr "Es werden %d Dateien benötigt."
@@ -999,47 +1009,47 @@
msgid "kernel"
msgstr "Kernel"
-#: seq/aconnect/aconnect.c:326
+#: seq/aconnect/aconnect.c:307
#, c-format
msgid "can't open sequencer\n"
msgstr "Fehler beim Öffnen des Sequenzers\n"
-#: seq/aconnect/aconnect.c:354
+#: seq/aconnect/aconnect.c:335
#, c-format
msgid "can't get client id\n"
msgstr "Fehler beim Lesen der Client-ID\n"
-#: seq/aconnect/aconnect.c:361
+#: seq/aconnect/aconnect.c:342
#, c-format
msgid "can't set client info\n"
msgstr "Fehler beim Setzen des Client-Namens\n"
-#: seq/aconnect/aconnect.c:368
+#: seq/aconnect/aconnect.c:349
#, c-format
msgid "invalid sender address %s\n"
msgstr "ungültige Sender-Adresse %s\n"
-#: seq/aconnect/aconnect.c:373 seq/aseqnet/aseqnet.c:290
+#: seq/aconnect/aconnect.c:354 seq/aseqnet/aseqnet.c:290
#, c-format
msgid "invalid destination address %s\n"
msgstr "ungültige Ziel-Adresse %s\n"
-#: seq/aconnect/aconnect.c:387
+#: seq/aconnect/aconnect.c:368
#, c-format
msgid "No subscription is found\n"
msgstr "keine Verbindung gefunden\n"
-#: seq/aconnect/aconnect.c:392
+#: seq/aconnect/aconnect.c:373
#, c-format
msgid "Disconnection failed (%s)\n"
msgstr "Verbindungs-Trennung fehlgeschlagen (%s)\n"
-#: seq/aconnect/aconnect.c:398
+#: seq/aconnect/aconnect.c:379
#, c-format
msgid "Connection is already subscribed\n"
msgstr "Verbindung ist bereits vorhanden\n"
-#: seq/aconnect/aconnect.c:403
+#: seq/aconnect/aconnect.c:384
#, c-format
msgid "Connection failed (%s)\n"
msgstr "Verbindung fehlgeschlagen (%s)\n"
@@ -1369,7 +1379,7 @@
"Fehler beim Aufwachen aus dem Ruhezustand, Re-Initialisierung "
"fehlgeschlagen: %s\n"
-#: speaker-test/speaker-test.c:539 speaker-test/speaker-test.c:953
+#: speaker-test/speaker-test.c:539 speaker-test/speaker-test.c:954
#, c-format
msgid "No enough memory\n"
msgstr "Nicht genug Speicher\n"
@@ -1424,7 +1434,7 @@
msgid "xrun_recovery failed: %d,%s\n"
msgstr "xrun_recovery fehlgeschlagen: %d, %s\n"
-#: speaker-test/speaker-test.c:733
+#: speaker-test/speaker-test.c:734
#, c-format
msgid ""
"Usage: speaker-test [OPTION]... \n"
@@ -1461,72 +1471,72 @@
"-W,--wavdir benutze Verzeichnis mit darin enthaltenen WAV-Dateien\n"
"\n"
-#: speaker-test/speaker-test.c:851
+#: speaker-test/speaker-test.c:852
#, c-format
msgid "Invalid number of periods %d\n"
msgstr "Ungültige Periodenanzahl %d\n"
-#: speaker-test/speaker-test.c:865 speaker-test/speaker-test.c:869
+#: speaker-test/speaker-test.c:866 speaker-test/speaker-test.c:870
#, c-format
msgid "Invalid test type %s\n"
msgstr "Ungültiger Test-Typ %s\n"
-#: speaker-test/speaker-test.c:881
+#: speaker-test/speaker-test.c:882
#, c-format
msgid "Invalid parameter for -s option.\n"
msgstr "Ungültiger Wert für Option -s\n"
-#: speaker-test/speaker-test.c:895
+#: speaker-test/speaker-test.c:896
#, c-format
msgid "Unknown option '%c'\n"
msgstr "Unbekannte Options '%c'\n"
-#: speaker-test/speaker-test.c:909
+#: speaker-test/speaker-test.c:910
#, c-format
msgid "Playback device is %s\n"
msgstr "Wiedergabe-Gerät ist %s\n"
-#: speaker-test/speaker-test.c:910
+#: speaker-test/speaker-test.c:911
#, c-format
msgid "Stream parameters are %iHz, %s, %i channels\n"
msgstr "Stream-Parameter sind %i Hz, %s, %i Kanäle\n"
-#: speaker-test/speaker-test.c:913
+#: speaker-test/speaker-test.c:914
#, c-format
msgid "Using 16 octaves of pink noise\n"
msgstr "Verwende 16 Oktaven rosa Rauschen\n"
-#: speaker-test/speaker-test.c:916
+#: speaker-test/speaker-test.c:917
#, c-format
msgid "Sine wave rate is %.4fHz\n"
msgstr "Sinuswelle mit Frequenz %.4f Hz\n"
-#: speaker-test/speaker-test.c:919
+#: speaker-test/speaker-test.c:920
#, c-format
msgid "WAV file(s)\n"
msgstr "WAV-Datei(en)\n"
-#: speaker-test/speaker-test.c:925
+#: speaker-test/speaker-test.c:926
#, c-format
msgid "Playback open error: %d,%s\n"
msgstr "Fehler beim Öffnen des Gerätes: %d, %s\n"
-#: speaker-test/speaker-test.c:930
+#: speaker-test/speaker-test.c:931
#, c-format
msgid "Setting of hwparams failed: %s\n"
msgstr "Fehler beim Setzen der Hardware-Parameter: %s\n"
-#: speaker-test/speaker-test.c:935
+#: speaker-test/speaker-test.c:936
#, c-format
msgid "Setting of swparams failed: %s\n"
msgstr "Fehler beim Setzen der Software-Parameter: %s\n"
-#: speaker-test/speaker-test.c:984 speaker-test/speaker-test.c:1006
+#: speaker-test/speaker-test.c:985 speaker-test/speaker-test.c:1007
#, c-format
msgid "Transfer failed: %s\n"
msgstr "Schreibfehler: %s\n"
-#: speaker-test/speaker-test.c:994
+#: speaker-test/speaker-test.c:995
#, c-format
msgid "Time per period = %lf\n"
msgstr "Zeit pro Periode = %lf\n"
!!! po/ja.gmo and po/ja.gmo differ
--- po/ja.po
+++ po/ja.po
@@ -8,7 +8,7 @@
msgstr ""
"Project-Id-Version: alsa-utils 1.0.9a\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-12-16 16:28+0100\n"
+"POT-Creation-Date: 2010-04-16 13:19+0200\n"
"PO-Revision-Date: 2009-05-27 15:08+0200\n"
"Last-Translator: Takashi Iwai <tiwai at suse.de>\n"
"Language-Team: Japanese\n"
@@ -180,47 +180,47 @@
msgstr "このカードには制御可能なミキサーがありません"
#. TRANSLATORS: playback on; one character
-#: alsamixer/mixer_display.c:524 alsamixer/mixer_display.c:529
+#: alsamixer/mixer_display.c:537 alsamixer/mixer_display.c:542
msgid "O"
msgstr ""
#. TRANSLATORS: playback muted; one character
-#: alsamixer/mixer_display.c:526 alsamixer/mixer_display.c:530
+#: alsamixer/mixer_display.c:539 alsamixer/mixer_display.c:543
msgid "M"
msgstr ""
#. TRANSLATORS: "left"; no more than two characters
-#: alsamixer/mixer_display.c:544
+#: alsamixer/mixer_display.c:557
msgid "L"
msgstr ""
#. TRANSLATORS: "right"; no more than two characters
-#: alsamixer/mixer_display.c:548
+#: alsamixer/mixer_display.c:561
msgid "R"
msgstr ""
#. TRANSLATORS: no more than eight characters
-#: alsamixer/mixer_display.c:550
+#: alsamixer/mixer_display.c:563
msgid "CAPTURE"
msgstr "録音"
-#: alsamixer/mixer_display.c:600
+#: alsamixer/mixer_display.c:613
msgid "Front"
msgstr "フロント"
-#: alsamixer/mixer_display.c:603
+#: alsamixer/mixer_display.c:616
msgid "Rear"
msgstr "リア"
-#: alsamixer/mixer_display.c:606 speaker-test/speaker-test.c:107
+#: alsamixer/mixer_display.c:619 speaker-test/speaker-test.c:107
msgid "Center"
msgstr "センター"
-#: alsamixer/mixer_display.c:609
+#: alsamixer/mixer_display.c:622
msgid "Woofer"
msgstr "低音"
-#: alsamixer/mixer_display.c:612
+#: alsamixer/mixer_display.c:625
msgid "Side"
msgstr "サイド"
@@ -366,24 +366,24 @@
msgid "Cannot open file \"%s\"."
msgstr "\"%s\"をオープンできません"
-#: aplay/aplay.c:139
+#: aplay/aplay.c:147
msgid "raw data"
msgstr "raw データ"
-#: aplay/aplay.c:140
+#: aplay/aplay.c:148
msgid "VOC"
msgstr "VOC"
-#: aplay/aplay.c:142
+#: aplay/aplay.c:150
msgid "WAVE"
msgstr "WAVE"
-#: aplay/aplay.c:143
+#: aplay/aplay.c:151
msgid "Sparc Audio"
msgstr "Sparc オーディオ"
-#: aplay/aplay.c:164
-#, c-format
+#: aplay/aplay.c:172
+#, fuzzy, c-format
msgid ""
"Usage: %s [OPTION]... [FILE]...\n"
"\n"
@@ -421,6 +421,11 @@
" expression for validation is: coef * (buffer_size / "
"2)\n"
" --test-nowait do not wait for ring buffer - eats whole CPU\n"
+" --max-file-time=# start another output file when the old file has "
+"recorded\n"
+" for this many seconds\n"
+" --process-id-file write the process ID here\n"
+" --use-strftime apply the strftime facility to the output file name\n"
msgstr ""
"使用法: %s [オプション]... [ファイル]...\n"
"\n"
@@ -457,12 +462,12 @@
" テスト範囲: coef * (buffer_size / 2)\n"
" --test-nowait リングバッファのウエイトを禁止 - 注意:高CPU負荷\n"
-#: aplay/aplay.c:199 speaker-test/speaker-test.c:749
+#: aplay/aplay.c:211 speaker-test/speaker-test.c:750
#, c-format
msgid "Recognized sample formats are:"
msgstr "認識されるサンプルフォーマット:"
-#: aplay/aplay.c:205
+#: aplay/aplay.c:217
#, c-format
msgid ""
"\n"
@@ -471,154 +476,159 @@
"\n"
"これらのいくつかは指定のハードウェアで使用不可能な場合があります\n"
-#: aplay/aplay.c:206
+#: aplay/aplay.c:218
#, c-format
msgid "The availabled format shortcuts are:\n"
msgstr "可能なフォーマットの省略形:\n"
-#: aplay/aplay.c:207
+#: aplay/aplay.c:219
#, c-format
msgid "-f cd (16 bit little endian, 44100, stereo)\n"
msgstr "-f cd (16 ビット、リトルエンディアン、44100、ステレオ)\n"
-#: aplay/aplay.c:208
+#: aplay/aplay.c:220
#, c-format
msgid "-f cdr (16 bit big endian, 44100, stereo)\n"
msgstr "-f cdr (16 ビット、ビッグエンディアン、44100、ステレオ)\n"
-#: aplay/aplay.c:209
+#: aplay/aplay.c:221
#, c-format
msgid "-f dat (16 bit little endian, 48000, stereo)\n"
msgstr "-f dat (16 ビット、リトルエンディアン、48000、ステレオ)\n"
-#: aplay/aplay.c:223
+#: aplay/aplay.c:235
msgid "no soundcards found..."
msgstr "サウンドカードが見つかりません..."
-#: aplay/aplay.c:226
+#: aplay/aplay.c:238
#, c-format
msgid "**** List of %s Hardware Devices ****\n"
msgstr "**** ハードウェアデバイス %s のリスト ****\n"
-#: aplay/aplay.c:255
+#: aplay/aplay.c:267
#, c-format
msgid "card %i: %s [%s], device %i: %s [%s]\n"
msgstr "カード %i: %s [%s], デバイス %i: %s [%s]\n"
-#: aplay/aplay.c:261
+#: aplay/aplay.c:273
#, c-format
msgid " Subdevices: %i/%i\n"
msgstr " サブデバイス: %i/%i\n"
-#: aplay/aplay.c:268
+#: aplay/aplay.c:280
#, c-format
msgid " Subdevice #%i: %s\n"
msgstr " サブデバイス #%i: %s\n"
-#: aplay/aplay.c:332
+#: aplay/aplay.c:356
#, c-format
msgid "Aborted by signal %s...\n"
msgstr "シグナル %s で中断...\n"
-#: aplay/aplay.c:430
+#: aplay/aplay.c:467
msgid "command should be named either arecord or aplay"
msgstr "arecord または aplay コマンドのみ可能"
-#: aplay/aplay.c:469
+#: aplay/aplay.c:506
#, c-format
msgid "unrecognized file format %s"
msgstr "不正なファイルフォーマット %s"
-#: aplay/aplay.c:476
+#: aplay/aplay.c:513
#, c-format
msgid "value %i for channels is invalid"
msgstr "不正なチャネル数 %i"
-#: aplay/aplay.c:495
+#: aplay/aplay.c:532
#, c-format
msgid "wrong extended format '%s'"
msgstr "不正な拡張フォーマット '%s'"
-#: aplay/aplay.c:506
+#: aplay/aplay.c:543
#, c-format
msgid "bad speed value %i"
msgstr "不正なレート値 %i"
-#: aplay/aplay.c:592
+#: aplay/aplay.c:638
#, c-format
msgid "Try `%s --help' for more information.\n"
msgstr "より詳しい情報は「%s --help」を実行してください\n"
-#: aplay/aplay.c:608
+#: aplay/aplay.c:654
#, c-format
msgid "audio open error: %s"
msgstr ""
-#: aplay/aplay.c:613
+#: aplay/aplay.c:659
#, c-format
msgid "info error: %s"
msgstr ""
-#: aplay/aplay.c:620
+#: aplay/aplay.c:666
#, c-format
msgid "nonblock setting error: %s"
msgstr ""
-#: aplay/aplay.c:630 aplay/aplay.c:737 aplay/aplay.c:1104
+#: aplay/aplay.c:676 aplay/aplay.c:800 aplay/aplay.c:1167
msgid "not enough memory"
msgstr "メモリが足りません"
-#: aplay/aplay.c:727
+#: aplay/aplay.c:700
+#, fuzzy, c-format
+msgid "Cannot create process ID file %s: %s"
+msgstr "WAVファイルがオープンできません: %s\n"
+
+#: aplay/aplay.c:790
#, c-format
msgid "read error (called from line %i)"
msgstr "リードエラー (%i 行)"
-#: aplay/aplay.c:785
+#: aplay/aplay.c:848
#, c-format
msgid "unknown length of 'fmt ' chunk (read %u, should be %u at least)"
msgstr ""
-#: aplay/aplay.c:795
+#: aplay/aplay.c:858
#, c-format
msgid ""
"unknown length of extensible 'fmt ' chunk (read %u, should be %u at least)"
msgstr ""
-#: aplay/aplay.c:800
+#: aplay/aplay.c:863
msgid "wrong format tag in extensible 'fmt ' chunk"
msgstr ""
-#: aplay/aplay.c:807
+#: aplay/aplay.c:870
#, c-format
msgid "can't play WAVE-file format 0x%04x which is not PCM or FLOAT encoded"
msgstr ""
-#: aplay/aplay.c:811
+#: aplay/aplay.c:874
#, c-format
msgid "can't play WAVE-files with %d tracks"
msgstr "%d トラックを含む WAVE ファイルは再生できません"
-#: aplay/aplay.c:819 aplay/aplay.c:919
+#: aplay/aplay.c:882 aplay/aplay.c:982
#, c-format
msgid "Warning: format is changed to U8\n"
msgstr "警告: フォーマットは U8 に変更されます\n"
-#: aplay/aplay.c:825
+#: aplay/aplay.c:888
#, c-format
msgid "Warning: format is changed to S16_LE\n"
msgstr "警告: フォーマットは S16_LE に変更されます\n"
-#: aplay/aplay.c:833
+#: aplay/aplay.c:896
#, c-format
msgid "Warning: format is changed to S24_3LE\n"
msgstr "警告: フォーマットは S24_3LE に変更されます\n"
-#: aplay/aplay.c:839
+#: aplay/aplay.c:902
#, c-format
msgid "Warning: format is changed to S24_LE\n"
msgstr "警告: フォーマットは S24_LE に変更されます\n"
-#: aplay/aplay.c:843
+#: aplay/aplay.c:906
#, c-format
msgid ""
" can't play WAVE-files with sample %d bits in %d bytes wide (%d channels)"
@@ -626,261 +636,261 @@
"%2$d バイト長 %1$d サンプルビット (%3$d チャネル) の WAVE ファイルは再生でき"
"ません"
-#: aplay/aplay.c:855
+#: aplay/aplay.c:918
#, c-format
msgid " can't play WAVE-files with sample %d bits wide"
msgstr "%d ビット長のサンプルの WAVE ファイルは再生できません"
-#: aplay/aplay.c:913
+#: aplay/aplay.c:976
#, c-format
msgid "Warning: format is changed to MU_LAW\n"
msgstr "警告: フォーマットは MU_LAW に変更されます\n"
-#: aplay/aplay.c:925
+#: aplay/aplay.c:988
#, c-format
msgid "Warning: format is changed to S16_BE\n"
msgstr "警告: フォーマットは S16_BE に変更されます\n"
-#: aplay/aplay.c:938 aplay/aplay.c:1780 aplay/aplay.c:1787 aplay/aplay.c:2309
-#: aplay/aplay.c:2321
+#: aplay/aplay.c:1001 aplay/aplay.c:1843 aplay/aplay.c:1850 aplay/aplay.c:2372
+#: aplay/aplay.c:2384
msgid "read error"
msgstr "リードエラー"
-#: aplay/aplay.c:968
+#: aplay/aplay.c:1031
msgid "Broken configuration for this PCM: no configurations available"
msgstr "指定の PCM を使用できません: 設定がありません"
-#: aplay/aplay.c:985
+#: aplay/aplay.c:1048
msgid "Access type not available"
msgstr "アクセスタイプが使用不可能"
-#: aplay/aplay.c:990
+#: aplay/aplay.c:1053
msgid "Sample format non available"
msgstr "サンプルフォーマットが使用不可能"
-#: aplay/aplay.c:996
+#: aplay/aplay.c:1059
msgid "Channels count non available"
msgstr "チャネル数が使用不可能"
-#: aplay/aplay.c:1011
+#: aplay/aplay.c:1074
#, c-format
msgid "Warning: rate is not accurate (requested = %iHz, got = %iHz)\n"
msgstr "警告: レートが不正確です (要求値 = %iHz, 使用値 = %iHz)\n"
-#: aplay/aplay.c:1017
+#: aplay/aplay.c:1080
#, c-format
msgid " please, try the plug plugin %s\n"
msgstr " plug プラグイン%s を使用してください\n"
-#: aplay/aplay.c:1053
+#: aplay/aplay.c:1116
msgid "Unable to install hw params:"
msgstr "hw params のインストールに失敗しました:"
-#: aplay/aplay.c:1060
+#: aplay/aplay.c:1123
#, c-format
msgid "Can't use period equal to buffer size (%lu == %lu)"
msgstr "period と buffer サイズには同じ値を使用できません (%lu == %lu)"
-#: aplay/aplay.c:1091
+#: aplay/aplay.c:1154
msgid "unable to install sw params:"
msgstr "sw params のインストールに失敗しました:"
-#: aplay/aplay.c:1166
+#: aplay/aplay.c:1229
#, c-format
msgid "status error: %s"
msgstr "ステータスエラー: %s"
-#: aplay/aplay.c:1176 aplay/aplay.c:1187
+#: aplay/aplay.c:1239 aplay/aplay.c:1250
#, c-format
msgid "%s!!! (at least %.3f ms long)\n"
msgstr "%s!!! (少なくとも %.3f ms)\n"
-#: aplay/aplay.c:1177 aplay/aplay.c:1180 aplay/aplay.c:1188
+#: aplay/aplay.c:1240 aplay/aplay.c:1243 aplay/aplay.c:1251
msgid "underrun"
msgstr "アンダーラン"
-#: aplay/aplay.c:1177 aplay/aplay.c:1188
+#: aplay/aplay.c:1240 aplay/aplay.c:1251
msgid "overrun"
msgstr "オーバーラン"
-#: aplay/aplay.c:1192
+#: aplay/aplay.c:1255
#, c-format
msgid "Status:\n"
msgstr "ステータス:\n"
-#: aplay/aplay.c:1196
+#: aplay/aplay.c:1259
#, c-format
msgid "xrun: prepare error: %s"
msgstr ""
-#: aplay/aplay.c:1202
+#: aplay/aplay.c:1265
#, c-format
msgid "Status(DRAINING):\n"
msgstr "ステータス(DRAINING):\n"
-#: aplay/aplay.c:1206
+#: aplay/aplay.c:1269
#, c-format
msgid "capture stream format change? attempting recover...\n"
msgstr "録音ストリームのフォーマットが変更? 修復を試みます...\n"
-#: aplay/aplay.c:1208
+#: aplay/aplay.c:1271
#, c-format
msgid "xrun(DRAINING): prepare error: %s"
msgstr ""
-#: aplay/aplay.c:1215
+#: aplay/aplay.c:1278
#, c-format
msgid "Status(R/W):\n"
msgstr "ステータス(R/W):\n"
-#: aplay/aplay.c:1218
+#: aplay/aplay.c:1281
#, c-format
msgid "read/write error, state = %s"
msgstr "読み書きエラー, ステータス = %s"
-#: aplay/aplay.c:1228
+#: aplay/aplay.c:1291
#, c-format
msgid "Suspended. Trying resume. "
msgstr "サスペンド中です。レジュームします。"
-#: aplay/aplay.c:1233
+#: aplay/aplay.c:1296
#, c-format
msgid "Failed. Restarting stream. "
msgstr "失敗しました。ストリームを再スタートします。"
-#: aplay/aplay.c:1235
+#: aplay/aplay.c:1298
#, c-format
msgid "suspend: prepare error: %s"
msgstr "サスペンド: prepare エラー: %s"
-#: aplay/aplay.c:1240
+#: aplay/aplay.c:1303
#, c-format
msgid "Done.\n"
msgstr "終了\n"
-#: aplay/aplay.c:1262
+#: aplay/aplay.c:1325
#, c-format
msgid " !clip "
msgstr ""
-#: aplay/aplay.c:1409
+#: aplay/aplay.c:1472
#, c-format
msgid "Unsupported bit size %d.\n"
msgstr ""
-#: aplay/aplay.c:1443
+#: aplay/aplay.c:1506
#, c-format
msgid "Max peak (%li samples): 0x%08x "
msgstr "最大ピーク (%li サンプル): 0x%08x "
-#: aplay/aplay.c:1477
+#: aplay/aplay.c:1540
#, c-format
msgid ""
"Suspicious buffer position (%li total): avail = %li, delay = %li, buffer = %"
"li\n"
msgstr ""
-#: aplay/aplay.c:1540
+#: aplay/aplay.c:1603
#, c-format
msgid "write error: %s"
msgstr "書込エラー: %s"
-#: aplay/aplay.c:1586
+#: aplay/aplay.c:1649
#, c-format
msgid "writev error: %s"
msgstr "書込(writev)エラー: %s"
-#: aplay/aplay.c:1629
+#: aplay/aplay.c:1692
#, c-format
msgid "read error: %s"
msgstr "読込エラー: %s"
-#: aplay/aplay.c:1672
+#: aplay/aplay.c:1735
#, c-format
msgid "readv error: %s"
msgstr "読込(readv)エラー: %s"
-#: aplay/aplay.c:1720
+#: aplay/aplay.c:1783
msgid "can't allocate buffer for silence"
msgstr "サイレンス用のバッファの取得に失敗しました"
-#: aplay/aplay.c:1729 aplay/aplay.c:1955 aplay/aplay.c:1960 aplay/aplay.c:2007
-#: aplay/aplay.c:2016 aplay/aplay.c:2023 aplay/aplay.c:2033 aplay/aplay.c:2039
-#: aplay/aplay.c:2111 aplay/aplay.c:2141 aplay/aplay.c:2155
+#: aplay/aplay.c:1792 aplay/aplay.c:2018 aplay/aplay.c:2023 aplay/aplay.c:2070
+#: aplay/aplay.c:2079 aplay/aplay.c:2086 aplay/aplay.c:2096 aplay/aplay.c:2102
+#: aplay/aplay.c:2174 aplay/aplay.c:2204 aplay/aplay.c:2218
msgid "write error"
msgstr "書込エラー"
-#: aplay/aplay.c:1742
+#: aplay/aplay.c:1805
#, c-format
msgid "voc_pcm_flush - silence error"
msgstr ""
-#: aplay/aplay.c:1745
+#: aplay/aplay.c:1808
msgid "voc_pcm_flush error"
msgstr ""
-#: aplay/aplay.c:1771
+#: aplay/aplay.c:1834
msgid "malloc error"
msgstr "malloc エラー"
-#: aplay/aplay.c:1775
+#: aplay/aplay.c:1838
#, c-format
msgid "Playing Creative Labs Channel file '%s'...\n"
msgstr "Creative Labs Channel ファイル '%s' を演奏中...\n"
-#: aplay/aplay.c:1843 aplay/aplay.c:1935
+#: aplay/aplay.c:1906 aplay/aplay.c:1998
msgid "can't play packed .voc files"
msgstr "packed .voc ファイルは演奏できません"
-#: aplay/aplay.c:1895
+#: aplay/aplay.c:1958
#, c-format
msgid "can't play loops; %s isn't seekable\n"
msgstr "ループ演奏できません。%s はシーク不可能です\n"
-#: aplay/aplay.c:1944
+#: aplay/aplay.c:2007
#, c-format
msgid "unknown blocktype %d. terminate."
msgstr "未知のブロックタイプ %d: 終了します。"
-#: aplay/aplay.c:2075
+#: aplay/aplay.c:2138
#, c-format
msgid "Wave doesn't support %s format..."
msgstr "WAVE は %s フォーマットをサポートしません..."
-#: aplay/aplay.c:2135
+#: aplay/aplay.c:2198
#, c-format
msgid "Sparc Audio doesn't support %s format..."
msgstr "Sparc オーディオは %s フォーマットをサポートしません..."
-#: aplay/aplay.c:2216
+#: aplay/aplay.c:2279
msgid "Playing"
msgstr "再生中"
-#: aplay/aplay.c:2216
+#: aplay/aplay.c:2279
msgid "Recording"
msgstr "録音中"
-#: aplay/aplay.c:2220
+#: aplay/aplay.c:2283
#, c-format
msgid "Rate %d Hz, "
msgstr "レート %d Hz, "
-#: aplay/aplay.c:2222
+#: aplay/aplay.c:2285
#, c-format
msgid "Mono"
msgstr "モノラル"
-#: aplay/aplay.c:2224
+#: aplay/aplay.c:2287
#, c-format
msgid "Stereo"
msgstr "ステレオ"
-#: aplay/aplay.c:2226
+#: aplay/aplay.c:2289
#, c-format
msgid "Channels %i"
msgstr "チャネル数 %i"
-#: aplay/aplay.c:2585 aplay/aplay.c:2638
+#: aplay/aplay.c:2798 aplay/aplay.c:2851
#, c-format
msgid "You need to specify %d files"
msgstr "%d 個のファイルを指定してください"
@@ -991,47 +1001,47 @@
msgid "kernel"
msgstr "カーネル"
-#: seq/aconnect/aconnect.c:326
+#: seq/aconnect/aconnect.c:307
#, c-format
msgid "can't open sequencer\n"
msgstr "sequencer をオープンできません\n"
-#: seq/aconnect/aconnect.c:354
+#: seq/aconnect/aconnect.c:335
#, c-format
msgid "can't get client id\n"
msgstr "クライアント ID を取得できません\n"
-#: seq/aconnect/aconnect.c:361
+#: seq/aconnect/aconnect.c:342
#, c-format
msgid "can't set client info\n"
msgstr "クライアント情報を取得できません\n"
-#: seq/aconnect/aconnect.c:368
+#: seq/aconnect/aconnect.c:349
#, c-format
msgid "invalid sender address %s\n"
msgstr "送信アドレスが不正です: %s\n"
-#: seq/aconnect/aconnect.c:373 seq/aseqnet/aseqnet.c:290
+#: seq/aconnect/aconnect.c:354 seq/aseqnet/aseqnet.c:290
#, c-format
msgid "invalid destination address %s\n"
msgstr "受信アドレスが不正です: %s\n"
-#: seq/aconnect/aconnect.c:387
+#: seq/aconnect/aconnect.c:368
#, c-format
msgid "No subscription is found\n"
msgstr "接続が見つかりません\n"
-#: seq/aconnect/aconnect.c:392
+#: seq/aconnect/aconnect.c:373
#, c-format
msgid "Disconnection failed (%s)\n"
msgstr "切り離しに失敗 (%s)\n"
-#: seq/aconnect/aconnect.c:398
+#: seq/aconnect/aconnect.c:379
#, c-format
msgid "Connection is already subscribed\n"
msgstr "既に接続されています\n"
-#: seq/aconnect/aconnect.c:403
+#: seq/aconnect/aconnect.c:384
#, c-format
msgid "Connection failed (%s)\n"
msgstr "接続に失敗 (%s)\n"
@@ -1356,7 +1366,7 @@
msgid "Can't recovery from suspend, prepare failed: %s\n"
msgstr "サスペンドから復帰失敗: %s\n"
-#: speaker-test/speaker-test.c:539 speaker-test/speaker-test.c:953
+#: speaker-test/speaker-test.c:539 speaker-test/speaker-test.c:954
#, c-format
msgid "No enough memory\n"
msgstr "メモリが足りません\n"
@@ -1411,7 +1421,7 @@
msgid "xrun_recovery failed: %d,%s\n"
msgstr "xrun_recovery 失敗: %d,%s\n"
-#: speaker-test/speaker-test.c:733
+#: speaker-test/speaker-test.c:734
#, c-format
msgid ""
"Usage: speaker-test [OPTION]... \n"
@@ -1449,72 +1459,72 @@
"-W,--wavdir WAVファイルのあるディレクトリを指定\n"
"\n"
-#: speaker-test/speaker-test.c:851
+#: speaker-test/speaker-test.c:852
#, c-format
msgid "Invalid number of periods %d\n"
msgstr "不正なピリオド数 %d\n"
-#: speaker-test/speaker-test.c:865 speaker-test/speaker-test.c:869
+#: speaker-test/speaker-test.c:866 speaker-test/speaker-test.c:870
#, c-format
msgid "Invalid test type %s\n"
msgstr "不正なテストタイプ %s\n"
-#: speaker-test/speaker-test.c:881
+#: speaker-test/speaker-test.c:882
#, c-format
msgid "Invalid parameter for -s option.\n"
msgstr "-s オプションの値が不正です\n"
-#: speaker-test/speaker-test.c:895
+#: speaker-test/speaker-test.c:896
#, c-format
msgid "Unknown option '%c'\n"
msgstr "未知のオプション '%c'\n"
-#: speaker-test/speaker-test.c:909
+#: speaker-test/speaker-test.c:910
#, c-format
msgid "Playback device is %s\n"
msgstr "再生デバイス: %s\n"
-#: speaker-test/speaker-test.c:910
+#: speaker-test/speaker-test.c:911
#, c-format
msgid "Stream parameters are %iHz, %s, %i channels\n"
msgstr "ストリームパラメータ: %iHz, %s, %i チャネル\n"
-#: speaker-test/speaker-test.c:913
+#: speaker-test/speaker-test.c:914
#, c-format
msgid "Using 16 octaves of pink noise\n"
msgstr "16 オクターブのピンクノイズを使用\n"
-#: speaker-test/speaker-test.c:916
+#: speaker-test/speaker-test.c:917
#, c-format
msgid "Sine wave rate is %.4fHz\n"
msgstr "正弦波レート: %.4fHz\n"
-#: speaker-test/speaker-test.c:919
+#: speaker-test/speaker-test.c:920
#, c-format
msgid "WAV file(s)\n"
msgstr "WAV ファイル\n"
-#: speaker-test/speaker-test.c:925
+#: speaker-test/speaker-test.c:926
#, c-format
msgid "Playback open error: %d,%s\n"
msgstr "再生オープンエラー: %d,%s\n"
-#: speaker-test/speaker-test.c:930
+#: speaker-test/speaker-test.c:931
#, c-format
msgid "Setting of hwparams failed: %s\n"
msgstr "hwparams の設定に失敗: %s\n"
-#: speaker-test/speaker-test.c:935
+#: speaker-test/speaker-test.c:936
#, c-format
msgid "Setting of swparams failed: %s\n"
msgstr "swparams の設定に失敗: %s\n"
-#: speaker-test/speaker-test.c:984 speaker-test/speaker-test.c:1006
+#: speaker-test/speaker-test.c:985 speaker-test/speaker-test.c:1007
#, c-format
msgid "Transfer failed: %s\n"
msgstr "転送に失敗しました: %s\n"
-#: speaker-test/speaker-test.c:994
+#: speaker-test/speaker-test.c:995
#, c-format
msgid "Time per period = %lf\n"
msgstr "ピリオド時間 = %lf\n"
--- seq/aconnect/aconnect.c
+++ seq/aconnect/aconnect.c
@@ -192,52 +192,33 @@
snd_seq_port_info_t *pinfo, int count)
{
snd_seq_query_subscribe_t *query;
+ snd_seq_port_info_t *port;
+ snd_seq_port_subscribe_t *subs;
snd_seq_query_subscribe_alloca(&query);
snd_seq_query_subscribe_set_root(query, snd_seq_port_info_get_addr(pinfo));
-
snd_seq_query_subscribe_set_type(query, SND_SEQ_QUERY_SUBS_READ);
snd_seq_query_subscribe_set_index(query, 0);
- for (; snd_seq_query_port_subscribers(seq, query) >= 0;
- snd_seq_query_subscribe_set_index(query, snd_seq_query_subscribe_get_index(query) + 1)) {
- snd_seq_port_info_t *port;
- snd_seq_port_subscribe_t *subs;
+
+ snd_seq_port_info_alloca(&port);
+ snd_seq_port_subscribe_alloca(&subs);
+
+ while (snd_seq_query_port_subscribers(seq, query) >= 0) {
const snd_seq_addr_t *sender = snd_seq_query_subscribe_get_root(query);
const snd_seq_addr_t *dest = snd_seq_query_subscribe_get_addr(query);
- snd_seq_port_info_alloca(&port);
- if (snd_seq_get_any_port_info(seq, dest->client, dest->port, port) < 0)
- continue;
- if (!(snd_seq_port_info_get_capability(port) & SND_SEQ_PORT_CAP_SUBS_WRITE))
- continue;
- if (snd_seq_port_info_get_capability(port) & SND_SEQ_PORT_CAP_NO_EXPORT)
- continue;
- snd_seq_port_subscribe_alloca(&subs);
- snd_seq_port_subscribe_set_queue(subs, snd_seq_query_subscribe_get_queue(query));
- snd_seq_port_subscribe_set_sender(subs, sender);
- snd_seq_port_subscribe_set_dest(subs, dest);
- snd_seq_unsubscribe_port(seq, subs);
- }
- snd_seq_query_subscribe_set_type(query, SND_SEQ_QUERY_SUBS_WRITE);
- snd_seq_query_subscribe_set_index(query, 0);
- for (; snd_seq_query_port_subscribers(seq, query) >= 0;
- snd_seq_query_subscribe_set_index(query, snd_seq_query_subscribe_get_index(query) + 1)) {
- snd_seq_port_info_t *port;
- snd_seq_port_subscribe_t *subs;
- const snd_seq_addr_t *dest = snd_seq_query_subscribe_get_root(query);
- const snd_seq_addr_t *sender = snd_seq_query_subscribe_get_addr(query);
- snd_seq_port_info_alloca(&port);
- if (snd_seq_get_any_port_info(seq, sender->client, sender->port, port) < 0)
- continue;
- if (!(snd_seq_port_info_get_capability(port) & SND_SEQ_PORT_CAP_SUBS_READ))
- continue;
- if (snd_seq_port_info_get_capability(port) & SND_SEQ_PORT_CAP_NO_EXPORT)
+ if (snd_seq_get_any_port_info(seq, dest->client, dest->port, port) < 0 ||
+ !(snd_seq_port_info_get_capability(port) & SND_SEQ_PORT_CAP_SUBS_WRITE) ||
+ (snd_seq_port_info_get_capability(port) & SND_SEQ_PORT_CAP_NO_EXPORT)) {
+ snd_seq_query_subscribe_set_index(query, snd_seq_query_subscribe_get_index(query) + 1);
continue;
- snd_seq_port_subscribe_alloca(&subs);
+ }
snd_seq_port_subscribe_set_queue(subs, snd_seq_query_subscribe_get_queue(query));
snd_seq_port_subscribe_set_sender(subs, sender);
snd_seq_port_subscribe_set_dest(subs, dest);
- snd_seq_unsubscribe_port(seq, subs);
+ if (snd_seq_unsubscribe_port(seq, subs) < 0) {
+ snd_seq_query_subscribe_set_index(query, snd_seq_query_subscribe_get_index(query) + 1);
+ }
}
}
--- speaker-test/speaker-test.c
+++ speaker-test/speaker-test.c
@@ -689,6 +689,7 @@
double phase = 0;
int err, n;
+ fflush(stdout);
if (test_type == TEST_WAV) {
int bufsize = snd_pcm_frames_to_bytes(handle, period_size);
n = 0;
++++++ alsa-utils.yaml (new)
--- alsa-utils.yaml
+++ alsa-utils.yaml
+Name: alsa-utils
+Summary: Advanced Linux Sound Architecture (ALSA) utilities
+Version: 1.0.23
+Release: 1
+Group: Applications/Multimedia
+License: GPLv2+
+URL: http://www.alsa-project.org/
+Sources:
+ - ftp://ftp.alsa-project.org/pub/utils/alsa-utils-%{version}.tar.bz2
+ - alsaunmute
+ - alsaunmute.1
+ - alsa-info.sh
+ - alsa.rules
+ - alsactl.conf
+Description: |
+ This package contains command line utilities for the Advanced Linux Sound
+ Architecture (ALSA).
+
+Requires:
+ - alsa-lib >= %{version}
+ - dialog
+PkgBR:
+ - alsa-lib-devel >= %{version}
+ - ncurses-devel
+ - gettext-devel
+ - xmlto
+Conflicts:
+ - udev < 062
+Configure: none
+Builder: none
+LocaleName: "%{name}"
++++++ alsaunmute.1 (new)
--- alsaunmute.1
+++ alsaunmute.1
+.TH ALSAUNMUTE 1 "21 April 2010"
+.SH NAME
+alsaunmute \- a simple script to initialize ALSA sound devices
+
+.SH DESCRIPTION
+\fBalsaunmute\fP is a shell script which runs the \fBalsactl(1)\fP
+utility with \fIinit\fP argument (see the script for details).
+
+.SH OPTIONS
+None
+
+.SS
+Example:
+\fBalsaunmute\fR
+
+.SH SEE ALSO
+\fB
+alsactl(1),
+alsamixer(1),
+amixer(1)
+\fP
+
+.SH BUGS
+None known.
+
+.SH AUTHOR
+\fBalsaunmute\fP is by Jaroslav Kysela <perex at perex.cz>
+
More information about the MeeGo-commits
mailing list