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

Add CI support for macos-14 Apple Silicon #1589

Merged
merged 11 commits into from
Feb 1, 2024
Merged

Add CI support for macos-14 Apple Silicon #1589

merged 11 commits into from
Feb 1, 2024

Conversation

traversaro
Copy link
Member

@traversaro traversaro commented Jan 30, 2024

Fix #1231 .
Fix #916 .

macos-14 is Apple Silicon, see https://github.blog/changelog/2024-01-30-github-actions-introducing-the-new-m1-macos-runner-available-to-open-source/ . I also changed macos-latest to macos-12, as now macos-latest is an alias for macos-12 (see https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories) and it is a bit confusing otherwise

fyi @DanielePucci, that should reduce possible regressions for Apple Silicon users in the future.

@traversaro
Copy link
Member Author

CI fails with:

CMake Error at cmake/YarpFindDependencies.cmake:187 (message):
  Optional package ACE not found.  Please install it or enable the option
  "SKIP_ACE" to build yarp.
Call Stack (most recent call first):
  cmake/YarpFindDependencies.cmake:707 (check_skip_dependency)
  CMakeLists.txt:60 (include)

So #1573 is not working as expected.

@traversaro
Copy link
Member Author

traversaro commented Jan 30, 2024

CI fails with:

CMake Error at cmake/YarpFindDependencies.cmake:187 (message):
  Optional package ACE not found.  Please install it or enable the option
  "SKIP_ACE" to build yarp.
Call Stack (most recent call first):
  cmake/YarpFindDependencies.cmake:707 (check_skip_dependency)
  CMakeLists.txt:60 (include)

So #1573 is not working as expected.

The debug print prints:

2024-01-30T22:04:33.5853280Z -- Fetching YCM.
2024-01-30T22:04:41.1446350Z -- ==========> ROBOTOLOGY_CONFIGURING_UNDER_CONDA: ON
2024-01-30T22:04:41.1486270Z -- ==========> APPLE: 1
2024-01-30T22:04:41.1486880Z -- ==========> CMAKE_SYSTEM_PROCESSOR: x86_64

so I guess we are installing the wrong mambaforge?

@traversaro
Copy link
Member Author

so I guess we are installing the wrong mambaforge?

Indeed we were using an old setup-miniconda release, let's update it to v3 and see it this improves.

@traversaro
Copy link
Member Author

To actually have Apple Silicon CI, for the MATLAB part we need to also add msdk files for Apple Silicon.

@traversaro
Copy link
Member Author

so I guess we are installing the wrong mambaforge?

Indeed we were using an old setup-miniconda release, let's update it to v3 and see it this improves.

Same problem with v3, let's try to directly pass the install file as suggested in conda-incubator/setup-miniconda#312 (comment) .

@traversaro
Copy link
Member Author

First errors in blocktestcore:

2024-01-30T23:02:48.2279580Z [6/95] Building CXX object src/blocktestcore/CMakeFiles/blocktestcore.dir/infoLogger.cpp.o
2024-01-30T23:02:48.2281000Z FAILED: src/blocktestcore/CMakeFiles/blocktestcore.dir/infoLogger.cpp.o 
2024-01-30T23:02:48.2287940Z /Users/runner/miniconda3/envs/test/bin/arm64-apple-darwin20.0.0-clang++ -DBOOST_ATOMIC_DYN_LINK -DBOOST_ATOMIC_NO_LIB -DBOOST_FILESYSTEM_DYN_LINK -DBOOST_FILESYSTEM_NO_LIB -DBOOST_SYSTEM_DYN_LINK -DBOOST_SYSTEM_NO_LIB -Dblocktestcore_EXPORTS -I/Users/runner/work/robotology-superbuild/robotology-superbuild/b/src/blocktestcore/src/blocktestcore/blocktestcore_autogen/include -I/Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore -I/Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/extern/pugixml -ftree-vectorize -fPIC -fstack-protector-strong -O2 -pipe -stdlib=libc++ -fvisibility-inlines-hidden -fmessage-length=0 -isystem /Users/runner/miniconda3/envs/test/include -Wall -Wextra -O3 -DNDEBUG -std=gnu++17 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -fPIC -MD -MT src/blocktestcore/CMakeFiles/blocktestcore.dir/infoLogger.cpp.o -MF src/blocktestcore/CMakeFiles/blocktestcore.dir/infoLogger.cpp.o.d -o src/blocktestcore/CMakeFiles/blocktestcore.dir/infoLogger.cpp.o -c /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.cpp
2024-01-30T23:02:48.2294820Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.cpp:14:
2024-01-30T23:02:48.2296180Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.h:15:
2024-01-30T23:02:48.2297830Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/type.h:16:
2024-01-30T23:02:48.2301670Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2304050Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2305280Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2306410Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2308200Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2310060Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:36:20: error: expected unqualified-id
2024-01-30T23:02:48.2310950Z     auto my_fd = ::dirfd(dir.get());
2024-01-30T23:02:48.2311800Z                    ^
2024-01-30T23:02:48.2313060Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:136:21: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2314240Z #define dirfd(dirp) ({                         \
2024-01-30T23:02:48.2314760Z                     ^
2024-01-30T23:02:48.2324290Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.cpp:14:
2024-01-30T23:02:48.2325840Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.h:15:
2024-01-30T23:02:48.2327520Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/type.h:16:
2024-01-30T23:02:48.2329840Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2330860Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2331820Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2335300Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2336540Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2338250Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:36:20: error: unexpected type name 'DIR': expected expression
2024-01-30T23:02:48.2339900Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:5: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2341250Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2341590Z     ^
2024-01-30T23:02:48.2342370Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.cpp:14:
2024-01-30T23:02:48.2344590Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.h:15:
2024-01-30T23:02:48.2346100Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/type.h:16:
2024-01-30T23:02:48.2347420Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2350080Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2350800Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2351710Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2353270Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2355000Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:36:20: error: use of undeclared identifier '_dirp'
2024-01-30T23:02:48.2356210Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:10: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2357230Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2357810Z          ^
2024-01-30T23:02:48.2359780Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.cpp:14:
2024-01-30T23:02:48.2361310Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.h:15:
2024-01-30T23:02:48.2363210Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/type.h:16:
2024-01-30T23:02:48.2364990Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2366280Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2367010Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2367860Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2370200Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2371350Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:120:24: error: expected unqualified-id
2024-01-30T23:02:48.2375690Z         auto my_fd = ::dirfd(dir);
2024-01-30T23:02:48.2376890Z                        ^
2024-01-30T23:02:48.2378230Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:136:21: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2380120Z #define dirfd(dirp) ({                         \
2024-01-30T23:02:48.2381230Z                     ^
2024-01-30T23:02:48.2382000Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.cpp:14:
2024-01-30T23:02:48.2383660Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.h:15:
2024-01-30T23:02:48.2385550Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/type.h:16:
2024-01-30T23:02:48.2387000Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2390360Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2391380Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2392750Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2394120Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2395810Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:120:24: error: unexpected type name 'DIR': expected expression
2024-01-30T23:02:48.2397040Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:5: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2398100Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2398830Z     ^
2024-01-30T23:02:48.2399510Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.cpp:14:
2024-01-30T23:02:48.2400910Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/infoLogger.h:15:
2024-01-30T23:02:48.2401980Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/type.h:16:
2024-01-30T23:02:48.2403030Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2403870Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2404550Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2405340Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2406110Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2407130Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:120:24: error: use of undeclared identifier '_dirp'
2024-01-30T23:02:48.2408200Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:10: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2408770Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2409090Z          ^
2024-01-30T23:02:48.2409250Z 6 errors generated.
2024-01-30T23:02:48.2409640Z [7/95] Building CXX object src/blocktestcore/CMakeFiles/blocktestcore.dir/clockFacility.cpp.o
2024-01-30T23:02:48.2410220Z FAILED: src/blocktestcore/CMakeFiles/blocktestcore.dir/clockFacility.cpp.o 
2024-01-30T23:02:48.2415620Z /Users/runner/miniconda3/envs/test/bin/arm64-apple-darwin20.0.0-clang++ -DBOOST_ATOMIC_DYN_LINK -DBOOST_ATOMIC_NO_LIB -DBOOST_FILESYSTEM_DYN_LINK -DBOOST_FILESYSTEM_NO_LIB -DBOOST_SYSTEM_DYN_LINK -DBOOST_SYSTEM_NO_LIB -Dblocktestcore_EXPORTS -I/Users/runner/work/robotology-superbuild/robotology-superbuild/b/src/blocktestcore/src/blocktestcore/blocktestcore_autogen/include -I/Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore -I/Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/extern/pugixml -ftree-vectorize -fPIC -fstack-protector-strong -O2 -pipe -stdlib=libc++ -fvisibility-inlines-hidden -fmessage-length=0 -isystem /Users/runner/miniconda3/envs/test/include -Wall -Wextra -O3 -DNDEBUG -std=gnu++17 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -fPIC -MD -MT src/blocktestcore/CMakeFiles/blocktestcore.dir/clockFacility.cpp.o -MF src/blocktestcore/CMakeFiles/blocktestcore.dir/clockFacility.cpp.o.d -o src/blocktestcore/CMakeFiles/blocktestcore.dir/clockFacility.cpp.o -c /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.cpp
2024-01-30T23:02:48.2421060Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.cpp:1:
2024-01-30T23:02:48.2422210Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.h:15:
2024-01-30T23:02:48.2423260Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2424300Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2424930Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2425880Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2426900Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2427970Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:36:20: error: expected unqualified-id
2024-01-30T23:02:48.2428580Z     auto my_fd = ::dirfd(dir.get());
2024-01-30T23:02:48.2428810Z                    ^
2024-01-30T23:02:48.2429360Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:136:21: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2430000Z #define dirfd(dirp) ({                         \
2024-01-30T23:02:48.2430270Z                     ^
2024-01-30T23:02:48.2430990Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.cpp:1:
2024-01-30T23:02:48.2432110Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.h:15:
2024-01-30T23:02:48.2433150Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2433990Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2434680Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2435410Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2436260Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2437270Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:36:20: error: unexpected type name 'DIR': expected expression
2024-01-30T23:02:48.2438430Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:5: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2439010Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2439260Z     ^
2024-01-30T23:02:48.2439920Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.cpp:1:
2024-01-30T23:02:48.2441050Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.h:15:
2024-01-30T23:02:48.2443740Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2444560Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2445200Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2445930Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2446720Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2447740Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:36:20: error: use of undeclared identifier '_dirp'
2024-01-30T23:02:48.2448760Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:10: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2449330Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2449650Z          ^
2024-01-30T23:02:48.2450280Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.cpp:1:
2024-01-30T23:02:48.2451500Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.h:15:
2024-01-30T23:02:48.2452580Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2453500Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2454130Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2454860Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2455650Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2456590Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:120:24: error: expected unqualified-id
2024-01-30T23:02:48.2457260Z         auto my_fd = ::dirfd(dir);
2024-01-30T23:02:48.2457480Z                        ^
2024-01-30T23:02:48.2458030Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:136:21: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2458610Z #define dirfd(dirp) ({                         \
2024-01-30T23:02:48.2458870Z                     ^
2024-01-30T23:02:48.2459520Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.cpp:1:
2024-01-30T23:02:48.2460670Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.h:15:
2024-01-30T23:02:48.2461720Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2462500Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2463140Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2463910Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2464800Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2465840Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:120:24: error: unexpected type name 'DIR': expected expression
2024-01-30T23:02:48.2466900Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:5: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2467540Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2467800Z     ^
2024-01-30T23:02:48.2468470Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.cpp:1:
2024-01-30T23:02:48.2469600Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/clockFacility.h:15:
2024-01-30T23:02:48.2470640Z In file included from /Users/runner/work/robotology-superbuild/robotology-superbuild/src/blocktestcore/src/blocktestcore/general.h:3:
2024-01-30T23:02:48.2471430Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process.hpp:23:
2024-01-30T23:02:48.2472060Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/async.hpp:43:
2024-01-30T23:02:48.2472780Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/async_in.hpp:19:
2024-01-30T23:02:48.2473560Z In file included from /Users/runner/miniconda3/envs/test/include/boost/process/detail/used_handles.hpp:14:
2024-01-30T23:02:48.2474540Z /Users/runner/miniconda3/envs/test/include/boost/process/detail/posix/handles.hpp:120:24: error: use of undeclared identifier '_dirp'
2024-01-30T23:02:48.2475660Z /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/dirent.h:137:10: note: expanded from macro 'dirfd'
2024-01-30T23:02:48.2476250Z     DIR *_dirp = (dirp);                       \
2024-01-30T23:02:48.2476500Z          ^
2024-01-30T23:02:48.2476660Z 6 errors generated.
2024-01-30T23:02:48.2476920Z ninja: build stopped: subcommand failed.

Probably we can disable ROBOTOLOGY_ENABLE_TESTING (for this error) and ROBOTOLOGY_ENABLE_ICUB_HEAD (as it requires ace) for now.

@traversaro
Copy link
Member Author

To actually have Apple Silicon CI, for the MATLAB part we need to also add msdk files for Apple Silicon.

Now we reached an error related to that:

[5/27] Linking CXX shared library lib/libmxpp.0.1.dylib
FAILED: lib/libmxpp.0.1.dylib 
: && /Users/runner/miniconda3/envs/test/bin/arm64-apple-darwin20.0.0-clang++ -ftree-vectorize -fPIC -fstack-protector-strong -O2 -pipe -stdlib=libc++ -fvisibility-inlines-hidden -fmessage-length=0 -isystem /Users/runner/miniconda3/envs/test/include -O3 -DNDEBUG -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -dynamiclib -Wl,-headerpad_max_install_names -Wl,-headerpad_max_install_names -Wl,-dead_strip_dylibs -Wl,-rpath,/Users/runner/miniconda3/envs/test/lib -L/Users/runner/miniconda3/envs/test/lib   -current_version 0.1.0 -o lib/libmxpp.0.1.dylib -install_name @rpath/libmxpp.0.1.dylib deps/mxpp/CMakeFiles/mxpp.dir/src/MxArray.cpp.o  -Wl,-rpath,/Users/runner/work/robotology-superbuild/robotology-superbuild/msdk_R2020a_mexmaci64/bin/maci64  /Users/runner/work/robotology-superbuild/robotology-superbuild/msdk_R2020a_mexmaci64/bin/maci64/libmx.dylib && :
ld: warning: ignoring file /Users/runner/work/robotology-superbuild/robotology-superbuild/msdk_R2020a_mexmaci64/bin/maci64/libmx.dylib, building for macOS-arm64 but attempting to link with file built for macOS-x86_64
Undefined symbols for architecture arm64:
  "_mxArrayToString_800", referenced from:
      mxpp::MxArray::asString(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) in MxArray.cpp.o
  "_mxFree_800", referenced from:
      mxpp::MxArray::asString(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) in MxArray.cpp.o
  "_mxGetCell_800", referenced from:
      mxpp::MxArray::asMxCell(std::__1::vector<std::__1::shared_ptr<mxpp::MxArray>, std::__1::allocator<std::__1::shared_ptr<mxpp::MxArray>>>&) in MxArray.cpp.o
  "_mxGetClassID_800", referenced from:
      mxpp::MxArray::MxArray(mxArray_tag const*, bool) in MxArray.cpp.o
  "_mxGetDimensions_800", referenced from:
      mxpp::MxArray::MxArray(mxArray_tag const*, bool) in MxArray.cpp.o
  "_mxGetFieldByNumber_800", referenced from:
      mxpp::MxArray::asMxStruct(std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::shared_ptr<mxpp::MxArray>, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const, std::__1::shared_ptr<mxpp::MxArray>>>>&) in MxArray.cpp.o
  "_mxGetFieldNameByNumber_800", referenced from:
      mxpp::MxArray::asMxStruct(std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::shared_ptr<mxpp::MxArray>, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const, std::__1::shared_ptr<mxpp::MxArray>>>>&) in MxArray.cpp.o
  "_mxGetM_800", referenced from:
      mxpp::MxArray::MxArray(mxArray_tag const*, bool) in MxArray.cpp.o
  "_mxGetN_800", referenced from:
      mxpp::MxArray::MxArray(mxArray_tag const*, bool) in MxArray.cpp.o
  "_mxGetNumberOfDimensions_800", referenced from:
      mxpp::MxArray::MxArray(mxArray_tag const*, bool) in MxArray.cpp.o
  "_mxGetNumberOfElements_800", referenced from:
      mxpp::MxArray::MxArray(mxArray_tag const*, bool) in MxArray.cpp.o
      mxpp::MxArray::asMxCell(std::__1::vector<std::__1::shared_ptr<mxpp::MxArray>, std::__1::allocator<std::__1::shared_ptr<mxpp::MxArray>>>&) in MxArray.cpp.o
  "_mxGetNumberOfFields_800", referenced from:
      mxpp::MxArray::asMxStruct(std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::shared_ptr<mxpp::MxArray>, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const, std::__1::shared_ptr<mxpp::MxArray>>>>&) in MxArray.cpp.o
  "_mxGetPr_800", referenced from:
      mxpp::MxArray::asVectorDouble(std::__1::vector<double, std::__1::allocator<double>>&) in MxArray.cpp.o
  "_mxGetScalar_800", referenced from:
      mxpp::MxArray::Impl::asScalar(double&) in MxArray.cpp.o
      mxpp::MxArray::asInt(int&) in MxArray.cpp.o
      mxpp::MxArray::asUInt(unsigned int&) in MxArray.cpp.o
      mxpp::MxArray::asInt32(int&) in MxArray.cpp.o
      mxpp::MxArray::asDouble(double&) in MxArray.cpp.o
  "_mxIsComplex_800", referenced from:
      mxpp::MxArray::asVectorDouble(std::__1::vector<double, std::__1::allocator<double>>&) in MxArray.cpp.o
  "_mxIsDouble_800", referenced from:
      mxpp::MxArray::asVectorDouble(std::__1::vector<double, std::__1::allocator<double>>&) in MxArray.cpp.o
  "_mxIsLogicalScalarTrue_800", referenced from:
      mxpp::MxArray::asBool(bool&) in MxArray.cpp.o
  "_mxIsLogicalScalar_800", referenced from:
      mxpp::MxArray::asBool(bool&) in MxArray.cpp.o
  "_mxIsNumeric_800", referenced from:
      mxpp::MxArray::Impl::asScalar(double&) in MxArray.cpp.o
      mxpp::MxArray::asInt(int&) in MxArray.cpp.o
      mxpp::MxArray::asUInt(unsigned int&) in MxArray.cpp.o
      mxpp::MxArray::asInt32(int&) in MxArray.cpp.o
      mxpp::MxArray::asDouble(double&) in MxArray.cpp.o
  "_mxIsScalar_800", referenced from:
      mxpp::MxArray::Impl::asScalar(double&) in MxArray.cpp.o
      mxpp::MxArray::MxArray(mxArray_tag const*, bool) in MxArray.cpp.o
      mxpp::MxArray::asInt(int&) in MxArray.cpp.o
      mxpp::MxArray::asUInt(unsigned int&) in MxArray.cpp.o
      mxpp::MxArray::asInt32(int&) in MxArray.cpp.o
      mxpp::MxArray::asDouble(double&) in MxArray.cpp.o
ld: symbol(s) not found for architecture arm64
clang-16: error: linker command failed with exit code 1 (use -v to see invocation)
[6/27] Building CXX object sources/Core/CMakeFiles/Core.dir/src/Parameter.cpp.o

@traversaro
Copy link
Member Author

Cool, disabling ICUB_HEAD, ROBOT_TESTING and MATLAB the CI on Apple Silicon is successful in ~23 minutes: https://github.com/robotology/robotology-superbuild/actions/runs/7718783179/job/21040755061 .

@traversaro
Copy link
Member Author

ROBOTOLOGY_ENABLE_ICUB_HEAD support is blocked by conda-forge/ace-feedstock#29, while I opened robotology/blocktest#66 to track the problem blocking ROBOTOLOGY_ENABLE_ROBOT_TESTING.

@traversaro
Copy link
Member Author

There are still some CMake failures in finding Matlab, but it seems related to old FindMatlab.cmake files hanging around, see #1044 for the issue tracking that.

@traversaro
Copy link
Member Author

Stable branch passing: https://github.com/robotology/robotology-superbuild/actions/runs/7738402350/job/21099140928?pr=1589 . The Unstable branch is not passing, probably we have a few repo still on devel, it could make sense to just use master on all those low dev repos.

@traversaro
Copy link
Member Author

Finally green, merging.

@traversaro traversaro merged commit 3dac05c into master Feb 1, 2024
34 checks passed
@traversaro traversaro deleted the addmacosm1ci branch February 1, 2024 14:26
@DanielePucci
Copy link
Contributor

Thanks @traversaro, I am sure I will be among those who will benefit from this.

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