added stix_compoocharsbcstr(), stix_compbcharsbcstr().

added code to handle statically linked modules.
fixed more build issues
This commit is contained in:
hyunghwan.chung
2016-12-31 17:19:40 +00:00
parent 54dd7675b0
commit 65b230da24
8 changed files with 83 additions and 65 deletions

View File

@ -5,7 +5,7 @@ CPPFLAGS_COMMON = \
-I$(abs_builddir)/../lib \
-I$(abs_srcdir) \
-I$(abs_srcdir)/../lib \
-I$(includedir)
-I$(includedir) -fPIC
if WIN32
# you must adjust the value of DEFAULT_MODPOSTFIX according
@ -21,10 +21,13 @@ if ENABLE_STATIC_MODULE
# STATIC MODULES BUILT INTO MAIN LIBRARY
##################################################
noinst_LIBRARIES = libstix-stdio.a
noinst_LTLIBRARIES = libstix-console.la libstix-stdio.la
libstix_stdio_a_SOURCES = stdio.c
libstix_stdio_a_CPPFLAGS = $(CPPFLAGS_COMMON)
libstix_console_la_SOURCES = console.c
libstix_console_la_CPPFLAGS = $(CPPFLAGS_COMMON)
libstix_stdio_la_SOURCES = stdio.c
libstix_stdio_la_CPPFLAGS = $(CPPFLAGS_COMMON)
else

View File

@ -14,7 +14,6 @@
@SET_MAKE@
VPATH = @srcdir@
am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
am__make_running_with_option = \
@ -100,18 +99,6 @@ mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/lib/stix-cfg.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
LIBRARIES = $(noinst_LIBRARIES)
ARFLAGS = cru
AM_V_AR = $(am__v_AR_@AM_V@)
am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
am__v_AR_0 = @echo " AR " $@;
am__v_AR_1 =
libstix_stdio_a_AR = $(AR) $(ARFLAGS)
libstix_stdio_a_LIBADD =
am__libstix_stdio_a_SOURCES_DIST = stdio.c
@ENABLE_STATIC_MODULE_TRUE@am_libstix_stdio_a_OBJECTS = \
@ENABLE_STATIC_MODULE_TRUE@ libstix_stdio_a-stdio.$(OBJEXT)
libstix_stdio_a_OBJECTS = $(am_libstix_stdio_a_OBJECTS)
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
@ -140,13 +127,15 @@ am__uninstall_files_from_dir = { \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(pkgmodexecdir)"
LTLIBRARIES = $(pkgmodexec_LTLIBRARIES)
LTLIBRARIES = $(noinst_LTLIBRARIES) $(pkgmodexec_LTLIBRARIES)
am__DEPENDENCIES_1 =
@ENABLE_STATIC_MODULE_FALSE@libstix_console_la_DEPENDENCIES = \
@ENABLE_STATIC_MODULE_FALSE@ $(am__DEPENDENCIES_1)
am__libstix_console_la_SOURCES_DIST = console.c console.h
@ENABLE_STATIC_MODULE_FALSE@am_libstix_console_la_OBJECTS = \
@ENABLE_STATIC_MODULE_FALSE@ libstix_console_la-console.lo
@ENABLE_STATIC_MODULE_TRUE@am_libstix_console_la_OBJECTS = \
@ENABLE_STATIC_MODULE_TRUE@ libstix_console_la-console.lo
libstix_console_la_OBJECTS = $(am_libstix_console_la_OBJECTS)
AM_V_lt = $(am__v_lt_@AM_V@)
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
@ -158,11 +147,14 @@ libstix_console_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
$(LDFLAGS) -o $@
@ENABLE_STATIC_MODULE_FALSE@am_libstix_console_la_rpath = -rpath \
@ENABLE_STATIC_MODULE_FALSE@ $(pkgmodexecdir)
@ENABLE_STATIC_MODULE_TRUE@am_libstix_console_la_rpath =
@ENABLE_STATIC_MODULE_FALSE@libstix_stdio_la_DEPENDENCIES = \
@ENABLE_STATIC_MODULE_FALSE@ $(am__DEPENDENCIES_1)
am__libstix_stdio_la_SOURCES_DIST = stdio.c m-stdio.h
@ENABLE_STATIC_MODULE_FALSE@am_libstix_stdio_la_OBJECTS = \
@ENABLE_STATIC_MODULE_FALSE@ libstix_stdio_la-stdio.lo
@ENABLE_STATIC_MODULE_TRUE@am_libstix_stdio_la_OBJECTS = \
@ENABLE_STATIC_MODULE_TRUE@ libstix_stdio_la-stdio.lo
libstix_stdio_la_OBJECTS = $(am_libstix_stdio_la_OBJECTS)
libstix_stdio_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \
@ -170,6 +162,7 @@ libstix_stdio_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
-o $@
@ENABLE_STATIC_MODULE_FALSE@am_libstix_stdio_la_rpath = -rpath \
@ENABLE_STATIC_MODULE_FALSE@ $(pkgmodexecdir)
@ENABLE_STATIC_MODULE_TRUE@am_libstix_stdio_la_rpath =
AM_V_P = $(am__v_P_@AM_V@)
am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
am__v_P_0 = false
@ -204,10 +197,8 @@ AM_V_CCLD = $(am__v_CCLD_@AM_V@)
am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
am__v_CCLD_0 = @echo " CCLD " $@;
am__v_CCLD_1 =
SOURCES = $(libstix_stdio_a_SOURCES) $(libstix_console_la_SOURCES) \
$(libstix_stdio_la_SOURCES)
DIST_SOURCES = $(am__libstix_stdio_a_SOURCES_DIST) \
$(am__libstix_console_la_SOURCES_DIST) \
SOURCES = $(libstix_console_la_SOURCES) $(libstix_stdio_la_SOURCES)
DIST_SOURCES = $(am__libstix_console_la_SOURCES_DIST) \
$(am__libstix_stdio_la_SOURCES_DIST)
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
@ -395,15 +386,21 @@ top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AUTOMAKE_OPTIONS = nostdinc
CPPFLAGS_COMMON = -I$(abs_builddir) -I$(abs_builddir)/../lib \
-I$(abs_srcdir) -I$(abs_srcdir)/../lib -I$(includedir) \
-I$(abs_srcdir) -I$(abs_srcdir)/../lib -I$(includedir) -fPIC \
$(am__append_1) $(am__append_2)
##################################################
# STATIC MODULES BUILT INTO MAIN LIBRARY
##################################################
@ENABLE_STATIC_MODULE_TRUE@noinst_LIBRARIES = libstix-stdio.a
@ENABLE_STATIC_MODULE_TRUE@libstix_stdio_a_SOURCES = stdio.c
@ENABLE_STATIC_MODULE_TRUE@libstix_stdio_a_CPPFLAGS = $(CPPFLAGS_COMMON)
@ENABLE_STATIC_MODULE_TRUE@noinst_LTLIBRARIES = libstix-console.la libstix-stdio.la
@ENABLE_STATIC_MODULE_FALSE@libstix_console_la_SOURCES = console.c console.h
@ENABLE_STATIC_MODULE_TRUE@libstix_console_la_SOURCES = console.c
@ENABLE_STATIC_MODULE_FALSE@libstix_console_la_CPPFLAGS = $(CPPFLAGS_COMMON)
@ENABLE_STATIC_MODULE_TRUE@libstix_console_la_CPPFLAGS = $(CPPFLAGS_COMMON)
@ENABLE_STATIC_MODULE_FALSE@libstix_stdio_la_SOURCES = stdio.c m-stdio.h
@ENABLE_STATIC_MODULE_TRUE@libstix_stdio_la_SOURCES = stdio.c
@ENABLE_STATIC_MODULE_FALSE@libstix_stdio_la_CPPFLAGS = $(CPPFLAGS_COMMON)
@ENABLE_STATIC_MODULE_TRUE@libstix_stdio_la_CPPFLAGS = $(CPPFLAGS_COMMON)
##################################################
# DYNAMIC MODULES
@ -412,12 +409,8 @@ CPPFLAGS_COMMON = -I$(abs_builddir) -I$(abs_builddir)/../lib \
@ENABLE_STATIC_MODULE_FALSE@LIBADD_COMMON = -lstix
@ENABLE_STATIC_MODULE_FALSE@pkgmodexecdir = $(libdir)
@ENABLE_STATIC_MODULE_FALSE@pkgmodexec_LTLIBRARIES = libstix-stdio.la libstix-console.la
@ENABLE_STATIC_MODULE_FALSE@libstix_stdio_la_SOURCES = stdio.c m-stdio.h
@ENABLE_STATIC_MODULE_FALSE@libstix_stdio_la_CPPFLAGS = $(CPPFLAGS_COMMON)
@ENABLE_STATIC_MODULE_FALSE@libstix_stdio_la_LDFLAGS = $(LDFLAGS_COMMON)
@ENABLE_STATIC_MODULE_FALSE@libstix_stdio_la_LIBADD = $(LIBADD_COMMON)
@ENABLE_STATIC_MODULE_FALSE@libstix_console_la_SOURCES = console.c console.h
@ENABLE_STATIC_MODULE_FALSE@libstix_console_la_CPPFLAGS = $(CPPFLAGS_COMMON)
@ENABLE_STATIC_MODULE_FALSE@libstix_console_la_LDFLAGS = $(LDFLAGS_COMMON)
@ENABLE_STATIC_MODULE_FALSE@libstix_console_la_LIBADD = $(LIBADD_COMMON) -ltermcap
all: all-am
@ -455,13 +448,16 @@ $(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
clean-noinstLIBRARIES:
-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
libstix-stdio.a: $(libstix_stdio_a_OBJECTS) $(libstix_stdio_a_DEPENDENCIES) $(EXTRA_libstix_stdio_a_DEPENDENCIES)
$(AM_V_at)-rm -f libstix-stdio.a
$(AM_V_AR)$(libstix_stdio_a_AR) libstix-stdio.a $(libstix_stdio_a_OBJECTS) $(libstix_stdio_a_LIBADD)
$(AM_V_at)$(RANLIB) libstix-stdio.a
clean-noinstLTLIBRARIES:
-test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
@list='$(noinst_LTLIBRARIES)'; \
locs=`for p in $$list; do echo $$p; done | \
sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
sort -u`; \
test -z "$$locs" || { \
echo rm -f $${locs}; \
rm -f $${locs}; \
}
install-pkgmodexecLTLIBRARIES: $(pkgmodexec_LTLIBRARIES)
@$(NORMAL_INSTALL)
@ -511,7 +507,6 @@ distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libstix_console_la-console.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libstix_stdio_a-stdio.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libstix_stdio_la-stdio.Plo@am__quote@
.c.o:
@ -538,20 +533,6 @@ distclean-compile:
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
libstix_stdio_a-stdio.o: stdio.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libstix_stdio_a_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libstix_stdio_a-stdio.o -MD -MP -MF $(DEPDIR)/libstix_stdio_a-stdio.Tpo -c -o libstix_stdio_a-stdio.o `test -f 'stdio.c' || echo '$(srcdir)/'`stdio.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libstix_stdio_a-stdio.Tpo $(DEPDIR)/libstix_stdio_a-stdio.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='stdio.c' object='libstix_stdio_a-stdio.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libstix_stdio_a_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libstix_stdio_a-stdio.o `test -f 'stdio.c' || echo '$(srcdir)/'`stdio.c
libstix_stdio_a-stdio.obj: stdio.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libstix_stdio_a_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libstix_stdio_a-stdio.obj -MD -MP -MF $(DEPDIR)/libstix_stdio_a-stdio.Tpo -c -o libstix_stdio_a-stdio.obj `if test -f 'stdio.c'; then $(CYGPATH_W) 'stdio.c'; else $(CYGPATH_W) '$(srcdir)/stdio.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libstix_stdio_a-stdio.Tpo $(DEPDIR)/libstix_stdio_a-stdio.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='stdio.c' object='libstix_stdio_a-stdio.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libstix_stdio_a_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libstix_stdio_a-stdio.obj `if test -f 'stdio.c'; then $(CYGPATH_W) 'stdio.c'; else $(CYGPATH_W) '$(srcdir)/stdio.c'; fi`
libstix_console_la-console.lo: console.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libstix_console_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libstix_console_la-console.lo -MD -MP -MF $(DEPDIR)/libstix_console_la-console.Tpo -c -o libstix_console_la-console.lo `test -f 'console.c' || echo '$(srcdir)/'`console.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libstix_console_la-console.Tpo $(DEPDIR)/libstix_console_la-console.Plo
@ -656,7 +637,7 @@ distdir: $(DISTFILES)
done
check-am: all-am
check: check-am
all-am: Makefile $(LIBRARIES) $(LTLIBRARIES)
all-am: Makefile $(LTLIBRARIES)
installdirs:
for dir in "$(DESTDIR)$(pkgmodexecdir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
@ -693,7 +674,7 @@ maintainer-clean-generic:
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \
clean-pkgmodexecLTLIBRARIES mostlyclean-am
distclean: distclean-am
@ -765,7 +746,7 @@ uninstall-am: uninstall-pkgmodexecLTLIBRARIES
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
clean-libtool clean-noinstLIBRARIES \
clean-libtool clean-noinstLTLIBRARIES \
clean-pkgmodexecLTLIBRARIES cscopelist-am ctags ctags-am \
distclean distclean-compile distclean-generic \
distclean-libtool distclean-tags distdir dvi dvi-am html \