Early work on Synergy.

* Make Haiku a recognized platform.
* Build fails early for an unknown reason (compiler prints some warnings
and stops)
* Not sure wether this can be built with gcc4 (secondary compiler), as
it would need to work as an input_server add-on...
* Synergy homepage does advertise gcc2.95.3 as the minimal required
version, but that may be out of date.
This commit is contained in:
Adrien Destugues
2014-08-05 20:16:36 +02:00
parent aabfe9e4ce
commit 325c575406
2 changed files with 116 additions and 0 deletions

View File

@@ -0,0 +1,68 @@
From e51832b0a2707aec5b8e4719ab6a3e07e2f98178 Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Tue, 5 Aug 2014 20:10:49 +0200
Subject: First attempt at getting things to compile.
* Compiler fails on the first compiled file, without an error message.
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6d6b770..f07772f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -145,12 +145,7 @@ if (UNIX)
check_type_size(short SIZEOF_SHORT)
# pthread is used on both Linux and Mac
- check_library_exists("pthread" pthread_create "" HAVE_PTHREAD)
- if (HAVE_PTHREAD)
- list(APPEND libs pthread)
- else()
- message(FATAL_ERROR "Missing library: pthread")
- endif()
+ find_package(Threads REQUIRED)
# curl is used on both Linux and Mac
find_package(CURL)
@@ -191,6 +186,8 @@ if (UNIX)
${lib_Carbon}
)
+ elseif(HAIKU)
+ # TODO
else() # not-apple
# add include dir for bsd (posix uses /usr/include/)
@@ -291,6 +288,8 @@ if (UNIX)
if (APPLE)
add_definitions(-DWINAPI_CARBON=1 -D_THREAD_SAFE)
+ elseif(HAIKU)
+ add_definitions(-DWINAPI_BEAPI=1)
else (APPLE)
add_definitions(-DWINAPI_XWINDOWS=1)
endif()
diff --git a/ext/toolchain/commands1.py b/ext/toolchain/commands1.py
index ef492f2..7334cae 100644
--- a/ext/toolchain/commands1.py
+++ b/ext/toolchain/commands1.py
@@ -737,7 +737,7 @@ class InternalCommands:
if sys.platform == 'win32':
gui_make_cmd = self.w32_make_cmd
- elif sys.platform in ['linux2', 'sunos5', 'freebsd7', 'darwin']:
+ elif sys.platform in ['linux2', 'sunos5', 'freebsd7', 'darwin', 'haiku1']:
gui_make_cmd = self.make_cmd + " -w"
else:
raise Exception('Unsupported platform: ' + sys.platform)
@@ -1579,7 +1579,7 @@ class InternalCommands:
def get_generators(self):
if sys.platform == 'win32':
return self.win32_generators
- elif sys.platform in ['linux2', 'sunos5', 'freebsd7', 'aix5']:
+ elif sys.platform in ['linux2', 'sunos5', 'freebsd7', 'aix5', 'haiku1']:
return self.unix_generators
elif sys.platform == 'darwin':
return self.darwin_generators
--
1.8.3.4

View File

@@ -0,0 +1,48 @@
SUMMARY="Mouse and Keyboard sharing software"
DESCRIPTION="Most people think of their computers as single, isolated units. \
Our mission is to change that so people think of all their computers as \
a single seamless system.
Synergy brings your computers together in one cohesive experience; its free \
and open source cross-platform software for sharing one mouse and keyboard \
between multiple computers on your desk. It works on Windows, Mac OS X and \
Linux allowing you to seamlessly move your mouse cursor between computers.
"
HOMEPAGE="http://www.synergy-project.org"
REVISION="1"
LICENSE="GNU GPL v2"
ARCHITECTURES="!x86_gcc2"
COPYRIGHT="2002 Chris Schoeneman
2012 Bolton Software Ltd."
SRC_URI="$HOMEPAGE/files/packages/synergy-1.5.0-r2278-Source.tar.gz"
CHECKSUM_SHA256="66bf6016a2e71b2b2b26fc445d28324d1d286b6fca7ae3e9d19fd300769af024"
SOURCE_DIR="synergy-${portVersion}-Source"
PROVIDES="
synergy = $portVersion
"
BUILD_REQUIRES="
devel:libcurl
"
BUILD_PREREQUIRES="
haiku_devel >= $haikuVersion
cmd:cmake
cmd:gcc
cmd:make
cmd:python
cmd:sh
"
BUILD()
{
./hm.sh conf -g1 --skip-gui
./hm.sh build
}
INSTALL()
{
false
}