-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
compiling in OSX #827
Comments
That wiki page is likely to be out of date. I'll have a look and try to help... |
Thanks for the quick reply. I've kept digging, but haven't made much progress. I've also tried to compile with cmake (by running "cmake .. -DCMAKE_BUILD_TYPE=Release"), but this ends with "-- Configuring incomplete, errors occurred!". Here are some the error messages shown: "Imported targets and dependency information not available for Boost version" |
If you want to build Slic3r on OSX with static dependencies, then you need
to compile TBB from https://github.com/wjakob/tbb with CMake and set the
following environment variables:
# Where to find the static Intel Thread Building Blocks library?
export TBB_DIR=where_you_unpacked_it
export TBB_INSTALL_DIR=${TBB_DIR}
# Enforce static linking of Boost libraries
export SLIC3R_STATIC=1
~
…On Thu, Apr 5, 2018 at 8:04 PM, v-mat ***@***.***> wrote:
Thanks for the quick reply. I've kept digging, but haven't made much
progress. I've also tried to compile with cmake (by running "cmake ..
-DCMAKE_BUILD_TYPE=Release"), but this ends with "-- Configuring
incomplete, errors occurred!". Here are some the error messages shown:
"Imported targets and dependency information not available for Boost
version"
"Unable to find the requested Boost libraries."
"Could NOT find TBB (missing: TBB_INCLUDE_DIRS TBB_LIBRARIES)"
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#827 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AFj5I0zLK7VYoL40fT1Jg507O8ITfsP1ks5tlly4gaJpZM4TIr3B>
.
|
If you decide to link dynamically, you may try to get tbb through homebrew,
but frankly I don't remember whether it works. I am just happy our OSX
build server is running until we get fully rid of the Perl stuff. Then we
may finally automate the build process.
…On Thu, Apr 5, 2018 at 8:22 PM, bubnikv . ***@***.***> wrote:
If you want to build Slic3r on OSX with static dependencies, then you need
to compile TBB from https://github.com/wjakob/tbb with CMake and set the
following environment variables:
# Where to find the static Intel Thread Building Blocks library?
export TBB_DIR=where_you_unpacked_it
export TBB_INSTALL_DIR=${TBB_DIR}
# Enforce static linking of Boost libraries
export SLIC3R_STATIC=1
~
On Thu, Apr 5, 2018 at 8:04 PM, v-mat ***@***.***> wrote:
> Thanks for the quick reply. I've kept digging, but haven't made much
> progress. I've also tried to compile with cmake (by running "cmake ..
> -DCMAKE_BUILD_TYPE=Release"), but this ends with "-- Configuring
> incomplete, errors occurred!". Here are some the error messages shown:
>
> "Imported targets and dependency information not available for Boost
> version"
> "Unable to find the requested Boost libraries."
> "Could NOT find TBB (missing: TBB_INCLUDE_DIRS TBB_LIBRARIES)"
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub
> <#827 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AFj5I0zLK7VYoL40fT1Jg507O8ITfsP1ks5tlly4gaJpZM4TIr3B>
> .
>
|
Thanks bubnikv. I'm afraid "export SLIC3R_STATIC=1" didn't help with the BOOST issue, but "cmake .. -DBOOST_ROOT:PATHNAME=~/boost_1_64_0/" seems to have taken care of it. Now I'm running into the following: "Could NOT find TBB (missing: TBB_LIBRARIES) (found version "2017.0")" I actually don't see a /lib under my /tbb, nor in https://github.com/wjakob/tbb... |
I actually don't see a /lib under my /tbb, nor in
https://github.com/wjakob/tbb...
You have to build tbb first.
…On Thu, Apr 5, 2018 at 10:40 PM, v-mat ***@***.***> wrote:
Thanks bubnikv. I'm afraid "export SLIC3R_STATIC=1" didn't help with the
BOOST issue, but "cmake .. -DBOOST_ROOT:PATHNAME=~/boost_1_64_0/" seems
to have taken care of it.
Now I'm running into the following:
"Could NOT find TBB (missing: TBB_LIBRARIES) (found version "2017.0")"
I actually don't see a /lib under my /tbb, nor in
https://github.com/wjakob/tbb...
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#827 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AFj5I-VnwOyITU5qtIOXd8a8RgJ4lIWAks5tloE5gaJpZM4TIr3B>
.
|
Oops, you're right. I've just built it with brew (couldn't find how to with cmake) and set the environment variables as you said above. I'm still running into the same error though, i.e.: "Could NOT find TBB (missing: TBB_LIBRARIES) (found version "2018.0")" If I do have to compile with cmake, could you please share how? |
To build tbb statically, just
unpack https://github.com/wjakob/tbb
go to the tbb directory
create a build directory
change to the build directory
run
cmake .. -DTBB_BUILD_SHARED=OFF -DTBB_BUILD_TESTS=OFF
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
That should be all to it.
…On Fri, Apr 6, 2018 at 12:00 AM, v-mat ***@***.***> wrote:
Oops, you're right. I've just built it with brew (couldn't find how to
with cmake) and set the environment variables as you said above. I'm still
running into the same error though, i.e.:
"Could NOT find TBB (missing: TBB_LIBRARIES) (found version "2018.0")"
If I do have to compile with cmake, could you please share how?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#827 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AFj5I6xnvWPODxH6btUjoRvaUCq1kMlRks5tlpPogaJpZM4TIr3B>
.
|
Any progress on your compilation efforts? |
Thanks for asking. I did managed to build tbb as per your previous post and I can run cmake without any errors, but I still get the same original error message when invoking "perl slic3d.pl" (full error message below): <<< |
What will It seems like you are still linking tbb dynamically, so there is inconsistent linkage for some reason. |
otool -L ~/slic3r/Slic3r/local-lib/lib/perl5/darwin-thread-multi-2level/auto/Slic3r/XS/XS.bundle prints this: Any change you could provide me with a TBB binary dist pre-compiled for static linking? My OS is OSX 10.12. |
Unfortunately that gave me no hint. It looks that this XS.bundle was
compiled with static TBB.
Any change you could provide me with a TBB binary dist pre-compiled for
static linking? My OS is OSX 10.12.
I don't think that is the problem. More likely you have mixed up multiple
versions of Slic3r or TBB on your system.
…On Mon, May 14, 2018 at 10:57 PM, v-mat ***@***.***> wrote:
otool -L ~/slic3r/Slic3r/local-lib/lib/perl5/darwin-thread-multi-
2level/auto/Slic3r/XS/XS.bundle prints this:
<<<<
local-lib/lib/perl5/darwin-thread-multi-2level/auto/Slic3r/XS/XS.bundle:
/System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL
(compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit
(compatibility version 1.0.0, current version 275.0.0)
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
(compatibility version 150.0.0, current version 1349.92.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version
307.5.0)
/usr/local/opt/wxmac/lib/libwx_baseu-3.0.dylib (compatibility version
5.0.0, current version 5.0.0)
/usr/local/opt/wxmac/lib/libwx_osx_cocoau_core-3.0.dylib (compatibility
version 5.0.0, current version 5.0.0)
/usr/local/opt/wxmac/lib/libwx_osx_cocoau_adv-3.0.dylib (compatibility
version 5.0.0, current version 5.0.0)
/usr/lib/libcurl.4.dylib (compatibility version 7.0.0, current version
9.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version
1238.60.2)
Any change you could provide me with a TBB binary dist pre-compiled for
static linking? My OS is OSX 10.12.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#827 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AFj5Iw7h5j8h5NlLhnXRc2TbEHOLPAeqks5tye_CgaJpZM4TIr3B>
.
|
I followed the given instructions, although they were somewhat fragmented. I do appreciate you trying to help. I look forward to the updated wiki for OSX. |
I, too, am trying to build on MacOS. I got boost resolved by building it locally but I cannot get TBB to be recognized at all. I cloned tbb from github and built it which seemed to go OK. I do get the three libtbb _static.a files built. I get
I have set the environment variables correctly I think: I could just wait for Monday when the RC will get updated but I have a project I'd like to do over the weekend. |
@vojtechkral is polishing a build description for 1.42 PE. Closing this old issue discussing the Perl based build system. |
Version
1.38.5 and 1.39.1
Operating system type + version
OSX 10.12.6
Behavior
Have been trying to compile slic3d with no luck. Following instructions on:
https://github.com/slic3r/Slic3r/wiki/Running-Slic3r-from-git-on-OS-X
Getting stuck at "BOOST_DIR=~/boost_1_64_0 SLIC3R_STATIC=1 perl Build.PL". This seems to run fine, but when I invoke "perl slic3d.pl", I'm getting this message:
"Can't locate Slic3r/XS.pm in @inc (you may need to install the Slic3r::XS module) (@inc contains: ..."
I saw the updated instruction "How to build - Windows.md" under /doc of the 1.39.1 (mentioned in #781), but not for OSX..
Any help would be appreciated.
The text was updated successfully, but these errors were encountered: