As building with -Wl,--no-undefined might cause issues when
combined with other linker flags (e.g. with -fsanitize=address see #3289)
it is now disabled per default but can be re-enabled with
-DWITH_NO_UNDEFINED=ON.
It is enabled for ci builds on linux to find undefined symbols.
If a target is linked against libraries with cmake
(target_link_libraries) and the libraries are not marked as PRIVATE
they are "exported" and in case a other target is linked against this
target it is also linked against *all* (not private) libraries.
Without declaring private libraries PRIVATE a lot of over linking
(linking against unneeded libraries) was done.
When nothing is declared, only export symbols defined
with WINPR_API or FREERDP_API defined.
Override this setting if BUILD_TESTING to allow tests
access to internal functions usually not exposed.
Extend winpr and client/common to support a new option "/buildconfig".
When used build the following build specific information is print:
* cmake options
* cflags
* compiler
* target architecture
* cmake build type
With this commit the "exported" components (usable with pkg-config and
cmake find module package)
* winpr - winpr library and headers
* freerdp - core library and headers
* freerdp-client - client specific library
* freerdp-server - server specific library
* rdtk - rdtk headers and library
To allow the installation of multiple different version (different major
number) the include files were moved into the respective sub folder:
freerdp -> freerdp{MAJOR}/freerdp (currently freerdp2/freerdp/)
winpr -> winpr{MAJOR}/winpr (currently winrp1/winpr/)
rdtk -> rdpk{MAJOR}/rdtk (currently rdtk0/rdtk/
The generated pkg-config and cmake find modules now also include the major
version number. Currently the following pkg-config are generated and
installed.
* winpr1
* freerdp2
* freerdp-server2
* freerdp-client2
* rdtk0
As cmake is able to handle multiple versions out of the box the
following can be used to find a specific module:
find_package(WinPR)
find_package(FreeRDP)
find_package(FreeRDP-Server)
find_package(FreeRDP-Client)
find_package(RdTk)
As cmake doesn't automatically resolve dependencies for packages it is
necessary to manually include the requirements. For example if
FreeRDP-Client is required WinPR and FreeRDP need to be included
(find_package) as well.
This commit also fixes the installation when STATIC_CHANNELS are built.
WITH STATIC_CHANNELS all channels are linked into libfreerdp-client, for
this all channels are generated as linker archive and linked together in
the final step. Before the intermediate linker archives were, although
not required and useful, installed. Same applies for server side
channels.
uClibc variants do not provide the C99 long double math functions like ceill,
powl, etc.. For future compatibility use check_symbol_exists() to check
whether these functions are available, and keep the result in
HAVE_MATH_C99_LONG_DOUBLE. Use that instead of the fragile Cygwin version
check in triodef.h.
Fixes build failures under uClibc(-ng) like:
../../libwinpr/utils/libwinpr-utils.so.0.1.0: undefined reference to `powl'
../../libwinpr/utils/libwinpr-utils.so.0.1.0: undefined reference to `fmodl'
../../libwinpr/utils/libwinpr-utils.so.0.1.0: undefined reference to `ceill'
../../libwinpr/utils/libwinpr-utils.so.0.1.0: undefined reference to `log10l'
../../libwinpr/utils/libwinpr-utils.so.0.1.0: undefined reference to `floorl'
collect2: error: ld returned 1 exit status
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
uClibc master branch, as well as uclibc-ng add eventfd_{read,write}
definitions. Instead of testing for __UCLIBC__, have cmake explicitly check
for the existence of eventfd_read and save the result in
WITH_EVENTFD_READ_WRITE.
Fixes build errors like:
.../winpr/libwinpr/synch/event.c:120:12: error: static declaration of 'eventfd_read' follows non-static declaration
static int eventfd_read(int fd, eventfd_t* value)
^
In file included from .../winpr/libwinpr/synch/event.c:39:0:
.../usr/include/sys/eventfd.h:37:12: note: previous declaration of 'eventfd_read' was here
extern int eventfd_read (int __fd, eventfd_t *__value);
^
.../winpr/libwinpr/synch/event.c:125:12: error: static declaration of 'eventfd_write' follows non-static declaration
static int eventfd_write(int fd, eventfd_t value)
^
In file included from .../winpr/libwinpr/synch/event.c:39:0:
.../usr/include/sys/eventfd.h:40:12: note: previous declaration of 'eventfd_write' was here
extern int eventfd_write (int __fd, eventfd_t __value);
Unlike i386, x32 can't accept -march=i686 but wants -fPIC, same as amd64
(both are x86_64 ABIs after all). Thus, check for the __x86_64__ define
instead of pointer width.
Implement an initial Wayland client, which will build if
the wayland-client development libraries are detected
(or if -DWITH_WAYLAND:BOOL=ON is set). It is currently
view-only, but inputs will be implemented soon.
It uses the software SHM interface, which means it does not
require GL acceleration to run. It should be compatible
with any compositor
Signed-off-by: Manuel Bachmann <tarnyko@tarnyko.net>
"libfreerdp" consisted of multiple (small) single libraries. If the cmake
option MONOLITHIC was used only one library was build combining all of
the libfreerdp-* libraries.
The only exceptions to this are libfreerdp-server and libfreerdp-client these
are build as separate libraries.
This commit obsoltes non-monolithic builds and makes monolithic builds
the default. The cmake option MONOLITHIC is also removed.
winpr is now always build as single library.
The build option MONOLITHIC_BUILD doesn't influence this behavior anymore.
The only exception is winpr-makecert-tool which is still build as extra
library.
This obsoletes complex_libraries for winpr.
select() has the major drawback that it cannot handle file descriptor
that are bigger than 1024. This patch makes use of poll() instead of
select() when poll() support is available.
This patch adds an option to compile freerdp in a valgrind compliant way.
The purpose is to ease memchecking when connecting with TLS. We mark bytes
retrieved from SSL_read() as plainly defined to prevent the undefined contamination.
With the patch and the option activated you get a single warning at connection
during the handshake, and nothing after.
Flags for C and C++ compiler need to be checked seperately since
the c and c++ compiler might not support the same flags (even if
they are the same version).
* generate pkg-config files top level to make sure all
exports are available (eg. client/server)
* .pc libs section is now generated from export libraries
* update .pc file to use .private fields (prevent overlinking)
When building for iphone simulator it is required to set the CMAKE_OSX_SYSROOT
to "iphonesimulator" otherwise command line builds (with cmake --build) will fail.
If a deployment target is set within CMakeLists.txt detection might fail
if CMAKE_OSX_SYSROOT isn't set.
In case no deployment target is specified the latest available SDK is used as
deployment target and sysroot is set accordingly.
An other deployment target can still be set with -DCMAKE_OSX_DEPLOYMENT_TARGET=10.x
when running cmake for the first time or can be overwritten in cmake cache
later on.
10.6 isn't shipped with xcode > 4.4 anymore per default
If older/newer deployment target is required it can be set with
-DCMAKE_OSX_DEPLOYMENT_TARGET=10.x
NOTE: Wayk-client still does not work on 10.6 because of a missing library used by Qt5.
Dyld Error Message:
Library not loaded: /usr/lib/libc++.1.dylib
Referenced from: /Applications/wayk-client.app/Contents/MacOS/../Frameworks/QtCore.framework/Versions/5/QtCore
Reason: image not found
# By Marc-André Moreau
# Via Marc-André Moreau
* 'master' of git://github.com/awakecoding/FreeRDP:
cmake: remove debug output
cmake: add vendor-specific packaging extension point
cmake: fix package generation on Mac OS X