Skip to content

Haxe app build failing on hxcpp_zlib during compilation #1215

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

Open
piotrzarzycki21 opened this issue Apr 15, 2025 · 3 comments
Open

Haxe app build failing on hxcpp_zlib during compilation #1215

piotrzarzycki21 opened this issue Apr 15, 2025 · 3 comments

Comments

@piotrzarzycki21
Copy link

I was try to build my Haxe application on Mac OS Sequoia 15.4 and it's failing with following errors. On Mac OS Sequoia 15.1 build is successful.

Compiling group: hxcpp_zlib
xcrun --sdk macosx15.4 clang++ -I/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13 -DSTDC -DHAVE_UNISTD_H -Wno-unknown-warning -Wno-unknown-warning-option -Wno-deprecated-non-prototype -c -fvisibility=hidden -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk -g -I/usr/local/lib/haxe/lib/hxcpp/git/include -DHX_MACOS -arch x86_64 -Wno-parentheses -Wno-null-dereference -Wno-unused-value -Wno-format-extra-args -Wno-overflow -Wno-bool-conversion -DHXCPP_DEBUG -DHXCPP_M64 -DHXCPP_VISIT_ALLOCS(haxe) -DHXCPP_CHECK_POINTER(haxe) -DHXCPP_STACK_TRACE(haxe) -DHXCPP_STACK_LINE(haxe) -DHX_SMART_STRINGS(haxe) -DHXCPP_API_LEVEL=430(haxe) ... tags=[haxe,static]
 - /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.c  []
Error: In file included from /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.c:8:
/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.h:170:11: warning: 'OS_CODE' macro redefined [-Wmacro-redefined]
  170 | #  define OS_CODE 19
      |           ^
/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.h:141:11: note: previous definition is here
  141 | #  define OS_CODE  7
      |           ^
In file included from /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.c:10:
In file included from /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/gzguts.h:21:
In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/stdio.h:61:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/_stdio.h:318:7: error: expected identifier or '('
  318 | FILE    *fdopen(int, const char *) __DARWIN_ALIAS_STARTING(__MAC_10_6, __IPHONE_2_0, __DARWIN_ALIAS(fdopen));
      |          ^
/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.h:147:33: note: expanded from macro 'fdopen'
  147 | #        define fdopen(fd,mode) NULL /* No fdopen() */
      |                                 ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/17/include/__stddef_null.h:26:16: note: expanded from macro 'NULL'
   26 | #define NULL ((void*)0)
      |                ^
In file included from /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.c:10:
In file included from /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/gzguts.h:21:
In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/stdio.h:61:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/_stdio.h:318:7: error: expected ')'
/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.h:147:33: note: expanded from macro 'fdopen'
  147 | #        define fdopen(fd,mode) NULL /* No fdopen() */
      |                                 ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/17/include/__stddef_null.h:26:16: note: expanded from macro 'NULL'
   26 | #define NULL ((void*)0)
      |                ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/_stdio.h:318:7: note: to match this '('
/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.h:147:33: note: expanded from macro 'fdopen'
  147 | #        define fdopen(fd,mode) NULL /* No fdopen() */
      |                                 ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/17/include/__stddef_null.h:26:15: note: expanded from macro 'NULL'
   26 | #define NULL ((void*)0)
      |               ^
In file included from /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.c:10:
In file included from /usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/gzguts.h:21:
In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/stdio.h:61:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/_stdio.h:318:7: error: expected ')'
  318 | FILE    *fdopen(int, const char *) __DARWIN_ALIAS_STARTING(__MAC_10_6, __IPHONE_2_0, __DARWIN_ALIAS(fdopen));
      |          ^
/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.h:147:33: note: expanded from macro 'fdopen'
  147 | #        define fdopen(fd,mode) NULL /* No fdopen() */
      |                                 ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/17/include/__stddef_null.h:26:22: note: expanded from macro 'NULL'
   26 | #define NULL ((void*)0)
      |                      ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/usr/include/_stdio.h:318:7: note: to match this '('
/usr/local/lib/haxe/lib/hxcpp/git/project/thirdparty/zlib-1.2.13/zutil.h:147:33: note: expanded from macro 'fdopen'
  147 | #        define fdopen(fd,mode) NULL /* No fdopen() */
      |                                 ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/17/include/__stddef_null.h:26:14: note: expanded from macro 'NULL'
   26 | #define NULL ((void*)0)
      |              ^
1 warning and 3 errors generated.
@barisyild
Copy link

Lime has similar problem and fixed with following commit: openfl/lime@bc8f9df

@piotrzarzycki21
Copy link
Author

Thanks @barisyild . I have switched my project to Lime develop branch, but it didn't help. I have still the same issue.

@barisyild
Copy link

Thanks @barisyild . I have switched my project to Lime develop branch, but it didn't help. I have still the same issue.

Yeah just fixes lime side, hxcpp is still needs fixed.

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