koanlogic / klone

KLone is a fully-featured, multiplatform, web application development framework, targeted especially for embedded systems and appliances.
http://koanlogic.com/klone/
Other
146 stars 41 forks source link

not compiled on Debian 8 and linuxmint 18 #4

Open vlpoliakov opened 7 years ago

vlpoliakov commented 7 years ago

wget make file - OK

make:

processing configuration output from cache make -C /home/sysadmin/klone-3.1.0 make[1]: Entering directory '/home/sysadmin/klone-3.1.0' make[2]: Entering directory '/home/sysadmin/klone-3.1.0' make[3]: Entering directory '/home/sysadmin/klone-3.1.0' make[3]: Nothing to be done for 'host-setup-pre'. make[3]: Nothing to be done for 'host-setup'. make[3]: Nothing to be done for 'host-setup-post'. make[3]: Leaving directory '/home/sysadmin/klone-3.1.0' make[2]: Leaving directory '/home/sysadmin/klone-3.1.0' make[2]: Entering directory '/home/sysadmin/klone-3.1.0' make[3]: Entering directory '/home/sysadmin/klone-3.1.0' make[3]: Nothing to be done for 'klone-setup-pre'. ==> setup... make[4]: Entering directory '/home/sysadmin/klone-3.1.0/build/target' make[5]: Entering directory '/home/sysadmin/klone-3.1.0/build/target' make[5]: Nothing to be done for 'fetch-hook-pre'. ==> fetching klone-core-3.1.0 from http://koanlogic.com/klone/klone-core-3.1.0.tar.gz make[5]: Nothing to be done for 'fetch-hook-post'. make[5]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target' make[5]: Entering directory '/home/sysadmin/klone-3.1.0/build/target' make[5]: Nothing to be done for 'unzip-hook-pre'. ==> unzipping klone-core-3.1.0.tar.gz make[5]: Nothing to be done for 'unzip-hook-post'. make[5]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target' make[4]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target' make[4]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/makl' installing shlib file "/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/makl/shlib/linux.mk" installing toolchain file "/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/makl/tc/linux.tc" make[4]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/makl' preprocessing command-line arguments checking for basic required tools setting package name to klone setting version to 3.1.0 checking for header stdint checking for header getopt checking for header unistd checking for header sys_select checking for header sys_wait checking for header sys_dir checking for header sys_socket checking for symbol LOG_PERROR checking for symbol SA_RESTART checking for symbol TCP_NODELAY adding optional lib dependency openssl adding optional lib dependency openssl_psk adding optional lib dependency z adding optional lib dependency cyassl checking for type pid_t checking for tm_gmtoff in struct tm checking for fork() support checking for gcc stack-protector support checking va_list behaviour checking existence of function: syslog checking existence of function: mkstemp checking existence of function: localtime_r checking for inline keyword support compilation failed [wrn] failed check on optional inline keyword support adding optional featx dependency doxygen handling command-line arguments checking dependencies searching for optional lib feature openssl searching for optional lib feature openssl_psk searching for optional lib feature z searching for optional lib feature cyassl [wrn] could not find optional dependency 'cyassl' searching for optional featx feature doxygen [wrn] makl_file_sub(): could not find skin/default/Makefile.in - skipping [wrn] makl_file_sub(): could not find doc/doxy/kl1.doxy.in - skipping processing configuration output from cache make[4]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0' make[5]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/build/libu' ==> processing libu [see /home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/build/libu/party.log for details] ==> configuring libu with args: --prefix=/usr/local --no_docs --compat_1X --libs=/usr/local ==> building libu party.mk:82: recipe for target '.realmake' failed make[5]: [.realmake] Error 2 make[5]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/build/libu' /home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/makl/mk/subdir.mk:40: recipe for target 'build/libu.all' failed make[4]: [build/libu.all] Error 2 make[4]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0' build/mk/klone-app.mk:145: recipe for target 'klone-setup' failed make[3]: [klone-setup] Error 2 make[3]: Leaving directory '/home/sysadmin/klone-3.1.0' target-options.mk:35: recipe for target '.real-klone-setup' failed make[2]: [.real-klone-setup] Error 2 make[2]: Leaving directory '/home/sysadmin/klone-3.1.0' /home/sysadmin/klone-3.1.0/build/makl/mk/target-options.mk:16: recipe for target 'target-options-default' failed make[1]: [target-options-default] Error 1 make[1]: Leaving directory '/home/sysadmin/klone-3.1.0' klapp.mk:67: recipe for target 'all' failed make: [all] Error 2

stewy commented 7 years ago

Hello,

please post also your libu compilation log (/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/build/libu/party.log).

Any other useful system info, such as compiler if you installed a non-default version? Cheers

ps: I just bootstrapped klone successfully on Debian 8.2.

vlpoliakov commented 7 years ago

preprocessing command-line arguments checking for basic required tools setting package name to libu setting version to 2.3.0rc3 adding optional featx dependency doxygen checking for type long double checking for type long long checking for type intmax_t checking for type _Bool checking for type float _Complex checking for type double _Complex checking for type long double _Complex checking for type pid_t checking for type ssize_t checking for type socklen_t checking for type in_addr_t checking for type struct rusage checking for symbol TCP_NODELAY checking for symbol INET_ADDRSTRLEN checking for symbol SO_BROADCAST checking for symbol MAP_FIXED checking existence of function: daemon checking existence of function: setsockopt checking existence of function: getsockopt checking existence of function: getpid checking existence of function: link checking existence of function: unlink checking existence of function: sleep checking existence of function: mkstemps checking existence of function: setenv checking existence of function: mmap checking existence of function: fcntl checking existence of function: sysconf checking existence of function: getpagesize checking existence of function: fnmatch checking existence of function: strtok_r checking existence of function: strsep checking existence of function: strlcpy compilation failed [wrn] failed check on optional function strlcpy checking existence of function: strlcat compilation failed [wrn] failed check on optional function strlcat checking existence of function: strtod checking existence of function: gettimeofday checking existence of function: timegm checking existence of function: syslog checking existence of function: vsyslog checking existence of function: strtoumax checking existence of function: getaddrinfo checking existence of function: uname checking existence of function: fork checking existence of function: wait3 checking existence of function: wait checking existence of function: sigaction checking existence of function: setitimer checking existence of function: isfinite compilation failed [wrn] failed check on optional function isfinite checking for function strerror_r checking for header complex checking for header unistd checking for header stdlib checking for header paths checking for header sysuio checking for header strings checking for header sys_socket checking for header netinet_in checking for header netinet_tcp checking for tm_zone support checking for extern variable optarg checking for extern variable optind checking for inline keyword support handling command-line arguments checking dependencies searching for optional featx feature doxygen checking for type struct sockaddr_in checking for type struct sockaddr_in6 checking for type struct sockaddr_un checking for header netinet_sctp compilation failed [wrn] failed check on optional header HAVE_NETINET_SCTP [wrn] makl_file_sub(): could not find doc/doxy/libu.doxy.in - skipping processing configuration output from cache make[5]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu' make[6]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include' make[7]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include/u' for d in missing toolbox ; do rm -f $d && ln -s ../$d ; done make[7]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include/u' make[7]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include/toolbox' make[7]: Nothing to be done for 'all'. make[7]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include/toolbox' make[7]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include/missing' make[7]: Nothing to be done for 'all'. make[7]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include/missing' make[6]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include' make[6]: Entering directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/srcs' gcc -pipe -pipe -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0 -DHAVE_CONF_H -Dinline -pipe -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0 -DHAVE_CONF_H -Dinline -DHAVE_CONF_H -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include -D_GNU_SOURCE -O2 -c toolbox/memory.c -o toolbox/memory.o gcc -pipe -pipe -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0 -DHAVE_CONF_H -Dinline -pipe -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0 -DHAVE_CONF_H -Dinline -DHAVE_CONF_H -I/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/include -D_GNU_SOURCE -O2 -c toolbox/misc.c -o toolbox/misc.o

:0:8: error: expected identifier or '(' before numeric constant toolbox/misc.c:41:1: note: in expansion of macro 'inline' inline int u_isblank (int c) ^ :0:8: error: expected identifier or '(' before numeric constant toolbox/misc.c:56:1: note: in expansion of macro 'inline' inline int u_isblank_str (const char *s) ^ :0:8: error: expected identifier or '(' before numeric constant toolbox/misc.c:78:1: note: in expansion of macro 'inline' inline int u_isnl (int c) ^ :0:8: error: expected identifier or '(' before numeric constant toolbox/misc.c:203:1: note: in expansion of macro 'inline' inline int u_strlcpy(char *dst, const char *src, size_t size) ^ :0:8: error: expected identifier or '(' before numeric constant toolbox/misc.c:223:1: note: in expansion of macro 'inline' inline int u_strlcat(char *dst, const char *src, size_t size) ^ :0:8: error: expected identifier or '(' before numeric constant toolbox/misc.c:480:1: note: in expansion of macro 'inline' inline void u_use_unused_args (char *dummy, ...) ^ lib.mk:55: recipe for target 'toolbox/misc.o' failed make[6]: *** [toolbox/misc.o] Error 1 make[6]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu/srcs' subdir.mk:40: recipe for target 'srcs.all' failed make[5]: *** [srcs.all] Error 2 make[5]: Leaving directory '/home/sysadmin/klone-3.1.0/build/target/klone-core-3.1.0/libu'
vlpoliakov commented 7 years ago

Dear Sirs!  Hello! 

I made some test on LinuxMint 18.1 (4.4.0-67-generic #88-Ubuntu SMP Wed Mar 8 16:34:45 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux) 

Default gcc version - 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.4)  make project klone 3.1.0  with some errors: 

libu/party.log: :0:8: error: expected identifier or ‘(’ before numeric constanttoolbox/misc.c:41:1: note: in expansion of macro ‘inline’inline int u_isblank (int c) ^ ... ...  

but older versions gcc from repository, 

gcc version 4.7.4 (Ubuntu/Linaro 4.7.4-3ubuntu12)  compile OK! gcc version 4.8.5 (Ubuntu 4.8.5-4ubuntu2)  compile OK! gcc version 4.9.3 (Ubuntu 4.9.3-13ubuntu2)  compile OK! 

brgds,Vladimir 

thomas-fossati commented 7 years ago

Hi Vladimir,

The complete fix is not super trivial, but if you are OK with a quick patch you can try this:

$ mkdir klone && cd klone
$ cat << 'END' > Makefile
KLONE_VERSION = 3.1.0
WEBAPP_DIR = $(CURDIR)/webapp
KLONE_TARGET_PATCH_FILE = $(CURDIR)/klone-core-3.1.0-makl_checkinline.patch
include klapp.mk
klapp.mk: ; wget -O $@ -c http://koanlogic.com/klone/klapp-2.0.0.mk
END
$ cat << 'END' > klone-core-3.1.0-makl_checkinline.patch
diff -Naur klone-core-3.1.0-orig/configure klone-core-3.1.0/configure
--- klone-core-3.1.0-orig/configure 2012-09-05 01:09:59.000000000 +0100
+++ klone-core-3.1.0/configure  2017-03-21 18:32:31.000000000 +0000
@@ -20,7 +20,6 @@
 # MaKL preamble
 . "${MAKL_DIR}"/cf/makl.init
 . build/makl_checkfork
-. build/makl_va_list_by_value
 . build/makl_checkstackp

 # Preprocess arguments
@@ -168,9 +167,6 @@
 # -fstack-protector-all
 makl_checkstackp          0

-# check va_list behaviour
-makl_va_list_by_value
-
 makl_checkfunc          0   "syslog" "" ""
 makl_checkfunc          0   "mkstemp" "" ""
 makl_checkfunc          0   "localtime_r" "" ""
diff -Naur klone-core-3.1.0-orig/makl/cf/helpers/makl_checkinline.sh klone-core-3.1.0/makl/cf/helpers/makl_checkinline.sh
--- klone-core-3.1.0-orig/makl/cf/helpers/makl_checkinline.sh   2012-09-05 01:09:55.000000000 +0100
+++ klone-core-3.1.0/makl/cf/helpers/makl_checkinline.sh    2017-03-21 18:33:31.000000000 +0000
@@ -18,6 +18,7 @@
     makl_info "checking for inline keyword support"

     "${CAT}" << EOF > "${tmpfile}"
+static int _f(void);
 inline int _f(void) { return 0; }
 int main() { return _f(); }
 EOF
END
$ make
vlpoliakov commented 7 years ago

Hi, Thomas!  Your patch is Magic! 

I compiled klone 3.1.0 with default gcc on Linuxmint 18.1 version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.4)!! 

Big thanks!! Vladimir.  

 --  WP