psemiletov / tea-qt

TEA text editor
https://tea.ourproject.org
GNU General Public License v3.0
88 stars 11 forks source link

Build fails on macOS-12: `spellchecker.h: fatal error: 'uchar.h' file not found` #69

Closed barracuda156 closed 1 month ago

barracuda156 commented 1 month ago
  make: Entering directory `/opt/local/var/macports/build/_Users_runner_work_powerpc-ports_powerpc-ports_ports_editors_tea/tea/work/tea-qt-63.1.0'
  /Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -I/opt/local/include -Os -std=gnu++11  -arch x86_64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=12.0 -Wall -Wextra -fPIC -DVERSION_NUMBER=\"63.1.0\" -DASPELL_ENABLE -DHUNSPELL_ENABLE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -I/opt/local/include/hunspell -I/opt/local/libexec/qt5/lib/QtWidgets.framework/Headers -I/opt/local/libexec/qt5/lib/QtGui.framework/Headers -I/opt/local/libexec/qt5/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/AGL.framework/Headers -I/opt/local/libexec/qt5/mkspecs/macx-clang -F/opt/local/libexec/qt5/lib -o tea.o src/tea.cpp
  /Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -I/opt/local/include -Os -std=gnu++11  -arch x86_64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=12.0 -Wall -Wextra -fPIC -DVERSION_NUMBER=\"63.1.0\" -DASPELL_ENABLE -DHUNSPELL_ENABLE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -I/opt/local/include/hunspell -I/opt/local/libexec/qt5/lib/QtWidgets.framework/Headers -I/opt/local/libexec/qt5/lib/QtGui.framework/Headers -I/opt/local/libexec/qt5/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/AGL.framework/Headers -I/opt/local/libexec/qt5/mkspecs/macx-clang -F/opt/local/libexec/qt5/lib -o main.o src/main.cpp
  /Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -I/opt/local/include -Os -std=gnu++11  -arch x86_64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=12.0 -Wall -Wextra -fPIC -DVERSION_NUMBER=\"63.1.0\" -DASPELL_ENABLE -DHUNSPELL_ENABLE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -I/opt/local/include/hunspell -I/opt/local/libexec/qt5/lib/QtWidgets.framework/Headers -I/opt/local/libexec/qt5/lib/QtGui.framework/Headers -I/opt/local/libexec/qt5/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/AGL.framework/Headers -I/opt/local/libexec/qt5/mkspecs/macx-clang -F/opt/local/libexec/qt5/lib -o todo.o src/todo.cpp
  /Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -I/opt/local/include -Os -std=gnu++11  -arch x86_64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=12.0 -Wall -Wextra -fPIC -DVERSION_NUMBER=\"63.1.0\" -DASPELL_ENABLE -DHUNSPELL_ENABLE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -I/opt/local/include/hunspell -I/opt/local/libexec/qt5/lib/QtWidgets.framework/Headers -I/opt/local/libexec/qt5/lib/QtGui.framework/Headers -I/opt/local/libexec/qt5/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/AGL.framework/Headers -I/opt/local/libexec/qt5/mkspecs/macx-clang -F/opt/local/libexec/qt5/lib -o textproc.o src/textproc.cpp
  /Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -I/opt/local/include -Os -std=gnu++11  -arch x86_64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=12.0 -Wall -Wextra -fPIC -DVERSION_NUMBER=\"63.1.0\" -DASPELL_ENABLE -DHUNSPELL_ENABLE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -I/opt/local/include/hunspell -I/opt/local/libexec/qt5/lib/QtWidgets.framework/Headers -I/opt/local/libexec/qt5/lib/QtGui.framework/Headers -I/opt/local/libexec/qt5/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/AGL.framework/Headers -I/opt/local/libexec/qt5/mkspecs/macx-clang -F/opt/local/libexec/qt5/lib -o libretta_calc.o src/libretta_calc.cpp
  In file included from src/main.cpp:26:
  In file included from src/tea.h:49:
  src/spellchecker.h:38:10: fatal error: 'uchar.h' file not found
  #include <uchar.h>
           ^~~~~~~~~
  1 error generated.
  make: *** [main.o] Error 1
  make: *** Waiting for unfinished jobs....
  In file included from src/tea.cpp:76:
  In file included from src/tea.h:49:
  src/spellchecker.h:38:10: fatal error: 'uchar.h' file not found
  #include <uchar.h>
           ^~~~~~~~~
  1 error generated.
  make: *** [tea.o] Error 1
  make: Leaving directory `/opt/local/var/macports/build/_Users_runner_work_powerpc-ports_powerpc-ports_ports_editors_tea/tea/work/tea-qt-63.1.0'
  Command failed:  cd "/opt/local/var/macports/build/_Users_runner_work_powerpc-ports_powerpc-ports_ports_editors_tea/tea/work/tea-qt-63.1.0" && /usr/bin/make -j4 -w all 
  Exit code: 2
  Error: Failed to build tea: command execution failed
  DEBUG: Error code: CHILDSTATUS 6380 2
  DEBUG: Backtrace: command execution failed
      while executing
  "system {*}$notty {*}$callback {*}$nice $fullcmdstring"
      invoked from within
  "command_exec -callback portprogress::target_progress_callback build"
      (procedure "portbuild::build_main" line 10)
      invoked from within
  "$procedure $targetname"
  Error: See /opt/local/var/macports/logs/_Users_runner_work_powerpc-ports_powerpc-ports_ports_editors_tea/tea/main.log for details.
  Error: Follow https://guide.macports.org/#project.tickets if you believe there is a bug.
  Error: Processing of port tea failed
  Build of 'tea' failed.
barracuda156 commented 1 month ago

Apparently it can just be removed? https://chromium-review.googlesource.com/c/v8/v8/+/4823404

psemiletov commented 1 month ago

No, I just forgot some ifdefs to check it. uchar header is needed on some compiler versions/plaforms, I don't remember now excactly. I'll try to fix soon, thank you!

psemiletov commented 1 month ago

Hmm, on MacOS-12 builds fine. I need to expore it further.

barracuda156 commented 1 month ago

I don’t have it locally, but it failed on CI, which is where I copied the log. Commit is this one: https://github.com/barracuda156/powerpc-ports/commit/b17d4f6a9fbc84c20db7c3382f2ee9f6401300ec (when I am back to laptop, I give a direct link to CI log).

psemiletov commented 1 month ago

Please try the last TEA commit - I think I fixed the issue.

barracuda156 commented 1 month ago

From CI, it worked for macOS 12. Also confirmed that the same builds fine on my 10.6 ppc. Thank you!