Browse Source

JackWeakAPI.cpp renamed in JackWeakAPI.c

git-svn-id: http://subversion.jackaudio.org/jack/jack2/trunk/jackmp@4319 0c269be4-1314-0410-8aa9-9f06e86f4224
tags/1.9.8
sletz 14 years ago
parent
commit
11a6f26f13
2 changed files with 11 additions and 13 deletions
  1. +4
    -0
      ChangeLog
  2. +7
    -13
      common/JackWeakAPI.c

+ 4
- 0
ChangeLog View File

@@ -34,6 +34,10 @@ Valerio Pilo
Jackdmp changes log Jackdmp changes log
--------------------------- ---------------------------


2011-04-18 Stephane Letz <letz@grame.fr>

* JackWeakAPI.cpp renamed in JackWeakAPI.c.

2011-04-04 Stephane Letz <letz@grame.fr> 2011-04-04 Stephane Letz <letz@grame.fr>


* Correct driver lifetime management. * Correct driver lifetime management.


common/JackWeakAPI.cpp → common/JackWeakAPI.c View File

@@ -1,10 +1,6 @@
//============================================================================= //=============================================================================
// MuseScore
// Linux Music Score Editor
// $Id:
// //
// jackWeakAPI based on code from Stéphane Letz (Grame)
// partly based on Julien Pommier (PianoTeq : http://www.pianoteq.com/) code.
// jackWeakAPI partly based on Julien Pommier (PianoTeq : http://www.pianoteq.com/) code.
// //
// Copyright (C) 2002-2007 Werner Schweer and others // Copyright (C) 2002-2007 Werner Schweer and others
// Copyright (C) 2009 Grame // Copyright (C) 2009 Grame
@@ -24,6 +20,7 @@
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.


#include <jack/jack.h> #include <jack/jack.h>
#include <jack/session.h>
#include <jack/thread.h> #include <jack/thread.h>
#include <jack/midiport.h> #include <jack/midiport.h>
#include <math.h> #include <math.h>
@@ -31,7 +28,7 @@
#include <dlfcn.h> #include <dlfcn.h>
#endif #endif
#include <stdlib.h> #include <stdlib.h>
#include <iostream>
#include <stdio.h>


/* dynamically load libjack and forward all registered calls to libjack /* dynamically load libjack and forward all registered calls to libjack
(similar to what relaytool is trying to do, but more portably..) (similar to what relaytool is trying to do, but more portably..)
@@ -40,17 +37,14 @@
typedef void (*print_function)(const char *); typedef void (*print_function)(const char *);
typedef void *(*thread_routine)(void*); typedef void *(*thread_routine)(void*);


using std::cerr;

int libjack_is_present = 0; // public symbol, similar to what relaytool does.
static int libjack_is_present = 0; // public symbol, similar to what relaytool does.


#ifdef WIN32 #ifdef WIN32
HMODULE libjack_handle = 0;
static HMODULE libjack_handle = 0;
#else #else
static void *libjack_handle = 0; static void *libjack_handle = 0;
#endif #endif



static void __attribute__((constructor)) tryload_libjack() static void __attribute__((constructor)) tryload_libjack()
{ {
if (getenv("SKIP_LIBJACK") == 0) { // just in case libjack is causing troubles.. if (getenv("SKIP_LIBJACK") == 0) { // just in case libjack is causing troubles..
@@ -293,8 +287,8 @@ DECL_VOID_FUNCTION(jack_free, (void* ptr), (ptr));


// session // session
DECL_FUNCTION(int, jack_set_session_callback, (jack_client_t* ext_client, JackSessionCallback session_callback, void* arg), (ext_client, session_callback, arg)); DECL_FUNCTION(int, jack_set_session_callback, (jack_client_t* ext_client, JackSessionCallback session_callback, void* arg), (ext_client, session_callback, arg));
DECL_FUNCTION(jack_session_command_t*, jack_session_notify, (jack_client_t* ext_client, const char* target, jack_session_event_type_t ev_type, const char* path), (ext_client, target, ev_type, path)à);
DECL_FUNCTION(int jack_session_reply, (jack_client_t* ext_client, jack_session_event_t *event), (ext_client, event));
DECL_FUNCTION(jack_session_command_t*, jack_session_notify, (jack_client_t* ext_client, const char* target, jack_session_event_type_t ev_type, const char* path), (ext_client, target, ev_type, path));
DECL_FUNCTION(int, jack_session_reply, (jack_client_t* ext_client, jack_session_event_t *event), (ext_client, event));
DECL_VOID_FUNCTION(jack_session_event_free, (jack_session_event_t* ev), (ev)); DECL_VOID_FUNCTION(jack_session_event_free, (jack_session_event_t* ev), (ev));
DECL_FUNCTION(char*, jack_get_uuid_for_client_name, (jack_client_t* ext_client, const char* client_name),(ext_client, client_name)); DECL_FUNCTION(char*, jack_get_uuid_for_client_name, (jack_client_t* ext_client, const char* client_name),(ext_client, client_name));
DECL_FUNCTION(char*, jack_get_client_name_by_uuid, (jack_client_t* ext_client, const char* client_uuid),(ext_client, client_uuid)); DECL_FUNCTION(char*, jack_get_client_name_by_uuid, (jack_client_t* ext_client, const char* client_uuid),(ext_client, client_uuid));

Loading…
Cancel
Save