Hi Nicolás,

> I'm writing a CMake build system for BOINC


I'm not familiar with CMake, but please don't try to build BOINC for the Mac 
via UNIX-style make files.  As I have written many times on these email lists, 
I strongly recommend _against_ building BOINC for the Mac using configure / 
make or autotools for a number of reasons, and especially when building BOINC 
Manager.  If you wish to automate the build, please use (or adapt) these two 
scripts (or the scripts they call) which I have provided in the mac_build 
directory:
..../mac_build/setupForBOINC.sh
..../mac_build/BuildMacBOINC.sh

For full instructions on building BOINC for the Mac, including the libraries, 
please see:
..../mac_build/HowToBuildBOINC_XCode.rtf

Some of the reasons for building from these scripts include:

* The Xcode project invoked by ..../mac_build/BuildMacBOINC.sh builds 
"universal binaries" of the libraries which include both 32-bit and 64-bit 
versions.

* It is very important to build WxWidgets for BOINC on the Mac using 
..../mac_build/buildWxMac.sh, which is invoked from 
..../mac_build/setupForBOINC.sh.  This script installs several patches to the 
wxWidgets sources to fix critical bugs.

* The precompiled header source at ..../clientgui/mac/MacGUI.pch sets up a 
number of defines needed by the wxWidgets headers included by BOINC manager 
source files to correctly build the Manager.

* The Xcode project builds the executable utilities setprojectgrp and switcher 
required by the Client to run under BOINC's Sandbox Security.

* The Xcode project builds the executable utility gfx_witcher required by the 
Mac screensaver to run under BOINC's Sandbox Security.

* The Xcode project invokes a number of scripts during the build process that 
are needed to properly build the Manager and for other purposes, including the 
following.

  * It correctly sets the executable bits for the BOINC client.
  * When building the libraries, it copies them into the correct location for 
building the samples (example_app, vboxwrapper, wrapper, etc.)
  * It creates the various plist files with the current version numbers needed 
by the Manager, Mac installer and uninstaller and Mac screen saver.
  * It generates the symbol table files for the Client and Manager.
  * It sets proper ownership and permissions for the Manager to run correctly 
under BOINC's Sandbox Security.
  * It creates files needed by the ..../mac_installer/release_boinc.sh script 
to build the Mac installer.

Any build system needs to take all these things into account.

Cheers,
--Charlie

On Jan 11, 2015, at 8:00 AM, Nicolás Alvarez <[email protected]> wrote:

> Hello boincers,
> 
> I'm writing a CMake build system for BOINC (currently only lib and
> api) and I'm having troubles on Mac. Once I added the Mac-specific
> source files, I get this:
> 
> lib/procinfo_mac.cpp:48:15: error: use of undeclared identifier 'getpid'
> 
> At first I thought I was missing HAVE_UNISTD_H in my config.h, but it
> appears procinfo_mac.cpp isn't including unistd.h at all, so I can't
> figure out how this ever works with either autotools or Xcode... Does
> this currently build for any of you?
> 
> -- 
> Nicolás
> _______________________________________________
> boinc_dev mailing list
> [email protected]
> http://lists.ssl.berkeley.edu/mailman/listinfo/boinc_dev
> To unsubscribe, visit the above URL and
> (near bottom of page) enter your email address.
> 

_______________________________________________
boinc_dev mailing list
[email protected]
http://lists.ssl.berkeley.edu/mailman/listinfo/boinc_dev
To unsubscribe, visit the above URL and
(near bottom of page) enter your email address.

Reply via email to