в общем такое дело, есть приложение(там 2 микросервера с обменом по TPC\IP и модуль ядра который общается с нестандартным железом) которое мы разрабатывали под линукс. возникла нужда перенести его на платформу FreeBSD 10.2(версию честно говоря брали просто посвежее).
сразу повылазила куча граблей и вопросов:
-в нетбинсе 8.2(рабочая среда под которой разрабатывали наше приложение под линукс) терминал ничего не выводит, во время запуска приложения, ни по русски ни по английскии. терминал в нетбинсе настроен под UTF8. если запускать скомпилированное приложение из консоли виртуальной машины - все сообщения отображаются нормально.
-при компиляции модулей приложения ссылки на заголовочные файлы - другие, может можно компилятору указать просто путь на линкусовые заголовочные файлы? для совместимости.
-засада с модулем ядра: при попытке скомпилить образец модуля ядра из руководства разработчика FreeBSD, все компилится, но не устанавливается - говорит версии не совместимы. попытался пересобрать мир и ядро чтобы устранить эту ошибку. не смог - ошибка при компиляции
--------------------------------------------------------------
>>> stage 4.2: building libraries
--------------------------------------------------------------
===> gnu/lib/libssp/libssp_nonshared (obj,depend,all,install)
===> gnu/lib/libgcc (obj,depend,all,install)
===> lib/libcompiler_rt (obj,depend,all,install)
===> gnu/lib/csu (obj,depend,all,install)
===> lib/csu/i386-elf (obj,depend,all,install)
===> lib/libc (obj,depend,all,install)
===> lib/libcompiler_rt (obj,depend,all,install)
===> lib/libc_nonshared (obj,depend,all,install)
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/__iconv.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/__iconv_free_list.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/__iconv_get_list.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconv.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconv_canonicalize.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconv_close.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconv_open.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconv_open_into.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconv_set_relocation_prefix.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconvctl.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
In file included from /usr/src/lib/libc_nonshared/../libc/iconv/iconvlist.c:30:
In file included from /usr/obj/usr/src/tmp/usr/include/iconv.h:38:
In file included from /usr/obj/usr/src/tmp/usr/include/wchar.h:228:
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:91:2: error: #endif without #if
#endif /* _XLOCALE_WCHAR_H */
^
/usr/obj/usr/src/tmp/usr/include/xlocale/_wchar.h:92:2: error: #endif without #if
#endif /* _XLOCALE_H_ */
^
2 errors generated.
mkdep: compile failed
--- .depend ---
*** [.depend] Error code 1
make[4]: stopped in /usr/src/lib/libc_nonshared
1 error
make[4]: stopped in /usr/src/lib/libc_nonshared
--- lib/libc_nonshared__L ---
*** [lib/libc_nonshared__L] Error code 2
make[3]: stopped in /usr/src
A failure has been detected in another branch of the parallel make
make[4]: stopped in /usr/src/gnu/lib/csu
--- gnu/lib/csu__L ---
*** [gnu/lib/csu__L] Error code 2
make[3]: stopped in /usr/src
A failure has been detected in another branch of the parallel make
make[4]: stopped in /usr/src/lib/libc
--- lib/libc__L ---
*** [lib/libc__L] Error code 2
make[3]: stopped in /usr/src
3 errors
make[3]: stopped in /usr/src
--- libraries ---
*** [libraries] Error code 2
make[2]: stopped in /usr/src
1 error
make[2]: stopped in /usr/src
--- _libraries ---
*** [_libraries] Error code 2
make[1]: stopped in /usr/src
1 error
make[1]: stopped in /usr/src
--- buildworld ---
*** [buildworld] Error code 2
make: stopped in /usr/src
1 error
make: stopped in /usr/src
-засада с мейками: в линуксе стандарт gmake а во FreeBSD make. у них разные синтаксисы, можно ли как нибуть сделать что то типа "гибридного" мейк файла, в котором вызовы были обоих мейков возможны?
- если не парится с компиляцией модуля ядра, а взять линуксовый скомпиленный, можно ли его подсунуть Фряхе и каким образом?
ребят сильно ногами не пинайте, первый проект под BSD.
Пользуйтесь спойлером