Skip to content
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

Installation with scons on MacOS #18

Open
larsgrobe opened this issue Jul 15, 2022 · 3 comments
Open

Installation with scons on MacOS #18

larsgrobe opened this issue Jul 15, 2022 · 3 comments

Comments

@larsgrobe
Copy link

Hi,
I am just making a new attempt to use alta for fitting models to measured BSDF. Unfortunately, I had no success building on my current MacOS Monterey 12.4. My guess is that this is mainly due to some python incompatibilies, but I cannot decipher the error messages. So some observations.

  • I have scons and most dependencies installed via macports. For some reason, ceres is not found (macports installed libceres.a in /opt/local/lib).
  • I have python 3.10 as default, and I run scons --cfg=configs/scons/config-macos-clang.py
  • scons then gives me several warning and finally throws an error (I cut the previous checks):

Checking for C++ header file unsupported/Eigen/LevenbergMarquardt... yes
scons: warning: Calling missing SConscript without error is deprecated.
Transition by adding must_exist=False to SConscript calls.
Missing SConscript 'build/sources/plugins/rational_fitter_eigen/SConscript'
File "/Users/lars/git/alta/sources/plugins/SConscript", line 52, in build_plugin
scons: warning: Ignoring missing SConscript 'build/sources/plugins/rational_fitter_leastsquare/SConscript'
File "/Users/lars/git/alta/sources/plugins/SConscript", line 52, in build_plugin
scons: warning: Ignoring missing SConscript 'build/sources/plugins/rational_fitter_quadprog/SConscript'
File "/Users/lars/git/alta/sources/plugins/SConscript", line 52, in build_plugin
scons: warning: Ignoring missing SConscript 'build/sources/plugins/rational_fitter_parallel/SConscript'
File "/Users/lars/git/alta/sources/plugins/SConscript", line 52, in build_plugin
TypeError: 'NoneType' object is not iterable:
File "/Users/lars/git/alta/SConstruct", line 341:
plugins = alta_sconscript('sources/plugins/SConscript')
File "/Users/lars/git/alta/SConstruct", line 335:
return env.SConscript(script,
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/SCons/Script/SConscript.py", line 597:
return _SConscript(self.fs, *files, **subst_kw)
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/SCons/Script/SConscript.py", line 285:
exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
File "/Users/lars/git/alta/sources/plugins/SConscript", line 78:
a_flat_list_of_targets = list( itertools.chain(*(list(targets))))

@belcour
Copy link
Owner

belcour commented Jul 18, 2022

Hi Lars,

I do not have access to the setup you have unfortunately.
We are slowly moving to CMake for our build system. If you are using the master branch, you can use it to build almost all the library.

Best,
-Laurent

@larsgrobe
Copy link
Author

larsgrobe commented Jun 19, 2023

Hi Laurent,

just a quick update on this. I have been able to build alta with some modifications to the scons configuration. I am using the clang compiler and Eigen3 from macports.
CXX = 'clang++-mp-16'
(...)
EIGEN_INC = ['/opt/local/include/eigen3']
(...)
I compiled flann from a git:
FLANN_INC = ['/Users/lars/git/flann/src/cpp']
FLANN_DIR = ['/Users/lars/git/flann/src/cpp']
FLANN_LIB = ['flann']

I have not been able to get the ceres, nlopt, and ipopt fitters running though. I will check the option to rely on cmake rather than scons, but did not do so yet.

Best, Lars.

@belcour
Copy link
Owner

belcour commented Aug 31, 2023

Thanks for your feedback. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants