Re: GNUstep core release
Not a regression but I get a lot of no-brainer warnings during compilation of the base package. For example this will create an error during runtime: NSCalendarDate.m:1778:7: warning: using integer absolute value function 'abs' when argument is of floating point type [-Wabsolute-value] a = abs(d - (_seconds_since_ref + offset(_time_zone, self))); ^ NSCalendarDate.m:1778:7: note: use function 'fabs' instead a = abs(d - (_seconds_since_ref + offset(_time_zone, self))); ^~~ fabs abs will treat the result as int and the result will be defective. Another example is: /usr/GNUstep/Local/Library/Headers/objc/runtime.h:195:13: note: expanded from macro 'NO' # define NO ((BOOL)0) AGSOutput.m:2412:14: warning: expression which evaluates to zero treated as a null pointer constant of type 'NSString *' [-Wnon-literal-null-conversion] return NO; Not a problem during runtime but still an ugly warning. Finally I get this warning with the clang 3.7 compiler: In file included from /usr/include/string.h:25: /usr/include/features.h:148:3: warning: _BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE [-W#warnings] # warning _BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE this could be handled with __clang_version__ ___ Gnustep-dev mailing list Gnustep-dev@gnu.org https://lists.gnu.org/mailman/listinfo/gnustep-dev
win32 show-stoppers
During my attempt to build libobjc2 for windows I stumbled over several problems. I still investigate it because I find Objective-C superior to C++ but at the moment I find no other alternative to compile applications on all major systems: 1. Exception unwinding: For windows you need seh support. This is now initial implemented in Clang but still missing in LLVM. The GCC 32Bit unwinding lib was also missing from my (Linux) build. This missing feature was caused by a (now expired) patent issue. 2. MinGW Clang support: MinGW (w64) only supports GCC I could not find help for several compilation problems. Also I don't know if all necessary MinGW patches are now in the clang (repository) trunk. 3. CMake: The host/client cross-compilation rules for Clang are missing. if an experimental fork/branch for gnustep/libobjc2 on win32 x64 would be created I would gladly help you with the port. On 16.12.2014 03:15, Hovik Melikyan wrote: Hello, I'm trying to compile libobjc2 on Windows/MinGW. At the moment I'm stuck on this line in objc_msgSend.x86-32.S: addl $_GLOBAL_OFFSET_TABLE_+(8b-7b), %ebx Clang aborts here with this message: unsupported relocation type (I think it's an assertion). Command line used: clang.exe -DGC_DEBUG -DGNUSTEP -DNO_LEGACY \ -DTYPE_DEPENDENT_DISPATCH -D_BSD_SOURCE=1 \ -D_XOPEN_SOURCE=700 -D__BSD_VISIBLE=1 \ -D__OBJC_RUNTIME_INTERNAL__=1 -Dobjc_EXPORTS -fPIC \ -c objc_msgSend.S with clang 3.5. I think I understand what global offset table is for, but I have no clue why clang's assembly refuses to compile it. Any ideas on how to fix this line to compile and work on MinGW 32? (I'm pretty sure there are a lot more problems ahead with this port. At least the calling convention in this asm file will have to be taken care of, and possibly more. I'm just wondering if anyone has ever had any success with it. I can't find anything apart from some older posts here in 2010 then 2013, with no positive outcome.) Thanks! -- H.M. ___ Gnustep-dev mailing list Gnustep-dev@gnu.org https://lists.gnu.org/mailman/listinfo/gnustep-dev ___ Gnustep-dev mailing list Gnustep-dev@gnu.org https://lists.gnu.org/mailman/listinfo/gnustep-dev
libobjc2/objc_msgSend.S cross-compilation problems
I'm trying to cross-compile libobjc2 revision (38113/head) from a linux 64bit host to a mingw64 / win32 (i686-w64-mingw32) target system. The compilation freezes at following position: [ 30%] Building ASM object CMakeFiles/objc.dir/objc_msgSend.S.obj /usr/local/bin/i686-w64-mingw32-clang -DGC_DEBUG -DGNUSTEP -DNO_LEGACY -DTYPE_DEPENDENT_DISPATCH -D_BSD_SOURCE=1 -D_XOPEN_SOURCE=700 -D__BSD_VISIBLE=1 -D__OBJC_RUNTIME_INTERNAL__=1 -Dobjc_EXPORTS -O2 -g -DNDEBUG -fPIC -o CMakeFiles/objc.dir/objc_msgSend.S.obj -c /home/yousry/Documents/sourceProjects/win32/gnuStep/libobjc2/objc_msgSend.S or verbose: clang version 3.6.0 (219586) Target: i686-w64-windows-gnu Thread model: posix /usr/local/bin/clang-3.6 -cc1 -triple i686-w64-windows-gnu -E -disable-free -disable-llvm-verifier -main-file-name objc_msgSend.S -mrelocation-model pic -pic-level 2 -mthread-model posix -mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases -target-cpu pentium4 -v -g -dwarf-column-info -coverage-file /home/yousry/Documents/sourceProjects/win32/gnuStep/libobjc2/build/CMakeFiles/objc.dir/objc_msgSend.S.obj -nostdsysteminc -nobuiltininc -resource-dir /usr/local/bin/../lib/clang/3.6.0 -isystem /usr/local/bin/../lib/clang/3.6.0/include -isystem /usr/i686-w64-mingw32/include -isystem /usr/i686-w64-mingw32/include/../../../usr/include/c++/4.8.2 -isystem /usr/i686-w64-mingw32/include/../../../usr/include/c++/4.8.2/i686-w64-mingw32 -D _STDIO_S_DEFINED -D GC_DEBUG -D GNUSTEP -D NO_LEGACY -D TYPE_DEPENDENT_DISPATCH -D _BSD_SOURCE=1 -D _XOPEN_SOURCE=700 -D __BSD_VISIBLE=1 -D __OBJC_RUNTIME_INTERNAL__=1 -D objc_EXPORTS -D NDEBUG -O2 -fdebug-compilation-dir /home/yousry/Documents/sourceProjects/win32/gnuStep/libobjc2/build -ferror-limit 19 -fmessage-length 228 -mstackrealign -fno-use-cxa-atexit -fobjc-runtime=gcc -fdiagnostics-show-option -vectorize-loops -vectorize-slp -o /tmp/objc_msgSend-d035ac.s -x assembler-with-cpp /home/yousry/Documents/sourceProjects/win32/gnuStep/libobjc2/objc_msgSend.S clang -cc1 version 3.6.0 based upon LLVM 3.6.0svn default target x86_64-unknown-linux-gnu #include ... search starts here: #include ... search starts here: /usr/local/bin/../lib/clang/3.6.0/include /usr/i686-w64-mingw32/include /usr/i686-w64-mingw32/include/../../../usr/include/c++/4.8.2 /usr/i686-w64-mingw32/include/../../../usr/include/c++/4.8.2/i686-w64-mingw32 End of search list. /usr/local/bin/clang-3.6 -cc1as -triple i686-w64-windows-gnu -filetype obj -main-file-name objc_msgSend.S -target-cpu pentium4 -g -fdebug-compilation-dir /home/yousry/Documents/sourceProjects/win32/gnuStep/libobjc2/build -dwarf-debug-producer clang version 3.6.0 (219586) -o CMakeFiles/objc.dir/objc_msgSend.S.obj /tmp/objc_msgSend-d035ac.s I also tried to use clang 3.5 with the same result. GCC (4.8.2) gives this result: i686-w64-mingw32-gcc -DGC_DEBUG -DGNUSTEP -DNO_LEGACY -DTYPE_DEPENDENT_DISPATCH -D_BSD_SOURCE=1 -D_XOPEN_SOURCE=700 -D__BSD_VISIBLE=1 -D__OBJC_RUNTIME_INTERNAL__=1 -Dobjc_EXPORTS -O2 -g -DNDEBUG -o CMakeFiles/objc.dir/objc_msgSend.S.obj -c /home/barnaby/Documents/sourceProjects/win32/gnuStep/libobjc2/objc_msgSend.S -v Using built-in specs. COLLECT_GCC=i686-w64-mingw32-gcc Target: i686-w64-mingw32 Configured with: ../../src/configure --build=x86_64-linux-gnu --prefix=/usr --includedir='/usr/include' --mandir='/usr/share/man' --infodir='/usr/share/info' --sysconfdir=/etc --localstatedir=/var --libexecdir='/usr/lib/gcc-mingw-w64' --disable-maintainer-mode --disable-dependency-tracking --prefix=/usr --enable-shared --enable-static --disable-multilib --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --libdir=/usr/lib --enable-libstdcxx-time=yes --with-tune=generic --enable-version-specific-runtime-libs --enable-threads=posix --enable-fully-dynamic-string --enable-sjlj-exceptions --enable-libgomp --enable-languages=c,c++,fortran,objc,obj-c++ --enable-lto --with-plugin-ld --target=i686-w64-mingw32 --with-gxx-include-dir=/usr/include/c++/4.8 --with-as=/usr/bin/i686-w64-mingw32-as --with-ld=/usr/bin/i686-w64-mingw32-ld Thread model: posix gcc version 4.8.2 (GCC) COLLECT_GCC_OPTIONS='-D' 'GC_DEBUG' '-D' 'GNUSTEP' '-D' 'NO_LEGACY' '-D' 'TYPE_DEPENDENT_DISPATCH' '-D' '_BSD_SOURCE=1' '-D' '_XOPEN_SOURCE=700' '-D' '__BSD_VISIBLE=1' '-D' '__OBJC_RUNTIME_INTERNAL__=1' '-D' 'objc_EXPORTS' '-O2' '-g' '-D' 'NDEBUG' '-o' 'CMakeFiles/objc.dir/objc_msgSend.S.obj' '-c' '-v' '-mtune=generic' '-march=pentiumpro' /usr/lib/gcc/i686-w64-mingw32/4.8/cc1 -E -lang-asm -quiet -v -D_REENTRANT -D GC_DEBUG -D GNUSTEP -D NO_LEGACY -D TYPE_DEPENDENT_DISPATCH -D _BSD_SOURCE=1 -D _XOPEN_SOURCE=700 -D __BSD_VISIBLE=1 -D __OBJC_RUNTIME_INTERNAL__=1 -D objc_EXPORTS -D NDEBUG /home/barnaby/Documents/sourceProjects/win32/gnuStep/libobjc2/objc_msgSend.S -mtune=generic -march=pentiumpro -g -fworking-directory -O2 -fno-directives-only -o /tmp/ccOBD4ND.s ignoring nonexistent directory