Ola a todos, tengo un problema compilando mod_harbour.v2 on two operating system.
En el Ubuntu 64 22.04 lts tengo este error
hbmk2: Compilazione del sotto-progetto (livello 2): libmhapache.hbp
hbmk2: Creating dynamic library... output/linux/liblibmhapache.so
hbmk2: Dynamic lib link command:
gcc -shared -o output/linux/liblibmhapache.so 'output/linux/.hbmk/linux/gcc/hbdyn/mh_apache.o' 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func.o' output/linux/.hbmk/linux/gcc/hbdyn/cookies.o 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func.o' output/linux/.hbmk/linux/gcc/hbdyn/main.o output/linux/.hbmk/linux/gcc/hbdyn/persistence.o output/linux/.hbmk/linux/gcc/hbdyn/prepro.o output/linux/.hbmk/linux/gcc/hbdyn/preproPHP.o output/linux/.hbmk/linux/gcc/hbdyn/trace.o output/linux/.hbmk/linux/gcc/hbdyn/errorsys.o output/linux/.hbmk/linux/gcc/hbdyn/sessions.o 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func_c.o' 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func_c.o' @libs.txt -Wl,--start-group -lhbextern -lhbdebug -lhbvmmt -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgttrm -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lm -lpthread -ldl -lrt -lpcre -lz -lgpm -Wl,--end-group -L/usr/local/lib/harbour
/usr/bin/ld: /usr/local/lib/harbour/libhbvmmt.a(hvmall.o): relocation R_X86_64_TPOFF32 against `hb_stack_ptr' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: failed to set dynamic section sizes: bad value
collect2: error: ld returned 1 exit status
hbmk2[libmhapache]: Error: Running dynamic lib link command. 1
gcc -shared -o output/linux/liblibmhapache.so 'output/linux/.hbmk/linux/gcc/hbdyn/mh_apache.o' 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func.o' output/linux/.hbmk/linux/gcc/hbdyn/cookies.o 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func.o' output/linux/.hbmk/linux/gcc/hbdyn/main.o output/linux/.hbmk/linux/gcc/hbdyn/persistence.o output/linux/.hbmk/linux/gcc/hbdyn/prepro.o output/linux/.hbmk/linux/gcc/hbdyn/preproPHP.o output/linux/.hbmk/linux/gcc/hbdyn/trace.o output/linux/.hbmk/linux/gcc/hbdyn/errorsys.o output/linux/.hbmk/linux/gcc/hbdyn/sessions.o 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func_c.o' 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func_c.o' @libs.txt -Wl,--start-group -lhbextern -lhbdebug -lhbvmmt -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgttrm -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lm -lpthread -ldl -lrt -lpcre -lz -lgpm -Wl,--end-group -L/usr/local/lib/harbour
el mismo problema lo tengo con freebsd 13.0 con el compilador clang
alguien tiene una solucion a este problema ?
saludos
problem generating mod-harbour.v2 on nix
-
- Mensajes: 8
- Registered for: 3 years 1 month
-
- Mensajes: 42
- Registered for: 3 years 1 month
Hi, your harbour core and contribs must be built with ...
export HB_USER_CFLAGS="-fPIC"
Diego.
export HB_USER_CFLAGS="-fPIC"
Diego.
nikko1960 escribió: ↑Jue May 19, 2022 9:59 am Ola a todos, tengo un problema compilando mod_harbour.v2 on two operating system.
En el Ubuntu 64 22.04 lts tengo este error
hbmk2: Compilazione del sotto-progetto (livello 2): libmhapache.hbp
hbmk2: Creating dynamic library... output/linux/liblibmhapache.so
hbmk2: Dynamic lib link command:
gcc -shared -o output/linux/liblibmhapache.so 'output/linux/.hbmk/linux/gcc/hbdyn/mh_apache.o' 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func.o' output/linux/.hbmk/linux/gcc/hbdyn/cookies.o 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func.o' output/linux/.hbmk/linux/gcc/hbdyn/main.o output/linux/.hbmk/linux/gcc/hbdyn/persistence.o output/linux/.hbmk/linux/gcc/hbdyn/prepro.o output/linux/.hbmk/linux/gcc/hbdyn/preproPHP.o output/linux/.hbmk/linux/gcc/hbdyn/trace.o output/linux/.hbmk/linux/gcc/hbdyn/errorsys.o output/linux/.hbmk/linux/gcc/hbdyn/sessions.o 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func_c.o' 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func_c.o' @libs.txt -Wl,--start-group -lhbextern -lhbdebug -lhbvmmt -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgttrm -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lm -lpthread -ldl -lrt -lpcre -lz -lgpm -Wl,--end-group -L/usr/local/lib/harbour
/usr/bin/ld: /usr/local/lib/harbour/libhbvmmt.a(hvmall.o): relocation R_X86_64_TPOFF32 against `hb_stack_ptr' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: failed to set dynamic section sizes: bad value
collect2: error: ld returned 1 exit status
hbmk2[libmhapache]: Error: Running dynamic lib link command. 1
gcc -shared -o output/linux/liblibmhapache.so 'output/linux/.hbmk/linux/gcc/hbdyn/mh_apache.o' 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func.o' output/linux/.hbmk/linux/gcc/hbdyn/cookies.o 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func.o' output/linux/.hbmk/linux/gcc/hbdyn/main.o output/linux/.hbmk/linux/gcc/hbdyn/persistence.o output/linux/.hbmk/linux/gcc/hbdyn/prepro.o output/linux/.hbmk/linux/gcc/hbdyn/preproPHP.o output/linux/.hbmk/linux/gcc/hbdyn/trace.o output/linux/.hbmk/linux/gcc/hbdyn/errorsys.o output/linux/.hbmk/linux/gcc/hbdyn/sessions.o 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func_c.o' 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func_c.o' @libs.txt -Wl,--start-group -lhbextern -lhbdebug -lhbvmmt -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgttrm -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lm -lpthread -ldl -lrt -lpcre -lz -lgpm -Wl,--end-group -L/usr/local/lib/harbour
el mismo problema lo tengo con freebsd 13.0 con el compilador clang
alguien tiene una solucion a este problema ?
saludos
-
- Mensajes: 8
- Registered for: 3 years 1 month
Gracias Diego por tu informacion.
todavia no lo he compilado en ubuntu, porque el sistema esta trabajando por otro servicio.
En freebsd, el compilador me informa que hay un error en la funcion void function 'mod_harbourV2_child_init en source mod_harbour.c
esto es el error :
../../../../source/mod_harbour.c:223:10: error: void function 'mod_harbourV2_child_init' should not return a value [-Wreturn-type]
return HTTP_INTERNAL_SERVER_ERROR;
y por lo poco que conosco el lenguaje C, corectamente una funcion con la declaracion void no debe revolver algun valor.
gracis de todo.
todavia no lo he compilado en ubuntu, porque el sistema esta trabajando por otro servicio.
En freebsd, el compilador me informa que hay un error en la funcion void function 'mod_harbourV2_child_init en source mod_harbour.c
esto es el error :
../../../../source/mod_harbour.c:223:10: error: void function 'mod_harbourV2_child_init' should not return a value [-Wreturn-type]
return HTTP_INTERNAL_SERVER_ERROR;
y por lo poco que conosco el lenguaje C, corectamente una funcion con la declaracion void no debe revolver algun valor.
gracis de todo.
-
- Mensajes: 8
- Registered for: 3 years 1 month
bueno
finalmente he conmpilado mod_harbour.v2 en linux ubuntu 22.04 lts
por salir del problema he incluido estas lineas el el mod_harbour.v.2.1.hbp
-i/usr/include/apache2
-i/usr/include/apr-1.0
esta es la lista de la compilacion
hbmk2 mod_harbour.v2.1.hbp
hbmk2: Compilazione del sotto-progetto (livello 2): libmhapache.hbp
hbmk2: Creating dynamic library... output/linux/liblibmhapache.so
hbmk2: Dynamic lib link command:
gcc -shared -o output/linux/liblibmhapache.so 'output/linux/.hbmk/linux/gcc/hbdyn/mh_apache.o' 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func.o' output/linux/.hbmk/linux/gcc/hbdyn/cookies.o 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func.o' output/linux/.hbmk/linux/gcc/hbdyn/main.o output/linux/.hbmk/linux/gcc/hbdyn/persistence.o output/linux/.hbmk/linux/gcc/hbdyn/prepro.o output/linux/.hbmk/linux/gcc/hbdyn/preproPHP.o output/linux/.hbmk/linux/gcc/hbdyn/trace.o output/linux/.hbmk/linux/gcc/hbdyn/errorsys.o output/linux/.hbmk/linux/gcc/hbdyn/sessions.o 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func_c.o' 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func_c.o' @libs.txt -Wl,--start-group -lhbextern -lhbdebug -lhbvmmt -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgttrm -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lm -lpthread -ldl -lrt -lpcre -lz -lgpm -Wl,--end-group -L/usr/local/lib/harbour
hbmk2: Compilazione in corso...
hbmk2: 'cd' su: output/linux/.hbmk/linux/gcc/hbdyn
hbmk2: Comando del compilatore C/C++:
gcc -c -O3 -TC -W -Wall -pipe -fPIC -DHB_DYNLIB -I/usr/local/include/harbour -I/usr/include/apache2 -I'/usr/include/apr-1.0' '../../../../../../source/mod_harbour.c'
../../../../../../source/mod_harbour.c: In function ‘shm_cleanup_wrapper’:
../../../../../../source/mod_harbour.c:65:47: warning: unused parameter ‘unused’ [-Wunused-parameter]
65 | static apr_status_t shm_cleanup_wrapper(void *unused)
| ~~~~~~^~~~~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_pre_config’:
../../../../../../source/mod_harbour.c:99:68: warning: unused parameter ‘plog’ [-Wunused-parameter]
99 | static int mod_harbourV2_pre_config(apr_pool_t *pconf, apr_pool_t *plog,
| ~~~~~~~~~~~~^~~~
../../../../../../source/mod_harbour.c49: warning: unused parameter ‘ptemp’ [-Wunused-parameter]
100 | apr_pool_t *ptemp)
| ~~~~~~~~~~~~^~~~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_post_config’:
../../../../../../source/mod_harbour.c:108:69: warning: unused parameter ‘plog’ [-Wunused-parameter]
108 | static int mod_harbourV2_post_config(apr_pool_t *pconf, apr_pool_t *plog,
| ~~~~~~~~~~~~^~~~
../../../../../../source/mod_harbour.c:109:50: warning: unused parameter ‘ptemp’ [-Wunused-parameter]
109 | apr_pool_t *ptemp, server_rec *s)
| ~~~~~~~~~~~~^~~~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_child_init’:
../../../../../../source/mod_harbour.c:201:26: warning: comparison between pointer and integer
201 | if (mh_config.mh_nVms == NULL)
| ^~
In file included from ../../../../../../source/mod_harbour.c:7:
/usr/local/include/harbour/httpd.h:534:46: warning: ‘return’ with a value, in function returning void [-Wreturn-type]
534 | #define HTTP_INTERNAL_SERVER_ERROR 500
| ^~~
../../../../../../source/mod_harbour.c:223:17: note: in expansion of macro ‘HTTP_INTERNAL_SERVER_ERROR’
223 | return HTTP_INTERNAL_SERVER_ERROR;
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
../../../../../../source/mod_harbour.c:171:13: note: declared here
171 | static void mod_harbourV2_child_init(apr_pool_t *p, server_rec *s)
| ^~~~~~~~~~~~~~~~~~~~~~~~
../../../../../../source/mod_harbour.c: In function ‘mh_lib_set_path’:
../../../../../../source/mod_harbour.c:235:25: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
235 | mh_config.mh_library = arg;
| ^
../../../../../../source/mod_harbour.c:233:47: warning: unused parameter ‘cmd’ [-Wunused-parameter]
233 | static const char *mh_lib_set_path(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~~~~~~^~~
../../../../../../source/mod_harbour.c:233:58: warning: unused parameter ‘cfg’ [-Wunused-parameter]
233 | static const char *mh_lib_set_path(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~^~~
../../../../../../source/mod_harbour.c: In function ‘mh_lib_set_nvms’:
../../../../../../source/mod_harbour.c:241:47: warning: unused parameter ‘cmd’ [-Wunused-parameter]
241 | static const char *mh_lib_set_nvms(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~~~~~~^~~
../../../../../../source/mod_harbour.c:241:58: warning: unused parameter ‘cfg’ [-Wunused-parameter]
241 | static const char *mh_lib_set_nvms(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~^~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_register_hooks’:
../../../../../../source/mod_harbour.c:351:54: warning: unused parameter ‘p’ [-Wunused-parameter]
351 | static void mod_harbourV2_register_hooks(apr_pool_t *p)
| ~~~~~~~~~~~~^
../../../../../../source/mod_harbour.c: At top level:
../../../../../../source/mod_harbour.c:368:5: warning: missing initializer for field ‘flags’ of ‘module’ {aka ‘struct module_struct’} [-Wmissing-field-initializers]
368 | mod_harbourV2_register_hooks};
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../../../../../../source/mod_harbour.c:8:
/usr/include/apache2/http_config.h:420:9: note: ‘flags’ declared here
420 | int flags;
| ^~~~~
hbmk2: 'cd' indietro.
hbmk2: Creating dynamic library... output/linux/libmod_harbour.v2.so
hbmk2: Dynamic lib link command:
gcc -shared -o 'output/linux/libmod_harbour.v2.so' 'output/linux/.hbmk/linux/gcc/hbdyn/mod_harbour.o' -Wl,--start-group -Wl,--end-group -L/usr/local/lib/harbour
y esto es ele resultado
nikko@nikko-ThinkCentre-M900:/opt/harbour/contrib/mod_harbour.v2$ ls output/linux -l
totale 4930
-rwxrwxr-x 1 nikko nikko 9089776 mag 21 11:27 liblibmhapache.so
-rwxrwxr-x 1 nikko nikko 22544 mag 21 11:27 libmod_harbour.v2.so
parece que el gcc sea mas acomodante del clang por el tipo de funcion void, tambien si lo evidencia en la compilacion
consejo la modifica del mod_harbour.v2.1.hbp con las istruciones de arriba
desde ahora en adelante busco de pruebar el mo_harbour.
saludos desde italia
finalmente he conmpilado mod_harbour.v2 en linux ubuntu 22.04 lts
por salir del problema he incluido estas lineas el el mod_harbour.v.2.1.hbp
-i/usr/include/apache2
-i/usr/include/apr-1.0
esta es la lista de la compilacion
hbmk2 mod_harbour.v2.1.hbp
hbmk2: Compilazione del sotto-progetto (livello 2): libmhapache.hbp
hbmk2: Creating dynamic library... output/linux/liblibmhapache.so
hbmk2: Dynamic lib link command:
gcc -shared -o output/linux/liblibmhapache.so 'output/linux/.hbmk/linux/gcc/hbdyn/mh_apache.o' 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func.o' output/linux/.hbmk/linux/gcc/hbdyn/cookies.o 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func.o' output/linux/.hbmk/linux/gcc/hbdyn/main.o output/linux/.hbmk/linux/gcc/hbdyn/persistence.o output/linux/.hbmk/linux/gcc/hbdyn/prepro.o output/linux/.hbmk/linux/gcc/hbdyn/preproPHP.o output/linux/.hbmk/linux/gcc/hbdyn/trace.o output/linux/.hbmk/linux/gcc/hbdyn/errorsys.o output/linux/.hbmk/linux/gcc/hbdyn/sessions.o 'output/linux/.hbmk/linux/gcc/hbdyn/ap_func_c.o' 'output/linux/.hbmk/linux/gcc/hbdyn/legacy_func_c.o' @libs.txt -Wl,--start-group -lhbextern -lhbdebug -lhbvmmt -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgttrm -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lm -lpthread -ldl -lrt -lpcre -lz -lgpm -Wl,--end-group -L/usr/local/lib/harbour
hbmk2: Compilazione in corso...
hbmk2: 'cd' su: output/linux/.hbmk/linux/gcc/hbdyn
hbmk2: Comando del compilatore C/C++:
gcc -c -O3 -TC -W -Wall -pipe -fPIC -DHB_DYNLIB -I/usr/local/include/harbour -I/usr/include/apache2 -I'/usr/include/apr-1.0' '../../../../../../source/mod_harbour.c'
../../../../../../source/mod_harbour.c: In function ‘shm_cleanup_wrapper’:
../../../../../../source/mod_harbour.c:65:47: warning: unused parameter ‘unused’ [-Wunused-parameter]
65 | static apr_status_t shm_cleanup_wrapper(void *unused)
| ~~~~~~^~~~~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_pre_config’:
../../../../../../source/mod_harbour.c:99:68: warning: unused parameter ‘plog’ [-Wunused-parameter]
99 | static int mod_harbourV2_pre_config(apr_pool_t *pconf, apr_pool_t *plog,
| ~~~~~~~~~~~~^~~~
../../../../../../source/mod_harbour.c49: warning: unused parameter ‘ptemp’ [-Wunused-parameter]
100 | apr_pool_t *ptemp)
| ~~~~~~~~~~~~^~~~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_post_config’:
../../../../../../source/mod_harbour.c:108:69: warning: unused parameter ‘plog’ [-Wunused-parameter]
108 | static int mod_harbourV2_post_config(apr_pool_t *pconf, apr_pool_t *plog,
| ~~~~~~~~~~~~^~~~
../../../../../../source/mod_harbour.c:109:50: warning: unused parameter ‘ptemp’ [-Wunused-parameter]
109 | apr_pool_t *ptemp, server_rec *s)
| ~~~~~~~~~~~~^~~~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_child_init’:
../../../../../../source/mod_harbour.c:201:26: warning: comparison between pointer and integer
201 | if (mh_config.mh_nVms == NULL)
| ^~
In file included from ../../../../../../source/mod_harbour.c:7:
/usr/local/include/harbour/httpd.h:534:46: warning: ‘return’ with a value, in function returning void [-Wreturn-type]
534 | #define HTTP_INTERNAL_SERVER_ERROR 500
| ^~~
../../../../../../source/mod_harbour.c:223:17: note: in expansion of macro ‘HTTP_INTERNAL_SERVER_ERROR’
223 | return HTTP_INTERNAL_SERVER_ERROR;
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
../../../../../../source/mod_harbour.c:171:13: note: declared here
171 | static void mod_harbourV2_child_init(apr_pool_t *p, server_rec *s)
| ^~~~~~~~~~~~~~~~~~~~~~~~
../../../../../../source/mod_harbour.c: In function ‘mh_lib_set_path’:
../../../../../../source/mod_harbour.c:235:25: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
235 | mh_config.mh_library = arg;
| ^
../../../../../../source/mod_harbour.c:233:47: warning: unused parameter ‘cmd’ [-Wunused-parameter]
233 | static const char *mh_lib_set_path(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~~~~~~^~~
../../../../../../source/mod_harbour.c:233:58: warning: unused parameter ‘cfg’ [-Wunused-parameter]
233 | static const char *mh_lib_set_path(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~^~~
../../../../../../source/mod_harbour.c: In function ‘mh_lib_set_nvms’:
../../../../../../source/mod_harbour.c:241:47: warning: unused parameter ‘cmd’ [-Wunused-parameter]
241 | static const char *mh_lib_set_nvms(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~~~~~~^~~
../../../../../../source/mod_harbour.c:241:58: warning: unused parameter ‘cfg’ [-Wunused-parameter]
241 | static const char *mh_lib_set_nvms(cmd_parms *cmd, void *cfg, const char *arg)
| ~~~~~~^~~
../../../../../../source/mod_harbour.c: In function ‘mod_harbourV2_register_hooks’:
../../../../../../source/mod_harbour.c:351:54: warning: unused parameter ‘p’ [-Wunused-parameter]
351 | static void mod_harbourV2_register_hooks(apr_pool_t *p)
| ~~~~~~~~~~~~^
../../../../../../source/mod_harbour.c: At top level:
../../../../../../source/mod_harbour.c:368:5: warning: missing initializer for field ‘flags’ of ‘module’ {aka ‘struct module_struct’} [-Wmissing-field-initializers]
368 | mod_harbourV2_register_hooks};
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../../../../../../source/mod_harbour.c:8:
/usr/include/apache2/http_config.h:420:9: note: ‘flags’ declared here
420 | int flags;
| ^~~~~
hbmk2: 'cd' indietro.
hbmk2: Creating dynamic library... output/linux/libmod_harbour.v2.so
hbmk2: Dynamic lib link command:
gcc -shared -o 'output/linux/libmod_harbour.v2.so' 'output/linux/.hbmk/linux/gcc/hbdyn/mod_harbour.o' -Wl,--start-group -Wl,--end-group -L/usr/local/lib/harbour
y esto es ele resultado
nikko@nikko-ThinkCentre-M900:/opt/harbour/contrib/mod_harbour.v2$ ls output/linux -l
totale 4930
-rwxrwxr-x 1 nikko nikko 9089776 mag 21 11:27 liblibmhapache.so
-rwxrwxr-x 1 nikko nikko 22544 mag 21 11:27 libmod_harbour.v2.so
parece que el gcc sea mas acomodante del clang por el tipo de funcion void, tambien si lo evidencia en la compilacion
consejo la modifica del mod_harbour.v2.1.hbp con las istruciones de arriba
desde ahora en adelante busco de pruebar el mo_harbour.
saludos desde italia
-
- Mensajes: 8
- Registered for: 3 years 1 month
buenos dias
hoy he hecho un git pull
y he rigenerado el harbour con
export HB_USER_CFLAGS="-fPIC"
esto es el output del comando env
SHELL=/bin/bash
SESSION_MANAGER=local/nikko-ThinkCentre-M900:@/tmp/.ICE-unix/47498,unix/nikko-ThinkCentre-M900:/tmp/.ICE-unix/47498
QT_ACCESSIBILITY=1
COLORTERM=truecolor
XDG_CONFIG_DIRS=/etc/xdg/xdg-xfce:/etc/xdg:/etc/xdg
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session2
XDG_MENU_PREFIX=xfce-
GTK_IM_MODULE=ibus
LANGUAGE=it
SSH_AUTH_SOCK=/tmp/ssh-XXXXXXbR6zNP/agent.47625
XMODIFIERS=@im=ibus
DESKTOP_SESSION=xfce
SSH_AGENT_PID=47626
GTK_MODULES=gail:atk-bridge
XDG_SEAT=seat0
PWD=/opt/harbour/contrib/mod_harbour.v2
LOGNAME=nikko
XDG_SESSION_DESKTOP=xfce
XDG_SESSION_TYPE=x11
PANEL_GDK_CORE_DEVICE_EVENTS=0
XAUTHORITY=/home/nikko/.Xauthority
XDG_GREETER_DATA_DIR=/var/lib/lightdm-data/nikko
GDM_LANG=it
HB_USER_CFLAGS=-fPIC
HOME=/home/nikko
LANG=it_IT.UTF-8
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:
XDG_CURRENT_DESKTOP=XFCE
VTE_VERSION=6800
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
GNOME_TERMINAL_SCREEN=/org/gnome/Terminal/screen/eb9d8e0b_045d_40e4_a1a9_58b562992154
CLUTTER_IM_MODULE=ibus
LESSCLOSE=/usr/bin/lesspipe %s %s
XDG_SESSION_CLASS=user
TERM=xterm-256color
LESSOPEN=| /usr/bin/lesspipe %s
USER=nikko
GNOME_TERMINAL_SERVICE=:1.265
DISPLAY=:0.0
SHLVL=1
QT_IM_MODULE=ibus
XDG_VTNR=7
XDG_SESSION_ID=c8
XDG_RUNTIME_DIR=/run/user/1000
XDG_DATA_DIRS=/usr/share/xfce4:/usr/share/xfce:/usr/share/gnome:/usr/local/share:/usr/share:/var/lib/snapd/desktop:/usr/share
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
GDMSESSION=xfce
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
OLDPWD=/opt/harbour/contrib/mod_harbour.v2/output
_=/usr/bin/env
y despues busco de recompilar el mod_harbour.v2.1.hbp
y sale el mismo error
/usr/bin/ld: /usr/local/lib/harbour/libhbvmmt.a(hvmall.o): relocation R_X86_64_TPOFF32 against `hb_stack_ptr' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: failed to set dynamic section sizes: bad value
collect2: error: ld returned 1 exit status
hbmk2[libmhapache]: Error: Running dynamic lib link command. 1
cual es el mi error
saludos
hoy he hecho un git pull
y he rigenerado el harbour con
export HB_USER_CFLAGS="-fPIC"
esto es el output del comando env
SHELL=/bin/bash
SESSION_MANAGER=local/nikko-ThinkCentre-M900:@/tmp/.ICE-unix/47498,unix/nikko-ThinkCentre-M900:/tmp/.ICE-unix/47498
QT_ACCESSIBILITY=1
COLORTERM=truecolor
XDG_CONFIG_DIRS=/etc/xdg/xdg-xfce:/etc/xdg:/etc/xdg
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session2
XDG_MENU_PREFIX=xfce-
GTK_IM_MODULE=ibus
LANGUAGE=it
SSH_AUTH_SOCK=/tmp/ssh-XXXXXXbR6zNP/agent.47625
XMODIFIERS=@im=ibus
DESKTOP_SESSION=xfce
SSH_AGENT_PID=47626
GTK_MODULES=gail:atk-bridge
XDG_SEAT=seat0
PWD=/opt/harbour/contrib/mod_harbour.v2
LOGNAME=nikko
XDG_SESSION_DESKTOP=xfce
XDG_SESSION_TYPE=x11
PANEL_GDK_CORE_DEVICE_EVENTS=0
XAUTHORITY=/home/nikko/.Xauthority
XDG_GREETER_DATA_DIR=/var/lib/lightdm-data/nikko
GDM_LANG=it
HB_USER_CFLAGS=-fPIC
HOME=/home/nikko
LANG=it_IT.UTF-8
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:
XDG_CURRENT_DESKTOP=XFCE
VTE_VERSION=6800
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
GNOME_TERMINAL_SCREEN=/org/gnome/Terminal/screen/eb9d8e0b_045d_40e4_a1a9_58b562992154
CLUTTER_IM_MODULE=ibus
LESSCLOSE=/usr/bin/lesspipe %s %s
XDG_SESSION_CLASS=user
TERM=xterm-256color
LESSOPEN=| /usr/bin/lesspipe %s
USER=nikko
GNOME_TERMINAL_SERVICE=:1.265
DISPLAY=:0.0
SHLVL=1
QT_IM_MODULE=ibus
XDG_VTNR=7
XDG_SESSION_ID=c8
XDG_RUNTIME_DIR=/run/user/1000
XDG_DATA_DIRS=/usr/share/xfce4:/usr/share/xfce:/usr/share/gnome:/usr/local/share:/usr/share:/var/lib/snapd/desktop:/usr/share
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
GDMSESSION=xfce
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
OLDPWD=/opt/harbour/contrib/mod_harbour.v2/output
_=/usr/bin/env
y despues busco de recompilar el mod_harbour.v2.1.hbp
y sale el mismo error
/usr/bin/ld: /usr/local/lib/harbour/libhbvmmt.a(hvmall.o): relocation R_X86_64_TPOFF32 against `hb_stack_ptr' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: failed to set dynamic section sizes: bad value
collect2: error: ld returned 1 exit status
hbmk2[libmhapache]: Error: Running dynamic lib link command. 1
cual es el mi error
saludos