MacOS M1 build failure

37 views
Skip to first unread message

Jaroslaw Kawa

unread,
Oct 10, 2023, 6:39:29 PM10/10/23
to fix8 support
I have installed the most recent POCO Complete edition. bootstrap and configure steps succeed but make runs into the following 

mac ~/Desktop/fix8-1.4.3$ make
/Applications/Xcode.app/Contents/Developer/usr/bin/make  all-recursive
Making all in runtime
/bin/sh ../libtool  --tag=CXX   --mode=compile g++ -DHAVE_CONFIG_H -I. -I..  -I../include   -g -O2 -std=c++11 -Wall -MT xml.lo -MD -MP -MF .deps/xml.Tpo -c -o xml.lo xml.cpp
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I.. -I../include -g -O2 -std=c++11 -Wall -MT xml.lo -MD -MP -MF .deps/xml.Tpo -c xml.cpp  -fno-common -DPIC -o .libs/xml.o
In file included from xml.cpp:38:
In file included from ../include/fix8/f8includes.hpp:78:
In file included from ../include/fix8/mpmc.hpp:53:
In file included from ../include/fix8/ff/allocator.hpp:117:
In file included from ../include/fix8/ff/ubuffer.hpp:73:
In file included from ../include/fix8/ff/dynqueue.hpp:46:
../include/fix8/ff/buffer.hpp:225:13: error: use of undeclared identifier 'WMB'
            WMB();
            ^
../include/fix8/ff/buffer.hpp:257:13: error: use of undeclared identifier 'WMB'
            WMB();
            ^
../include/fix8/ff/buffer.hpp:456:13: error: use of undeclared identifier 'WMB'
            WMB();
            ^
In file included from xml.cpp:38:
In file included from ../include/fix8/f8includes.hpp:78:
In file included from ../include/fix8/mpmc.hpp:53:
In file included from ../include/fix8/ff/allocator.hpp:117:
In file included from ../include/fix8/ff/ubuffer.hpp:73:
In file included from ../include/fix8/ff/dynqueue.hpp:47:
../include/fix8/ff/spin-lock.hpp:61:27: warning: braces around scalar initializer [-Wbraced-scalar-init]
    AtomicFlagWrapper():F(ATOMIC_FLAG_INIT) {}
                          ^~~~~~~~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/atomic:2656:26: note: expanded from macro 'ATOMIC_FLAG_INIT'
#define ATOMIC_FLAG_INIT {false}
                         ^~~~~~~
In file included from xml.cpp:38:
In file included from ../include/fix8/f8includes.hpp:78:
In file included from ../include/fix8/mpmc.hpp:53:
In file included from ../include/fix8/ff/allocator.hpp:117:
In file included from ../include/fix8/ff/ubuffer.hpp:73:
../include/fix8/ff/dynqueue.hpp:168:9: error: use of undeclared identifier 'WMB'
        WMB();
        ^
In file included from xml.cpp:38:
In file included from ../include/fix8/f8includes.hpp:78:
In file included from ../include/fix8/mpmc.hpp:53:
In file included from ../include/fix8/ff/allocator.hpp:120:
../include/fix8/ff/utils.hpp:89:15: error: unknown type name 'ticks'
static inline ticks ticks_wait(ticks nticks) {
              ^
../include/fix8/ff/utils.hpp:89:32: error: unknown type name 'ticks'
static inline ticks ticks_wait(ticks nticks) {
                               ^
../include/fix8/ff/utils.hpp:94:5: error: use of undeclared identifier 'ticks'; did you mean 'nticks'?
    ticks delta;
    ^~~~~
    nticks
../include/fix8/ff/utils.hpp:89:38: note: 'nticks' declared here
static inline ticks ticks_wait(ticks nticks) {
                                     ^
../include/fix8/ff/utils.hpp:94:10: error: expected ';' after expression
    ticks delta;
         ^
         ;
../include/fix8/ff/utils.hpp:94:11: error: use of undeclared identifier 'delta'
    ticks delta;
          ^
../include/fix8/ff/utils.hpp:95:5: error: use of undeclared identifier 'ticks'; did you mean 'nticks'?
    ticks t0 = getticks();
    ^~~~~
    nticks
../include/fix8/ff/utils.hpp:89:38: note: 'nticks' declared here
static inline ticks ticks_wait(ticks nticks) {
                                     ^
../include/fix8/ff/utils.hpp:95:10: error: expected ';' after expression
    ticks t0 = getticks();
         ^
         ;
../include/fix8/ff/utils.hpp:95:11: error: use of undeclared identifier 't0'
    ticks t0 = getticks();
          ^
../include/fix8/ff/utils.hpp:95:16: error: use of undeclared identifier 'getticks'
    ticks t0 = getticks();
               ^
../include/fix8/ff/utils.hpp:96:10: error: use of undeclared identifier 'delta'
    do { delta = (getticks()) - t0; } while (delta < nticks);
         ^
../include/fix8/ff/utils.hpp:96:19: error: use of undeclared identifier 'getticks'
    do { delta = (getticks()) - t0; } while (delta < nticks);
                  ^
../include/fix8/ff/utils.hpp:96:33: error: use of undeclared identifier 't0'
    do { delta = (getticks()) - t0; } while (delta < nticks);
                                ^
../include/fix8/ff/utils.hpp:96:46: error: use of undeclared identifier 'delta'; did you mean 'delete'?
    do { delta = (getticks()) - t0; } while (delta < nticks);
                                             ^~~~~
                                             delete
../include/fix8/ff/utils.hpp:96:52: error: expected expression
    do { delta = (getticks()) - t0; } while (delta < nticks);
                                                   ^
../include/fix8/ff/utils.hpp:97:12: error: use of undeclared identifier 'delta'; did you mean 'delete'?
    return delta-nticks;
           ^~~~~
           delete
fatal error: too many errors emitted, stopping now [-ferror-limit=]
1 warning and 20 errors generated.
make[2]: *** [xml.lo] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

Daniel Egloff

unread,
Jan 17, 2024, 5:27:30 PM1/17/24
to fix8 support
I investigated a bit:

- on ARM M1 it is 64 bit so the compiler directive is __arm64__ but fix8 uses __arm__ to check, if one adds __arm64__ the assembly inline code has several size related warnings, which let me guess it will most likely break
- there is an issue with the __MAC_OS_X_VERSION_MIN_REQUIRED to decide if to use system posix_memalign or override it
- there is an issue in determining where ticks is defined

And some more. So the current code cannot compile as it has several issues which has to be fixed. It requires an update. 
Hoever, looking at the commit history, the project is not really maintained anymore actively. I may be wrong - I hope so :) 

Reply all
Reply to author
Forward
0 new messages