Skip to content

Commit 0a3a5a7

Browse files
committed
Merge branch 'v0.20.x'
2 parents c5996c0 + f7fffc9 commit 0a3a5a7

File tree

7 files changed

+23
-10
lines changed

7 files changed

+23
-10
lines changed

NEWS

+5
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@ ver 0.21 (not yet released)
99
* output
1010
- alsa: non-blocking mode
1111

12+
ver 0.20.8 (not yet released)
13+
* output
14+
- osx: fix build failure due to missing "noexcept"
15+
* fix build failure with GCC 4.x
16+
1217
ver 0.20.7 (2017/05/15)
1318
* database
1419
- simple: fix false positive directory loop detection with NFS

python/build/libs.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,8 @@
5858
)
5959

6060
ffmpeg = FfmpegProject(
61-
'http://ffmpeg.org/releases/ffmpeg-3.3.tar.xz',
62-
'599e7f7c017221c22011c4037b88bdcd1c47cd40c1e466838bc3c465f3e9569d',
61+
'http://ffmpeg.org/releases/ffmpeg-3.3.1.tar.xz',
62+
'b702a7fc656ac23e276b8c823a2f646e4e6f6309bb2788435a708e69bea98f2f',
6363
'lib/libavcodec.a',
6464
[
6565
'--disable-shared', '--enable-static',

src/Main.cxx

+10-2
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,16 @@ static constexpr size_t KILOBYTE = 1024;
120120
static constexpr size_t MEGABYTE = 1024 * KILOBYTE;
121121

122122
static constexpr size_t DEFAULT_BUFFER_SIZE = 4 * MEGABYTE;
123-
static constexpr size_t MIN_BUFFER_SIZE = std::max(CHUNK_SIZE * 32,
124-
64 * KILOBYTE);
123+
124+
static
125+
#if GCC_OLDER_THAN(5,0)
126+
/* gcc 4.x has no "constexpr" for std::max() */
127+
const
128+
#else
129+
constexpr
130+
#endif
131+
size_t MIN_BUFFER_SIZE = std::max(CHUNK_SIZE * 32,
132+
64 * KILOBYTE);
125133

126134
static constexpr unsigned DEFAULT_BUFFER_BEFORE_PLAY = 10;
127135

src/output/plugins/HaikuOutputPlugin.cxx

+2-2
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ class HaikuOutput {
8181
size_t Play(const void *chunk, size_t size);
8282
void Cancel();
8383

84-
std::chrono::steady_clock::duration Delay();
84+
std::chrono::steady_clock::duration Delay() noexcept;
8585

8686
void FillBuffer(void* _buffer, size_t size,
8787
gcc_unused const media_raw_audio_format& _format);
@@ -311,7 +311,7 @@ HaikuOutput::Play(const void *chunk, size_t size)
311311
}
312312

313313
inline std::chrono::steady_clock::duration
314-
HaikuOutput::Delay()
314+
HaikuOutput::Delay() noexcept
315315
{
316316
unsigned delay = buffer_filled ? 0 : buffer_delay;
317317

src/output/plugins/OSXOutputPlugin.cxx

+1-1
Original file line numberDiff line numberDiff line change
@@ -670,7 +670,7 @@ osx_output_play(AudioOutput *ao, const void *chunk, size_t size)
670670
}
671671

672672
static std::chrono::steady_clock::duration
673-
osx_output_delay(AudioOutput *ao)
673+
osx_output_delay(AudioOutput *ao) noexcept
674674
{
675675
OSXOutput *od = (OSXOutput *)ao;
676676
return od->ring_buffer->write_available()

src/output/plugins/PulseOutputPlugin.cxx

+2-2
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class PulseOutput {
101101
void Open(AudioFormat &audio_format);
102102
void Close();
103103

104-
std::chrono::steady_clock::duration Delay();
104+
std::chrono::steady_clock::duration Delay() noexcept;
105105
size_t Play(const void *chunk, size_t size);
106106
void Cancel();
107107
bool Pause();
@@ -741,7 +741,7 @@ PulseOutput::StreamPause(bool pause)
741741
}
742742

743743
inline std::chrono::steady_clock::duration
744-
PulseOutput::Delay()
744+
PulseOutput::Delay() noexcept
745745
{
746746
Pulse::LockGuard lock(mainloop);
747747

src/output/plugins/sles/SlesOutputPlugin.cxx

+1-1
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ class SlesOutput {
9898
void Open(AudioFormat &audio_format);
9999
void Close();
100100

101-
std::chrono::steady_clock::duration Delay() {
101+
std::chrono::steady_clock::duration Delay() noexcept {
102102
return pause && !cancel
103103
? std::chrono::milliseconds(100)
104104
: std::chrono::steady_clock::duration::zero();

0 commit comments

Comments
 (0)