Build libapplauncherd as a real library with exported symbols

Boosters would include objects directly from launcherlib rather than
linking to it, which makes no sense of any kind.
pull/1/head
John Brooks 13 years ago
parent 12bd4a6db2
commit 9a6cc6c657

@ -15,6 +15,12 @@ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -W -Wall -Wextra -g -O3")
set(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "")
set(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS "")
set(CMAKE_SKIP_BUILD_RPATH FALSE)
set(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE)
set(CMAKE_INSTALL_RPATH "/usr/lib/applauncherd/")
set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE)
# Find libdl
find_library(LIBDL NAMES dl)

@ -20,6 +20,7 @@
#ifndef APPDATA_H
#define APPDATA_H
#include "launcherlib.h"
#include <stdint.h>
#include <string>
@ -33,7 +34,7 @@ using std::vector;
typedef int (*entry_t)(int, char **);
//! Structure for application data read from the invoker
class AppData
class DECL_EXPORT AppData
{
public:

@ -20,6 +20,7 @@
#ifndef BOOSTER_H
#define BOOSTER_H
#include "launcherlib.h"
#include <QX11Info>
#include <cstdlib>
@ -50,7 +51,7 @@ class SingleInstance;
* Booster instance dies with the launched application and a new one must be created
* in advance so as to launch a new application.
*/
class Booster
class DECL_EXPORT Booster
{
public:

@ -20,6 +20,7 @@
#ifndef CONNECTION_H
#define CONNECTION_H
#include "launcherlib.h"
#include "appdata.h"
#include "protocol.h"
@ -38,7 +39,7 @@ using std::string;
* and the launcher daemon. The low-level communication code is mostly taken
* from the maemo-launcher used in Maemo 5. It might need a re-write.
*/
class Connection
class DECL_EXPORT Connection
{
public:

@ -0,0 +1,6 @@
#ifndef LAUNCHERLIB_H
#define LAUNCHERLIB_H
#define DECL_EXPORT __attribute__ ((__visibility__("default")))
#endif

@ -20,6 +20,7 @@
#ifndef LOGGER_H
#define LOGGER_H
#include "launcherlib.h"
#include <cstdarg>
/*!
@ -27,7 +28,7 @@
* \brief Logging utility class
*
*/
class Logger
class DECL_EXPORT Logger
{
public:

@ -30,8 +30,6 @@
#include <sys/file.h>
#include <stdexcept>
#define DECL_EXPORT extern "C" __attribute__ ((__visibility__("default")))
int g_sigPipeFd = -1;
char g_pipeDataSigChld = SIGCHLD;
char g_pipeDataSigTerm = SIGTERM;
@ -71,7 +69,7 @@ static void sigHupHandler(int)
}
//! Main function
DECL_EXPORT int main(int argc, char * argv[])
extern "C" DECL_EXPORT int main(int argc, char * argv[])
{
// Open the log
Logger::openLog(PROG_NAME_LAUNCHER);

@ -20,6 +20,7 @@
#ifndef SINGLEINSTANCE_H
#define SINGLEINSTANCE_H
#include "launcherlib.h"
#include <tr1/memory>
using std::tr1::shared_ptr;
@ -50,7 +51,7 @@ struct SingleInstancePluginEntry
};
//! Class that loads the single-instance binary as a plugin.
class SingleInstance
class DECL_EXPORT SingleInstance
{
public:

@ -20,12 +20,11 @@
#ifndef SOCKETMANAGER_H
#define SOCKETMANAGER_H
#include "launcherlib.h"
#include <map>
using std::map;
#include <string>
using std::map;
using std::string;
/*!
@ -34,7 +33,7 @@ using std::string;
* SocketManager Manages sockets that are used in the invoker <-> booster
* communication.
*/
class SocketManager
class DECL_EXPORT SocketManager
{
public:

Loading…
Cancel
Save