mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
[test] compilation fixes
This commit is contained in:
parent
f73503cb7a
commit
294732babc
@ -7,4 +7,4 @@ test('cookies', t, depends:[exe], env:test_lib, workdir:meson.current_build_dir(
|
||||
|
||||
parsetstdeps = files('parser.c', 'parsetst.c')
|
||||
|
||||
executable('parsetst', parsetstdeps, testdeps, c_args:['-DHAVE_CONFIG_H'], include_directories:['.', '..', '../..'])
|
||||
executable('parsetst', parsetstdeps, testdeps, dependencies:[iconvdeps], c_args:['-DHAVE_CONFIG_H'], include_directories:['.', '..', '../..'])
|
||||
|
@ -16,6 +16,18 @@ int get_ctl_handle()
|
||||
return -1;
|
||||
}
|
||||
|
||||
char *
|
||||
gettext(const char *text)
|
||||
{
|
||||
return (char *)text;
|
||||
}
|
||||
|
||||
int
|
||||
os_default_charset(void)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
|
@ -1,2 +1,3 @@
|
||||
t = executable('parse-meta-refresh-test', 'parse-meta-refresh-test.c', testdeps, meson.current_source_dir() + '/../parse-meta-refresh.c', c_args:['-DHAVE_CONFIG_H'], include_directories:['.', '..', '../..', '../../..', '../../../..'])
|
||||
t = executable('parse-meta-refresh-test', 'parse-meta-refresh-test.c', testdeps, meson.current_source_dir() + '/../parse-meta-refresh.c', dependencies:[iconvdeps],
|
||||
c_args:['-DHAVE_CONFIG_H'], include_directories:['.', '..', '../..', '../../..', '../../../..'])
|
||||
test('parse-meta-refresh', t)
|
||||
|
@ -15,7 +15,20 @@
|
||||
#include "util/memory.h"
|
||||
|
||||
/* fake tty get function, needed for charsets.c */
|
||||
int get_ctl_handle() {
|
||||
int
|
||||
get_ctl_handle() {
|
||||
return -1;
|
||||
}
|
||||
|
||||
char *
|
||||
gettext(const char *text)
|
||||
{
|
||||
return (char *)text;
|
||||
}
|
||||
|
||||
int
|
||||
os_default_charset(void)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@ -13,7 +13,21 @@
|
||||
#include "util/string.h"
|
||||
|
||||
/* fake tty get function, needed for charsets.c */
|
||||
int get_ctl_handle() {
|
||||
int
|
||||
get_ctl_handle()
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
char *
|
||||
gettext(const char *text)
|
||||
{
|
||||
return (char *)text;
|
||||
}
|
||||
|
||||
int
|
||||
os_default_charset(void)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@ -1,2 +1,3 @@
|
||||
t = executable('match-hostname-test', 'match-hostname-test.c', meson.source_root()+'/src/network/ssl/match-hostname.c', testdeps, c_args:['-DHAVE_CONFIG_H'], include_directories:['.', '..', '../..', '../../..', '../../../..'])
|
||||
t = executable('match-hostname-test', 'match-hostname-test.c', meson.source_root()+'/src/network/ssl/match-hostname.c', testdeps, dependencies:[iconvdeps],
|
||||
c_args:['-DHAVE_CONFIG_H'], include_directories:['.', '..', '../..', '../../..', '../../../..'])
|
||||
test('match-hostname-test', t)
|
||||
|
@ -16,7 +16,21 @@
|
||||
#include "util/test.h"
|
||||
|
||||
/* fake tty get function, needed for charsets.c */
|
||||
int get_ctl_handle() {
|
||||
int
|
||||
get_ctl_handle()
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
char *
|
||||
gettext(const char *text)
|
||||
{
|
||||
return (char *)text;
|
||||
}
|
||||
|
||||
int
|
||||
os_default_charset(void)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
srcs += files('ftp.c', 'parse.c')
|
||||
|
||||
exe = executable('ftp-parser', 'ftp-parser.c', 'parse.c', meson.source_root()+'/src/protocol/date.c', testdeps,
|
||||
exe = executable('ftp-parser', 'ftp-parser.c', 'parse.c', meson.source_root()+'/src/protocol/date.c', testdeps, dependencies:[iconvdeps],
|
||||
c_args:['-DHAVE_CONFIG_H'], cpp_args:['-DHAVE_CONFIG_H'], include_directories:['.','../..','../../..'],
|
||||
build_by_default:false)
|
||||
|
||||
|
@ -2,36 +2,8 @@ idna_dep = dependency('libidn')
|
||||
|
||||
uri_test_files = files('uri-test.c', 'stub.c', meson.current_source_dir()+'/../protocol.cpp', meson.current_source_dir()+'/../uri.c')
|
||||
|
||||
if conf_data.get('CONFIG_NLS') and not conf_data.get('CONFIG_GETTEXT')
|
||||
uri_test_files += files(
|
||||
meson.source_root()+'/src/intl/gettext/bindtextdom.c',
|
||||
meson.source_root()+'/src/intl/gettext/dcgettext.c',
|
||||
meson.source_root()+'/src/intl/gettext/dcigettext.c',
|
||||
meson.source_root()+'/src/intl/gettext/dcngettext.c',
|
||||
meson.source_root()+'/src/intl/gettext/dgettext.c',
|
||||
meson.source_root()+'/src/intl/gettext/dngettext.c',
|
||||
meson.source_root()+'/src/intl/gettext/explodename.c',
|
||||
meson.source_root()+'/src/intl/gettext/finddomain.c',
|
||||
meson.source_root()+'/src/intl/gettext/gettext.c',
|
||||
meson.source_root()+'/src/intl/gettext/intl-compat.c',
|
||||
meson.source_root()+'/src/intl/gettext/l10nflist.c',
|
||||
meson.source_root()+'/src/intl/gettext/libintl.c',
|
||||
meson.source_root()+'/src/intl/gettext/loadmsgcat.c',
|
||||
meson.source_root()+'/src/intl/gettext/localcharset.c',
|
||||
meson.source_root()+'/src/intl/gettext/localealias.c',
|
||||
meson.source_root()+'/src/intl/gettext/ngettext.c',
|
||||
meson.source_root()+'/src/intl/gettext/plural.c',
|
||||
meson.source_root()+'/src/intl/gettext/textdomain.c')
|
||||
endif
|
||||
|
||||
if conf_data.get('CONFIG_NLS') and conf_data.get('CONFIG_GETTEXT')
|
||||
uri_test_files += files(
|
||||
meson.source_root()+'/src/intl/libintl.c',
|
||||
meson.source_root()+'/src/util/env.c')
|
||||
endif
|
||||
|
||||
exe = executable('uri-test', uri_test_files,
|
||||
testdeps, dependencies: [idna_dep, mozjsdeps],
|
||||
testdeps, dependencies: [iconvdeps, idna_dep, mozjsdeps, wattdeps],
|
||||
c_args:['-DHAVE_CONFIG_H'], cpp_args:['-DHAVE_CONFIG_H'], include_directories:['.', '..', '../..', '../../..', '../../../..'])
|
||||
t = find_program('test-normalize-uri')
|
||||
test_lib = environment({'TEST_LIB':meson.source_root()+'/test/libtest.sh'})
|
||||
|
@ -47,6 +47,7 @@ struct program {
|
||||
STUB_MODULE(auth_module);
|
||||
STUB_MODULE(bittorrent_protocol_module);
|
||||
STUB_MODULE(cgi_protocol_module);
|
||||
STUB_MODULE(dgi_protocol_module);
|
||||
STUB_MODULE(file_protocol_module);
|
||||
STUB_MODULE(finger_protocol_module);
|
||||
STUB_MODULE(fsp_protocol_module);
|
||||
@ -83,6 +84,7 @@ STUB_PROTOCOL_HANDLER(about_protocol_handler);
|
||||
STUB_PROTOCOL_HANDLER(bittorrent_protocol_handler);
|
||||
STUB_PROTOCOL_HANDLER(bittorrent_peer_protocol_handler);
|
||||
STUB_PROTOCOL_HANDLER(data_protocol_handler);
|
||||
STUB_PROTOCOL_HANDLER(dgi_protocol_handler);
|
||||
STUB_PROTOCOL_EXTERNAL_HANDLER(ecmascript_protocol_handler);
|
||||
STUB_PROTOCOL_HANDLER(file_protocol_handler);
|
||||
STUB_PROTOCOL_HANDLER(finger_protocol_handler);
|
||||
|
@ -19,11 +19,26 @@ get_default_protocol(void)
|
||||
return "file://";
|
||||
}
|
||||
|
||||
char *
|
||||
gettext(const char *text)
|
||||
{
|
||||
return (char *)text;
|
||||
}
|
||||
|
||||
int
|
||||
os_default_charset(void)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
int current_charset;
|
||||
|
||||
#include "protocol/uri.h"
|
||||
#include "util/string.h"
|
||||
|
||||
/* fake tty get function, needed for charsets.c */
|
||||
int get_ctl_handle()
|
||||
int
|
||||
get_ctl_handle()
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user