[haiku-commits] haiku: hrev51133 - in src: tests/kits/media/playsound bin/playsound bin/media_client tests/kits/media/media_client kits/media/experimental

  • From: b.vitruvio@xxxxxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Fri, 28 Apr 2017 02:18:03 +0200 (CEST)

hrev51133 adds 6 changesets to branch 'master'
old head: a2be272b553ea07f8fb6bfa867b55efe07fdf4a0
new head: 4263f2570d445b25d4bf74493b36f2ecca880570
overview: 
http://cgit.haiku-os.org/haiku/log/?qt=range&q=4263f2570d44+%5Ea2be272b553e

----------------------------------------------------------------------------

a33c8f4c2a7e: MediaClient: Some more consistency in args order

ada4f9788f0a: MediaClient: Add play and test options

a34acb8cb683: Remove play* commands from build
  
  * Add media_client as replacement

0d25cdf03182: Remove play* commands from bin

dda3a9c309b7: Move media_client to bin

4263f2570d44: media_client: Fix Jamfiles to build correctly

                                [ Dario Casalinuovo <b.vitruvio@xxxxxxxxx> ]

----------------------------------------------------------------------------

15 files changed, 220 insertions(+), 31 deletions(-)
build/jam/images/definitions/regular             |   5 +-
.../media/experimental/SimpleMediaClient.h       |   6 +-
src/bin/Jamfile                                  |   2 +-
.../kits/media => bin}/media_client/Jamfile      |   4 +-
src/bin/media_client/MediaPlay.cpp               | 114 +++++++++++++++++++
src/bin/media_client/MediaPlay.h                 |  12 ++
.../media_client/MediaTest.cpp}                  |  31 +++--
src/bin/media_client/MediaTest.h                 |  12 ++
src/bin/media_client/media_client.cpp            |  43 +++++++
.../media/experimental/SimpleMediaClient.cpp     |  18 +--
src/tests/kits/media/Jamfile                     |   2 +-
src/{bin => tests/kits/media}/playsound/Jamfile  |   2 +-
.../kits/media}/playsound/playfile.cpp           |   0
.../kits/media}/playsound/playsound.cpp          |   0
.../kits/media}/playsound/playwav.cpp            |   0

############################################################################

Commit:      a33c8f4c2a7e6758751d402c382fae1cb9be7079
URL:         http://cgit.haiku-os.org/haiku/commit/?id=a33c8f4c2a7e
Author:      Dario Casalinuovo <b.vitruvio@xxxxxxxxx>
Date:        Thu Apr 27 23:59:25 2017 UTC

MediaClient: Some more consistency in args order

----------------------------------------------------------------------------

diff --git a/headers/private/media/experimental/SimpleMediaClient.h 
b/headers/private/media/experimental/SimpleMediaClient.h
index 27d9818..cd4a539 100755
--- a/headers/private/media/experimental/SimpleMediaClient.h
+++ b/headers/private/media/experimental/SimpleMediaClient.h
@@ -48,7 +48,7 @@ public:
        virtual BSimpleMediaInput*              BeginInput();
        virtual BSimpleMediaOutput*             BeginOutput();
 
-                       void                                    
SetNotificationHook(notify_hook notifyHook = NULL,
+                       void                                    
SetHook(notify_hook notifyHook = NULL,
                                                                                
void* cookie = NULL);
 
 protected:
@@ -58,7 +58,7 @@ protected:
        virtual void                                    HandleSeek(bigtime_t 
mediaTime,
                                                                                
bigtime_t performanceTime);
 
-       virtual status_t                                
HandleFormatSuggestion(media_type type,
+       virtual status_t                                
FormatSuggestion(media_type type,
                                                                                
int32 quality, media_format* format);
 
 private:
@@ -103,8 +103,8 @@ public:
        // Used to notify or inquire the client about what to do when certain
        // events happen.
        typedef status_t                                (*notify_hook)(
-                                                                               
notification what,
                                                                                
BMediaConnection* connection,
+                                                                               
notification what,
                                                                                
...);
 
                        // Use this to set your callbacks.
diff --git a/src/kits/media/experimental/SimpleMediaClient.cpp 
b/src/kits/media/experimental/SimpleMediaClient.cpp
index e3501b0..0bc1d76 100644
--- a/src/kits/media/experimental/SimpleMediaClient.cpp
+++ b/src/kits/media/experimental/SimpleMediaClient.cpp
@@ -48,7 +48,7 @@ BSimpleMediaClient::BeginOutput()
 
 
 void
-BSimpleMediaClient::SetNotificationHook(notify_hook notifyHook, void* cookie)
+BSimpleMediaClient::SetHook(notify_hook notifyHook, void* cookie)
 {
        CALLED();
 
@@ -91,7 +91,7 @@ BSimpleMediaClient::HandleSeek(bigtime_t mediaTime, bigtime_t 
performanceTime)
 
 
 status_t
-BSimpleMediaClient::HandleFormatSuggestion(media_type type, int32 quality,
+BSimpleMediaClient::FormatSuggestion(media_type type, int32 quality,
        media_format* format)
 {
        if (fNotifyHook != NULL) {
@@ -169,7 +169,7 @@ void
 BSimpleMediaInput::Connected(const media_format& format)
 {
        if (fNotifyHook != NULL)
-               (*fNotifyHook)(BSimpleMediaConnection::B_INPUT_CONNECTED, this);
+               (*fNotifyHook)(this, BSimpleMediaConnection::B_INPUT_CONNECTED);
 
        BMediaInput::Connected(format);
 }
@@ -179,7 +179,7 @@ void
 BSimpleMediaInput::Disconnected()
 {
        if (fNotifyHook != NULL)
-               (*fNotifyHook)(BSimpleMediaConnection::B_INPUT_DISCONNECTED, 
this);
+               (*fNotifyHook)(this, 
BSimpleMediaConnection::B_INPUT_DISCONNECTED);
 
        BMediaConnection::Disconnected();
 }
@@ -191,7 +191,7 @@ BSimpleMediaInput::HandleBuffer(BBuffer* buffer)
        CALLED();
 
        if (fProcessHook != NULL)
-               (*fProcessHook)((BMediaConnection*)this, buffer);
+               (*fProcessHook)(this, buffer);
 }
 
 
@@ -214,8 +214,8 @@ status_t
 BSimpleMediaOutput::FormatProposal(media_format* format)
 {
        if (fNotifyHook != NULL) {
-               return (*fNotifyHook)(BSimpleMediaConnection::B_FORMAT_PROPOSAL,
-                       this, format);
+               return (*fNotifyHook)(this,
+                       BSimpleMediaConnection::B_FORMAT_PROPOSAL, format);
        }
 
        return BMediaOutput::FormatProposal(format);
@@ -226,7 +226,7 @@ void
 BSimpleMediaOutput::Connected(const media_format& format)
 {
        if (fNotifyHook != NULL)
-               (*fNotifyHook)(BSimpleMediaConnection::B_OUTPUT_CONNECTED, 
this);
+               (*fNotifyHook)(this, 
BSimpleMediaConnection::B_OUTPUT_CONNECTED);
 
        BSimpleMediaConnection::Connected(format);
 }
@@ -236,7 +236,7 @@ void
 BSimpleMediaOutput::Disconnected()
 {
        if (fNotifyHook != NULL)
-               (*fNotifyHook)(BSimpleMediaConnection::B_OUTPUT_DISCONNECTED, 
this);
+               (*fNotifyHook)(this, 
BSimpleMediaConnection::B_OUTPUT_DISCONNECTED);
 
        BSimpleMediaConnection::Disconnected();
 }

############################################################################

Commit:      ada4f9788f0a6047bef1f2a0d604bea55736ddd3
URL:         http://cgit.haiku-os.org/haiku/commit/?id=ada4f9788f0a
Author:      Dario Casalinuovo <b.vitruvio@xxxxxxxxx>
Date:        Fri Apr 28 00:03:02 2017 UTC

MediaClient: Add play and test options

----------------------------------------------------------------------------

diff --git a/src/tests/kits/media/media_client/Jamfile 
b/src/tests/kits/media/media_client/Jamfile
index 260955b..a0a3b98 100644
--- a/src/tests/kits/media/media_client/Jamfile
+++ b/src/tests/kits/media/media_client/Jamfile
@@ -6,5 +6,7 @@ UsePrivateHeaders [ FDirName media experimental ] ;
 
 SimpleTest media_client :
        media_client.cpp
+       MediaPlay.cpp
+       MediaTest.cpp
        : libmedia.so be root [ TargetLibsupc++ ]
 ;
diff --git a/src/tests/kits/media/media_client/MediaPlay.cpp 
b/src/tests/kits/media/media_client/MediaPlay.cpp
new file mode 100644
index 0000000..73d2207
--- /dev/null
+++ b/src/tests/kits/media/media_client/MediaPlay.cpp
@@ -0,0 +1,114 @@
+/*
+ * Copyright 2017, Dario Casalinuovo. All rights reserved.
+ * Copyright 2005, Marcus Overhagen, marcus@xxxxxxxxxxxx. All rights reserved.
+ * Copyright 2005, Jérôme Duval. All rights reserved.
+ * Distributed under the terms of the MIT License.
+ */
+
+#include "MediaPlay.h"
+
+#include <Entry.h>
+#include <MediaFile.h>
+#include <MediaTrack.h>
+#include <OS.h>
+#include <SoundPlayer.h>
+#include <Url.h>
+
+#include <stdio.h>
+#include <unistd.h>
+#include <fcntl.h>
+#include <signal.h>
+
+thread_id reader = -1;
+sem_id finished = -1;
+BMediaTrack* playTrack;
+media_format playFormat;
+BSoundPlayer* player = 0;
+volatile bool interrupt = false;
+
+
+void
+play_buffer(void *cookie, void * buffer, size_t size, const 
media_raw_audio_format & format)
+{
+       int64 frames = 0;
+       
+       // Use your feeling, Obi-Wan, and find him you will. 
+       playTrack->ReadFrames(buffer, &frames);
+       
+       if (frames <=0) {
+               player->SetHasData(false);
+               release_sem(finished);
+       }
+}
+
+
+void
+keyb_int(int)
+{
+       // Are you threatening me, Master Jedi?
+       interrupt = true;
+       release_sem(finished);
+}
+
+
+int media_play(const char* uri)
+{
+       BUrl url;
+       entry_ref ref;
+       BMediaFile* playFile;
+
+       if (get_ref_for_path(uri, &ref) != B_OK) {
+               url.SetUrlString(uri);
+               if (url.IsValid()) {
+                       playFile = new BMediaFile(url);
+               } else
+                       return 2;
+       } else
+               playFile = new BMediaFile(&ref);
+
+       if (playFile->InitCheck() != B_OK) {
+               delete playFile;
+               return 2;
+       }
+       
+       for (int i = 0; i < playFile->CountTracks(); i++) {
+               BMediaTrack* track = playFile->TrackAt(i);
+               playFormat.type = B_MEDIA_RAW_AUDIO;
+               if ((track->DecodedFormat(&playFormat) == B_OK) 
+                               && (playFormat.type == B_MEDIA_RAW_AUDIO)) {
+                       playTrack = track;
+                       break;
+               }
+               if (track)
+                       playFile->ReleaseTrack(track);
+       }
+
+       // Good relations with the Wookiees, I have. 
+       signal(SIGINT, keyb_int);
+
+       finished = create_sem(0, "finish wait");
+       
+       printf("Playing file...\n");
+       
+       // Execute Plan 66!
+       player = new BSoundPlayer(&playFormat.u.raw_audio, "playfile", 
play_buffer);
+       player->SetVolume(1.0f);
+
+       // Join me, Padmé and together we can rule this galaxy. 
+       player->SetHasData(true);
+       player->Start();
+
+       acquire_sem(finished);
+
+       if (interrupt == true) {
+               // Once more, the Sith will rule the galaxy. 
+               printf("Interrupted\n");
+               player->Stop();
+               kill_thread(reader);
+       }
+
+       printf("Playback finished.\n");
+
+       delete player;
+       delete playFile;
+}
diff --git a/src/tests/kits/media/media_client/MediaPlay.h 
b/src/tests/kits/media/media_client/MediaPlay.h
new file mode 100644
index 0000000..84670a7
--- /dev/null
+++ b/src/tests/kits/media/media_client/MediaPlay.h
@@ -0,0 +1,12 @@
+/*
+ * Copyright 2017, Dario Casalinuovo. All rights reserved.
+ * Distributed under the terms of the MIT License.
+ */
+
+#ifndef _MEDIA_CLIENT_PLAY
+#define _MEDIA_CLIENT_PLAY
+
+int media_play(const char* uri);
+
+#endif
+
diff --git a/src/tests/kits/media/media_client/MediaTest.cpp 
b/src/tests/kits/media/media_client/MediaTest.cpp
new file mode 100644
index 0000000..d1dbe83
--- /dev/null
+++ b/src/tests/kits/media/media_client/MediaTest.cpp
@@ -0,0 +1,140 @@
+/*
+ * Copyright 2017, Dario Casalinuovo. All rights reserved.
+ * Distributed under the terms of the MIT License.
+ */
+
+#include "MediaTest.h"
+
+#include <SimpleMediaClient.h>
+#include <MediaConnection.h>
+#include <SupportDefs.h>
+
+#include <assert.h>
+#include <stdio.h>
+
+#include <debug.h>
+
+#ifdef DEBUG
+#define DELAYED_MODE 1
+#define SNOOZE_FOR 10000000
+#endif
+
+
+static BSimpleMediaClient* sProducer = NULL;
+static BSimpleMediaClient* sConsumer = NULL;
+static BSimpleMediaClient* sFilter = NULL;
+
+
+void
+_InitClients(bool hasFilter)
+{
+       sProducer = new BSimpleMediaClient("MediaClientProducer");
+       sConsumer = new BSimpleMediaClient("MediaClientConsumer");
+
+       if (hasFilter)
+               sFilter = new BSimpleMediaClient("MediaClientFilter");
+       else
+               sFilter = NULL;
+}
+
+
+void
+_DeleteClients()
+{
+       delete sProducer;
+       delete sConsumer;
+       delete sFilter;
+}
+
+
+media_format
+_BuildRawAudioFormat()
+{
+       media_format format;
+       format.type = B_MEDIA_RAW_AUDIO;
+       format.u.raw_audio = media_multi_audio_format::wildcard;
+
+       return format;
+}
+
+
+void
+_ConsumerProducerTest()
+{
+       _InitClients(false);
+
+       BSimpleMediaOutput* output = sProducer->BeginOutput();
+       BSimpleMediaInput* input = sConsumer->BeginInput();
+
+       output->SetAcceptedFormat(_BuildRawAudioFormat());
+       input->SetAcceptedFormat(_BuildRawAudioFormat());
+
+       assert(sConsumer->Connect(input, output) == B_OK);
+
+       #ifdef DELAYED_MODE
+       snooze(SNOOZE_FOR);
+       #endif
+
+       assert(sConsumer->Disconnect() == B_OK);
+
+       _DeleteClients();
+}
+
+
+void
+_ProducerConsumerTest()
+{
+       _InitClients(false);
+
+       BMediaOutput* output = sProducer->BeginOutput();
+       BMediaInput* input = sConsumer->BeginInput();
+
+       assert(sProducer->Connect(output, input) == B_OK);
+
+       #ifdef DELAYED_MODE
+       snooze(SNOOZE_FOR);
+       #endif
+
+       assert(sProducer->Disconnect() == B_OK);
+
+       _DeleteClients();
+}
+
+
+void
+_ProducerFilterConsumerTest()
+{
+       _InitClients(true);
+
+       BMediaOutput* output = sProducer->BeginOutput();
+       BMediaInput* input = sConsumer->BeginInput();
+
+       BMediaInput* filterInput = sFilter->BeginInput();
+       BMediaOutput* filterOutput = sFilter->BeginOutput();
+
+       assert(sFilter->Bind(filterInput, filterOutput) == B_OK);
+
+       assert(sProducer->Connect(output, filterInput) == B_OK);
+       assert(sFilter->Connect(filterOutput, input) == B_OK);
+       #ifdef DELAYED_MODE
+       snooze(SNOOZE_FOR);
+       #endif
+
+       assert(sFilter->Disconnect() == B_OK);
+
+       _DeleteClients();
+}
+
+
+void
+media_test()
+{
+       printf("Testing Simple (1:1) Producer-Consumer configuration: ");
+       _ConsumerProducerTest();
+       _ProducerConsumerTest();
+       printf("OK\n");
+
+       printf("Testing Simple (1:1:1) Producer-Filter-Consumer configuration: 
");
+       _ProducerFilterConsumerTest();
+       printf("OK\n");
+}
diff --git a/src/tests/kits/media/media_client/MediaTest.h 
b/src/tests/kits/media/media_client/MediaTest.h
new file mode 100644
index 0000000..3cca65f
--- /dev/null
+++ b/src/tests/kits/media/media_client/MediaTest.h
@@ -0,0 +1,12 @@
+/*
+ * Copyright 2017, Dario Casalinuovo. All rights reserved.
+ * Distributed under the terms of the MIT License.
+ */
+
+#ifndef _MEDIA_CLIENT_TEST
+#define _MEDIA_CLIENT_TEST
+
+void media_test();
+
+#endif
+
diff --git a/src/tests/kits/media/media_client/media_client.cpp 
b/src/tests/kits/media/media_client/media_client.cpp
index 1e94fb5..c490efe 100644
--- a/src/tests/kits/media/media_client/media_client.cpp
+++ b/src/tests/kits/media/media_client/media_client.cpp
@@ -1,133 +1,43 @@
 /*
- * Copyright 2016, Dario Casalinuovo. All rights reserved.
+ * Copyright 2016-2017, Dario Casalinuovo. All rights reserved.
  * Distributed under the terms of the MIT License.
  */
 
-#include <SimpleMediaClient.h>
-#include <MediaConnection.h>
-#include <SupportDefs.h>
+#include <Application.h>
 
-#include <debug.h>
-
-#include <assert.h>
 #include <stdio.h>
+#include <string.h>
 
-#ifdef DEBUG
-#define DELAYED_MODE 1
-#define SNOOZE_FOR 10000000
-#endif
-
-
-static BSimpleMediaClient* sProducer = NULL;
-static BSimpleMediaClient* sConsumer = NULL;
-static BSimpleMediaClient* sFilter = NULL;
-
-
-void _InitClients(bool hasFilter)
-{
-       sProducer = new BSimpleMediaClient("MediaClientProducer");
-       sConsumer = new BSimpleMediaClient("MediaClientConsumer");
-
-       if (hasFilter)
-               sFilter = new BSimpleMediaClient("MediaClientFilter");
-       else
-               sFilter = NULL;
-}
-
-
-void _DeleteClients()
-{
-       delete sProducer;
-       delete sConsumer;
-       delete sFilter;
-}
-
-
-media_format _BuildRawAudioFormat()
-{
-       media_format format;
-       format.type = B_MEDIA_RAW_AUDIO;
-       format.u.raw_audio = media_multi_audio_format::wildcard;
-
-       return format;
-}
-
-
-void _ConsumerProducerTest()
-{
-       _InitClients(false);
-
-       BSimpleMediaOutput* output = sProducer->BeginOutput();
-       BSimpleMediaInput* input = sConsumer->BeginInput();
-
-       output->SetAcceptedFormat(_BuildRawAudioFormat());
-       input->SetAcceptedFormat(_BuildRawAudioFormat());
+#include "MediaPlay.h"
+#include "MediaTest.h"
 
-       assert(sConsumer->Connect(input, output) == B_OK);
 
-       #ifdef DELAYED_MODE
-       snooze(SNOOZE_FOR);
-       #endif
-
-       assert(sConsumer->Disconnect() == B_OK);
-
-       _DeleteClients();
-}
-
-
-void _ProducerConsumerTest()
-{
-       _InitClients(false);
-
-       BMediaOutput* output = sProducer->BeginOutput();
-       BMediaInput* input = sConsumer->BeginInput();
-
-       assert(sProducer->Connect(output, input) == B_OK);
-
-       #ifdef DELAYED_MODE
-       snooze(SNOOZE_FOR);
-       #endif
-
-       assert(sProducer->Disconnect() == B_OK);
-
-       _DeleteClients();
-}
-
-
-void _ProducerFilterConsumerTest()
+void print_usage()
 {
-       _InitClients(true);
-
-       BMediaOutput* output = sProducer->BeginOutput();
-       BMediaInput* input = sConsumer->BeginInput();
-
-       BMediaInput* filterInput = sFilter->BeginInput();
-       BMediaOutput* filterOutput = sFilter->BeginOutput();
-
-       assert(sFilter->Bind(filterInput, filterOutput) == B_OK);
-
-       assert(sProducer->Connect(output, filterInput) == B_OK);
-       assert(sFilter->Connect(filterOutput, input) == B_OK);
-       #ifdef DELAYED_MODE
-       snooze(SNOOZE_FOR);
-       #endif
-
-       assert(sFilter->Disconnect() == B_OK);
-
-       _DeleteClients();
+       printf("Usage:\n");
+       printf("  media_client play <uri>\n");
+       printf("  media_client test\n");
 }
 
 
-int main()
+int main(int argc, char *argv[])
 {
-       printf("Testing Simple (1:1) Producer-Consumer configuration: ");
-       _ConsumerProducerTest();
-       _ProducerConsumerTest();
-       printf("OK\n");
-
-       printf("Testing Simple (1:1:1) Producer-Filter-Consumer configuration: 
");
-       _ProducerFilterConsumerTest();
-       printf("OK\n");
-
-       return 0;
+       if (argc < 2) {
+               print_usage();
+               return 0;
+       }
+
+       BApplication* app = new BApplication(
+               "application/x-vnd.Haiku-media_client");
+
+       int ret = 0;
+       if (strcmp(argv[1], "play") == 0) {
+               if (argc < 3) {
+                       print_usage();
+               } else
+                       ret = media_play(argv[2]);
+       } else if (strcmp(argv[1], "test") == 0)
+               media_test();
+
+       return ret;
 }

############################################################################

Commit:      a34acb8cb68308f88daa2637b70b04c32abe6bfe
URL:         http://cgit.haiku-os.org/haiku/commit/?id=a34acb8cb683
Author:      Dario Casalinuovo <b.vitruvio@xxxxxxxxx>
Date:        Fri Apr 28 00:04:35 2017 UTC

Remove play* commands from build

* Add media_client as replacement

----------------------------------------------------------------------------

diff --git a/build/jam/images/definitions/regular 
b/build/jam/images/definitions/regular
index 74ed52f..10b846e 100644
--- a/build/jam/images/definitions/regular
+++ b/build/jam/images/definitions/regular
@@ -9,9 +9,8 @@ SYSTEM_BIN += [ FFilterByBuildFeatures
        dpms
        FirstBootPrompt fwcontrol@x86
        installsound
-       mail mail2mbox mbox2mail mkdos mount_nfs
-       play playfile playsound playwav
-       screenshot setdecor spamdbm
+       mail mail2mbox mbox2mail media_client mkdos mount_nfs
+       play screenshot setdecor spamdbm
        translate
        WindowShade
 ] ;

############################################################################

Commit:      0d25cdf0318272b4e79205d6b1efde8ec2fbf583
URL:         http://cgit.haiku-os.org/haiku/commit/?id=0d25cdf03182
Author:      Dario Casalinuovo <b.vitruvio@xxxxxxxxx>
Date:        Fri Apr 28 00:05:27 2017 UTC

Remove play* commands from bin

----------------------------------------------------------------------------

diff --git a/src/bin/playsound/Jamfile b/src/tests/kits/media/playsound/Jamfile
similarity index 100%
rename from src/bin/playsound/Jamfile
rename to src/tests/kits/media/playsound/Jamfile
diff --git a/src/bin/playsound/playfile.cpp 
b/src/tests/kits/media/playsound/playfile.cpp
similarity index 100%
rename from src/bin/playsound/playfile.cpp
rename to src/tests/kits/media/playsound/playfile.cpp
diff --git a/src/bin/playsound/playsound.cpp 
b/src/tests/kits/media/playsound/playsound.cpp
similarity index 100%
rename from src/bin/playsound/playsound.cpp
rename to src/tests/kits/media/playsound/playsound.cpp
diff --git a/src/bin/playsound/playwav.cpp 
b/src/tests/kits/media/playsound/playwav.cpp
similarity index 100%
rename from src/bin/playsound/playwav.cpp
rename to src/tests/kits/media/playsound/playwav.cpp

############################################################################

Commit:      dda3a9c309b722e0ebb69f890677fd22a3880b9f
URL:         http://cgit.haiku-os.org/haiku/commit/?id=dda3a9c309b7
Author:      Dario Casalinuovo <b.vitruvio@xxxxxxxxx>
Date:        Fri Apr 28 00:06:16 2017 UTC

Move media_client to bin

----------------------------------------------------------------------------

diff --git a/src/tests/kits/media/media_client/Jamfile 
b/src/bin/media_client/Jamfile
similarity index 100%
rename from src/tests/kits/media/media_client/Jamfile
rename to src/bin/media_client/Jamfile
diff --git a/src/tests/kits/media/media_client/MediaPlay.cpp 
b/src/bin/media_client/MediaPlay.cpp
similarity index 100%
rename from src/tests/kits/media/media_client/MediaPlay.cpp
rename to src/bin/media_client/MediaPlay.cpp
diff --git a/src/tests/kits/media/media_client/MediaPlay.h 
b/src/bin/media_client/MediaPlay.h
similarity index 100%
rename from src/tests/kits/media/media_client/MediaPlay.h
rename to src/bin/media_client/MediaPlay.h
diff --git a/src/tests/kits/media/media_client/MediaTest.cpp 
b/src/bin/media_client/MediaTest.cpp
similarity index 100%
rename from src/tests/kits/media/media_client/MediaTest.cpp
rename to src/bin/media_client/MediaTest.cpp
diff --git a/src/tests/kits/media/media_client/MediaTest.h 
b/src/bin/media_client/MediaTest.h
similarity index 100%
rename from src/tests/kits/media/media_client/MediaTest.h
rename to src/bin/media_client/MediaTest.h
diff --git a/src/tests/kits/media/media_client/media_client.cpp 
b/src/bin/media_client/media_client.cpp
similarity index 100%
rename from src/tests/kits/media/media_client/media_client.cpp
rename to src/bin/media_client/media_client.cpp

############################################################################

Revision:    hrev51133
Commit:      4263f2570d445b25d4bf74493b36f2ecca880570
URL:         http://cgit.haiku-os.org/haiku/commit/?id=4263f2570d44
Author:      Dario Casalinuovo <b.vitruvio@xxxxxxxxx>
Date:        Fri Apr 28 00:10:26 2017 UTC

media_client: Fix Jamfiles to build correctly

----------------------------------------------------------------------------

diff --git a/src/bin/Jamfile b/src/bin/Jamfile
index 18d4281..29c7b0b 100644
--- a/src/bin/Jamfile
+++ b/src/bin/Jamfile
@@ -270,6 +270,7 @@ SubInclude HAIKU_TOP src bin locale ;
 SubInclude HAIKU_TOP src bin makebootable ;
 #SubInclude HAIKU_TOP src bin makeudfimage ;
 SubInclude HAIKU_TOP src bin mail_utils ;
+SubInclude HAIKU_TOP src bin media_client ;
 SubInclude HAIKU_TOP src bin mkdos ;
 SubInclude HAIKU_TOP src bin mkfs ;
 SubInclude HAIKU_TOP src bin multiuser ;
@@ -278,7 +279,6 @@ SubInclude HAIKU_TOP src bin package_repo ;
 SubInclude HAIKU_TOP src bin pc ;
 SubInclude HAIKU_TOP src bin pcmcia-cs ;
 SubInclude HAIKU_TOP src bin pkgman ;
-SubInclude HAIKU_TOP src bin playsound ;
 SubInclude HAIKU_TOP src bin rc ;
 SubInclude HAIKU_TOP src bin rmd160 ;
 SubInclude HAIKU_TOP src bin screen_blanker ;
diff --git a/src/bin/media_client/Jamfile b/src/bin/media_client/Jamfile
index a0a3b98..6314347 100644
--- a/src/bin/media_client/Jamfile
+++ b/src/bin/media_client/Jamfile
@@ -1,4 +1,4 @@
-SubDir HAIKU_TOP src tests kits media media_client ;
+SubDir HAIKU_TOP src bin media_client ;
 
 UsePrivateHeaders media ;
 
diff --git a/src/tests/kits/media/Jamfile b/src/tests/kits/media/Jamfile
index ca7fd7d..f1aa917 100644
--- a/src/tests/kits/media/Jamfile
+++ b/src/tests/kits/media/Jamfile
@@ -18,7 +18,6 @@ UnitTestLib libmediatest.so :
        : be media [ TargetLibstdc++ ] [ TargetLibsupc++ ]
 ;
 
-SubInclude HAIKU_TOP src tests kits media media_client ;
 SubInclude HAIKU_TOP src tests kits media media_decoder ;
 SubInclude HAIKU_TOP src tests kits media mpeg2_decoder_test ;
 SubInclude HAIKU_TOP src tests kits media mp3_decoder_test ;
@@ -26,6 +25,7 @@ SubInclude HAIKU_TOP src tests kits media mp3_reader_test ;
 SubInclude HAIKU_TOP src tests kits media notificationtest ;
 SubInclude HAIKU_TOP src tests kits media nodetest ;
 SubInclude HAIKU_TOP src tests kits media playwav ;
+SubInclude HAIKU_TOP src tests kits media playsound ;
 SubInclude HAIKU_TOP src tests kits media soundplayer ;
 SubInclude HAIKU_TOP src tests kits media streamer_sniff_test ;
 SubInclude HAIKU_TOP src tests kits media wav_reader_test ;
diff --git a/src/tests/kits/media/playsound/Jamfile 
b/src/tests/kits/media/playsound/Jamfile
index d4256dc..a163340 100644
--- a/src/tests/kits/media/playsound/Jamfile
+++ b/src/tests/kits/media/playsound/Jamfile
@@ -1,4 +1,4 @@
-SubDir HAIKU_TOP src bin playsound ;
+SubDir HAIKU_TOP src tests kits media playsound ;
 
 BinCommand playfile :
        playfile.cpp


Other related posts:

  • » [haiku-commits] haiku: hrev51133 - in src: tests/kits/media/playsound bin/playsound bin/media_client tests/kits/media/media_client kits/media/experimental - b . vitruvio