Commit 96b4279ccdda8c0e7179dd4619cdf8d242c714a3

Authored by perry.werneck@gmail.com
1 parent 1c15ded7

Trabalhando na versão android

Showing 3 changed files with 26 additions and 9 deletions   Show diff stats
globals.h
... ... @@ -171,12 +171,16 @@ extern H3270 h3270;
171 171 LIB3270_INTERNAL XtAppContext appcontext;
172 172 #endif /*]*/
173 173  
174   -LIB3270_INTERNAL const char *build;
175   -LIB3270_INTERNAL const char *build_rpq_timestamp;
176   -LIB3270_INTERNAL const char *build_rpq_version;
177   -LIB3270_INTERNAL int children;
178   -// LIB3270_INTERNAL char *current_host;
179   -// LIB3270_INTERNAL unsigned short current_port;
  174 +
  175 +// Version strings
  176 +LIB3270_INTERNAL const char * build;
  177 +LIB3270_INTERNAL const char * app_defaults_version;
  178 +LIB3270_INTERNAL const char * sccsid;
  179 +LIB3270_INTERNAL const char * build_rpq_timestamp;
  180 +LIB3270_INTERNAL const char * build_rpq_version;
  181 +LIB3270_INTERNAL const char * build_rpq_revision;
  182 +
  183 +LIB3270_INTERNAL int children;
180 184  
181 185 #if defined(X3270_DBCS) /*[*/
182 186 LIB3270_INTERNAL Boolean dbcs;
... ...
sources.mak
... ... @@ -26,9 +26,10 @@
26 26  
27 27 # Terminal only sources
28 28 TERMINAL_SOURCES = bounds.c XtGlue.c ctlr.c util.c toggles.c screen.c selection.c kybd.c telnet.c \
29   - host.c sf.c ansi.c log.c resolver.c xio.c tables.c proxy.c utf8.c charset.c
  29 + host.c sf.c ansi.c log.c resolver.c xio.c tables.c proxy.c utf8.c charset.c \
  30 + version.c
30 31  
31 32 # Full library sources
32 33 SOURCES = $(TERMINAL_SOURCES) init.c actions.c ft.c ft_cut.c ft_dft.c glue.c resources.c \
33   - rpq.c see.c trace_ds.c paste.c macros.c fallbacks.c version.c
  34 + rpq.c see.c trace_ds.c paste.c macros.c fallbacks.c
34 35  
... ...
util.c
... ... @@ -1151,10 +1151,12 @@ void * Calloc(size_t nelem, size_t elsize)
1151 1151  
1152 1152 LIB3270_EXPORT char * lib3270_get_resource_string(const char *first_element, ...)
1153 1153 {
1154   -#ifndef ANDROID
  1154 +#ifdef ANDROID
1155 1155  
1156 1156 #warning Work in progress
1157 1157  
  1158 +#else
  1159 +
1158 1160 char buffer[4096];
1159 1161 char * ptr = buffer;
1160 1162 const char * element;
... ... @@ -1184,3 +1186,13 @@ LIB3270_EXPORT char * lib3270_get_resource_string(const char *first_element, ...
1184 1186 #endif
1185 1187 return NULL;
1186 1188 }
  1189 +
  1190 +LIB3270_EXPORT const char * lib3270_get_version(void)
  1191 +{
  1192 + return build_rpq_version;
  1193 +}
  1194 +
  1195 +LIB3270_EXPORT const char * lib3270_get_revision(void)
  1196 +{
  1197 + return build_rpq_revision;
  1198 +}
... ...