diff options
Diffstat (limited to 'utilities')
98 files changed, 8792 insertions, 2136 deletions
diff --git a/utilities/.cvsignore b/utilities/.cvsignore deleted file mode 100644 index 941045f..0000000 --- a/utilities/.cvsignore +++ /dev/null @@ -1,31 +0,0 @@ -.deps -.libs -Makefile -Makefile.in -addgb -addld -addvs -cipherraw -ciphertest -ciphertest2 -emptyvss -gbfidx -imp2gbs -imp2ld -imp2vs -installmgr -lexdump -mkfastmod -mod2imp -mod2osis -mod2vpl -mod2zmod -modwrite -osis2mod -step2vpl -stepdump -thml2gbs -txt2sword -vpl2mod -vs2osisref -xml2gbs diff --git a/utilities/Makefile.am b/utilities/Makefile.am index c453f80..ee817ea 100644 --- a/utilities/Makefile.am +++ b/utilities/Makefile.am @@ -6,7 +6,7 @@ noinst_PROGRAMS = cipherraw lexdump \ stepdump step2vpl gbfidx modwrite addvs emptyvss \ addgb genbookutil treeidxutil -bin_PROGRAMS = mod2imp mod2osis osis2mod tei2mod vs2osisref mod2vpl \ +bin_PROGRAMS = mod2imp mod2osis osis2mod tei2mod vs2osisref vs2osisreftxt mod2vpl \ mkfastmod vpl2mod imp2vs installmgr xml2gbs imp2gbs #if INSTALLMGR @@ -58,6 +58,7 @@ xml2gbs_SOURCES = xml2gbs.cpp osis2mod_SOURCES = osis2mod.cpp tei2mod_SOURCES = tei2mod.cpp vs2osisref_SOURCES = vs2osisref.cpp +vs2osisreftxt_SOURCES = vs2osisreftxt.cpp genbookutil_SOURCES = genbookutil.cpp treeidxutil_SOURCES = treeidxutil.cpp diff --git a/utilities/Makefile.in b/utilities/Makefile.in index d27987e..9f7ac82 100644 --- a/utilities/Makefile.in +++ b/utilities/Makefile.in @@ -1,8 +1,8 @@ -# Makefile.in generated by automake 1.10 from Makefile.am. +# Makefile.in generated by automake 1.10.2 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -38,17 +38,20 @@ noinst_PROGRAMS = cipherraw$(EXEEXT) lexdump$(EXEEXT) \ modwrite$(EXEEXT) addvs$(EXEEXT) emptyvss$(EXEEXT) \ addgb$(EXEEXT) genbookutil$(EXEEXT) treeidxutil$(EXEEXT) bin_PROGRAMS = mod2imp$(EXEEXT) mod2osis$(EXEEXT) osis2mod$(EXEEXT) \ - tei2mod$(EXEEXT) vs2osisref$(EXEEXT) mod2vpl$(EXEEXT) \ - mkfastmod$(EXEEXT) vpl2mod$(EXEEXT) imp2vs$(EXEEXT) \ - installmgr$(EXEEXT) xml2gbs$(EXEEXT) imp2gbs$(EXEEXT) \ - $(am__EXEEXT_1) + tei2mod$(EXEEXT) vs2osisref$(EXEEXT) vs2osisreftxt$(EXEEXT) \ + mod2vpl$(EXEEXT) mkfastmod$(EXEEXT) vpl2mod$(EXEEXT) \ + imp2vs$(EXEEXT) installmgr$(EXEEXT) xml2gbs$(EXEEXT) \ + imp2gbs$(EXEEXT) $(am__EXEEXT_1) DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ $(srcdir)/bcppmake/Makefile.am $(srcdir)/kylixmake/Makefile.am \ $(srcdir)/perl/Makefile.am subdir = utilities ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/acx_clucene.m4 \ - $(top_srcdir)/m4/cppunit.m4 $(top_srcdir)/configure.ac + $(top_srcdir)/m4/cppunit.m4 $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(install_sh) -d @@ -161,11 +164,15 @@ am_vs2osisref_OBJECTS = vs2osisref.$(OBJEXT) vs2osisref_OBJECTS = $(am_vs2osisref_OBJECTS) vs2osisref_LDADD = $(LDADD) vs2osisref_DEPENDENCIES = $(top_builddir)/lib/libsword.la +am_vs2osisreftxt_OBJECTS = vs2osisreftxt.$(OBJEXT) +vs2osisreftxt_OBJECTS = $(am_vs2osisreftxt_OBJECTS) +vs2osisreftxt_LDADD = $(LDADD) +vs2osisreftxt_DEPENDENCIES = $(top_builddir)/lib/libsword.la am_xml2gbs_OBJECTS = xml2gbs.$(OBJEXT) xml2gbs_OBJECTS = $(am_xml2gbs_OBJECTS) xml2gbs_LDADD = $(LDADD) xml2gbs_DEPENDENCIES = $(top_builddir)/lib/libsword.la -DEFAULT_INCLUDES = -I. -I$(top_builddir)/include@am__isrc@ +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/include depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ @@ -194,7 +201,8 @@ SOURCES = $(addgb_SOURCES) $(addld_SOURCES) $(addvs_SOURCES) \ $(mod2vpl_SOURCES) $(mod2zmod_SOURCES) $(modwrite_SOURCES) \ $(osis2mod_SOURCES) $(step2vpl_SOURCES) $(stepdump_SOURCES) \ $(tei2mod_SOURCES) $(treeidxutil_SOURCES) $(vpl2mod_SOURCES) \ - $(vs2osisref_SOURCES) $(xml2gbs_SOURCES) + $(vs2osisref_SOURCES) $(vs2osisreftxt_SOURCES) \ + $(xml2gbs_SOURCES) DIST_SOURCES = $(addgb_SOURCES) $(am__addld_SOURCES_DIST) \ $(addvs_SOURCES) $(cipherraw_SOURCES) $(emptyvss_SOURCES) \ $(gbfidx_SOURCES) $(genbookutil_SOURCES) $(imp2gbs_SOURCES) \ @@ -204,7 +212,8 @@ DIST_SOURCES = $(addgb_SOURCES) $(am__addld_SOURCES_DIST) \ $(am__mod2zmod_SOURCES_DIST) $(modwrite_SOURCES) \ $(osis2mod_SOURCES) $(step2vpl_SOURCES) $(stepdump_SOURCES) \ $(tei2mod_SOURCES) $(treeidxutil_SOURCES) $(vpl2mod_SOURCES) \ - $(vs2osisref_SOURCES) $(xml2gbs_SOURCES) + $(vs2osisref_SOURCES) $(vs2osisreftxt_SOURCES) \ + $(xml2gbs_SOURCES) RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ html-recursive info-recursive install-data-recursive \ install-dvi-recursive install-exec-recursive \ @@ -248,14 +257,14 @@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ -ECHO = @ECHO@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -F77 = @F77@ -FFLAGS = @FFLAGS@ +FGREP = @FGREP@ GENCCODE = @GENCCODE@ GENCMN = @GENCMN@ GENRB = @GENRB@ @@ -269,17 +278,23 @@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -302,7 +317,7 @@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ -ac_ct_F77 = @ac_ct_F77@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -336,6 +351,7 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ +lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -354,6 +370,7 @@ target_mingw32 = @target_mingw32@ target_os = @target_os@ target_system = @target_system@ target_vendor = @target_vendor@ +top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ with_conf = @with_conf@ @@ -399,6 +416,7 @@ xml2gbs_SOURCES = xml2gbs.cpp osis2mod_SOURCES = osis2mod.cpp tei2mod_SOURCES = tei2mod.cpp vs2osisref_SOURCES = vs2osisref.cpp +vs2osisreftxt_SOURCES = vs2osisreftxt.cpp genbookutil_SOURCES = genbookutil.cpp treeidxutil_SOURCES = treeidxutil.cpp installmgr_SOURCES = installmgr.cpp @@ -440,8 +458,8 @@ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/bc @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ - && exit 0; \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ @@ -474,8 +492,8 @@ install-binPROGRAMS: $(bin_PROGRAMS) || test -f $$p1 \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done @@ -575,6 +593,9 @@ vpl2mod$(EXEEXT): $(vpl2mod_OBJECTS) $(vpl2mod_DEPENDENCIES) vs2osisref$(EXEEXT): $(vs2osisref_OBJECTS) $(vs2osisref_DEPENDENCIES) @rm -f vs2osisref$(EXEEXT) $(CXXLINK) $(vs2osisref_OBJECTS) $(vs2osisref_LDADD) $(LIBS) +vs2osisreftxt$(EXEEXT): $(vs2osisreftxt_OBJECTS) $(vs2osisreftxt_DEPENDENCIES) + @rm -f vs2osisreftxt$(EXEEXT) + $(CXXLINK) $(vs2osisreftxt_OBJECTS) $(vs2osisreftxt_LDADD) $(LIBS) xml2gbs$(EXEEXT): $(xml2gbs_OBJECTS) $(xml2gbs_DEPENDENCIES) @rm -f xml2gbs$(EXEEXT) $(CXXLINK) $(xml2gbs_OBJECTS) $(xml2gbs_LDADD) $(LIBS) @@ -610,6 +631,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/treeidxutil.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vpl2mod.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vs2osisref.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vs2osisreftxt.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml2gbs.Po@am__quote@ .c.o: @@ -735,8 +757,8 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ mkid -fID $$unique tags: TAGS @@ -761,8 +783,8 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ @@ -772,13 +794,12 @@ ctags: CTAGS CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ - here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique diff --git a/utilities/addcomment.cpp b/utilities/addcomment.cpp index 4872dbf..b764774 100644 --- a/utilities/addcomment.cpp +++ b/utilities/addcomment.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <stdio.h> #include <iostream> #include <versekey.h> diff --git a/utilities/addgb.cpp b/utilities/addgb.cpp index c14a0e7..50be73a 100644 --- a/utilities/addgb.cpp +++ b/utilities/addgb.cpp @@ -1,3 +1,19 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <ctype.h> #include <stdio.h> #include <fcntl.h> diff --git a/utilities/addld.cpp b/utilities/addld.cpp index 5b7429e..85ab1ec 100644 --- a/utilities/addld.cpp +++ b/utilities/addld.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <fcntl.h> diff --git a/utilities/addvs.cpp b/utilities/addvs.cpp index 3d73344..499ee54 100644 --- a/utilities/addvs.cpp +++ b/utilities/addvs.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <fcntl.h> diff --git a/utilities/bcppmake/addgb.bpf b/utilities/bcppmake/addgb.bpf new file mode 100644 index 0000000..ef1bf22 --- /dev/null +++ b/utilities/bcppmake/addgb.bpf @@ -0,0 +1,11 @@ +USEUNIT("..\addgb.cpp");
+USELIB("..\..\..\icu-sword\as_is\borland\icuin.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icudatab.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icuuc.lib");
+USELIB("..\..\lib\libsword.lib");
+USELIB("..\..\..\biblecs\clucene\clucene.lib");
+//---------------------------------------------------------------------------
+This file is used by the project manager only and should be treated like the project file
+
+
+main
\ No newline at end of file diff --git a/utilities/bcppmake/addgb.bpr b/utilities/bcppmake/addgb.bpr new file mode 100644 index 0000000..058e82c --- /dev/null +++ b/utilities/bcppmake/addgb.bpr @@ -0,0 +1,126 @@ +<?xml version='1.0' encoding='utf-8' ?>
+<!-- C++Builder XML Project -->
+<PROJECT>
+ <MACROS>
+ <VERSION value="BCB.05.03"/>
+ <PROJECT value="addgb.exe"/>
+ <OBJFILES value="..\addgb.obj"/>
+ <RESFILES value=""/>
+ <IDLFILES value=""/>
+ <IDLGENFILES value=""/>
+ <DEFFILE value=""/>
+ <RESDEPEN value="$(RESFILES)"/>
+ <LIBFILES value="..\..\..\icu-sword\as_is\borland\icuin.lib
+ ..\..\..\icu-sword\as_is\borland\icudatab.lib
+ ..\..\..\icu-sword\as_is\borland\icuuc.lib ..\..\lib\libsword.lib
+ ..\..\..\biblecs\clucene\clucene.lib"/>
+ <LIBRARIES value=""/>
+ <SPARELIBS value=""/>
+ <PACKAGES value="VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi
+ ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi
+ VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi
+ dclocx50.bpi bcb2kaxserver50.bpi"/>
+ <PATHCPP value=".;.."/>
+ <PATHPAS value=".;"/>
+ <PATHRC value=".;"/>
+ <PATHASM value=".;"/>
+ <DEBUGLIBPATH value="$(BCB)\lib\debug"/>
+ <RELEASELIBPATH value="$(BCB)\lib\release"/>
+ <LINKER value="tlink32"/>
+ <USERDEFINES value="_ICU_;_ICUSWORD_;USBINARY;U_HAVE_PLACEMENT_NEW=0;USELUCENE;_CL_DISABLE_MULTITHREADING"/>
+ <SYSDEFINES value="NO_STRICT;_NO_VCL"/>
+ <MAINSOURCE value="addgb.bpf"/>
+ <INCLUDEPATH value="..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl;..\..\..\icu-sword\source\common;..\..\..\icu-sword\source\i18n"/>
+ <LIBPATH value="..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib"/>
+ <WARNINGS value="-w-par"/>
+ </MACROS>
+ <OPTIONS>
+ <IDLCFLAGS value="-I..\. -I.. -I..\..\include -I$(BCB)\include -I$(BCB)\include\vcl
+ -I..\..\..\icu-sword\source\common -I..\..\..\icu-sword\source\i18n
+ -src_suffix cpp -D_ICU_ -D_ICUSWORD_ -DUSBINARY -DU_HAVE_PLACEMENT_NEW=0
+ -DUSELUCENE -D_CL_DISABLE_MULTITHREADING -boa"/>
+ <CFLAG1 value="-O2 -H=$(BCB)\lib\vcl50.csm -Hc -Vx -Ve -X- -a8 -6 -b- -k- -vi -tWC -tWM -c"/>
+ <PFLAGS value="-$Y- -$L- -$D- -v -JPHNE -M"/>
+ <RFLAGS value=""/>
+ <AFLAGS value="/mx /w2 /zn"/>
+ <LFLAGS value="-D"" -ap -Tpe -x -Gn"/>
+ </OPTIONS>
+ <LINKER>
+ <ALLOBJ value="c0x32.obj $(OBJFILES)"/>
+ <ALLRES value="$(RESFILES)"/>
+ <ALLLIB value="$(LIBFILES) $(LIBRARIES) import32.lib cw32mt.lib"/>
+ </LINKER>
+ <IDEOPTIONS>
+[Version Info]
+IncludeVerInfo=0
+AutoIncBuild=0
+MajorVer=1
+MinorVer=0
+Release=0
+Build=0
+Debug=0
+PreRelease=0
+Special=0
+Private=0
+DLL=0
+Locale=1033
+CodePage=1252
+
+[Version Info Keys]
+CompanyName=
+FileDescription=
+FileVersion=1.0.0.0
+InternalName=
+LegalCopyright=
+LegalTrademarks=
+OriginalFilename=
+ProductName=
+ProductVersion=1.0.0.0
+Comments=
+
+[HistoryLists\hlIncludePath]
+Count=5
+Item0=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl;..\..\..\icu-sword\source\common;..\..\..\icu-sword\source\i18n
+Item1=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item2=..\;..\..\utilities;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item3=..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item4=..\..\utilities;$(BCB)\include;$(BCB)\include\vcl
+
+[HistoryLists\hlLibraryPath]
+Count=5
+Item0=..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item1=..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item2=..\;..;$(BCB)\lib\obj;$(BCB)\lib
+Item3=..\;..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+Item4=..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+
+[HistoryLists\hlDebugSourcePath]
+Count=1
+Item0=$(BCB)\source\vcl
+
+[HistoryLists\hlConditionals]
+Count=2
+Item0=_ICU_;_ICUSWORD_;USBINARY;U_HAVE_PLACEMENT_NEW=0;USELUCENE;_CL_DISABLE_MULTITHREADING
+Item1=_DEBUG
+
+[Debugging]
+DebugSourceDirs=$(BCB)\source\vcl
+
+[Parameters]
+RunParams=./nasb nasb.xml
+HostApplication=
+RemoteHost=
+RemotePath=
+RemoteDebug=0
+
+[Compiler]
+ShowInfoMsgs=0
+LinkDebugVcl=0
+LinkCGLIB=0
+
+[Language]
+ActiveLang=
+ProjectLang=
+RootDir=
+ </IDEOPTIONS>
+</PROJECT>
diff --git a/utilities/bcppmake/addld.bpf b/utilities/bcppmake/addld.bpf new file mode 100644 index 0000000..229b854 --- /dev/null +++ b/utilities/bcppmake/addld.bpf @@ -0,0 +1,11 @@ +USEUNIT("..\addld.cpp");
+USELIB("..\..\..\icu-sword\as_is\borland\icuin.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icudatab.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icuuc.lib");
+USELIB("..\..\lib\libsword.lib");
+USELIB("..\..\..\biblecs\clucene\clucene.lib");
+//---------------------------------------------------------------------------
+This file is used by the project manager only and should be treated like the project file
+
+
+main
\ No newline at end of file diff --git a/utilities/bcppmake/addld.bpr b/utilities/bcppmake/addld.bpr new file mode 100644 index 0000000..7d17bdc --- /dev/null +++ b/utilities/bcppmake/addld.bpr @@ -0,0 +1,126 @@ +<?xml version='1.0' encoding='utf-8' ?>
+<!-- C++Builder XML Project -->
+<PROJECT>
+ <MACROS>
+ <VERSION value="BCB.05.03"/>
+ <PROJECT value="addld.exe"/>
+ <OBJFILES value="..\addld.obj"/>
+ <RESFILES value=""/>
+ <IDLFILES value=""/>
+ <IDLGENFILES value=""/>
+ <DEFFILE value=""/>
+ <RESDEPEN value="$(RESFILES)"/>
+ <LIBFILES value="..\..\..\icu-sword\as_is\borland\icuin.lib
+ ..\..\..\icu-sword\as_is\borland\icudatab.lib
+ ..\..\..\icu-sword\as_is\borland\icuuc.lib ..\..\lib\libsword.lib
+ ..\..\..\biblecs\clucene\clucene.lib"/>
+ <LIBRARIES value=""/>
+ <SPARELIBS value=""/>
+ <PACKAGES value="VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi
+ ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi
+ VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi
+ dclocx50.bpi bcb2kaxserver50.bpi"/>
+ <PATHCPP value=".;.."/>
+ <PATHPAS value=".;"/>
+ <PATHRC value=".;"/>
+ <PATHASM value=".;"/>
+ <DEBUGLIBPATH value="$(BCB)\lib\debug"/>
+ <RELEASELIBPATH value="$(BCB)\lib\release"/>
+ <LINKER value="tlink32"/>
+ <USERDEFINES value="_ICU_;_ICUSWORD_;USBINARY;U_HAVE_PLACEMENT_NEW=0;USELUCENE;_CL_DISABLE_MULTITHREADING"/>
+ <SYSDEFINES value="NO_STRICT;_NO_VCL"/>
+ <MAINSOURCE value="addld.bpf"/>
+ <INCLUDEPATH value="..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl;..\..\..\icu-sword\source\common;..\..\..\icu-sword\source\i18n"/>
+ <LIBPATH value="..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib"/>
+ <WARNINGS value="-w-par"/>
+ </MACROS>
+ <OPTIONS>
+ <IDLCFLAGS value="-I..\. -I.. -I..\..\include -I$(BCB)\include -I$(BCB)\include\vcl
+ -I..\..\..\icu-sword\source\common -I..\..\..\icu-sword\source\i18n
+ -src_suffix cpp -D_ICU_ -D_ICUSWORD_ -DUSBINARY -DU_HAVE_PLACEMENT_NEW=0
+ -DUSELUCENE -D_CL_DISABLE_MULTITHREADING -boa"/>
+ <CFLAG1 value="-O2 -H=$(BCB)\lib\vcl50.csm -Hc -Vx -Ve -X- -a8 -6 -b- -k- -vi -tWC -tWM -c"/>
+ <PFLAGS value="-$Y- -$L- -$D- -v -JPHNE -M"/>
+ <RFLAGS value=""/>
+ <AFLAGS value="/mx /w2 /zn"/>
+ <LFLAGS value="-D"" -ap -Tpe -x -Gn"/>
+ </OPTIONS>
+ <LINKER>
+ <ALLOBJ value="c0x32.obj $(OBJFILES)"/>
+ <ALLRES value="$(RESFILES)"/>
+ <ALLLIB value="$(LIBFILES) $(LIBRARIES) import32.lib cw32mt.lib"/>
+ </LINKER>
+ <IDEOPTIONS>
+[Version Info]
+IncludeVerInfo=0
+AutoIncBuild=0
+MajorVer=1
+MinorVer=0
+Release=0
+Build=0
+Debug=0
+PreRelease=0
+Special=0
+Private=0
+DLL=0
+Locale=1033
+CodePage=1252
+
+[Version Info Keys]
+CompanyName=
+FileDescription=
+FileVersion=1.0.0.0
+InternalName=
+LegalCopyright=
+LegalTrademarks=
+OriginalFilename=
+ProductName=
+ProductVersion=1.0.0.0
+Comments=
+
+[HistoryLists\hlIncludePath]
+Count=5
+Item0=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl;..\..\..\icu-sword\source\common;..\..\..\icu-sword\source\i18n
+Item1=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item2=..\;..\..\utilities;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item3=..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item4=..\..\utilities;$(BCB)\include;$(BCB)\include\vcl
+
+[HistoryLists\hlLibraryPath]
+Count=5
+Item0=..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item1=..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item2=..\;..;$(BCB)\lib\obj;$(BCB)\lib
+Item3=..\;..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+Item4=..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+
+[HistoryLists\hlDebugSourcePath]
+Count=1
+Item0=$(BCB)\source\vcl
+
+[HistoryLists\hlConditionals]
+Count=2
+Item0=_ICU_;_ICUSWORD_;USBINARY;U_HAVE_PLACEMENT_NEW=0;USELUCENE;_CL_DISABLE_MULTITHREADING
+Item1=_DEBUG
+
+[Debugging]
+DebugSourceDirs=$(BCB)\source\vcl
+
+[Parameters]
+RunParams=./nasb nasb.xml
+HostApplication=
+RemoteHost=
+RemotePath=
+RemoteDebug=0
+
+[Compiler]
+ShowInfoMsgs=0
+LinkDebugVcl=0
+LinkCGLIB=0
+
+[Language]
+ActiveLang=
+ProjectLang=
+RootDir=
+ </IDEOPTIONS>
+</PROJECT>
diff --git a/utilities/bcppmake/addvs.bpf b/utilities/bcppmake/addvs.bpf new file mode 100644 index 0000000..f104965 --- /dev/null +++ b/utilities/bcppmake/addvs.bpf @@ -0,0 +1,11 @@ +USEUNIT("..\addvs.cpp");
+USELIB("..\..\..\icu-sword\as_is\borland\icuin.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icudatab.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icuuc.lib");
+USELIB("..\..\lib\libsword.lib");
+USELIB("..\..\..\biblecs\clucene\clucene.lib");
+//---------------------------------------------------------------------------
+This file is used by the project manager only and should be treated like the project file
+
+
+main
\ No newline at end of file diff --git a/utilities/bcppmake/addvs.bpr b/utilities/bcppmake/addvs.bpr new file mode 100644 index 0000000..23efd76 --- /dev/null +++ b/utilities/bcppmake/addvs.bpr @@ -0,0 +1,126 @@ +<?xml version='1.0' encoding='utf-8' ?>
+<!-- C++Builder XML Project -->
+<PROJECT>
+ <MACROS>
+ <VERSION value="BCB.05.03"/>
+ <PROJECT value="addvs.exe"/>
+ <OBJFILES value="..\addvs.obj"/>
+ <RESFILES value=""/>
+ <IDLFILES value=""/>
+ <IDLGENFILES value=""/>
+ <DEFFILE value=""/>
+ <RESDEPEN value="$(RESFILES)"/>
+ <LIBFILES value="..\..\..\icu-sword\as_is\borland\icuin.lib
+ ..\..\..\icu-sword\as_is\borland\icudatab.lib
+ ..\..\..\icu-sword\as_is\borland\icuuc.lib ..\..\lib\libsword.lib
+ ..\..\..\biblecs\clucene\clucene.lib"/>
+ <LIBRARIES value=""/>
+ <SPARELIBS value=""/>
+ <PACKAGES value="VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi
+ ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi
+ VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi
+ dclocx50.bpi bcb2kaxserver50.bpi"/>
+ <PATHCPP value=".;.."/>
+ <PATHPAS value=".;"/>
+ <PATHRC value=".;"/>
+ <PATHASM value=".;"/>
+ <DEBUGLIBPATH value="$(BCB)\lib\debug"/>
+ <RELEASELIBPATH value="$(BCB)\lib\release"/>
+ <LINKER value="tlink32"/>
+ <USERDEFINES value="_ICU_;_ICUSWORD_;USBINARY;U_HAVE_PLACEMENT_NEW=0;USELUCENE;_CL_DISABLE_MULTITHREADING"/>
+ <SYSDEFINES value="NO_STRICT;_NO_VCL"/>
+ <MAINSOURCE value="addvs.bpf"/>
+ <INCLUDEPATH value="..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl;..\..\..\icu-sword\source\common;..\..\..\icu-sword\source\i18n"/>
+ <LIBPATH value="..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib"/>
+ <WARNINGS value="-w-par"/>
+ </MACROS>
+ <OPTIONS>
+ <IDLCFLAGS value="-I..\. -I.. -I..\..\include -I$(BCB)\include -I$(BCB)\include\vcl
+ -I..\..\..\icu-sword\source\common -I..\..\..\icu-sword\source\i18n
+ -src_suffix cpp -D_ICU_ -D_ICUSWORD_ -DUSBINARY -DU_HAVE_PLACEMENT_NEW=0
+ -DUSELUCENE -D_CL_DISABLE_MULTITHREADING -boa"/>
+ <CFLAG1 value="-O2 -H=$(BCB)\lib\vcl50.csm -Hc -Vx -Ve -X- -a8 -6 -b- -k- -vi -tWC -tWM -c"/>
+ <PFLAGS value="-$Y- -$L- -$D- -v -JPHNE -M"/>
+ <RFLAGS value=""/>
+ <AFLAGS value="/mx /w2 /zn"/>
+ <LFLAGS value="-D"" -ap -Tpe -x -Gn"/>
+ </OPTIONS>
+ <LINKER>
+ <ALLOBJ value="c0x32.obj $(OBJFILES)"/>
+ <ALLRES value="$(RESFILES)"/>
+ <ALLLIB value="$(LIBFILES) $(LIBRARIES) import32.lib cw32mt.lib"/>
+ </LINKER>
+ <IDEOPTIONS>
+[Version Info]
+IncludeVerInfo=0
+AutoIncBuild=0
+MajorVer=1
+MinorVer=0
+Release=0
+Build=0
+Debug=0
+PreRelease=0
+Special=0
+Private=0
+DLL=0
+Locale=1033
+CodePage=1252
+
+[Version Info Keys]
+CompanyName=
+FileDescription=
+FileVersion=1.0.0.0
+InternalName=
+LegalCopyright=
+LegalTrademarks=
+OriginalFilename=
+ProductName=
+ProductVersion=1.0.0.0
+Comments=
+
+[HistoryLists\hlIncludePath]
+Count=5
+Item0=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl;..\..\..\icu-sword\source\common;..\..\..\icu-sword\source\i18n
+Item1=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item2=..\;..\..\utilities;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item3=..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item4=..\..\utilities;$(BCB)\include;$(BCB)\include\vcl
+
+[HistoryLists\hlLibraryPath]
+Count=5
+Item0=..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item1=..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item2=..\;..;$(BCB)\lib\obj;$(BCB)\lib
+Item3=..\;..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+Item4=..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+
+[HistoryLists\hlDebugSourcePath]
+Count=1
+Item0=$(BCB)\source\vcl
+
+[HistoryLists\hlConditionals]
+Count=2
+Item0=_ICU_;_ICUSWORD_;USBINARY;U_HAVE_PLACEMENT_NEW=0;USELUCENE;_CL_DISABLE_MULTITHREADING
+Item1=_DEBUG
+
+[Debugging]
+DebugSourceDirs=$(BCB)\source\vcl
+
+[Parameters]
+RunParams=./nasb nasb.xml
+HostApplication=
+RemoteHost=
+RemotePath=
+RemoteDebug=0
+
+[Compiler]
+ShowInfoMsgs=0
+LinkDebugVcl=0
+LinkCGLIB=0
+
+[Language]
+ActiveLang=
+ProjectLang=
+RootDir=
+ </IDEOPTIONS>
+</PROJECT>
diff --git a/utilities/bcppmake/libsword.bpf b/utilities/bcppmake/libsword.bpf index e4c4667..5d88df9 100644 --- a/utilities/bcppmake/libsword.bpf +++ b/utilities/bcppmake/libsword.bpf @@ -79,6 +79,7 @@ USEUNIT("..\..\src\modules\filters\utf8bidireorder.cpp"); USEUNIT("..\..\src\modules\filters\utf8cantillation.cpp"); USEUNIT("..\..\src\modules\filters\utf8greekaccents.cpp"); USEUNIT("..\..\src\modules\filters\utf8hebrewpoints.cpp"); +USEUNIT("..\..\src\modules\filters\utf8arabicpoints.cpp"); USEUNIT("..\..\src\modules\filters\utf8html.cpp"); USEUNIT("..\..\src\modules\filters\utf8latin1.cpp"); USEUNIT("..\..\src\modules\filters\utf8nfc.cpp"); diff --git a/utilities/bcppmake/libsword.bpr b/utilities/bcppmake/libsword.bpr index 8706c7a..ef0b094 100644 --- a/utilities/bcppmake/libsword.bpr +++ b/utilities/bcppmake/libsword.bpr @@ -64,6 +64,7 @@ ..\..\src\modules\filters\utf8cantillation.obj ..\..\src\modules\filters\utf8greekaccents.obj ..\..\src\modules\filters\utf8hebrewpoints.obj + ..\..\src\modules\filters\utf8arabicpoints.obj ..\..\src\modules\filters\utf8html.obj ..\..\src\modules\filters\utf8latin1.obj ..\..\src\modules\filters\utf8nfc.obj diff --git a/utilities/bcppmake/treeidxutil.bpf b/utilities/bcppmake/treeidxutil.bpf new file mode 100644 index 0000000..88eaef2 --- /dev/null +++ b/utilities/bcppmake/treeidxutil.bpf @@ -0,0 +1,11 @@ +USEUNIT("..\treeidxutil.cpp");
+USELIB("..\..\..\icu-sword\as_is\borland\icuin.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icudatab.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icuuc.lib");
+USELIB("..\..\lib\libsword.lib");
+USELIB("..\..\..\biblecs\clucene\clucene.lib");
+//---------------------------------------------------------------------------
+This file is used by the project manager only and should be treated like the project file
+
+
+main
\ No newline at end of file diff --git a/utilities/bcppmake/treeidxutil.bpr b/utilities/bcppmake/treeidxutil.bpr new file mode 100644 index 0000000..c04ef8c --- /dev/null +++ b/utilities/bcppmake/treeidxutil.bpr @@ -0,0 +1,122 @@ +<?xml version='1.0' encoding='utf-8' ?>
+<!-- C++Builder XML Project -->
+<PROJECT>
+ <MACROS>
+ <VERSION value="BCB.05.03"/>
+ <PROJECT value="treeidxutil.exe"/>
+ <OBJFILES value="..\treeidxutil.obj"/>
+ <RESFILES value=""/>
+ <IDLFILES value=""/>
+ <IDLGENFILES value=""/>
+ <DEFFILE value=""/>
+ <RESDEPEN value="$(RESFILES)"/>
+ <LIBFILES value="..\..\..\icu-sword\as_is\borland\icuin.lib
+ ..\..\..\icu-sword\as_is\borland\icudatab.lib
+ ..\..\..\icu-sword\as_is\borland\icuuc.lib ..\..\lib\libsword.lib
+ ..\..\..\biblecs\clucene\clucene.lib"/>
+ <LIBRARIES value=""/>
+ <SPARELIBS value=""/>
+ <PACKAGES value="VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi
+ ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi
+ VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi
+ dclocx50.bpi bcb2kaxserver50.bpi"/>
+ <PATHCPP value=".;.."/>
+ <PATHPAS value=".;"/>
+ <PATHRC value=".;"/>
+ <PATHASM value=".;"/>
+ <DEBUGLIBPATH value="$(BCB)\lib\debug"/>
+ <RELEASELIBPATH value="$(BCB)\lib\release"/>
+ <LINKER value="tlink32"/>
+ <USERDEFINES value=""/>
+ <SYSDEFINES value="NO_STRICT;_NO_VCL"/>
+ <MAINSOURCE value="treeidxutil.bpf"/>
+ <INCLUDEPATH value="..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl"/>
+ <LIBPATH value="..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib"/>
+ <WARNINGS value="-w-par"/>
+ </MACROS>
+ <OPTIONS>
+ <IDLCFLAGS value="-I..\. -I.. -I..\..\include -I$(BCB)\include -I$(BCB)\include\vcl
+ -src_suffix cpp -boa"/>
+ <CFLAG1 value="-O2 -H=$(BCB)\lib\vcl50.csm -Hc -Vx -Ve -X- -a8 -6 -b- -k- -vi -tWC -tWM -c"/>
+ <PFLAGS value="-$Y- -$L- -$D- -v -JPHNE -M"/>
+ <RFLAGS value=""/>
+ <AFLAGS value="/mx /w2 /zn"/>
+ <LFLAGS value="-D"" -ap -Tpe -x -Gn"/>
+ </OPTIONS>
+ <LINKER>
+ <ALLOBJ value="c0x32.obj $(OBJFILES)"/>
+ <ALLRES value="$(RESFILES)"/>
+ <ALLLIB value="$(LIBFILES) $(LIBRARIES) import32.lib cw32mt.lib"/>
+ </LINKER>
+ <IDEOPTIONS>
+[Version Info]
+IncludeVerInfo=0
+AutoIncBuild=0
+MajorVer=1
+MinorVer=0
+Release=0
+Build=0
+Debug=0
+PreRelease=0
+Special=0
+Private=0
+DLL=0
+Locale=1033
+CodePage=1252
+
+[Version Info Keys]
+CompanyName=
+FileDescription=
+FileVersion=1.0.0.0
+InternalName=
+LegalCopyright=
+LegalTrademarks=
+OriginalFilename=
+ProductName=
+ProductVersion=1.0.0.0
+Comments=
+
+[HistoryLists\hlIncludePath]
+Count=4
+Item0=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item1=..\;..\..\utilities;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item2=..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item3=..\..\utilities;$(BCB)\include;$(BCB)\include\vcl
+
+[HistoryLists\hlLibraryPath]
+Count=5
+Item0=..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item1=..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item2=..\;..;$(BCB)\lib\obj;$(BCB)\lib
+Item3=..\;..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+Item4=..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+
+[HistoryLists\hlDebugSourcePath]
+Count=1
+Item0=$(BCB)\source\vcl
+
+[HistoryLists\hlConditionals]
+Count=1
+Item0=_DEBUG
+
+[Debugging]
+DebugSourceDirs=$(BCB)\source\vcl
+
+[Parameters]
+RunParams=Gen1:1
+HostApplication=
+RemoteHost=
+RemotePath=
+RemoteDebug=0
+
+[Compiler]
+ShowInfoMsgs=0
+LinkDebugVcl=0
+LinkCGLIB=0
+
+[Language]
+ActiveLang=
+ProjectLang=
+RootDir=
+ </IDEOPTIONS>
+</PROJECT>
diff --git a/utilities/bcppmake/utilities.bpg b/utilities/bcppmake/utilities.bpg index d5c0db4..6d2e99b 100644 --- a/utilities/bcppmake/utilities.bpg +++ b/utilities/bcppmake/utilities.bpg @@ -12,8 +12,9 @@ BRCC = $(ROOT)\bin\brcc32.exe $** PROJECTS = icuuc.lib icuin.lib libcurl.lib clucene.lib libsword.lib \ osis2mod.exe mod2zmod.exe mod2vpl.exe mkfastmod.exe imp2gbs.exe vpl2mod.exe \ imp2ld.exe imp2vs.exe mod2imp.exe cipherraw.exe step2vpl.exe stepdump.exe \ - mod2osis.exe vs2osisref.exe xml2gbs.exe diatheke.exe installmgr.exe \ - tei2mod.exe + mod2osis.exe vs2osisref.exe vs2osisreftxt.exe xml2gbs.exe diatheke.exe \ + installmgr.exe tei2mod.exe emptyvss.exe addgb.exe addld.exe addvs.exe \ + treeidxutil.exe #------------------------------------------------------------------------------ default: $(PROJECTS) #------------------------------------------------------------------------------ @@ -110,4 +111,28 @@ libcurl.lib: ..\..\..\biblecs\apps\InstallMgr\libcurl.bpr $(ROOT)\bin\bpr2mak -t$(ROOT)\bin\deflib.bmk $** $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak +addgb.exe: addgb.bpr + $(ROOT)\bin\bpr2mak $** + $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak + +addld.exe: addld.bpr + $(ROOT)\bin\bpr2mak $** + $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak + +addvs.exe: addvs.bpr + $(ROOT)\bin\bpr2mak $** + $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak + +emptyvss.exe: emptyvss.bpr + $(ROOT)\bin\bpr2mak $** + $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak + +vs2osisreftxt.exe: vs2osisreftxt.bpr + $(ROOT)\bin\bpr2mak $** + $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak + +treeidxutil.exe: treeidxutil.bpr + $(ROOT)\bin\bpr2mak $** + $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak + diff --git a/utilities/bcppmake/vs2osisreftxt.bpf b/utilities/bcppmake/vs2osisreftxt.bpf new file mode 100644 index 0000000..fd5c23e --- /dev/null +++ b/utilities/bcppmake/vs2osisreftxt.bpf @@ -0,0 +1,11 @@ +USEUNIT("..\vs2osisreftxt.cpp");
+USELIB("..\..\..\icu-sword\as_is\borland\icuin.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icudatab.lib");
+USELIB("..\..\..\icu-sword\as_is\borland\icuuc.lib");
+USELIB("..\..\lib\libsword.lib");
+USELIB("..\..\..\biblecs\clucene\clucene.lib");
+//---------------------------------------------------------------------------
+This file is used by the project manager only and should be treated like the project file
+
+
+main
\ No newline at end of file diff --git a/utilities/bcppmake/vs2osisreftxt.bpr b/utilities/bcppmake/vs2osisreftxt.bpr new file mode 100644 index 0000000..70049a2 --- /dev/null +++ b/utilities/bcppmake/vs2osisreftxt.bpr @@ -0,0 +1,122 @@ +<?xml version='1.0' encoding='utf-8' ?>
+<!-- C++Builder XML Project -->
+<PROJECT>
+ <MACROS>
+ <VERSION value="BCB.05.03"/>
+ <PROJECT value="vs2osisreftxt.exe"/>
+ <OBJFILES value="..\vs2osisreftxt.obj"/>
+ <RESFILES value=""/>
+ <IDLFILES value=""/>
+ <IDLGENFILES value=""/>
+ <DEFFILE value=""/>
+ <RESDEPEN value="$(RESFILES)"/>
+ <LIBFILES value="..\..\..\icu-sword\as_is\borland\icuin.lib
+ ..\..\..\icu-sword\as_is\borland\icudatab.lib
+ ..\..\..\icu-sword\as_is\borland\icuuc.lib ..\..\lib\libsword.lib
+ ..\..\..\biblecs\clucene\clucene.lib"/>
+ <LIBRARIES value=""/>
+ <SPARELIBS value=""/>
+ <PACKAGES value="VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi
+ ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi
+ VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi
+ dclocx50.bpi bcb2kaxserver50.bpi"/>
+ <PATHCPP value=".;.."/>
+ <PATHPAS value=".;"/>
+ <PATHRC value=".;"/>
+ <PATHASM value=".;"/>
+ <DEBUGLIBPATH value="$(BCB)\lib\debug"/>
+ <RELEASELIBPATH value="$(BCB)\lib\release"/>
+ <LINKER value="tlink32"/>
+ <USERDEFINES value=""/>
+ <SYSDEFINES value="NO_STRICT;_NO_VCL"/>
+ <MAINSOURCE value="vs2osisreftxt.bpf"/>
+ <INCLUDEPATH value="..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl"/>
+ <LIBPATH value="..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib"/>
+ <WARNINGS value="-w-par"/>
+ </MACROS>
+ <OPTIONS>
+ <IDLCFLAGS value="-I..\. -I.. -I..\..\include -I$(BCB)\include -I$(BCB)\include\vcl
+ -src_suffix cpp -boa"/>
+ <CFLAG1 value="-O2 -H=$(BCB)\lib\vcl50.csm -Hc -Vx -Ve -X- -a8 -6 -b- -k- -vi -tWC -tWM -c"/>
+ <PFLAGS value="-$Y- -$L- -$D- -v -JPHNE -M"/>
+ <RFLAGS value=""/>
+ <AFLAGS value="/mx /w2 /zn"/>
+ <LFLAGS value="-D"" -ap -Tpe -x -Gn"/>
+ </OPTIONS>
+ <LINKER>
+ <ALLOBJ value="c0x32.obj $(OBJFILES)"/>
+ <ALLRES value="$(RESFILES)"/>
+ <ALLLIB value="$(LIBFILES) $(LIBRARIES) import32.lib cw32mt.lib"/>
+ </LINKER>
+ <IDEOPTIONS>
+[Version Info]
+IncludeVerInfo=0
+AutoIncBuild=0
+MajorVer=1
+MinorVer=0
+Release=0
+Build=0
+Debug=0
+PreRelease=0
+Special=0
+Private=0
+DLL=0
+Locale=1033
+CodePage=1252
+
+[Version Info Keys]
+CompanyName=
+FileDescription=
+FileVersion=1.0.0.0
+InternalName=
+LegalCopyright=
+LegalTrademarks=
+OriginalFilename=
+ProductName=
+ProductVersion=1.0.0.0
+Comments=
+
+[HistoryLists\hlIncludePath]
+Count=4
+Item0=..\;..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item1=..\;..\..\utilities;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item2=..;..\..\include;$(BCB)\include;$(BCB)\include\vcl
+Item3=..\..\utilities;$(BCB)\include;$(BCB)\include\vcl
+
+[HistoryLists\hlLibraryPath]
+Count=5
+Item0=..\;..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item1=..;..\..\lib;$(BCB)\lib\obj;$(BCB)\lib
+Item2=..\;..;$(BCB)\lib\obj;$(BCB)\lib
+Item3=..\;..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+Item4=..\..\utilities;$(BCB)\lib\obj;$(BCB)\lib
+
+[HistoryLists\hlDebugSourcePath]
+Count=1
+Item0=$(BCB)\source\vcl
+
+[HistoryLists\hlConditionals]
+Count=1
+Item0=_DEBUG
+
+[Debugging]
+DebugSourceDirs=$(BCB)\source\vcl
+
+[Parameters]
+RunParams=Gen1:1
+HostApplication=
+RemoteHost=
+RemotePath=
+RemoteDebug=0
+
+[Compiler]
+ShowInfoMsgs=0
+LinkDebugVcl=0
+LinkCGLIB=0
+
+[Language]
+ActiveLang=
+ProjectLang=
+RootDir=
+ </IDEOPTIONS>
+</PROJECT>
diff --git a/utilities/cipherraw.cpp b/utilities/cipherraw.cpp index 16aee18..026e06d 100644 --- a/utilities/cipherraw.cpp +++ b/utilities/cipherraw.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <fcntl.h> diff --git a/utilities/diatheke/.cvsignore b/utilities/diatheke/.cvsignore deleted file mode 100644 index f5ce63f..0000000 --- a/utilities/diatheke/.cvsignore +++ /dev/null @@ -1,5 +0,0 @@ -.deps -.libs -Makefile -Makefile.in -diatheke diff --git a/utilities/diatheke/Makefile.in b/utilities/diatheke/Makefile.in index 36d4273..fa59942 100644 --- a/utilities/diatheke/Makefile.in +++ b/utilities/diatheke/Makefile.in @@ -1,8 +1,8 @@ -# Makefile.in generated by automake 1.10 from Makefile.am. +# Makefile.in generated by automake 1.10.2 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -40,7 +40,10 @@ DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ subdir = utilities/diatheke ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/acx_clucene.m4 \ - $(top_srcdir)/m4/cppunit.m4 $(top_srcdir)/configure.ac + $(top_srcdir)/m4/cppunit.m4 $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(install_sh) -d @@ -56,7 +59,7 @@ diatheke_OBJECTS = $(am_diatheke_OBJECTS) am__DEPENDENCIES_1 = diatheke_DEPENDENCIES = $(top_builddir)/lib/libsword.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) -DEFAULT_INCLUDES = -I. -I$(top_builddir)/include@am__isrc@ +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/include depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ @@ -104,14 +107,14 @@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ -ECHO = @ECHO@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -F77 = @F77@ -FFLAGS = @FFLAGS@ +FGREP = @FGREP@ GENCCODE = @GENCCODE@ GENCMN = @GENCMN@ GENRB = @GENRB@ @@ -125,17 +128,23 @@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -158,7 +167,7 @@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ -ac_ct_F77 = @ac_ct_F77@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -192,6 +201,7 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ +lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -210,6 +220,7 @@ target_mingw32 = @target_mingw32@ target_os = @target_os@ target_system = @target_system@ target_vendor = @target_vendor@ +top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ with_conf = @with_conf@ @@ -239,8 +250,8 @@ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/cg @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ - && exit 0; \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ @@ -273,8 +284,8 @@ install-binPROGRAMS: $(bin_PROGRAMS) || test -f $$p1 \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done @@ -342,8 +353,8 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ mkid -fID $$unique tags: TAGS @@ -355,8 +366,8 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ @@ -366,13 +377,12 @@ ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ - here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique diff --git a/utilities/diatheke/cgi/dia-def.pl b/utilities/diatheke/cgi/dia-def.pl index e2f1d4f..206aaa6 100755 --- a/utilities/diatheke/cgi/dia-def.pl +++ b/utilities/diatheke/cgi/dia-def.pl @@ -1,5 +1,22 @@ #!/usr/bin/perl +# * +# * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) +# * CrossWire Bible Society +# * P. O. Box 2528 +# * Tempe, AZ 85280-2528 +# * +# * This program is free software; you can redistribute it and/or modify it +# * under the terms of the GNU General Public License as published by the +# * Free Software Foundation version 2. +# * +# * This program is distributed in the hope that it will be useful, but +# * WITHOUT ANY WARRANTY; without even the implied warranty of +# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# * General Public License for more details. +# * + + #change this variable to hostname of your server @values = split(/\&/,$ENV{'QUERY_STRING'}); $DOMAIN = $ENV{'REMOTE_ADDR'}; diff --git a/utilities/diatheke/cgi/diatheke.pl b/utilities/diatheke/cgi/diatheke.pl index ee36f11..8150d2c 100755 --- a/utilities/diatheke/cgi/diatheke.pl +++ b/utilities/diatheke/cgi/diatheke.pl @@ -1,5 +1,33 @@ #!/usr/bin/perl +######################################################################### +### WARNING: This is for demonstration purposes only. Do not deploy +### this CGI on a live website. There are security issues. +### You will likely be hacked if you try to deploy this on a +### live site. +### +### For a web Bible interface, please consider using +### SwordWeb, which can be also be installed on your +### server: http://www.crosswire.org/swordweb/ +######################################################################## + +# * +# * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) +# * CrossWire Bible Society +# * P. O. Box 2528 +# * Tempe, AZ 85280-2528 +# * +# * This program is free software; you can redistribute it and/or modify it +# * under the terms of the GNU General Public License as published by the +# * Free Software Foundation version 2. +# * +# * This program is distributed in the hope that it will be useful, but +# * WITHOUT ANY WARRANTY; without even the implied warranty of +# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# * General Public License for more details. +# * + + # Typical Linux/Unix settings $err = "2> /dev/null"; $sword_path = "/home/sword"; # SWORD_PATH environment variable you want to use @@ -110,8 +138,7 @@ foreach $i (@values) { $range = $mydata; $range =~ tr/+/ /; $range =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; - $range = "-r \"$range\""; - $range = shell_escape($range); + $range = "-r '" . shell_escape($range) . "'"; } elsif ($varname eq "strongs") { diff --git a/utilities/diatheke/corediatheke.cpp b/utilities/diatheke/corediatheke.cpp index d691a2f..f2dcac9 100644 --- a/utilities/diatheke/corediatheke.cpp +++ b/utilities/diatheke/corediatheke.cpp @@ -1,8 +1,23 @@ // Diatheke 4.2 by Chris Little <chrislit@crosswire.org> -// Copyright 1999-2002 by CrossWire Bible Society +// Copyright 1999-2009 by CrossWire Bible Society // http://www.crosswire.org/sword/diatheke -// Licensed under GNU General Public License (GPL) -// see accompanying LICENSE file for license details + +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include "corediatheke.h" #include <regex.h> @@ -64,7 +79,7 @@ void systemquery(const char * key, ostream* output){ if (names && descriptions) *output << " : "; if (descriptions) *output << target->Description(); *output << endl; - } + } } if (types) *output << "Dictionaries:\n"; for (it = manager.Modules.begin(); it != manager.Modules.end(); it++) { @@ -76,27 +91,39 @@ void systemquery(const char * key, ostream* output){ *output << endl; } } + if (types) *output << "Generic books:\n"; + for (it = manager.Modules.begin(); it != manager.Modules.end(); it++) { + target = it->second; + if (!strcmp(target->Type(), "Generic Books")) { + if (names) *output << target->Name(); + if (names && descriptions) *output << " : "; + if (descriptions) *output << target->Description(); + *output << endl; + } + } + } } -void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAIN, unsigned char outputencoding = ENC_UTF8, unsigned long optionfilters = 0, unsigned char searchtype = ST_NONE, const char *range = 0, const char *text = 0, const char *locale = 0, const char *ref = 0, ostream* output = &cout, const char *script = 0, signed short variants = 0) { - static DiathekeMgr manager; +void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAIN, unsigned char outputencoding = ENC_UTF8, unsigned long optionfilters = 0, unsigned char searchtype = ST_NONE, const char *range = 0, const char *text = 0, const char *locale = 0, const char *ref = 0, ostream* output = &cout, const char *script = 0, signed short variants = 0) { + static DiathekeMgr manager(NULL, NULL, false, outputencoding, outputformat, + ((OP_BIDI & optionfilters) == OP_BIDI), + ((OP_ARSHAPE & optionfilters) == OP_ARSHAPE)); ModMap::iterator it; ListKey listkey; SectionMap::iterator sit; ConfigEntMap::iterator eit; - - SWModule * target; + + SWModule *target; char *font = 0; char inputformat = 0; SWBuf encoding; - char querytype = 0; + char querytype = 0; if (locale) { LocaleMgr::getSystemLocaleMgr()->setDefaultLocaleName(locale); } - VerseKey vk; //deal with queries to "system" if (!::stricmp(text, "system")) { @@ -113,12 +140,13 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI return; } target = (*it).second; + SWKey *p = target->CreateKey(); + VerseKey *parser = SWDYNAMIC_CAST(VerseKey, p); + if (!parser) { + delete p; + parser = new VerseKey(); + } - manager.Markup(outputformat); - manager.Encoding(outputencoding); - manager.bidi = ((OP_BIDI & optionfilters) == OP_BIDI); - manager.shape = ((OP_ARSHAPE & optionfilters) == OP_ARSHAPE); - if ((sit = manager.config->Sections.find((*it).second->Name())) != manager.config->Sections.end()) { if ((eit = (*sit).second.find("SourceType")) != (*sit).second.end()) { if (!::stricmp((char *)(*eit).second.c_str(), "GBF")) @@ -127,6 +155,8 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI inputformat = FMT_THML; else if (!::stricmp((char *)(*eit).second.c_str(), "OSIS")) inputformat = FMT_OSIS; + else if (!::stricmp((char *)(*eit).second.c_str(), "TEI")) + inputformat = FMT_TEI; } encoding = ((eit = (*sit).second.find("Encoding")) != (*sit).second.end()) ? (*eit).second : (SWBuf)""; } @@ -143,12 +173,16 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI case FMT_OSIS : *output << "OSIS"; break; + case FMT_TEI : + *output << "TEI"; + break; default: *output << "Other"; - } + } *output << ";"; *output << target->Type(); *output << ";"; + delete parser; return; } @@ -160,7 +194,9 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI querytype = QT_COMM; else if (!strcmp(target->Type(), "Lexicons / Dictionaries")) querytype = QT_LD; - + else if (!strcmp(target->Type(), "Generic Books")) + querytype = QT_LD; + if (optionfilters & OP_FOOTNOTES) manager.setGlobalOption("Footnotes","On"); else @@ -208,13 +244,13 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI manager.setGlobalOption("Variants", "Secondary Readings"); } else - manager.setGlobalOption("Transliteration", "Primary Readings"); + manager.setGlobalOption("Variants", "Primary Readings"); if (optionfilters & OP_TRANSLITERATOR && script) manager.setGlobalOption("Transliteration", script); else manager.setGlobalOption("Transliteration", "Off"); - + if (querytype == QT_SEARCH) { //this test is just to determine if we've got SWKeys or VerseKeys @@ -224,7 +260,9 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI querytype = QT_BIBLE; else if (!strcmp(target->Type(), "Lexicons / Dictionaries")) querytype = QT_LD; - + else if (!strcmp(target->Type(), "Generic Books")) + querytype = QT_LD; + //do search stuff char st = 1 - searchtype; if (querytype == QT_BIBLE) { @@ -235,18 +273,17 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI *output << "\"-- "; if (range) { - VerseKey parser; - ListKey scope = parser.ParseVerseList(range, parser, true); + ListKey scope = parser->ParseVerseList(range, "Gen 1:1", true); listkey = target->Search(ref, st, REG_ICASE, &scope); } else listkey = target->Search(ref, st, REG_ICASE); - + if (strlen((const char*)listkey)) { if (!listkey.Error()) { if (outputformat == FMT_CGI) *output << "<entry>"; if (querytype == QT_BIBLE) { - vk = listkey; - *output << (const char *)vk; + *parser = listkey; + *output << (const char *)*parser; } else *output << (const char *)listkey; if (outputformat == FMT_CGI) *output << "</entry>"; @@ -256,20 +293,20 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI *output << " ; "; if (outputformat == FMT_CGI) *output << "<entry>"; if (querytype == QT_BIBLE) { - vk = listkey; - *output << (const char *)vk; + *parser = listkey; + *output << (const char *)*parser; } else *output << (const char *)listkey; if (outputformat == FMT_CGI) *output << "</entry>"; listkey++; } *output << " -- "; - + char *temp = new char[10]; sprintf(temp, "%u", listkey.Count()); *output << temp; delete [] temp; - + *output << " matches total ("; *output << target->Name(); *output << ")\n"; @@ -280,12 +317,12 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI *output << ")\n"; } } - + else if (querytype == QT_LD) { //do dictionary stuff - + target->setKey(ref); - + const char * text = (const char *) *target; if (outputformat == FMT_RTF) { @@ -298,8 +335,8 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI } else if (outputformat == FMT_HTML) { *output << "<meta http-equiv=\"content-type\" content=\"text/html; charset=UTF-8\">"; - } - + } + if (strlen(text)) { *output << (char*)target->KeyText(); if (font && (outputformat == FMT_HTML || outputformat == FMT_THML || outputformat == FMT_CGI)) { @@ -324,14 +361,14 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI *output << "("; *output << target->Name(); *output << ")\n"; - } + } if (outputformat == FMT_RTF) { *output << "}"; } } - + else if (querytype == QT_BIBLE || querytype == QT_COMM) { //do commentary/Bible stuff @@ -341,8 +378,8 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI if (strlen(font) == 0) font = 0; } } - - listkey = vk.ParseVerseList(ref, "Gen1:1", true); + + listkey = parser->ParseVerseList(ref, "Gen1:1", true); int i; if (outputformat == FMT_RTF) { @@ -359,10 +396,10 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI for (i = 0; i < listkey.Count() && maxverses; i++) { VerseKey *element = SWDYNAMIC_CAST(VerseKey, listkey.GetElement(i)); - if (element) { + if (element && element->isBoundSet()) { target->Key(element->LowerBound()); - vk = element->UpperBound(); - while (maxverses && target->Key() <= vk) { + *parser = element->UpperBound(); + while (maxverses && target->Key() <= *parser) { *output << (char*)target->KeyText(); if (font && (outputformat == FMT_HTML || outputformat == FMT_THML || outputformat == FMT_CGI)) { *output << ": <font face=\""; @@ -393,8 +430,8 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI *output << "<CM>"; *output << "\n"; - - if (target->Key() == vk) + + if (target->Key() == *parser) break; maxverses--; (*target)++; @@ -421,7 +458,7 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI else if (outputformat == FMT_RTF) { *output << "}"; } - + if (inputformat != FMT_THML && (outputformat == FMT_HTML || outputformat == FMT_THML || outputformat == FMT_CGI)) *output << "<br />"; else if (outputformat == FMT_OSIS) @@ -445,5 +482,6 @@ void doquery(unsigned long maxverses = -1, unsigned char outputformat = FMT_PLAI } } + delete parser; } diff --git a/utilities/diatheke/corediatheke.h b/utilities/diatheke/corediatheke.h index 0364b37..2ad4801 100644 --- a/utilities/diatheke/corediatheke.h +++ b/utilities/diatheke/corediatheke.h @@ -1,7 +1,23 @@ // Diatheke 4.2 by Chris Little <chrislit@crosswire.org> -// Copyright 1999-2002 by CrossWire Bible Society http://www.crosswire.org -// Licensed under GNU General Public License (GPL) -// see accompanying LICENSE file for license details +// Copyright 1999-2009 by CrossWire Bible Society +// http://www.crosswire.org/sword/diatheke + +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <stdio.h> #include <iostream> @@ -31,7 +47,7 @@ #define OP_BIDI 2048 #define OP_VARIANTS 4096 #define OP_RED 8192 - +#define OP_ARABICPOINTS 16384 #define ST_NONE 0 #define ST_REGEX 1 //0 #define ST_PHRASE 2 // -1 diff --git a/utilities/diatheke/diafiltmgr.h b/utilities/diatheke/diafiltmgr.h index 2ca34eb..0acdf1a 100644 --- a/utilities/diatheke/diafiltmgr.h +++ b/utilities/diatheke/diafiltmgr.h @@ -23,11 +23,12 @@ #define FMT_CGI 127 #include <encfiltmgr.h> + #ifndef NO_SWORD_NAMESPACE using namespace sword; #endif -class SWDLLEXPORT DiathekeFilterMgr : public EncodingFilterMgr { +class DiathekeFilterMgr : public EncodingFilterMgr { protected: SWFilter* fromthml; SWFilter* fromgbf; diff --git a/utilities/diatheke/diatheke.cpp b/utilities/diatheke/diatheke.cpp index 0a99c07..3ffe194 100644 --- a/utilities/diatheke/diatheke.cpp +++ b/utilities/diatheke/diatheke.cpp @@ -1,9 +1,23 @@ // Diatheke 4.2.1 by Chris Little <chrislit@crosswire.org> // Copyright 1999-2005 by CrossWire Bible Society // http://www.crosswire.org/sword/diatheke -// Licensed under GNU General Public License (GPL) -// see accompanying LICENSE file for license details +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include "corediatheke.h" #include "diathekemgr.h" @@ -32,7 +46,7 @@ void printsyntax() { fprintf (stderr, "Valid search_type values are: regex, multiword, and phrase(def).\n"); fprintf (stderr, "Valid option_filters values are: n (Strong's numbers),\n"); fprintf (stderr, " f (Footnotes), m (Morphology), h (Section Headings),\n"); - fprintf (stderr, " c (Cantillation), v (Hebrew Vowels), a (Greek Accents),\n"); + fprintf (stderr, " c (Cantillation), v (Hebrew Vowels), a (Greek Accents), p (Arabic Vowels)\n"); fprintf (stderr, " l (Lemmas), s (Scripture Crossrefs), r (Arabic Shaping,\n"); fprintf (stderr, " b (Bi-Directional Reordering), x (Red Words of Christ)\n"); @@ -129,6 +143,8 @@ int main(int argc, char **argv) optionfilters |= OP_BIDI; if (strchr(argv[i+1], 'x')) optionfilters |= OP_RED; + if (strchr(argv[i+1], 'p')) + optionfilters |= OP_ARABICPOINTS; i++; } } diff --git a/utilities/diatheke/diatheke.dsp b/utilities/diatheke/diatheke.dsp deleted file mode 100644 index 03085d3..0000000 --- a/utilities/diatheke/diatheke.dsp +++ /dev/null @@ -1,204 +0,0 @@ -# Microsoft Developer Studio Project File - Name="diatheke" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Console Application" 0x0103 - -CFG=diatheke - Win32 Debug with ICU -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "diatheke.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "diatheke.mak" CFG="diatheke - Win32 Debug with ICU" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "diatheke - Win32 Release" (based on "Win32 (x86) Console Application") -!MESSAGE "diatheke - Win32 Debug" (based on "Win32 (x86) Console Application") -!MESSAGE "diatheke - Win32 Debug with ICU" (based on "Win32 (x86) Console Application") -!MESSAGE "diatheke - Win32 Release with ICU" (based on "Win32 (x86) Console Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "diatheke - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c -# ADD CPP /nologo /MD /w /W0 /GX /O2 /I "../../include" /I "../../src/utilfuns/win32" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR /YX /FD /c -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libswordvc6.lib /nologo /subsystem:console /machine:I386 /libpath:"../../lib" - -!ELSEIF "$(CFG)" == "diatheke - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /MDd /w /W0 /Gm /GX /ZI /Od /I "../../include" /I "../../src/utilfuns/win32" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR /YX /FD /GZ /c -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libswordvc6d.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"../../lib" - -!ELSEIF "$(CFG)" == "diatheke - Win32 Debug with ICU" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "diatheke___Win32_Debug_with_ICU" -# PROP BASE Intermediate_Dir "diatheke___Win32_Debug_with_ICU" -# PROP BASE Ignore_Export_Lib 0 -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "ICUDebug" -# PROP Intermediate_Dir "ICUDebug" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /w /W0 /Gm /GX /ZI /Od /I "../../include" /I "../../src/utilfuns/win32" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "__VISUALC__" /FR /YX /FD /GZ /c -# ADD CPP /nologo /MDd /w /W0 /Gm /GX /ZI /Od /I "../../include" /I "../../src/utilfuns/win32" /I "../../../icu-sword/include" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "_ICU_" /D "_ICUSWORD_" /FR /YX /FD /GZ /c -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libsword.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"../../lib/vcppmake/vc6/Debug" -# ADD LINK32 icuin.lib icuuc.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libswordvc6icud.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"../../../icu-sword/lib" /libpath:"../../lib" - -!ELSEIF "$(CFG)" == "diatheke - Win32 Release with ICU" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "diatheke___Win32_Release_with_ICU" -# PROP BASE Intermediate_Dir "diatheke___Win32_Release_with_ICU" -# PROP BASE Ignore_Export_Lib 0 -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "ICURelease" -# PROP Intermediate_Dir "ICURelease" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /w /W0 /GX /O2 /I "../../include" /I "../../src/utilfuns/win32" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "__VISUALC__" /FR /YX /FD /c -# ADD CPP /nologo /MD /w /W0 /GX /O2 /I "../../include" /I "../../src/utilfuns/win32" /I "../../../icu-sword/include" /D "NDEBUG" /D "_ICU_" /D "_ICUSWORD_" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR /YX /FD /c -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libsword.lib /nologo /subsystem:console /machine:I386 /libpath:"../../lib/vcppmake/vc6/Release" -# ADD LINK32 icuin.lib icuuc.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libswordvc6icu.lib /nologo /subsystem:console /machine:I386 /libpath:"../../../icu-sword/lib" /libpath:"../../lib" - -!ENDIF - -# Begin Target - -# Name "diatheke - Win32 Release" -# Name "diatheke - Win32 Debug" -# Name "diatheke - Win32 Debug with ICU" -# Name "diatheke - Win32 Release with ICU" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\corediatheke.cpp -# End Source File -# Begin Source File - -SOURCE=.\diafiltmgr.cpp -# End Source File -# Begin Source File - -SOURCE=.\diatheke.cpp -# End Source File -# Begin Source File - -SOURCE=.\diathekemgr.cpp -# End Source File -# Begin Source File - -SOURCE=.\gbfcgi.cpp -# End Source File -# Begin Source File - -SOURCE=.\osiscgi.cpp -# End Source File -# Begin Source File - -SOURCE=.\thmlcgi.cpp -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\corediatheke.h -# End Source File -# Begin Source File - -SOURCE=.\diafiltmgr.h -# End Source File -# Begin Source File - -SOURCE=.\diathekemgr.h -# End Source File -# Begin Source File - -SOURCE=.\gbfcgi.h -# End Source File -# Begin Source File - -SOURCE=.\osiscgi.h -# End Source File -# Begin Source File - -SOURCE=.\thmlcgi.h -# End Source File -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# End Target -# End Project diff --git a/utilities/diatheke/diatheke.dsw b/utilities/diatheke/diatheke.dsw deleted file mode 100644 index 3bf8c0c..0000000 --- a/utilities/diatheke/diatheke.dsw +++ /dev/null @@ -1,44 +0,0 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "diatheke"=.\diatheke.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name libsword - End Project Dependency -}}} - -############################################################################### - -Project: "libsword"=..\..\lib\vcppmake\vc6\libsword.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - diff --git a/utilities/diatheke/diatheke.vcproj b/utilities/diatheke/diatheke.vcproj new file mode 100644 index 0000000..6b2b2ed --- /dev/null +++ b/utilities/diatheke/diatheke.vcproj @@ -0,0 +1,709 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="diatheke"
+ ProjectGUID="{891A765C-5503-4FED-B427-7AE1413DB264}"
+ TargetFrameworkVersion="0"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory=".\Debug"
+ IntermediateDirectory=".\Debug"
+ ConfigurationType="1"
+ InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="false"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Debug/diatheke.tlb"
+ HeaderFileName=""
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ PrecompiledHeaderFile=".\Debug/diatheke.pch"
+ AssemblerListingLocation=".\Debug/"
+ ObjectFile=".\Debug/"
+ ProgramDataBaseFileName=".\Debug/"
+ BrowseInformation="1"
+ SuppressStartupBanner="true"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="1033"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="icuin.lib icuuc.lib icudt.lib libsword.lib"
+ OutputFile=".\Debug/diatheke.exe"
+ LinkIncremental="2"
+ SuppressStartupBanner="true"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/Debug"
+ GenerateDebugInformation="true"
+ ProgramDatabaseFile=".\Debug/diatheke.pdb"
+ SubSystem="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ SuppressStartupBanner="true"
+ OutputFile=".\Debug/diatheke.bsc"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory=".\Release"
+ IntermediateDirectory=".\Release"
+ ConfigurationType="1"
+ InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="false"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Release/diatheke.tlb"
+ HeaderFileName=""
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;SWUSINGDLL"
+ StringPooling="true"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ PrecompiledHeaderFile=".\Release/diatheke.pch"
+ AssemblerListingLocation=".\Release/"
+ ObjectFile=".\Release/"
+ ProgramDataBaseFileName=".\Release/"
+ BrowseInformation="1"
+ SuppressStartupBanner="true"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="1033"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="icuin.lib icuuc.lib icudt.lib libsword.lib"
+ OutputFile=".\Release/diatheke.exe"
+ LinkIncremental="1"
+ SuppressStartupBanner="true"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/Release"
+ ProgramDatabaseFile=".\Release/diatheke.pdb"
+ SubSystem="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ SuppressStartupBanner="true"
+ OutputFile=".\Release/diatheke.bsc"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory=".\ICUDebug"
+ IntermediateDirectory=".\ICUDebug"
+ ConfigurationType="1"
+ InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="false"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\ICUDebug/diatheke.tlb"
+ HeaderFileName=""
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ PrecompiledHeaderFile=".\ICUDebug/diatheke.pch"
+ AssemblerListingLocation=".\ICUDebug/"
+ ObjectFile=".\ICUDebug/"
+ ProgramDataBaseFileName=".\ICUDebug/"
+ BrowseInformation="1"
+ SuppressStartupBanner="true"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="1033"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="icuin.lib icuuc.lib icudt.lib libsword.lib"
+ OutputFile=".\ICUDebug/diatheke.exe"
+ LinkIncremental="2"
+ SuppressStartupBanner="true"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ ProgramDatabaseFile=".\ICUDebug/diatheke.pdb"
+ SubSystem="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ SuppressStartupBanner="true"
+ OutputFile=".\ICUDebug/diatheke.bsc"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory=".\ICURelease"
+ IntermediateDirectory=".\ICURelease"
+ ConfigurationType="1"
+ InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="false"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\ICURelease/diatheke.tlb"
+ HeaderFileName=""
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ StringPooling="true"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ PrecompiledHeaderFile=".\ICURelease/diatheke.pch"
+ AssemblerListingLocation=".\ICURelease/"
+ ObjectFile=".\ICURelease/"
+ ProgramDataBaseFileName=".\ICURelease/"
+ BrowseInformation="1"
+ SuppressStartupBanner="true"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="1033"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="icuin.lib icuuc.lib icudt.lib libsword.lib"
+ OutputFile=".\ICURelease/diatheke.exe"
+ LinkIncremental="1"
+ SuppressStartupBanner="true"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ ProgramDatabaseFile=".\ICURelease/diatheke.pdb"
+ SubSystem="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ SuppressStartupBanner="true"
+ OutputFile=".\ICURelease/diatheke.bsc"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+ >
+ <File
+ RelativePath="corediatheke.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Debug with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="diafiltmgr.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Debug with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="diatheke.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Debug with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="diathekemgr.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Debug with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="gbfcgi.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Debug with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="osiscgi.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Debug with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="thmlcgi.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Debug with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release with ICU|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions=""
+ />
+ </FileConfiguration>
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl"
+ >
+ <File
+ RelativePath="corediatheke.h"
+ >
+ </File>
+ <File
+ RelativePath="diafiltmgr.h"
+ >
+ </File>
+ <File
+ RelativePath="diathekemgr.h"
+ >
+ </File>
+ <File
+ RelativePath="gbfcgi.h"
+ >
+ </File>
+ <File
+ RelativePath="osiscgi.h"
+ >
+ </File>
+ <File
+ RelativePath="thmlcgi.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/diatheke/diathekemgr.cpp b/utilities/diatheke/diathekemgr.cpp index 38cb46d..93351c0 100644 --- a/utilities/diatheke/diathekemgr.cpp +++ b/utilities/diatheke/diathekemgr.cpp @@ -1,21 +1,23 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + //--------------------------------------------------------------------------- -#include <thmlplain.h> -#include <gbfplain.h> -#include <thmlgbf.h> -#include <gbfthml.h> -#include <thmlhtml.h> -#include <gbfhtml.h> -#include <plainhtml.h> -#include <thmlhtmlhref.h> -#include <gbfhtmlhref.h> -#include <thmlrtf.h> -#include <gbfrtf.h> -#include <utilstr.h> #include <swmodule.h> -#include <swconfig.h> -#include "diafiltmgr.h" - #ifdef _ICU_ #include <utf8arshaping.h> #include <utf8bidireorder.h> @@ -27,8 +29,6 @@ #endif #include "diathekemgr.h" -#include "gbfcgi.h" -#include "thmlcgi.h" //--------------------------------------------------------------------------- DiathekeMgr::DiathekeMgr (SWConfig * iconfig, SWConfig * isysconfig, bool autoload, char enc, char mark, bool ibidi, bool ishape) @@ -38,9 +38,9 @@ DiathekeMgr::DiathekeMgr (SWConfig * iconfig, SWConfig * isysconfig, bool autolo shape = ishape; #ifdef _ICU_ - arshaping = new UTF8arShaping(); + arshaping = new UTF8arShaping(); bidireorder = new UTF8BiDiReorder(); - transliterator = new UTF8Transliterator(); + transliterator = new UTF8Transliterator(); #endif Load(); @@ -78,10 +78,10 @@ void DiathekeMgr::AddRenderFilters(SWModule *module, ConfigEntMap §ion) rtl = ((entry = section.find("Direction")) != section.end()) ? ((*entry).second == "RtoL") : false; #ifdef _ICU_ - if (shape && !strnicmp(lang.c_str(), "ar", 2)) { + if (shape) { module->AddRenderFilter(arshaping); } - if (bidi && rtl) { + if (bidi && rtl) { module->AddRenderFilter(bidireorder); } #endif diff --git a/utilities/diatheke/diathekemgr.h b/utilities/diatheke/diathekemgr.h index cbd8e6f..6225bbf 100644 --- a/utilities/diatheke/diathekemgr.h +++ b/utilities/diatheke/diathekemgr.h @@ -1,10 +1,27 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #ifndef DIATHEKEMGR_H #define DIATHEKEMGR_H #include <swmgr.h> #include "diafiltmgr.h" -enum PlatformIDs { WIN32S = 0, WIN9X, WINNT, WINCE }; +//enum PlatformIDs { WIN32S = 0, WIN9X, WINNT, WINCE }; class DiathekeMgr : public SWMgr { SWFilter *arshaping; @@ -12,13 +29,13 @@ class DiathekeMgr : public SWMgr { SWOptionFilter *transliterator; #ifdef WIN32 - char platformID; + char platformID; #endif protected: virtual void AddRenderFilters(SWModule *module, ConfigEntMap §ion); - virtual signed char Load (); - virtual void AddGlobalOptions (SWModule * module, ConfigEntMap & section, ConfigEntMap::iterator start, ConfigEntMap::iterator end); + virtual signed char Load (); + virtual void AddGlobalOptions (SWModule * module, ConfigEntMap & section, ConfigEntMap::iterator start, ConfigEntMap::iterator end); public: bool shape; diff --git a/utilities/diatheke/gbfcgi.cpp b/utilities/diatheke/gbfcgi.cpp index c581fa1..5112c46 100644 --- a/utilities/diatheke/gbfcgi.cpp +++ b/utilities/diatheke/gbfcgi.cpp @@ -1,18 +1,25 @@ /*************************************************************************** - gbfcgi.cpp - GBF to Diatheke/CGI format - ------------------- - begin : 2001-11-12 - copyright : 2001 by CrossWire Bible Society - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ + * gbfcgi.cpp - GBF to Diatheke/CGI format + * ------------------- + * begin : 2001-11-12 + * copyright : 2001 by CrossWire Bible Society + * + * + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <stdlib.h> #include <string.h> diff --git a/utilities/diatheke/gbfcgi.h b/utilities/diatheke/gbfcgi.h index c2b68c9..71ded1a 100644 --- a/utilities/diatheke/gbfcgi.h +++ b/utilities/diatheke/gbfcgi.h @@ -1,18 +1,25 @@ -/*-************************************************************************* - gbfcgi.h - description - ------------------- - begin : 2001-11-12 - copyright : 2001 by CrossWire Bible Society - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ +/************************************************************************** + * gbfcgi.h - description + * ------------------- + * begin : 2001-11-12 + * copyright : 2001 by CrossWire Bible Society + * + * + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #ifndef GBFCGI_H #define GBFCGI_H @@ -27,7 +34,7 @@ SWORD_NAMESPACE_START typedef std::map<SWBuf, SWBuf> DualStringMap; /** this filter converts GBF text to Diatheke/CGI format */ -class SWDLLEXPORT GBFCGI : public SWBasicFilter { +class GBFCGI : public SWBasicFilter { protected: virtual bool handleToken(SWBuf &buf, const char *token, DualStringMap &userData); public: diff --git a/utilities/diatheke/osiscgi.cpp b/utilities/diatheke/osiscgi.cpp index 68298e9..86c7ed0 100644 --- a/utilities/diatheke/osiscgi.cpp +++ b/utilities/diatheke/osiscgi.cpp @@ -1,18 +1,25 @@ /*************************************************************************** - osiscgi.cpp - OSIS to Diatheke/CGI format - ------------------- - begin : 2003-10-21 - copyright : 2003 by CrossWire Bible Society - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ + * osiscgi.cpp - OSIS to Diatheke/CGI format + * ------------------- + * begin : 2003-10-21 + * copyright : 2003 by CrossWire Bible Society + * + * + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <stdlib.h> #include "osiscgi.h" diff --git a/utilities/diatheke/osiscgi.h b/utilities/diatheke/osiscgi.h index c6c6411..d64e805 100644 --- a/utilities/diatheke/osiscgi.h +++ b/utilities/diatheke/osiscgi.h @@ -1,18 +1,25 @@ /*************************************************************************** - osiscgi.h - OSIS to Diatheke/CGI format - ------------------- - begin : 2003-10-21 - copyright : 2003 by CrossWire Bible Society - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ + * osiscgi.h - OSIS to Diatheke/CGI format + * ------------------- + * begin : 2003-10-21 + * copyright : 2003 by CrossWire Bible Society + * + * + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #ifndef OSISCGI_H #define OSISCGI_H @@ -25,7 +32,7 @@ SWORD_NAMESPACE_START /** this filter converts OSIS text to Diatheke/CGI format */ -class SWDLLEXPORT OSISCGI : public SWBasicFilter { +class OSISCGI : public SWBasicFilter { private: protected: class MyUserData : public BasicFilterUserData { diff --git a/utilities/diatheke/soap/sapouni.cgi b/utilities/diatheke/soap/sapouni.cgi index 24df769..5412d23 100755 --- a/utilities/diatheke/soap/sapouni.cgi +++ b/utilities/diatheke/soap/sapouni.cgi @@ -1,5 +1,21 @@ #!/usr/bin/perl +# * +# * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) +# * CrossWire Bible Society +# * P. O. Box 2528 +# * Tempe, AZ 85280-2528 +# * +# * This program is free software; you can redistribute it and/or modify it +# * under the terms of the GNU General Public License as published by the +# * Free Software Foundation version 2. +# * +# * This program is distributed in the hope that it will be useful, but +# * WITHOUT ANY WARRANTY; without even the implied warranty of +# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# * General Public License for more details. +# * + #version 1.0 package sapouni; diff --git a/utilities/diatheke/soap/soapatheke.pl b/utilities/diatheke/soap/soapatheke.pl index e3f88ed..c45fd98 100755 --- a/utilities/diatheke/soap/soapatheke.pl +++ b/utilities/diatheke/soap/soapatheke.pl @@ -1,5 +1,22 @@ #!/usr/bin/perl +# * +# * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) +# * CrossWire Bible Society +# * P. O. Box 2528 +# * Tempe, AZ 85280-2528 +# * +# * This program is free software; you can redistribute it and/or modify it +# * under the terms of the GNU General Public License as published by the +# * Free Software Foundation version 2. +# * +# * This program is distributed in the hope that it will be useful, but +# * WITHOUT ANY WARRANTY; without even the implied warranty of +# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# * General Public License for more details. +# * + + ## This is a test app and has no other purpose. use SOAP::Lite; diff --git a/utilities/diatheke/tcl/biblebot-diatheke.tcl b/utilities/diatheke/tcl/biblebot-diatheke.tcl index 1fea379..52d7568 100644 --- a/utilities/diatheke/tcl/biblebot-diatheke.tcl +++ b/utilities/diatheke/tcl/biblebot-diatheke.tcl @@ -1,9 +1,22 @@ # Diatheke/Tcl 3.0 by Chris Little <chrislit@gotjesus.org> # Based on code schema of <cking@acy.digex.net> -# Copyright 1999 by Chris Little -# Licensed under GNU General Public License (GPL) -# see accompanying LICENSE file for license details +# * +# * Copyright 1999-2009 CrossWire Bible Society (http://www.crosswire.org) +# * CrossWire Bible Society +# * P. O. Box 2528 +# * Tempe, AZ 85280-2528 +# * +# * This program is free software; you can redistribute it and/or modify it +# * under the terms of the GNU General Public License as published by the +# * Free Software Foundation version 2. +# * +# * This program is distributed in the hope that it will be useful, but +# * WITHOUT ANY WARRANTY; without even the implied warranty of +# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# * General Public License for more details. +# * + # This script is intended for use with libraries and modules from # the SWORD Project, available at http://www.crosswire.org/ diff --git a/utilities/diatheke/thmlcgi.cpp b/utilities/diatheke/thmlcgi.cpp index 5ad180d..1bcc5ba 100644 --- a/utilities/diatheke/thmlcgi.cpp +++ b/utilities/diatheke/thmlcgi.cpp @@ -1,18 +1,25 @@ /*************************************************************************** - thmlcgi.cpp - ThML to Diatheke/CGI format - ------------------- - begin : 2001-11-12 - copyright : 2001 by CrossWire Bible Society - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ + * thmlcgi.cpp - ThML to Diatheke/CGI format + * ------------------- + * begin : 2001-11-12 + * copyright : 2001 by CrossWire Bible Society + * + * + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <stdlib.h> #include <string.h> diff --git a/utilities/diatheke/thmlcgi.h b/utilities/diatheke/thmlcgi.h index efa9018..bfdee35 100644 --- a/utilities/diatheke/thmlcgi.h +++ b/utilities/diatheke/thmlcgi.h @@ -1,18 +1,25 @@ /*************************************************************************** - thmlcgi.h - OSIS to Diatheke/CGI format - ------------------- - begin : 2001-11-12 - copyright : 2001 by CrossWire Bible Society - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ + * thmlcgi.h - OSIS to Diatheke/CGI format + * ------------------- + * begin : 2001-11-12 + * copyright : 2001 by CrossWire Bible Society + * + * + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #ifndef THMLCGI_H #define THMLCGI_H @@ -27,7 +34,7 @@ SWORD_NAMESPACE_START typedef std::map<SWBuf, SWBuf> DualStringMap; /** this filter converts ThML text to Diatheke/CGI format */ -class SWDLLEXPORT ThMLCGI : public SWBasicFilter { +class ThMLCGI : public SWBasicFilter { protected: virtual bool handleToken(SWBuf &buf, const char *token, DualStringMap &userData); public: diff --git a/utilities/emptyvss.cpp b/utilities/emptyvss.cpp index 366aa21..61a1b6c 100644 --- a/utilities/emptyvss.cpp +++ b/utilities/emptyvss.cpp @@ -1,7 +1,25 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <swmgr.h> #include <swmodule.h> #include <versekey.h> #include <iostream> +#include <stdio.h> #ifndef NO_SWORD_NAMESPACE using sword::SWMgr; diff --git a/utilities/gbfidx.cpp b/utilities/gbfidx.cpp index 88921ac..4dc6e65 100644 --- a/utilities/gbfidx.cpp +++ b/utilities/gbfidx.cpp @@ -1,8 +1,25 @@ /***************************************************************************** * - * This code wreaks but works (at least for WEB). Good luck! + * This code reeks but works (at least for WEB). Good luck! + * + * + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * */ + #include <stdio.h> #include <stdlib.h> #include <string.h> diff --git a/utilities/genbookutil.cpp b/utilities/genbookutil.cpp index e9beb72..61b4821 100644 --- a/utilities/genbookutil.cpp +++ b/utilities/genbookutil.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <entriesblk.h> #include <iostream> #include <stdio.h> diff --git a/utilities/imp2gbs.cpp b/utilities/imp2gbs.cpp index 9488eef..ba6a222 100644 --- a/utilities/imp2gbs.cpp +++ b/utilities/imp2gbs.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <errno.h> diff --git a/utilities/imp2ld.cpp b/utilities/imp2ld.cpp index bde5b18..e9bd0c7 100644 --- a/utilities/imp2ld.cpp +++ b/utilities/imp2ld.cpp @@ -1,3 +1,20 @@ +/* +* Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) +* CrossWire Bible Society +* P. O. Box 2528 +* Tempe, AZ 85280-2528 +* +* This program is free software; you can redistribute it and/or modify it +* under the terms of the GNU General Public License as published by the +* Free Software Foundation version 2. +* +* This program is distributed in the hope that it will be useful, but +* WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +* General Public License for more details. +* +*/ + #include <string> #include <vector> #include <fstream> @@ -11,165 +28,120 @@ using std::string; #ifndef NO_SWORD_NAMESPACE -using sword::zLD; -using sword::ZipCompress; -using sword::RawLD4; -using sword::RawLD; -using sword::SWKey; + +using namespace sword; + #endif int main(int argc, char **argv) { - const char * helptext ="imp2ld 1.0 Lexicon/Dictionary/Daily Devotional/Glossary module creation tool for the SWORD Project\n usage:\n %s <filename> [modname] [ 4 (default) | 2 | z - module driver]\n"; - - signed long i = 0; - string keybuffer; - string entbuffer; - string linebuffer; - char modname[16]; - char links = 0; - std::vector<string> linkbuffer; - - if (argc > 2) { - strcpy (modname, argv[2]); - } - else if (argc > 1) { - for (i = 0; (i < 16) && (argv[1][i]) && (argv[1][i] != '.'); i++) { - modname[i] = argv[1][i]; - } - modname[i] = 0; - } - else { - fprintf(stderr, helptext, argv[0]); - exit(-1); - } - - std::ifstream infile(argv[1]); - - char mode = 1; - if (argc > 3) { - switch (*argv[3]) { - case 'z': - mode = 3; - break; - case '2': - mode = 2; - break; - default: - mode = 1; - } - } - - zLD* modZ = NULL; - RawLD* mod2 = NULL; - RawLD4* mod4 = NULL; - SWKey* key; - - if (mode == 3) { - zLD::createModule(modname); - modZ = new zLD(modname, 0, 0, 30, new ZipCompress()); - key = modZ->CreateKey(); - } - else if (mode == 2) { - RawLD::createModule(modname); - mod2 = new RawLD(modname); - key = mod2->CreateKey(); - } - else if (mode == 1) { - RawLD4::createModule(modname); - mod4 = new RawLD4(modname); - key = mod4->CreateKey(); - } - - key->Persist(1); - - while (!infile.eof()) { - std::getline(infile, linebuffer); - if (linebuffer.size() > 3 && linebuffer.substr(0,3) == "$$$") { - if (keybuffer.size() && entbuffer.size()) { - std::cout << keybuffer << std::endl; - *key = keybuffer.c_str(); - - if (mode == 3) { - modZ->setKey(*key); - modZ->setEntry(entbuffer.c_str(), entbuffer.size()); - for (i = 0; i < links; i++) { - SWKey tmpkey = linkbuffer[i].c_str(); - modZ->linkEntry(&tmpkey); - std::cout << "Linking: " << linkbuffer[i] << std::endl; - } + const char * helptext ="imp2ld 1.0 Lexicon/Dictionary/Daily Devotional/Glossary module creation tool for the SWORD Project\n usage:\n %s <filename> [modname] [ 4 (default) | 2 | z - module driver]\n"; + + signed long i = 0; + string keybuffer; + string entbuffer; + string linebuffer; + char modname[16]; + char links = 0; + std::vector<string> linkbuffer; + + if (argc > 2) { + strcpy (modname, argv[2]); } - else if (mode == 2) { - mod2->setKey(*key); - mod2->setEntry(entbuffer.c_str(), entbuffer.size()); - for (i = 0; i < links; i++) { - SWKey tmpkey = linkbuffer[i].c_str(); - mod2->linkEntry(&tmpkey); - std::cout << "Linking: " << linkbuffer[i] << std::endl; - } + else if (argc > 1) { + for (i = 0; (i < 16) && (argv[1][i]) && (argv[1][i] != '.'); i++) { + modname[i] = argv[1][i]; + } + modname[i] = 0; } - else if (mode == 1) { - mod4->setKey(*key); - mod4->setEntry(entbuffer.c_str(), entbuffer.size()); - for (i = 0; i < links; i++) { - SWKey tmpkey = linkbuffer[i].c_str(); - mod4->linkEntry(&tmpkey); - std::cout << "Linking: " << linkbuffer[i] << std::endl; - } + else { + fprintf(stderr, helptext, argv[0]); + exit(-1); } - } - if (linebuffer.size() > 3) - keybuffer = linebuffer.substr(3,linebuffer.size()) ; - entbuffer.resize(0); - linkbuffer.clear(); - links = 0; - } - else if (linebuffer.size() > 3 && linebuffer.substr(0,3) == "%%%") { - linkbuffer.push_back(linebuffer.substr(3,linebuffer.size())); - links++; - } - else { - entbuffer += linebuffer; - } - } - - //handle final entry - if (keybuffer.size() && entbuffer.size()) { - std::cout << keybuffer << std::endl; - *key = keybuffer.c_str(); - - if (mode == 3) { - modZ->setKey(*key); - modZ->setEntry(entbuffer.c_str(), entbuffer.size()); - for (i = 0; i < links; i++) { - SWKey tmpkey = linkbuffer[i].c_str(); - modZ->linkEntry(&tmpkey); - std::cout << "Linking: " << linkbuffer[i] << std::endl; - } - } - else if (mode == 2) { - mod2->setKey(*key); - mod2->setEntry(entbuffer.c_str(), entbuffer.size()); - for (i = 0; i < links; i++) { - SWKey tmpkey = linkbuffer[i].c_str(); - mod2->linkEntry(&tmpkey); - std::cout << "Linking: " << linkbuffer[i] << std::endl; - } - - } - else if (mode == 1) { - mod4->setKey(*key); - mod4->setEntry(entbuffer.c_str(), entbuffer.size()); - for (i = 0; i < links; i++) { - SWKey tmpkey = linkbuffer[i].c_str(); - mod4->linkEntry(&tmpkey); - std::cout << "Linking: " << linkbuffer[i] << std::endl; - } - - } - } - infile.close(); - - return 0; + + std::ifstream infile(argv[1]); + + char mode = 1; + if (argc > 3) { + switch (*argv[3]) { + case 'z': mode = 3; break; + case '2': mode = 2; break; + default: mode = 1; + } + } + + SWModule *mod = 0; + SWKey *key, *linkKey; + + switch (mode) { + case 3: + zLD::createModule(modname); + mod = new zLD(modname, 0, 0, 30, new ZipCompress()); + break; + case 2: + RawLD::createModule(modname); + mod = new RawLD(modname); + break; + case 1: + RawLD4::createModule(modname); + mod = new RawLD4(modname); + break; + } + + key = mod->CreateKey(); + linkKey = mod->CreateKey(); + key->Persist(1); + mod->setKey(key); + + while (!infile.eof()) { + std::getline(infile, linebuffer); + if (linebuffer.size() > 3 && linebuffer.substr(0,3) == "$$$") { + if (keybuffer.size() && entbuffer.size()) { + std::cout << keybuffer << std::endl; + *key = keybuffer.c_str(); + + mod->setEntry(entbuffer.c_str(), entbuffer.size()); + for (i = 0; i < links; i++) { + std::cout << "Linking: " << linkbuffer[i] << std::endl; + *linkKey = linkbuffer[i].c_str(); + mod->linkEntry(linkKey); + } + } + if (linebuffer.size() > 3) + keybuffer = linebuffer.substr(3,linebuffer.size()); + + entbuffer.resize(0); + linkbuffer.clear(); + links = 0; + } + else if (linebuffer.size() > 3 && linebuffer.substr(0,3) == "%%%") { + linkbuffer.push_back(linebuffer.substr(3,linebuffer.size())); + links++; + } + else { + entbuffer += linebuffer; + } + } + + //handle final entry + if (keybuffer.size() && entbuffer.size()) { + std::cout << keybuffer << std::endl; + *key = keybuffer.c_str(); + + mod->setEntry(entbuffer.c_str(), entbuffer.size()); + for (i = 0; i < links; i++) { + std::cout << "Linking: " << linkbuffer[i] << std::endl; + *linkKey = linkbuffer[i].c_str(); + mod->linkEntry(linkKey); + } + } + + infile.close(); + + delete linkKey; + delete key; + delete mod; + + return 0; } diff --git a/utilities/imp2vs.cpp b/utilities/imp2vs.cpp index 9ae3881..62d34a1 100644 --- a/utilities/imp2vs.cpp +++ b/utilities/imp2vs.cpp @@ -1,182 +1,215 @@ -#include <ctype.h> -#include <stdio.h> -#include <fcntl.h> -#include <errno.h> -#include <stdlib.h> -#include <string> -#include <fstream> -using namespace std; +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <iostream> #include <rawtext.h> - #include <rawtext4.h> +#include <rawtext4.h> #include <versekey.h> - +#include <swbuf.h> +#include <filemgr.h> +#include <stdio.h> #ifndef NO_SWORD_NAMESPACE -using sword::RawText; -using sword::RawText4; -using sword::VerseKey; -using sword::SWText; -using sword::ListKey; +using namespace sword; #endif +using namespace std; + +void writeEntry(const SWBuf &key, const SWBuf &entry, SWModule *module); + +void usage(const char *progName, const char *error = 0) { + if (error) fprintf(stderr, "\n%s: %s\n", progName, error); + fprintf(stderr, "\n=== imp2vs (Revision $Rev: 2234 $) SWORD Bible/Commentary importer.\n"); + fprintf(stderr, "\nusage: %s <imp_file> [options]\n", progName); + fprintf(stderr, " -a\t\t\t augment module if exists (default is to create new)\n"); + fprintf(stderr, " -o <output_path>\t where to write data files.\n"); + fprintf(stderr, " -4\t\t\t use 4 byte size entries (default is 2).\n"); + fprintf(stderr, " -v <v11n>\t\t specify a versification scheme to use (default is KJV)\n"); + fprintf(stderr, "\t\t\t\t Note: The following are valid values for v11n:\n"); + VerseMgr *vmgr = VerseMgr::getSystemVerseMgr(); + StringList av11n = vmgr->getVersificationSystems(); + for (StringList::iterator loop = av11n.begin(); loop != av11n.end(); loop++) { + fprintf(stderr, "\t\t\t\t\t%s\n", (*loop).c_str()); + } + fprintf(stderr, "\n"); + fprintf(stderr, "'imp' format is a simple standard for importing data into SWORD modules.\n" + "Required is a plain text file containing $$$key lines followed by content.\n\n" + "$$$Gen.1.1\n" + "In the beginning God created\n" + "the heavens and the earth\n" + "$$$Gen.1.2\n" + "and the earth...\n\n" + "Key lines can contain ranges, for example, a commentary entry which discusses\n" + "John 1:1-4 might have a key, $$$Jn.1.1-4. Special keys for intro entries use\n" + "standard SWORD notation, e.g. $$$Rom.4.0 for intro of Romans chapter 4,\n" + "$$$Rev.0.0 for intro of the Book of Revelation of John. $$$[ Module Heading ]\n" + "for entire module intro. $$$[ Testament 2 Heading ] for NT intro.\n\n"); + exit(-1); +} + + int main(int argc, char **argv) { - - const string helptext ="imp2vs 1.0 Bible/Commentary module creation tool for the SWORD Project\n usage:\n %s <filename> [output dir] \n"; - - string keybuffer = ""; - string entbuffer = ""; - string linebuffer = ""; - string modname = ""; - - if (argc > 2) { - modname = argv[2]; - } - else if (argc > 1) { - modname = "./"; - } - else { - fprintf(stderr, helptext.c_str(), argv[0]); - exit(-1); - } - int mode = 1; - if (argc > 3) { - switch (*argv[3]) { - case '4': - mode = 2; - break; - default: - mode = 1; - } - } - - - - try { - - ifstream infile(argv[1]); - - SWText* mod; - RawText * modRaw; - RawText4 * modRaw4; - - if (mode == 1) { - RawText::createModule(modname.c_str()); - modRaw= new RawText(modname.c_str()); - mod = modRaw; - } else { - RawText4::createModule(modname.c_str()); - modRaw4= new RawText4(modname.c_str()); - mod = modRaw4; - } - - VerseKey* vkey = new VerseKey; - vkey->Headings(1); - vkey->AutoNormalize(0); - vkey->Persist(1); - mod->setKey(*vkey); - char final; // 2 == pre-final line; 1 == final line; 0 == EOF - - getline(infile,linebuffer); - final = (!infile.eof()) + 1; - - while (final) { - if (final == 1 || (linebuffer.size() > 3 && linebuffer.substr(0,3) == "$$$")) { - if (keybuffer.size() && entbuffer.size()) { - std::cout << "from file: " << keybuffer << std::endl; - *vkey = keybuffer.c_str(); - if (!vkey->Chapter()) { - // bad hack: 0:0 is Book intro; (chapter):0 is Chapter intro; 0:2 is Module intro; 0:1 is Testament intro - int backstep = vkey->Verse(); - if (backstep) { - vkey->Verse(1); - vkey->Chapter(1); - switch (backstep) { - case 2: - vkey->Book(1); - vkey->Testament(0); - case 1: - vkey->Book(0); - vkey->Chapter(0); - } - vkey->Verse(0); - } - - std::cout << "adding entry: " << *vkey << " length " << entbuffer.size() << "/" << (unsigned short)entbuffer.size() << std::endl; - mod->setEntry(entbuffer.c_str(), entbuffer.size()); + + + // handle options + if (argc < 2) usage(*argv); + + const char *progName = argv[0]; + const char *inFileName = argv[1]; + SWBuf v11n = "KJV"; + SWBuf outPath = "./"; + bool fourByteSize = false; + bool append = false; + + for (int i = 2; i < argc; i++) { + if (!strcmp(argv[i], "-a")) { + append = true; + } + if (!strcmp(argv[i], "-4")) { + fourByteSize = true; + } + else if (!strcmp(argv[i], "-o")) { + if (i+1 < argc) outPath = argv[++i]; + else usage(progName, "-o requires <output_path>"); + } + else if (!strcmp(argv[i], "-v")) { + if (i+1 < argc) v11n = argv[++i]; + else usage(progName, "-v requires <v11n>"); + } + else usage(progName, (((SWBuf)"Unknown argument: ")+ argv[i]).c_str()); + } + // ----------------------------------------------------- + const VerseMgr::System *v = VerseMgr::getSystemVerseMgr()->getVersificationSystem(v11n); + if (!v) std::cout << "Warning: Versification " << v11n << " not found. Using KJV versification...\n"; + + + // setup module + if (!append) { + if (!fourByteSize) + RawText::createModule(outPath, v11n); + else RawText4::createModule(outPath, v11n); + } + + SWModule *module = (!fourByteSize) + ? (SWModule *)new RawText(outPath, 0, 0, 0, ENC_UNKNOWN, DIRECTION_LTR, FMT_UNKNOWN, 0, v11n) + : (SWModule *)new RawText4(outPath, 0, 0, 0, ENC_UNKNOWN, DIRECTION_LTR, FMT_UNKNOWN, 0, v11n); + // ----------------------------------------------------- + + + // setup module key to allow full range of possible values, and then some + VerseKey *vkey = (VerseKey *)module->CreateKey(); + vkey->Headings(1); + vkey->AutoNormalize(0); + vkey->Persist(1); + module->setKey(*vkey); + // ----------------------------------------------------- + + + // process input file + FileDesc *fd = FileMgr::getSystemFileMgr()->open(inFileName, FileMgr::RDONLY); + + SWBuf lineBuffer; + SWBuf currentKey; + SWBuf currentEntry; + + while (FileMgr::getLine(fd, lineBuffer)) { + if (lineBuffer.startsWith("$$$")) { + writeEntry(currentKey, currentEntry, module); + currentKey = lineBuffer; + currentKey << 3; + currentKey.trim(); + currentEntry = ""; + } + else { + currentEntry += lineBuffer; + } } - else { - ListKey listkey = vkey->ParseVerseList(keybuffer.c_str(), "Gen1:1", true); - int i; - bool havefirst = false; - VerseKey firstverse; - firstverse.Headings(1); - firstverse.AutoNormalize(0); - for (i = 0; i < listkey.Count(); i++) { - VerseKey *element = SWDYNAMIC_CAST(VerseKey, listkey.GetElement(i)); - if (element) { - *vkey = element->LowerBound(); - VerseKey finalkey = element->UpperBound(); - finalkey.Headings(1); - finalkey.AutoNormalize(0); - if (!havefirst) { - havefirst = true; - firstverse = *vkey; - - std::cout << "adding entry: " << *vkey << " length " << entbuffer.size() << "/" << (unsigned short)entbuffer.size() << std::endl; - mod->setEntry(entbuffer.c_str(), entbuffer.size()); - (*vkey)++; - } - while (! (finalkey < (*vkey))) { - std::cout << "linking entry: " << *vkey << " to " << firstverse << std::endl; - *mod << &firstverse; - (*vkey)++; - } - } - else { - if (havefirst) { - *vkey = (*listkey.GetElement(i)); - std::cout << "linking entry: " << *vkey << " to " << firstverse << std::endl; - *mod << &firstverse; - } - else { - *vkey = (*listkey.GetElement(i)); - havefirst = true; - firstverse = *vkey; - - std::cout << "adding entry: " << *vkey << " length " << entbuffer.size() << "/" << (unsigned short)entbuffer.size() << std::endl; - mod->setEntry(entbuffer.c_str(), entbuffer.size()); - } - } - } + writeEntry(currentKey, currentEntry, module); + + FileMgr::getSystemFileMgr()->close(fd); + + delete vkey; + + return 0; +} + + + +int page = 0; + + +void writeEntry(const SWBuf &key, const SWBuf &entry, SWModule *module) +{ + if (key.size() && entry.size()) { + std::cout << "from file: " << key << std::endl; + VerseKey *vkey = (VerseKey *)module->getKey(); + VerseKey *linkMaster = (VerseKey *)module->CreateKey(); + + ListKey listKey = vkey->ParseVerseList(key.c_str(), "Gen1:1", true); + + bool first = true; + for (listKey = TOP; !listKey.Error(); listKey++) { + *vkey = listKey; + if (first) { + *linkMaster = *vkey; + SWBuf text = module->getRawEntry(); + text += entry; + + + //------------------------------------------------------------ + // Tregelles Page marking special stuff + //------------------------------------------------------------ +/* + const char *pageMarker = "<seg type=\"page\" subtype=\""; + int newPage = page; + SWBuf pageData = strstr(text.c_str(), pageMarker); + if (pageData.length()) { + pageData << strlen(pageMarker); + const char *pn = pageData.stripPrefix('"'); + if (pn) newPage = atoi(pn); + } + // add page stuff for treg + if (text.startsWith(pageMarker)) { + // don't add anything cuz we already start with one + } + else { + SWBuf pm = pageMarker; + pm.appendFormatted("%d\" />", page); + text = pm + text; + } + + page = newPage; // when our line set a new page number + +*/ + //------------------------------------------------------------ + + + + + std::cout << "adding entry: " << *vkey << " length " << entry.size() << "/" << (unsigned short)text.size() << std::endl; + module->setEntry(text); + first = false; + } + else { + std::cout << "linking entry: " << *vkey << " to " << *linkMaster << std::endl; + module->linkEntry(linkMaster); + } + } + + delete linkMaster; } - } - if (linebuffer.size() > 3) - keybuffer = linebuffer.substr(3,linebuffer.size()) ; - entbuffer.resize(0); - } - else { - entbuffer.append(linebuffer); - } - final--; - if (final) { - getline(infile,linebuffer); - final = (!infile.eof()) + 1; - } - } - } - catch (const std::exception& e) { - std::cerr << "Exception: imp2vs failed: " << e.what() << std::endl; - std::cerr << "Line: " << linebuffer.size() << " " << linebuffer << std::endl; - std::cerr << "Key: " << keybuffer.size() << " " << keybuffer << std::endl; - std::cerr << "Ent: " << entbuffer.size() << " " << entbuffer << std::endl; - return -2; - } - catch (...) { - std::cerr << "Exception: imp2vs failed" << std::endl; - return -3; - } - - return 0; } diff --git a/utilities/installmgr.cpp b/utilities/installmgr.cpp index 60fc7ce..d4a8cb2 100644 --- a/utilities/installmgr.cpp +++ b/utilities/installmgr.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <swmgr.h> #include <installmgr.h> #include <filemgr.h> @@ -16,19 +33,70 @@ using std::map; SWMgr *mgr; InstallMgr *installMgr; +SWBuf baseDir; +SWBuf confPath; + + +class MyInstallMgr : public InstallMgr { +public: + MyInstallMgr(const char *privatePath = "./") : InstallMgr(privatePath) {} + +virtual bool isUserDisclaimerConfirmed() const { + static bool confirmed = false; + if (!confirmed) { + cout << "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n"; + cout << " -=+* WARNING *+=- -=+* WARNING *+=-\n\n\n"; + cout << "Although Install Manager provides a convenient way for installing\n"; + cout << "and upgrading SWORD components, it also uses a systematic method\n"; + cout << "for accessing sites which gives packet sniffers a target to lock\n"; + cout << "into for singling out users. \n\n\n"; + cout << "IF YOU LIVE IN A PERSECUTED COUNTRY AND DO NOT WISH TO RISK DETECTION,\n"; + cout << "YOU SHOULD *NOT* USE INSTALL MANAGER'S REMOTE SOURCE FEATURES.\n\n\n"; + cout << "Also, Remote Sources other than CrossWire may contain less than\n"; + cout << "quality modules, modules with unorthodox content, or even modules\n"; + cout << "which are not legitimately distributable. Many repositories\n"; + cout << "contain wonderfully useful content. These repositories simply\n"; + cout << "are not reviewed or maintained by CrossWire and CrossWire\n"; + cout << "cannot be held responsible for their content. CAVEAT EMPTOR.\n\n\n"; + cout << "If you understand this and are willing to enable remote source features\n"; + cout << "then type yes at the prompt\n\n"; + cout << "enable? [no] "; + + char prompt[10]; + fgets(prompt, 9, stdin); + confirmed = (!strcmp(prompt, "yes\n")); + } + return confirmed; +} + +}; + +void init() { + mgr = new SWMgr(); + SWBuf baseDir = mgr->getHomeDir(); + if (baseDir.length() < 1) baseDir = "."; + baseDir += "/.sword/InstallMgr"; + confPath = baseDir + "/InstallMgr.conf"; + installMgr = new MyInstallMgr(baseDir); +} + +// clean up and exit if status is 0 or negative error code void finish(int status) { delete installMgr; delete mgr; - cout << "\n"; - exit(status); + if (status < 1) { + cout << "\n"; + exit(status); + } } void usage(const char *progName) { fprintf(stderr, "usage: %s <option>\nOptions:\n" "\t-init\t\t\t\tcreate a basic user config file.\n" + "\t-sc\t\t\t\tsync config with known remote repo list\n" "\t\t\t\t\t\tWARNING: overwrites existing.\n" "\t-l\t\t\t\tlist installed modules\n" "\t-u <modName>\t\t\tuninstall module\n" @@ -44,24 +112,8 @@ void usage(const char *progName) { } -void initConfig() { - cout << "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n"; - cout << " -=+* WARNING *+=- -=+* WARNING *+=-\n\n\n"; - cout << "Although Install Manager provides a convenient way for installing\n"; - cout << "and upgrading SWORD components, it also uses a systematic method\n"; - cout << "for accessing sites which gives packet sniffers a target to lock\n"; - cout << "into for singling out users. \n\n\n"; - cout << "IF YOU LIVE IN A PERSECUTED COUNTRY AND DO NOT WISH TO RISK DETECTION,\n"; - cout << "YOU SHOULD *NOT* USE INSTALL MANAGER'S REMOTE SOURCE FEATURES.\n\n\n"; - cout << "if you understand this and are willing to enable remote source features\n"; - cout << "then type yes at the prompt\n\n"; - cout << "enable? [no] "; - char prompt[10]; - fgets(prompt, 9, stdin); - bool enable = (!strcmp(prompt, "yes\n")); - char *envhomedir = getenv ("HOME"); - SWBuf confPath = (envhomedir) ? envhomedir : "."; - confPath += "/.sword/InstallMgr/InstallMgr.conf"; +void createBasicConfig(bool enableRemote, bool addCrossWire) { + FileMgr::createParent(confPath.c_str()); remove(confPath.c_str()); @@ -72,21 +124,56 @@ void initConfig() { SWConfig config(confPath.c_str()); config["General"]["PassiveFTP"] = "true"; - if (enable) { + if (enableRemote) { config["Sources"]["FTPSource"] = is.getConfEnt(); } config.Save(); +} + + +void initConfig() { + + bool enable = installMgr->isUserDisclaimerConfirmed(); + + createBasicConfig(enable, true); + cout << "\n\nInitialized basic config file at [" << confPath << "]\n"; cout << "with remote source features " << ((enable) ? "ENABLED" : "DISABLED") << "\n"; } -void listModules(SWMgr *mgr) { +void syncConfig() { + + if (!installMgr->isUserDisclaimerConfirmed()) { // assert disclaimer is accepted + cout << "\n\nDisclaimer not accepted. Aborting."; + return; + } + + if (!FileMgr::existsFile(confPath.c_str())) { + createBasicConfig(true, false); + finish(1); // cleanup and don't exit + init(); // re-init with InstallMgr which uses our new config + } + + if (!installMgr->refreshRemoteSourceConfiguration()) + cout << "\nSync'd config file with master remote source list.\n"; + else cout << "\nFailed to sync config file with master remote source list.\n"; +} + + +void listModules(SWMgr *otherMgr) { cout << "Installed Modules:\n\n"; SWModule *module; - for (ModMap::iterator it = mgr->Modules.begin(); it != mgr->Modules.end(); it++) { - module = it->second; - cout << "[" << module->Name() << "] \t- " << module->Description() << "\n"; + std::map<SWModule *, int> mods = InstallMgr::getModuleStatus(*mgr, *otherMgr); + for (std::map<SWModule *, int>::iterator it = mods.begin(); it != mods.end(); it++) { + module = it->first; + SWBuf version = module->getConfigEntry("Version"); + SWBuf status = " "; + if (it->second & InstallMgr::MODSTAT_NEW) status = "*"; + if (it->second & InstallMgr::MODSTAT_OLDER) status = "-"; + if (it->second & InstallMgr::MODSTAT_UPDATED) status = "+"; + + cout << status << "[" << module->Name() << "] \t(" << version << ") \t- " << module->Description() << "\n"; } } @@ -108,9 +195,9 @@ void listRemoteSources() { cout << "Remote Sources:\n\n"; for (InstallSourceMap::iterator it = installMgr->sources.begin(); it != installMgr->sources.end(); it++) { cout << "[" << it->second->caption << "]\n"; - cout << "\tType ; " << it->second->type << "\n"; - cout << "\tSource ; " << it->second->source << "\n"; - cout << "\tDirectory; " << it->second->directory << "\n"; + cout << "\tType : " << it->second->type << "\n"; + cout << "\tSource : " << it->second->source << "\n"; + cout << "\tDirectory: " << it->second->directory << "\n"; } } @@ -121,6 +208,7 @@ void refreshRemoteSource(const char *sourceName) { fprintf(stderr, "Couldn't find remote source [%s]\n", sourceName); finish(-3); } + if (!installMgr->refreshRemoteSource(source->second)) cout << "Remote Source Refreshed\n"; else cerr << "Error Refreshing Remote Source\n"; @@ -182,6 +270,7 @@ void remoteInstallModule(const char *sourceName, const char *modName) { finish(-4); } module = it->second; + int error = installMgr->installModule(mgr, 0, module->Name(), is); if (error) { cout << "Error installing module: [" << module->Name() << "] (write permissions?)\n"; @@ -207,11 +296,7 @@ void localDirInstallModule(const char *dir, const char *modName) { int main(int argc, char **argv) { - mgr = new SWMgr(); - char *envhomedir = getenv ("HOME"); - SWBuf baseDir = (envhomedir) ? envhomedir : "."; - baseDir += "/.sword/InstallMgr"; - installMgr = new InstallMgr(baseDir); + init(); SWLog::getSystemLog()->setLogLevel(SWLog::LOG_DEBUG); @@ -251,7 +336,14 @@ int main(int argc, char **argv) { uninstallModule(argv[2]); break; case 's': - listRemoteSources(); + switch (argv[1][2]) { + case 0: // -s list sources + listRemoteSources(); + break; + case 'c': // -sc sync config with master + syncConfig(); + break; + } break; case 'r': // remote option switch (argv[1][2]) { diff --git a/utilities/kylixmake/libsword.bpr b/utilities/kylixmake/libsword.bpr index e634040..363a406 100644 --- a/utilities/kylixmake/libsword.bpr +++ b/utilities/kylixmake/libsword.bpr @@ -60,6 +60,7 @@ ../../src/modules/filters/utf8cantillation.o ../../src/modules/filters/utf8greekaccents.o ../../src/modules/filters/utf8hebrewpoints.o + ../../src/modules/filters/utf8arabicpoints.o ../../src/modules/filters/utf8html.o ../../src/modules/filters/utf8latin1.o ../../src/modules/filters/utf8nfc.o ../../src/modules/filters/utf8nfkd.o diff --git a/utilities/lexdump.c b/utilities/lexdump.c index 25ff5d7..72e1658 100644 --- a/utilities/lexdump.c +++ b/utilities/lexdump.c @@ -1,3 +1,24 @@ +/****************************************************************************** + * This utility outputs a specified ordinal entry from a lex + * + * $Id: lexdump.c 2362 2009-04-29 07:21:35Z scribe $ + * + * Copyright 1998-2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <fcntl.h> @@ -31,9 +52,9 @@ int main(int argc, char **argv) { tmpbuf = calloc(strlen(argv[1]) + 11,1); sprintf(tmpbuf, "%s.idx", argv[1]); - idxfd = open(tmpbuf, O_RDONLY|O_BINARY, S_IREAD|S_IWRITE|S_IRGRP|S_IROTH); + idxfd = open(tmpbuf, O_RDONLY|O_BINARY); sprintf(tmpbuf, "%s.dat", argv[1]); - datfd = open(tmpbuf, O_RDONLY|O_BINARY, S_IREAD|S_IWRITE|S_IRGRP|S_IROTH); + datfd = open(tmpbuf, O_RDONLY|O_BINARY); free(tmpbuf); offset = atoi(argv[2]) * 6; diff --git a/utilities/mkfastmod.cpp b/utilities/mkfastmod.cpp index eeebcaf..bee620e 100644 --- a/utilities/mkfastmod.cpp +++ b/utilities/mkfastmod.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <stdio.h> #include <rawtext.h> #include <swmgr.h> @@ -33,15 +50,13 @@ void percentUpdate(char percent, void *userData) { int main(int argc, char **argv) { - if (argc != 2) { fprintf(stderr, "usage: %s <modname>\n", argv[0]); exit(-1); } - + SWModule *target; ListKey listkey; - VerseKey vk; ModMap::iterator it; SWMgr manager; diff --git a/utilities/mod2imp.cpp b/utilities/mod2imp.cpp index a979407..0a108f9 100644 --- a/utilities/mod2imp.cpp +++ b/utilities/mod2imp.cpp @@ -1,75 +1,117 @@ -// Compression on variable granularity +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ -#include <fcntl.h> #include <iostream> -#include <fstream> -#include <string> - -#ifndef __GNUC__ -#include <io.h> -#else -#include <unistd.h> -#endif +#include <map> +#include <stdio.h> -#include <ztext.h> -#include <zld.h> -#include <zcom.h> +#include <markupfiltmgr.h> #include <swmgr.h> -#include <lzsscomprs.h> -#include <zipcomprs.h> +#include <swmodule.h> #include <versekey.h> -#include <stdio.h> + +using std::map; +using std::cout; +using std::endl; #ifndef NO_SWORD_NAMESPACE -using sword::SWModule; -using sword::SWMgr; -using sword::ModMap; -using sword::SWKey; -using sword::VerseKey; -using sword::SW_POSITION; + +using namespace sword; + #endif -void errorOutHelp(char *appName) { - std::cerr << appName << " - a tool to output a Sword module in SWORD's 'imp' import format\n"; - std::cerr << "usage: "<< appName << " <modname> \n"; - std::cerr << "\n\n"; +void usage(const char *progName, const char *error = 0) { + if (error) fprintf(stderr, "\n%s: %s\n", progName, error); + fprintf(stderr, "\n=== mod2imp (Revision $Rev: 2234 $) SWORD module exporter.\n"); + fprintf(stderr, "\nusage: %s <module_name> [options]\n" + "\t -r [output_format] - render content instead of outputting raw native\n" + "\t\tdata. output_format can be: OSIS, HTMLHREF, RTF.\n" + "\t -s - strip markup instead of outputting raw native data.\n" + "\t -f <option_name> <option_value> - when rendering (-r, above), option\n" + "\t\tfilter values can be set with this option.\n\n" + , progName); exit(-1); } int main(int argc, char **argv) { - SWModule *inModule = 0; - - if ((argc != 2)) { - errorOutHelp(argv[0]); + // handle options + if (argc < 2) usage(*argv); + + const char *progName = argv[0]; + const char *modName = argv[1]; + bool render = false; + bool strip = false; + SWBuf renderForm; + SWBuf optionName; + map<SWBuf, SWBuf> options; // optionName, optionValue; + + for (int i = 2; i < argc; i++) { + if (!strcmp(argv[i], "-r")) { + if (strip) usage(progName, "-r can't be supplied when using -s"); + if (i+1 < argc) renderForm = argv[++i]; + render = true; + } + else if (!strcmp(argv[i], "-s")) { + if (render) usage(progName, "-s can't be supplied when using -r"); + strip = true; + } + else if (!strcmp(argv[i], "-f")) { + if (i+1 < argc) optionName = argv[++i]; + if (i+1 < argc) options[optionName] = argv[++i]; + else usage(progName, "-f requires <option_name> <option_value>"); + } + else usage(progName, (((SWBuf)"Unknown argument: ")+ argv[i]).c_str()); } + // ----------------------------------------------------- - if ((!strcmp(argv[1], "-h")) || (!strcmp(argv[1], "--help")) || (!strcmp(argv[1], "/?")) || (!strcmp(argv[1], "-?")) || (!strcmp(argv[1], "-help"))) { - errorOutHelp(argv[0]); - } + MarkupFilterMgr *markupMgr = 0; + if (renderForm == "HTMLHREF") markupMgr = new MarkupFilterMgr(sword::FMT_HTMLHREF); + else if (renderForm == "OSIS") markupMgr = new MarkupFilterMgr(sword::FMT_OSIS); + else if (renderForm == "RTF") markupMgr = new MarkupFilterMgr(sword::FMT_RTF); + else if (renderForm.length()) usage(progName, (((SWBuf) "Unknown output_format for -r (")+renderForm+")").c_str()); - SWMgr mgr; + SWMgr *mgr = (markupMgr) ? new SWMgr(markupMgr) : new SWMgr(); - ModMap::iterator it = mgr.Modules.find(argv[1]); - if (it == mgr.Modules.end()) { - fprintf(stderr, "error: %s: couldn't find module: %s \n", argv[0], argv[1]); - exit(-2); + // set any options filters passed with -f + for (map<SWBuf, SWBuf>::iterator it = options.begin(); it != options.end(); it++) { + mgr->setGlobalOption(it->first, it->second); } - inModule = it->second; + SWModule *module = mgr->getModule(modName); + + if (!module) usage(progName, (((SWBuf) "Couldn't find module: ") + modName).c_str()); - SWKey *key = (SWKey *)*inModule; + + SWKey *key = module->getKey(); VerseKey *vkey = SWDYNAMIC_CAST(VerseKey, key); if (vkey) vkey->Headings(1); - for ((*inModule) = TOP; !inModule->Error(); (*inModule)++) { - std::cout << "$$$" << inModule->KeyText() << std::endl; - std::cout << inModule->getRawEntry() << std::endl; + for ((*module) = TOP; !module->Error(); (*module)++) { + std::cout << "$$$" << module->KeyText() << std::endl; + std::cout << ((render) ? module->RenderText() : (strip) ? module->StripText() : module->getRawEntry()) << "\n"; } + + cout << endl; + return 0; } diff --git a/utilities/mod2osis.cpp b/utilities/mod2osis.cpp index ee71e25..087300c 100644 --- a/utilities/mod2osis.cpp +++ b/utilities/mod2osis.cpp @@ -1,4 +1,20 @@ -// Compression on variable granularity +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <fcntl.h> #include <iostream> #include <fstream> @@ -79,7 +95,7 @@ int main(int argc, char **argv) int lastBook = 9999; int lastChap = 9999; if (!vkey) { - cerr << "Currently mod2zmod only works with verse keyed modules\n\n"; + cerr << "Currently mod2osis only works with verse keyed modules\n\n"; exit(-1); } @@ -122,13 +138,18 @@ int main(int argc, char **argv) cout << "\t</header>\n\n"; - (*inModule) = TOP; -// for ((*inModule) = TOP; (inModule->Key() < (VerseKey)"Mat 2:1"); (*inModule)++) { -// for ((*vkey) = "Mark6:29"; !inModule->Error(); (*inModule)++) { + (*inModule) = TOP; + + SWKey *p = inModule->CreateKey(); + VerseKey *tmpKey = SWDYNAMIC_CAST(VerseKey, p); + if (!tmpKey) { + delete p; + tmpKey = new VerseKey(); + } + *tmpKey = inModule->getKeyText(); - VerseKey tmpKey; - tmpKey.Headings(1); - tmpKey.AutoNormalize(0); + tmpKey->Headings(1); + tmpKey->AutoNormalize(0); for ((*inModule) = TOP; !inModule->Error(); (*inModule)++) { bool newTest = false; @@ -157,10 +178,10 @@ int main(int argc, char **argv) cout << "\t</div>\n"; } *buf = 0; - tmpKey = *vkey; - tmpKey.Chapter(0); - tmpKey.Verse(0); - sprintf(buf, "\t<div type=\"book\" osisID=\"%s\">\n", tmpKey.getOSISRef()); + *tmpKey = *vkey; + tmpKey->Chapter(0); + tmpKey->Verse(0); + sprintf(buf, "\t<div type=\"book\" osisID=\"%s\">\n", tmpKey->getOSISRef()); // filter.ProcessText(buf, 200 - 3, &lastHeading, inModule); cout << "" << buf << endl; openbook = true; @@ -172,9 +193,9 @@ int main(int argc, char **argv) cout << "\t</chapter>\n"; } *buf = 0; - tmpKey = *vkey; - tmpKey.Verse(0); - sprintf(buf, "\t<chapter osisID=\"%s\">\n", tmpKey.getOSISRef()); + *tmpKey = *vkey; + tmpKey->Verse(0); + sprintf(buf, "\t<chapter osisID=\"%s\">\n", tmpKey->getOSISRef()); // filter.ProcessText(buf, 200 - 3, &lastHeading, inModule); cout << "" << buf; openchap = true; diff --git a/utilities/mod2vpl.cpp b/utilities/mod2vpl.cpp index edcbfc6..09ec053 100644 --- a/utilities/mod2vpl.cpp +++ b/utilities/mod2vpl.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <swmgr.h> #include <swmodule.h> #include <swkey.h> diff --git a/utilities/mod2zmod.cpp b/utilities/mod2zmod.cpp index 4e91ea3..2e5be31 100644 --- a/utilities/mod2zmod.cpp +++ b/utilities/mod2zmod.cpp @@ -1,5 +1,22 @@ // Compression on variable granularity +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <fcntl.h> #include <iostream> #include <fstream> @@ -14,6 +31,7 @@ #include <ztext.h> #include <zld.h> #include <zcom.h> +#include <swtext.h> #include <swmgr.h> #include <lzsscomprs.h> #include <zipcomprs.h> @@ -23,20 +41,7 @@ #ifndef NO_SWORD_NAMESPACE -using sword::SWCompress; -using sword::CipherFilter; -using sword::SWModule; -using sword::SWMgr; -using sword::ModMap; -using sword::zText; -using sword::zLD; -using sword::zCom; -using sword::SWFilter; -using sword::VerseKey; -using sword::SWKey; -using sword::SW_POSITION; -using sword::ZipCompress; -using sword::LZSSCompress; +using namespace sword; #endif using std::cerr; @@ -113,9 +118,12 @@ int main(int argc, char **argv) int result = 0; switch (modType) { case BIBLE: - case COM: - result = zText::createModule(argv[2], iType); + case COM: { + SWKey *k = inModule->getKey(); + VerseKey *vk = SWDYNAMIC_CAST(VerseKey, k); + result = zText::createModule(argv[2], iType, vk->getVersificationSystem()); break; + } case LEX: result = zLD::createModule(argv[2]); break; @@ -128,10 +136,15 @@ int main(int argc, char **argv) switch (modType) { case BIBLE: - case COM: - outModule = new zText(argv[2], 0, 0, iType, compressor); // open our datapath with our RawText driver. + case COM: { + SWKey *k = inModule->getKey(); + VerseKey *vk = SWDYNAMIC_CAST(VerseKey, k); + outModule = new zText(argv[2], 0, 0, iType, compressor, + 0, ENC_UNKNOWN, DIRECTION_LTR, FMT_UNKNOWN, 0, + vk->getVersificationSystem()); // open our datapath with our RawText driver. ((VerseKey *)(SWKey *)(*inModule))->Headings(1); break; + } case LEX: outModule = new zLD(argv[2], 0, 0, iType, compressor); // open our datapath with our RawText driver. break; diff --git a/utilities/mod2zmod2.cpp b/utilities/mod2zmod2.cpp deleted file mode 100644 index d552e35..0000000 --- a/utilities/mod2zmod2.cpp +++ /dev/null @@ -1,205 +0,0 @@ -// Compression on variable granularity - -#include <fcntl.h> -#include <iostream> -#include <fstream> -#include <string> - -#ifndef __GNUC__ -#include <io.h> -#else -#include <unistd.h> -#endif - -//#include <ztext.h> -#include <ztext2.h> -//#include <zld.h> -//#include <zcom.h> -#include <swmgr.h> -#include <lzsscomprs.h> -#include <zipcomprs.h> -#include <versekey.h> -#include <versekey2.h> -#include <stdio.h> -#include <cipherfil.h> -#ifndef NO_SWORD_NAMESPACE -using sword::SWCompress; -using sword::CipherFilter; -using sword::SWModule; -using sword::SWMgr; -using sword::ModMap; -using sword::zText2; -//using sword::zLD; -//using sword::zCom; -using sword::SWFilter; -using sword::VerseKey2; -using sword::VerseKey; -using sword::SWKey; -using sword::SW_POSITION; -using sword::ZipCompress; -using sword::LZSSCompress; -#endif - -using std::cerr; -using std::string; -using std::cout; -using std::endl; - -void errorOutHelp(char *appName) { - cerr << appName << " - a tool to create compressed Sword modules\n"; - cerr << "version 0.1\n\n"; - cerr << "usage: "<< appName << " <modname> <datapath> [blockType [blockNum [compressType [cipherKey]]]]\n\n"; - cerr << "datapath: the directory in which to write the zModule\n"; - cerr << "blockType : (default 4)\n\t2 - verses\n\t3 - chapters\n\t4 - books\n"; - cerr << "blockNum : (default 1)\n\tnumber of blockType per block\n"; - cerr << "compressType: (default 1):\n\t1 - LZSS\n\t2 - Zip\n"; - cerr << "\n\n"; - exit(-1); -} - - -int main(int argc, char **argv) -{ - int iType = 4; - int iPerBlock = 1; - int compType = 1; - string cipherKey = ""; - SWCompress *compressor = 0; - SWModule *inModule = 0; - SWModule *outModule = 0; - - - if ((argc < 3) || (argc > 6)) { - errorOutHelp(argv[0]); - } - - if (argc > 3) { - iType = atoi(argv[3]); - if (argc > 4) { - iPerBlock = atoi(argv[4]); - if (argc > 5) { - compType = atoi(argv[5]); - if (argc > 6) { - cipherKey = argv[6]; - } - } - } - } - - if ((iType < 2) || (iType > 5) || (iPerBlock < 1) || (compType < 1) || (compType > 2) || (!strcmp(argv[1], "-h")) || - (!strcmp(argv[1], "--help")) || (!strcmp(argv[1], "/?")) || (!strcmp(argv[1], "-?")) || (!strcmp(argv[1], "-help"))) { - errorOutHelp(argv[0]); - } - - SWMgr mgr; - - ModMap::iterator it = mgr.Modules.find(argv[1]); - if (it == mgr.Modules.end()) { - fprintf(stderr, "error: %s: couldn't find module: %s \n", argv[0], argv[1]); - exit(-2); - } - - inModule = it->second; - - // Try to initialize a default set of datafiles and indicies at our - // datapath location passed to us from the user. - -#define BIBLE 1 -#define LEX 2 -#define COM 3 - - int modType = 0; - if (!strcmp(inModule->Type(), "Biblical Texts")) modType = BIBLE; - if (!strcmp(inModule->Type(), "Lexicons / Dictionaries")) modType = LEX; - if (!strcmp(inModule->Type(), "Commentaries")) modType = COM; - - switch (compType) { // these are deleted by zText - case 1: compressor = new LZSSCompress(); break; - case 2: compressor = new ZipCompress(); break; - } - cout << "Creating module " << argv[2] << endl; - int result = 1; - switch (modType) { - case BIBLE: - result = zText2::createModule(argv[2], iType); - break; - case LEX: - //result = zLD::createModule(argv[2]); - result = 1; - break; - case COM: - result = zText2::createModule(argv[2], iType); - break; - } - - if (result) { - fprintf(stderr, "error: %s: couldn't create module at path: %s \n", argv[0], argv[2]); - exit(-3); - } - - cout << "Opening datapath with driver " << argv[2] << " Type " << iType << " PerBlock " << iPerBlock << endl; - switch (modType) { - case BIBLE: - outModule = new zText2(argv[2], 0, 0, iType, iPerBlock, compressor); // open our datapath with our RawText driver. - ((VerseKey *)(SWKey *)(*inModule))->Headings(1); - break; - case LEX: - //outModule = new zLD(argv[2], 0, 0, iType, compressor); // open our datapath with our RawText driver. - break; - case COM: - outModule = new zText2(argv[2], 0, 0, iType, iPerBlock, compressor); // open our datapath with our RawText driver. - ((VerseKey *)(SWKey *)(*inModule))->Headings(1); - break; - } - - SWFilter *cipherFilter = 0; - if (!cipherKey.empty()) { - cipherFilter = new CipherFilter(cipherKey.c_str()); - outModule->AddRawFilter(cipherFilter); - } - - string lastBuffer = "Something that would never be first module entry"; - SWKey bufferKey; - SWKey lastBufferKey; - SWKey *outModuleKey = outModule->CreateKey(); - VerseKey2 *vkey = SWDYNAMIC_CAST(VerseKey2, outModuleKey); - outModuleKey->Persist(1); - if (vkey) { - vkey->Headings(1); - vkey->AutoNormalize(0); - } - outModule->setKey(*outModuleKey); - - inModule->setSkipConsecutiveLinks(false); - (*inModule) = TOP; - while (!inModule->Error()) { - bufferKey = *(SWKey *)(*inModule); - cout << bufferKey << endl; - // pseudo-check for link. Will get most common links. - if ((lastBuffer == inModule->getRawEntry()) &&(lastBuffer.length() > 0)) { - *outModuleKey = bufferKey; - outModule->linkEntry(&lastBufferKey); // link to last key - //cout << "Adding [" << bufferKey << "] link to: [" << lastBufferKey << "]\n"; - } - else { - lastBuffer = inModule->getRawEntry(); - lastBufferKey = inModule->KeyText(); - if (lastBuffer.length() > 0) { - //cout << "Adding [" << bufferKey << "] new text. \n"; - *outModuleKey = bufferKey; -// outModule->getRawEntry(); // snap -// outModule->setKey(bufferKey); - (*outModule) << lastBuffer.c_str(); // save new text; - } - else { - cout << "Skipping [" << bufferKey << "] no entry in inModule. \n"; - } - } - (*inModule)++; - } - delete outModule; - delete outModuleKey; - if (cipherFilter) - delete cipherFilter; -} - diff --git a/utilities/modwrite.cpp b/utilities/modwrite.cpp index deec68e..74f123e 100644 --- a/utilities/modwrite.cpp +++ b/utilities/modwrite.cpp @@ -1,4 +1,19 @@ -// Compression on variable granularity +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <fcntl.h> #include <iostream> diff --git a/utilities/no13.c b/utilities/no13.c index 5245d27..f84cfcc 100644 --- a/utilities/no13.c +++ b/utilities/no13.c @@ -1,3 +1,23 @@ +/****************************************************************************** + * Strips ascii 13 chars out of a file + * + * $Id: no13.c 2327 2009-04-22 11:42:33Z scribe $ + * + * Copyright 1998-2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ #include <fcntl.h> #include <stdio.h> diff --git a/utilities/osis2mod.cpp b/utilities/osis2mod.cpp index 69d984d..473a90f 100644 --- a/utilities/osis2mod.cpp +++ b/utilities/osis2mod.cpp @@ -1,24 +1,40 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <fcntl.h> #include <errno.h> #include <stdlib.h> -#include <string> #include <stack> +#include <vector> #include <iostream> #include <fstream> #include <utilstr.h> #include <swmgr.h> #include <rawtext.h> +#include <rawtext4.h> #include <swbuf.h> #include <utilxml.h> #include <listkey.h> #include <versekey.h> #include <ztext.h> -// #include <zld.h> -// #include <zcom.h> #include <lzsscomprs.h> #include <zipcomprs.h> #include <cipherfil.h> @@ -28,61 +44,61 @@ #include <latin1utf8.h> #endif -//#define DEBUG - -// Debug for simple transformation stack -//#define DEBUG_XFORM - -// Debug for parsing osisRefs -//#define DEBUG_REF - -// Debug for tag stack -//#define DEBUG_STACK - #ifndef NO_SWORD_NAMESPACE using namespace sword; #endif using namespace std; -#ifdef _ICU_ -UTF8NFC normalizer; -int normalized = 0; +// Turn debugging on and off +//#define DEBUG +int debug = 0; +const int DEBUG_WRITE = 1; // writing to module +const int DEBUG_VERSE = 2; // verse start and end +const int DEBUG_QUOTE = 4; // quotes, especially Words of Christ (WOC) +const int DEBUG_TITLE = 8; // titles +const int DEBUG_INTERVERSE = 16; // inter-verse maerial +const int DEBUG_XFORM = 32; // transformations +const int DEBUG_REV11N = 64; // versification +const int DEBUG_REF = 128; // parsing of osisID and osisRef +const int DEBUG_STACK = 256; // cleanup of references +const int DEBUG_OTHER = 512; // ins and outs of books, chapters and verses + +// Exit codes +const int EXIT_BAD_ARG = 1; // Bad parameter given for program +const int EXIT_NO_WRITE = 2; // Could not open the module for writing +const int EXIT_NO_CREATE = 3; // Could not create the module +const int EXIT_NO_READ = 4; // Could not open the input file for reading. +const int EXIT_BAD_NESTING = 5; // BSP or BCV nesting is bad +#ifdef _ICU_ +UTF8NFC normalizer; Latin1UTF8 converter; -int converted = 0; #endif +int normalized = 0; +int converted = 0; SWText *module = 0; -VerseKey *currentVerse = 0; +VerseKey currentVerse; +SWBuf v11n = "KJV"; char activeOsisID[255]; char currentOsisID[255]; -const char *osisabbrevs[] = {"Gen", "Exod", "Lev", "Num", "Deut", "Josh", "Judg", - "Ruth", "1Sam", "2Sam", "1Kgs", "2Kgs", "1Chr", "2Chr", "Ezra", "Neh", - "Esth", "Job", "Ps", "Prov", "Eccl", "Song", "Isa", "Jer", "Lam", "Ezek", - "Dan", "Hos", "Joel", "Amos", "Obad", "Jonah", "Mic", "Nah", "Hab", - "Zeph", "Hag", "Zech", "Mal", - "Matt", "Mark", "Luke", "John", "Acts", "Rom", "1Cor", "2Cor", "Gal", - "Eph", "Phil", "Col", "1Thess", "2Thess", "1Tim", "2Tim", "Titus", - "Phlm", "Heb", "Jas", "1Pet", "2Pet", "1John", "2John", "3John", - "Jude", "Rev"}; +SWBuf activeVerseText; + +ListKey currentKeyIDs = ListKey(); + +std::vector<ListKey> linkedVerses; static bool inCanonicalOSISBook = true; // osisID is for a book that is not in Sword's canon -static bool normalize = true; // Whether to normalize UTF-8 to NFC +static bool normalize = true; // Whether to normalize UTF-8 to NFC bool isOSISAbbrev(const char *buf) { - bool match = false; - for (int i = 0; i < 66; i++) { - if (!strcmp(buf, osisabbrevs[i])) { - match = true; - break; - } - } - return match; + VerseMgr *vmgr = VerseMgr::getSystemVerseMgr(); + const VerseMgr::System *av11n = vmgr->getVersificationSystem(currentVerse.getVersificationSystem()); + return av11n->getBookNumberByOSISName(buf) >= 0; } - /** * Determine whether the string contains a valid unicode sequence. * The following table give the pattern of a valid UTF-8 character. @@ -109,51 +125,92 @@ bool isOSISAbbrev(const char *buf) { * author DM Smith */ int detectUTF8(const char *txt) { - unsigned int countUTF8 = 0; - int count = 0; - - // Cast it to make masking and shifting easier - const unsigned char *p = (const unsigned char*) txt; - while (*p) { - // Is the high order bit set? - if (*p & 0x80) { - // Then count the number of high order bits that are set. - // This determines the number of following bytes - // that are a part of the unicode character - unsigned char i = *p; - for (count = 0; i & 0x80; count++) { - i <<= 1; - } - - // Validate count: - // Count 0: bug in code that would cause core walking - // Count 1: is a pattern of 10nnnnnn, - // which does not signal the start of a unicode character - // Count 5 to 8: 111110nn, 1111110n and 11111110 and 11111111 - // are not legal starts, either - if (count < 2 || count > 4) return 0; - - // At this point we expect (count - 1) following characters - // of the pattern 10nnnnnn - while (--count && *++p) { - // The pattern of each following character must be: 10nnnnnn - // So, compare the top 2 bits. - if ((0xc0 & *p) != 0x80) return 0; - } - - // Oops, we've run out of bytes too soon: Cannot be UTF-8 - if (count) return 0; - - // We have a valid UTF-8 character, so count it - countUTF8++; - } + unsigned int countUTF8 = 0; + int count = 0; + + // Cast it to make masking and shifting easier + const unsigned char *p = (const unsigned char*) txt; + while (*p) { + // Is the high order bit set? + if (*p & 0x80) { + // Then count the number of high order bits that are set. + // This determines the number of following bytes + // that are a part of the unicode character + unsigned char i = *p; + for (count = 0; i & 0x80; count++) { + i <<= 1; + } + + // Validate count: + // Count 0: bug in code that would cause core walking + // Count 1: is a pattern of 10nnnnnn, + // which does not signal the start of a unicode character + // Count 5 to 8: 111110nn, 1111110n and 11111110 and 11111111 + // are not legal starts, either + if (count < 2 || count > 4) return 0; + + // At this point we expect (count - 1) following characters + // of the pattern 10nnnnnn + while (--count && *++p) { + // The pattern of each following character must be: 10nnnnnn + // So, compare the top 2 bits. + if ((0xc0 & *p) != 0x80) return 0; + } + + // Oops, we've run out of bytes too soon: Cannot be UTF-8 + if (count) return 0; + + // We have a valid UTF-8 character, so count it + countUTF8++; + } - // Advance to the next character to examine. - p++; - } - - // At this point it is either UTF-8 or 7-bit ascii - return countUTF8 ? 1 : -1; + // Advance to the next character to examine. + p++; + } + + // At this point it is either UTF-8 or 7-bit ascii + return countUTF8 ? 1 : -1; +} + +void prepareSWText(const char *osisID, SWBuf &text) +{ + // Always check on UTF8 and report on non-UTF8 entries + int utf8State = detectUTF8(text.c_str()); + + // Trust, but verify. + if (!normalize && !utf8State) { + cout << "WARNING(UTF8): " << osisID << ": Should be converted to UTF-8 (" << text << ")" << endl; + } + +#ifdef _ICU_ + if (normalize) { + // Don't need to normalize text that is ASCII + // But assume other non-UTF-8 text is Latin1 (cp1252) and convert it to UTF-8 + if (!utf8State) { + cout << "INFO(UTF8): " << osisID << ": Converting to UTF-8 (" << text << ")" << endl; + converter.processText(text, (SWKey *)2); // note the hack of 2 to mimic a real key. TODO: remove all hacks + converted++; + + // Prepare for double check. This probably can be removed. + // But for now we are running the check again. + // This is to determine whether we need to normalize output of the conversion. + utf8State = detectUTF8(text.c_str()); + } + + // Double check. This probably can be removed. + if (!utf8State) { + cout << "ERROR(UTF8): " << osisID << ": Converting to UTF-8 (" << text << ")" << endl; + } + + if (utf8State > 0) { + SWBuf before = text; + normalizer.processText(text, (SWKey *)2); // note the hack of 2 to mimic a real key. TODO: remove all hacks + if (before != text) { + normalized++; + } + } + } +#endif } // This routine converts an osisID or osisRef into one that SWORD can parse into a verse list @@ -175,8 +232,10 @@ void prepareSWVerseKey(SWBuf &buf) { bool inRange = false; while (*p) { if (inRange) { -#ifdef DEBUG_REF - cout << "Copy range marker:" << *p << endl;; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << "DEBUG(REF): Copy range marker:" << *p << endl;; + } #endif // Range markers are copied as is *s++ = *p++; @@ -193,28 +252,36 @@ void prepareSWVerseKey(SWBuf &buf) { if (*n == ':') { // set p to skip the work prefix p = n + 1; -#ifdef DEBUG_REF - cout << "Found a work prefix "; - for (char *x = s; x <= n; x++) { - cout << *x; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << "DEBUG(REF): Found a work prefix "; + for (char *x = s; x <= n; x++) { + cout << *x; + } + cout << endl; } - cout << endl; #endif } // Now we are in the meat of an osisID. // Copy it to its end but stop on a grain marker of '!' -#ifdef DEBUG_REF - cout << "Copy osisID:"; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << "DEBUG(REF): Copy osisID:"; + } #endif while (*p && *p != '!' && *p != ' ' && *p != '-') { -#ifdef DEBUG_REF - cout << *p; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << *p; + } #endif *s++ = *p++; } -#ifdef DEBUG_REF - cout << endl; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << endl; + } #endif // The ! and everything following until we hit @@ -224,12 +291,14 @@ void prepareSWVerseKey(SWBuf &buf) { while (*n && *n != ' ' && *n != '-') { n++; } -#ifdef DEBUG_REF - cout << "Found a grain suffix "; - for (char *x = p; x < n; x++) { - cout << *x; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << "DEBUG(REF): Found a grain suffix "; + for (char *x = p; x < n; x++) { + cout << *x; + } + cout << endl; } - cout << endl; #endif p = n; } @@ -240,9 +309,11 @@ void prepareSWVerseKey(SWBuf &buf) { // then we are entering a range inRange = !inRange && *p == '-'; -#ifdef DEBUG_REF - if (inRange) { - cout << "Found a range" << endl; +#ifdef DEBUG + if (debug & DEBUG_REF) { + if (inRange) { + cout << "DEBUG(REF): Found a range" << endl; + } } #endif @@ -254,8 +325,10 @@ void prepareSWVerseKey(SWBuf &buf) { } // replacing them all with a ';' *s++ = ';'; -#ifdef DEBUG_REF - cout << "replacing space with ;. Remaining: " << p << endl; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << "DEBUG(REF): replacing space with ;. Remaining: " << p << endl; + } #endif } } @@ -267,607 +340,921 @@ void prepareSWVerseKey(SWBuf &buf) { *s = '\0'; // Since we modified the swbuf, we need to tell it what we have done buf.setSize(s - buf.c_str()); -#ifdef DEBUG_REF - cout << "shortended keyVal to`" << buf.c_str() << "`"<< endl; +#ifdef DEBUG + if (debug & DEBUG_REF) { + cout << "DEBUG(REF): shortended keyVal to`" << buf.c_str() << "`"<< endl; + } #endif } } -bool isKJVRef(const char *buf) { - VerseKey vk, test; - vk.AutoNormalize(0); - vk.Headings(1); // turn on mod/testmnt/book/chap headings - vk.Persist(1); - // lets do some tests on the verse -------------- - vk = buf; - test = buf; +/** + * Determine whether a verse as given is valid for the versification. + * This is done by comparing the before and after of normalization. + */ +bool isValidRef(const char *buf) { + // Create a VerseKey that does not do auto normalization + // Note: need to turn on headings so that a heading does not get normalized anyway + // And set it to the reference under question + VerseKey before; + before.setVersificationSystem(currentVerse.getVersificationSystem()); + before.AutoNormalize(0); + before.Headings(1); + before.setText(buf); + + // If we are a heading we must bail + // These will autonormalize to the last verse of the prior chapter + if (!before.Testament() || !before.Book() || !before.Chapter() || !before.Verse()) { + return true; + } + + // Create a VerseKey that does do auto normalization + // And set it to the reference under question + VerseKey after; + after.setVersificationSystem(currentVerse.getVersificationSystem()); + after.AutoNormalize(1); + after.setText(buf); + + if (before == after) + { + return true; + } + + // If we have gotten here the reference is not in the selected versification. + cout << "INFO(V11N): " << before << " is not in the " << currentVerse.getVersificationSystem() << " versification." << endl; - if (vk.Testament() && vk.Book() && vk.Chapter() && vk.Verse()) { // if we're not a heading #ifdef DEBUG - cout << (const char*)vk << " == " << (const char*)test << endl; -#endif - return (vk == test); + if (debug & DEBUG_REV11N) { + cout << "DEBUG(V11N): " << before << " normalizes to " << after << endl; } - else return true; // no check if we're a heading... Probably bad. +#endif + + return false; } +/** + * This routine is used to ensure that all the text in the input is saved to the module. + * Assumption: The input orders all the verses for a chapter in numerical order. Thus, any + * verses that are not in the chosen versification (v11n) follow those that are. + * + * The prior implementation of this adjusted the verse to the last one that is in the chosen v11n. + * If it the chapter were extra, then it is appended to the last verse of the last + * chapter in the chosen v11n for that book. If it is just extra verses for a chapter, then it is + * appended to the last verse of the chapter. + * + * The problem with this is when a OSIS verse refers to more than one verse, e.g. + * osisID="Gen.1.29 Gen.1.30 Gen.1.31" (Gen.1.31 is the last verse of the chapter in the chosen v11n) + * and then it is followed by Gen.1.32. + * + * This routine assumes that linking is postponed to the end so that in the example Gen.1.30-31 + * are not linked but rather empty. This routine will then find the last verse in the computed + * chapter that has content. + * + * Alternative, we could have done linking as we went, but this routine would have needed + * to find the first entry in the link set and elsewhere in the code when appending to a + * verse, it would need to be checked for adjacent links and those would have needed to be adjusted. + * + * param key the key that may need to be adjusted + */ +void makeValidRef(VerseKey &key) { + + int chapterMax = key.getChapterMax(); + int verseMax = key.getVerseMax(); -void makeKJVRef(VerseKey &key) { - cout << "re-versified " << key; #ifdef DEBUG - cout << "\tC" << (int)(key.builtin_books[key.Testament()-1][key.Book()-1].chapmax) << ":V" << (int)(key.builtin_books[key.Testament()-1][key.Book()-1].versemax[key.Chapter()-1]); + if (debug & DEBUG_REV11N) { + cout << "DEBUG(V11N) Chapter max:" << chapterMax << ", Verse Max:" << verseMax << endl; + } #endif - if (key.Chapter() > key.builtin_books[key.Testament()-1][key.Book()-1].chapmax) { - key.Chapter(key.builtin_books[key.Testament()-1][key.Book()-1].chapmax); - key.Verse(key.builtin_books[key.Testament()-1][key.Book()-1].versemax[key.Chapter()-1]); + + cout << "INFO(V11N): " << key.getOSISRef() << " is not in the " << key.getVersificationSystem() << " versification."; + // Since isValidRef returned false constrain the key to the nearest prior reference. + // If we are past the last chapter set the reference to the last chapter + if (key.Chapter() > chapterMax) { + key.Chapter(chapterMax); } - else if (key.Verse() > key.builtin_books[key.Testament()-1][key.Book()-1].versemax[key.Chapter()-1]) { - key.Verse(key.builtin_books[key.Testament()-1][key.Book()-1].versemax[key.Chapter()-1]); + + // Either we set the chapter to the last chapter and now need to set to the last verse in the chapter + // Or the verse is beyond the end of the chapter. + // In any case we need to constrain the verse to it's chapter. + key.Verse(verseMax); + + // There are three cases we want to handle: + // In the examples we are using the KJV versification where the last verse of Matt.7 is Matt.7.29. + // In each of these cases the out-of-versification, extra verse is Matt.7.30. + // 1) The "extra" verse follows the last verse in the chapter. + // <verse osisID="Matt.7.29">...</verse><verse osisID="Matt.7.30">...</verse> + // In this case re-versify Matt.7.30 as Matt.7.29. + // + // 2) The "extra" verse follows a range (a set of linked verses). + // <verse osisID="Matt.7.28-Matt.7.29">...</verse><verse osisID="Matt.7.30">...</verse> + // In this case, re-versify Matt.7.30 as Matt.7.28, the first verse in the linked set. + // Since we are post-poning linking, we want to re-reversify to the last entry in the module. + // + // 3) The last verse in the chapter is not in the input. There may be other verses missing as well. + // <verse osisID="Matt.7.8">...</verse><verse osisID="Matt.7.30">...</verse> + // In this case we should re-versify Matt.7.30 as Matt.7.29. + // However, since this and 2) are ambiguous, we'll re-reversify to the last entry in the module. + + while (!key.Error() && !module->hasEntry(&key)) { + key.decrement(1); } - cout << "\tas " << key << endl; -} + cout << " Appending content to " << key.getOSISRef() << endl; +} -void writeEntry(VerseKey &key, SWBuf &text, bool force = false) { - static SWBuf activeVerseText; +void writeEntry(SWBuf &text, bool force = false) { char keyOsisID[255]; - if (inCanonicalOSISBook) { - strcpy(keyOsisID, key.getOSISRef()); + static const char* revision = "<milestone type=\"x-importer\" subType=\"x-osis2mod\" n=\"$Rev: 2400 $\"/>"; + static bool firstOT = true; + static bool firstNT = true; - // set keyOsisID to anything that an osisID cannot be. - if (force) { - strcpy(keyOsisID, "-force"); - } - - static VerseKey lastKey; - lastKey.AutoNormalize(0); - lastKey.Headings(1); + if (!inCanonicalOSISBook) { + return; + } - VerseKey saveKey; - saveKey.AutoNormalize(0); - saveKey.Headings(1); - saveKey = key; + strcpy(keyOsisID, currentVerse.getOSISRef()); - // If we have seen a verse and the supplied one is different then we output the collected one. - if (*activeOsisID && strcmp(activeOsisID, keyOsisID)) { + // set keyOsisID to anything that an osisID cannot be. + if (force) { + strcpy(keyOsisID, "-force"); + } - key = lastKey; + static VerseKey lastKey; + lastKey.setVersificationSystem(currentVerse.getVersificationSystem()); + lastKey.AutoNormalize(0); + lastKey.Headings(1); - if (!isKJVRef(key)) { - makeKJVRef(key); - } + VerseKey saveKey; + saveKey.setVersificationSystem(currentVerse.getVersificationSystem()); + saveKey.AutoNormalize(0); + saveKey.Headings(1); + saveKey = currentVerse; -#ifdef _ICU_ - int utf8State = detectUTF8(activeVerseText.c_str()); - if (normalize) { - // Don't need to normalize text that is ASCII - // But assume other non-UTF-8 text is Latin1 (cp1252) and convert it to UTF-8 - if (!utf8State) { - cout << "Warning: " << activeOsisID << ": Converting to UTF-8 (" << activeVerseText << ")" << endl; - converter.processText(activeVerseText, (SWKey *)2); // note the hack of 2 to mimic a real key. TODO: remove all hacks - converted++; - - // Prepare for double check. This probably can be removed. - // But for now we are running the check again. - // This is to determine whether we need to normalize output of the conversion. - utf8State = detectUTF8(activeVerseText.c_str()); - } + // If we have seen a verse and the supplied one is different then we output the collected one. + if (*activeOsisID && strcmp(activeOsisID, keyOsisID)) { - // Double check. This probably can be removed. - if (!utf8State) { - cout << "Error: " << activeOsisID << ": Converting to UTF-8 (" << activeVerseText << ")" << endl; - } + if (!isValidRef(lastKey)) { + makeValidRef(lastKey); + } - if (utf8State > 0) { - SWBuf before = activeVerseText; - normalizer.processText(activeVerseText, (SWKey *)2); // note the hack of 2 to mimic a real key. TODO: remove all hacks - if (before != activeVerseText) { - normalized++; - } - } + currentVerse = lastKey; + + prepareSWText(activeOsisID, activeVerseText); + + // Put the revision into the module + int testmt = currentVerse.Testament(); + if ((testmt == 1 && firstOT) || (testmt == 2 && firstNT)) { + VerseKey t; + t.setVersificationSystem(currentVerse.getVersificationSystem()); + t.AutoNormalize(0); + t.Headings(1); + t = currentVerse; + currentVerse.Book(0); + currentVerse.Chapter(0); + currentVerse.Verse(0); + module->setEntry(revision); + currentVerse = t; + switch (testmt) { + case 1: + firstOT = false; + break; + case 2: + firstNT = false; + break; } -#endif + } - SWBuf currentText = module->getRawEntry(); - if (currentText.length()) { - cout << "Appending entry: " << key.getOSISRef() << ": " << activeVerseText << endl; - activeVerseText = currentText + " " + activeVerseText; - } + // If the entry already exists, then append this entry to the text. + // This is for verses that are outside the chosen versification. They are appended to the prior verse. + // The space should not be needed if we retained verse tags. + SWBuf currentText = module->getRawEntry(); + if (currentText.length()) { + cout << "INFO(WRITE): Appending entry: " << currentVerse.getOSISRef() << ": " << activeVerseText << endl; + activeVerseText = currentText + " " + activeVerseText; + } #ifdef DEBUG - cout << "Write: " << activeOsisID << ":" << key.getOSISRef() << ": " << activeVerseText << endl; -#endif - - module->setEntry(activeVerseText); - activeVerseText = ""; + if (debug & DEBUG_WRITE) { + cout << "DEBUG(WRITE): " << activeOsisID << ":" << currentVerse.getOSISRef() << ": " << activeVerseText << endl; } +#endif - // eliminate leading whitespace on the beginning of each verse and - // before we append to current content, since we just added one - text.trimStart(); - if (activeVerseText.length()) { - activeVerseText += " "; - activeVerseText += text; - } - else { - activeVerseText = text; - } + module->setEntry(activeVerseText); + activeVerseText = ""; + } - key = saveKey; - lastKey = key; - strcpy(activeOsisID, keyOsisID); + // The following is for initial verse content and for appending interverse content. + // Eliminate leading whitespace on the beginning of each verse and + // before we append to current content, since we just added one + text.trimStart(); + if (activeVerseText.length()) { + activeVerseText += " "; + activeVerseText += text; + } + else { + activeVerseText = text; } + // text has been consumed so clear it out. + text = ""; + + currentVerse = saveKey; + lastKey = currentVerse; + strcpy(activeOsisID, keyOsisID); } +void linkToEntry(VerseKey &linkKey, VerseKey &dest) { + + // Only link verses that are in the versification. + if (!isValidRef(linkKey)) { + return; + } -void linkToEntry(VerseKey& dest) { - //cout << "Verse: " << key << "\n"; - //cout << "TEXT: " << text << "\n\n"; - //SWBuf currentText = module->getRawEntry(); - //if (currentText.length()) - // text = currentText + " " + text; VerseKey saveKey; + saveKey.setVersificationSystem(currentVerse.getVersificationSystem()); saveKey.AutoNormalize(0); saveKey.Headings(1); - saveKey = *currentVerse; + saveKey = currentVerse; + currentVerse = linkKey; - if (!isKJVRef(*currentVerse)) { - makeKJVRef(*currentVerse); - } - - cout << "Linking " << module->KeyText() << " to " << dest.getText() << "\n"; + cout << "INFO(LINK): Linking " << currentVerse.getOSISRef() << " to " << dest.getOSISRef() << "\n"; module->linkEntry(&dest); - *currentVerse = saveKey; + currentVerse = saveKey; } // Return true if the content was handled or is to be ignored. // false if the what has been seen is to be accumulated and considered later. -bool handleToken(SWBuf &text, XMLTag *token) { +bool handleToken(SWBuf &text, XMLTag token) { // Everything between the begin book tag and the first begin chapter tag is inBookHeader - static bool inBookHeader = false; + static bool inBookHeader = false; + // Everything between the begin chapter tag and the first begin verse tag is inChapterHeader - static bool inChapterHeader = false; + static bool inChapterHeader = false; - // Flags to indicate whether we are in a book, chapter and/or verse - //static bool inBook = false; - //static bool inChapter = false; - static bool inVerse = true; + // Flags indicating whether we are processing the content of a chapter + static bool inChapter = false; - static SWBuf header = ""; + // Flags indicating whether we are processing the content of a verse + static bool inVerse = false; - // Used to remember titles that need to be handle specially - static SWBuf lastTitle = ""; - static int titleOffset = -1; - static bool inTitle = false; - static int titleDepth = 0; + // Flags indicating whether we are processing the content of to be prepended to a verse + static bool inPreVerse = false; + static int genID = 1; - static ListKey lastVerseIDs = ListKey(); + // Flag indicating whether we are in "Words of Christ" + static bool inWOC = false; + // Tag for WOC quotes within a verse + static XMLTag wocTag = "<q who=\"Jesus\" marker=\"\">"; + + // Flag used to indicate where useful text begins + static bool firstDiv = false; + + // Stack of quote elements used to handle Words of Christ + static std::stack<XMLTag> quoteStack; // Stack of elements used to validate that books, chapters and verses are well-formed // This goes beyond simple xml well-formed and also considers milestoned div, chapter and verse // to be begin and end tags, too. // It is an error if books and chapters are not well formed (though not required by OSIS) // It is a warning that verses are not well formed (because some clients are not ready) - static std::stack<XMLTag*> tagStack; - // The following are used to validate well-formedness - static int chapterDepth = 0; - static int bookDepth = 0; - static int verseDepth = 0; - - int tagDepth = tagStack.size(); - const char *tokenName = token->getName(); - bool isEndTag = token->isEndTag() || token->getAttribute("eID"); - const char *typeAttr = token->getAttribute("type"); - - //Titles are treated specially. - // If the title has an attribute type of "main" or "chapter" - // it belongs to its <div> or <chapter> and is treated as part of its heading - // Otherwise if it a title in a chapter before the first the first verse it - // is put into the verse as a preverse title. - if (!token->isEmpty() && !isEndTag && titleDepth == 0 && (!strcmp(tokenName, "title")) && (!typeAttr || (strcmp(typeAttr, "main") && strcmp(typeAttr, "chapter")))) { - titleOffset = text.length(); //start of the title tag - lastTitle = ""; - inTitle = true; - tagStack.push(token); -#ifdef DEBUG_STACK - cout << currentOsisID << ": push (" << tagStack.size() << ") " << token->getName() << endl; -#endif - titleDepth = tagStack.size(); - return false; - } - // Check titleDepth since titles can be nested. Don't want to quit too early. - else if (isEndTag && tagDepth == titleDepth && (!strcmp(tokenName, "title"))) { - lastTitle.append(text.c_str() + titleOffset); //<title ...> up to the end </title> - lastTitle.append(*token); //</title> - -#ifdef DEBUG - cout << currentOsisID << ":" << endl; - cout << "\tlastTitle: " << lastTitle.c_str() << endl; - cout << "\ttext-lastTitle: " << text.c_str()+titleOffset << endl; - cout << "\ttext: " << text.c_str() << endl; -#endif - inTitle = false; - titleDepth = 0; -#ifdef DEBUG_STACK - cout << currentOsisID << ": pop(" << tagStack.size() << ") " << tagStack.top()->getName() << endl; -#endif - tagStack.pop(); - return false; // don't add </title> to the text itself - } - + static std::stack<XMLTag> tagStack; + // The following are used to validate well-formedness + static int chapterDepth = 0; + static int bookDepth = 0; + static int verseDepth = 0; -//-- START TAG ------------------------------------------------------------------------- + int tagDepth = tagStack.size(); + const char *tokenName = token.getName(); + bool isEndTag = token.isEndTag() || token.getAttribute("eID"); + const char *typeAttr = token.getAttribute("type"); + // process start tags if (!isEndTag) { // Remember non-empty start tags - if (!token->isEmpty()) { + if (!token.isEmpty()) { tagStack.push(token); -#ifdef DEBUG_STACK - cout << currentOsisID << ": push (" << tagStack.size() << ") " << token->getName() << endl; +#ifdef DEBUG + if (debug & DEBUG_STACK) { + cout << "DEBUG(STACK): " << currentOsisID << ": push (" << tagStack.size() << ") " << token.getName() << endl; + } #endif } - //-- WITH OSIS ID ------------------------------------------------------------------------- - //-- OR ANNOTATE REF ------------------------------------------------------------------------- - if (token->getAttribute("osisID") || token->getAttribute("annotateRef")) { + // throw away everything up to the first div + if (!firstDiv) { + if (!strcmp(tokenName, "div")) { +#ifdef DEBUG + if (debug & DEBUG_OTHER) { + cout << "DEBUG(FOUND): Found first div and pitching prior material: " << text << endl; + } +#endif + // TODO: Save off the content to use it to suggest the module's conf. + firstDiv = true; + text = ""; + } + else { + // Collect the content so it can be used to suggest the module's conf. + return false; + } + } + + //-- WITH osisID OR annotateRef ------------------------------------------------------------------------- + // Handle Book, Chapter, and Verse (or commentary equivalent) + if (token.getAttribute("osisID") || token.getAttribute("annotateRef")) { - // BOOK START + // BOOK START, <div type="book" ...> if ((!strcmp(tokenName, "div")) && (typeAttr && !strcmp(typeAttr, "book"))) { - inVerse = false; if (inBookHeader || inChapterHeader) { // this one should never happen, but just in case #ifdef DEBUG - cout << currentOsisID << ": HEADING "; + if (debug & DEBUG_TITLE) { + cout << "DEBUG(TITLE): " << currentOsisID << ": OOPS HEADING " << endl; + cout << "\tinChapterHeader = " << inChapterHeader << endl; + cout << "\tinBookHeader = " << inBookHeader << endl; + } #endif - currentVerse->Testament(0); - currentVerse->Book(0); - currentVerse->Chapter(0); - currentVerse->Verse(0); - writeEntry(*currentVerse, text); + currentVerse.Testament(0); + currentVerse.Book(0); + currentVerse.Chapter(0); + currentVerse.Verse(0); + writeEntry(text); } - strcpy(currentOsisID, token->getAttribute("osisID")); - *currentVerse = currentOsisID; - currentVerse->Chapter(0); - currentVerse->Verse(0); - inBookHeader = true; + currentVerse = token.getAttribute("osisID"); + currentVerse.Chapter(0); + currentVerse.Verse(0); + strcpy(currentOsisID, currentVerse.getOSISRef()); + + inChapter = false; + inVerse = false; + inPreVerse = false; + inBookHeader = true; inChapterHeader = false; - lastTitle = ""; - text = ""; - bookDepth = tagStack.size(); - chapterDepth = 0; - verseDepth = 0; - inCanonicalOSISBook = isOSISAbbrev(token->getAttribute("osisID")); + bookDepth = tagStack.size(); + chapterDepth = 0; + verseDepth = 0; - return true; + inCanonicalOSISBook = isOSISAbbrev(token.getAttribute("osisID")); + if (!inCanonicalOSISBook) { + cout << "WARNING(V11N): New book is " << token.getAttribute("osisID") << " and is not in " << v11n << " versification, ignoring" << endl; + } +#ifdef DEBUG + else if (debug & DEBUG_OTHER) { + cout << "DEBUG(FOUND): New book is " << currentVerse.getOSISRef() << endl; + } +#endif + + return false; } - // CHAPTER START - else if (((!strcmp(tokenName, "div")) && (typeAttr && !strcmp(typeAttr, "chapter"))) - || (!strcmp(tokenName, "chapter")) - ) { - inVerse = false; + // CHAPTER START, <div type="chapter" ...> or <chapter ...> + if (((!strcmp(tokenName, "div")) && (typeAttr && !strcmp(typeAttr, "chapter"))) || + (!strcmp(tokenName, "chapter")) + ) { if (inBookHeader) { #ifdef DEBUG - cout << currentOsisID << ": BOOK HEADING "<< text.c_str() << endl; + if (debug & DEBUG_TITLE) { + cout << "DEBUG(TITLE): " << currentOsisID << ": BOOK HEADING "<< text.c_str() << endl; + } #endif - writeEntry(*currentVerse, text); + writeEntry(text); } - strcpy(currentOsisID, token->getAttribute("osisID")); - *currentVerse = currentOsisID; - currentVerse->Verse(0); - inBookHeader = false; + currentVerse = token.getAttribute("osisID"); + currentVerse.Verse(0); +#ifdef DEBUG + if (debug & DEBUG_OTHER) { + cout << "DEBUG(FOUND): Current chapter is " << currentVerse.getOSISRef() << " (" << token.getAttribute("osisID") << ")" << endl; + } +#endif + strcpy(currentOsisID, currentVerse.getOSISRef()); + + inChapter = true; + inVerse = false; + inPreVerse = false; + inBookHeader = false; inChapterHeader = true; - lastTitle = ""; - text = ""; - chapterDepth = tagStack.size(); - verseDepth = 0; - return true; + chapterDepth = tagStack.size(); + verseDepth = 0; + + return false; } - // VERSE OR COMMENTARY START - else if (!strcmp(tokenName, "verse") || - (!strcmp(tokenName, "div") && - token->getAttribute("annotateType"))) { + // VERSE, <verse ...> OR COMMENTARY START, <div annotateType="xxx" ...> + if (!strcmp(tokenName, "verse") || + (!strcmp(tokenName, "div") && token.getAttribute("annotateType"))) { #ifdef DEBUG - cout << "Entering verse" << endl; + if (debug & DEBUG_OTHER) { + cout << "DEBUG(FOUND): Entering verse" << endl; + } #endif - inVerse = true; if (inChapterHeader) { SWBuf heading = text; - - //make sure we don't insert the preverse title which belongs to the first verse of this chapter! - // Did we have a preverse title? - if (lastTitle.length()) - { - //Was the preVerse title in the header (error if not)? - const char* header = heading.c_str(); - const char* preVerse = strstr(header, lastTitle); - if (preVerse) { - if (preVerse == header) { - heading = ""; // do nothing - } - else { - // remove everything before the title from the beginning. - text = preVerse; - // Remove text from the end of the header. - heading.setSize(preVerse - header); - } - } - else { - cout << currentOsisID << ": Warning: Bug in code. Could not find title." << endl; - } - } - else { - text = ""; - } + text = ""; if (heading.length()) { #ifdef DEBUG - cout << currentOsisID << ": CHAPTER HEADING "<< heading.c_str() << endl; + if (debug & DEBUG_TITLE) { + cout << "DEBUG(TITLE): " << currentOsisID << ": CHAPTER HEADING "<< heading.c_str() << endl; + } #endif - writeEntry(*currentVerse, heading); + writeEntry(heading); } inChapterHeader = false; } - SWBuf keyVal = token->getAttribute(strcmp(tokenName, "verse") ? "annotateRef" : "osisID"); + // Did we have pre-verse material that needs to be marked? + if (inPreVerse) { + char genBuf[200]; + sprintf(genBuf, "<div type=\"x-milestone\" subType=\"x-preverse\" eID=\"pv%d\"/>", genID++); + text.append(genBuf); + } + + // Get osisID for verse or annotateRef for commentary + SWBuf keyVal = token.getAttribute(strcmp(tokenName, "verse") ? "annotateRef" : "osisID"); + + // Massage the key into a form that ParseVerseList can accept prepareSWVerseKey(keyVal); - lastVerseIDs = currentVerse->ParseVerseList(keyVal, *currentVerse, true); - // set currentVerse to the first value in the keyVal - VerseKey *element = SWDYNAMIC_CAST(VerseKey, lastVerseIDs.GetElement(0)); - if (element) { - *currentVerse = element->LowerBound().getText(); + // The osisID or annotateRef can be more than a single verse + // The first or only one is the currentVerse + // Use the last verse seen (i.e. the currentVerse) as the basis for recovering from bad parsing. + // This should never happen if the references are valid OSIS references + ListKey verseKeys = currentVerse.ParseVerseList(keyVal, currentVerse, true); + int memberKeyCount = verseKeys.Count(); + if (memberKeyCount) { + currentVerse = verseKeys.getElement(0); + // See if this osisID or annotateRef refers to more than one verse. + // If it does, save it until all verses have been seen. + // At that point we will output links. + // This can be done by incrementing, which will produce an error + // if there is only one verse. + verseKeys.setPosition(TOP); + verseKeys.increment(1); + if (!verseKeys.Error()) { + linkedVerses.push_back(verseKeys); + } } else { - *currentVerse = lastVerseIDs.GetElement(0)->getText(); + cout << "ERROR(REF): Invalid osisID/annotateRef: " << token.getAttribute(strcmp(tokenName, "verse") ? "annotateRef" : "osisID") << endl; } - strcpy(currentOsisID, currentVerse->getOSISRef()); + strcpy(currentOsisID, currentVerse.getOSISRef()); #ifdef DEBUG - cout << "Current verse is " << *currentVerse << endl; - cout << "osisID/annotateRef is adjusted to" << keyVal << endl; + if (debug & DEBUG_OTHER) { + cout << "DEBUG(FOUND): New current verse is " << currentVerse.getOSISRef() << endl; + cout << "DEBUG(FOUND): osisID/annotateRef is adjusted to: " << keyVal << endl; + } #endif - verseDepth = tagStack.size(); + inVerse = true; + inPreVerse = false; + inBookHeader = false; + inChapterHeader = false; + verseDepth = tagStack.size(); - return true; - } - } - // Handle stuff between the verses - // Whitespace producing empty tokens are appended to prior entry - // Also the quote - // This is a hack to get ESV to work - else if (!inTitle && !inVerse && token->isEmpty()) { // && !inBookHeader && !inChapterHeader) { - if (!strcmp(tokenName, "p") || - !strcmp(tokenName, "div") || - !strcmp(tokenName, "q") || - !strcmp(tokenName, "l") || - !strcmp(tokenName, "lb") || - !strcmp(tokenName, "lg") - ) { + // Include the token if it is not a verse + if (strcmp(tokenName, "verse")) { + text.append(token); + } #ifdef DEBUG - if (token) { - cout << currentOsisID << ": appending interverse start token " << *token << ":" << text.c_str() << endl; + else if (debug & DEBUG_VERSE) + { + // transform the verse into a milestone + XMLTag t = "<milestone resp=\"v\" />"; + // copy all the attributes of the verse element to the milestone + StringList attrNames = token.getAttributeNames(); + for (StringList::iterator loop = attrNames.begin(); loop != attrNames.end(); loop++) { + const char* attr = (*loop).c_str(); + t.setAttribute(attr, token.getAttribute(attr)); } + text.append(t); + } #endif - SWBuf tmp = token->toString(); - writeEntry(*currentVerse, tmp); + + if (inWOC) { + text.append(wocTag); + } return true; } + } // done with Handle Book, Chapter, and Verse (or commentary equivalent) + + // Now consider everything else. + + // Handle WOC quotes. + // Note this requires transformBSP to make them into milestones + // Otherwise have to do it here + if (!strcmp(tokenName, "q")) { + quoteStack.push(token); #ifdef DEBUG - else { - if (token) { - cout << currentOsisID << ": interverse start token " << *token << ":" << text.c_str() << endl; - } + if (debug & DEBUG_QUOTE) { + cout << "DEBUG(QUOTE): " << currentOsisID << ": quote top(" << quoteStack.size() << ") " << token << endl; } #endif + if (token.getAttribute("who") && !strcmp(token.getAttribute("who"), "Jesus")) { + inWOC = true; + + // Output per verse WOC markup. + text.append(wocTag); + + // Output the quotation mark if appropriate, inside the WOC. + // If there is no marker attribute, let the SWORD engine manufacture one. + // If there is a marker attribute and it has content, then output that. + // If the marker attribute is present and empty, then there is nothing to do. + // And have it within the WOC markup + if (!token.getAttribute("marker") || token.getAttribute("marker")[0]) { + token.setAttribute("who", 0); // remove the who="Jesus" + text.append(token); + } + return true; + } + return false; + } + + // Have we found the start of pre-verse material? + // Pre-verse material follows the following rules + // 1) Between the opening of a book and the first chapter, all the material is handled as an introduction to the book. + // 2) Between the opening of a chapter and the first verse, the material is split between the introduction of the chapter + // and the first verse of the chapter. + // A <div> with a type other than section will be taken as a chapter introduction. + // A <title> of type acrostic, psalm or no type, will be taken as a title for the verse. + // A <title> of type main or chapter will be seen as a chapter title. + // 3) Between verses, the material is split between the prior verse and the next verse. + // Basically, while end and empty tags are found, they belong to the prior verse. + // Once a begin tag is found, it belongs to the next verse. + // If the title has an attribute type of "main" or "chapter" + // it belongs to its <div> or <chapter> and is treated as part of its heading + // Otherwise if it a title in a chapter before the first the first verse it + // is put into the verse as a preverse title. + + if (!inPreVerse && !inBookHeader) { + if (inChapterHeader) { + // Determine when we are no longer in a chapter heading, but in pre-verse material: + // If we see one of the following: + // a section div + // a title that is not main or chapter + if ((!strcmp(tokenName, "div") && (typeAttr && !strcmp(typeAttr, "section"))) || + (!strcmp(tokenName, "title") && (!typeAttr || (strcmp(typeAttr, "main") && strcmp(typeAttr, "chapter")))) + ) { + // Since we have found the boundary, we need to write out the chapter heading + writeEntry(text); + // And we are no longer in the chapter heading + inChapterHeader = false; + // But rather, we are now in pre-verse material + inPreVerse = true; + } + } + else if (!inVerse && inChapter) { + inPreVerse = true; + } + + if (inPreVerse) { + char genBuf[200]; + sprintf(genBuf, "<div type=\"x-milestone\" subType=\"x-preverse\" sID=\"pv%d\"/>", genID++); + text.append(genBuf); + } } - } -//-- EMPTY and END TAG --------------------------------------------------------------------------------------------- +#ifdef DEBUG + if (debug & DEBUG_INTERVERSE) { + if (!inVerse && !inBookHeader && !inChapterHeader) { + cout << "DEBUG(INTERVERSE): " << currentOsisID << ": interverse start token " << token << ":" << text.c_str() << endl; + } + } +#endif + return false; + } // Done with procesing start and empty tags + + // Process end tags else { if (tagStack.empty()) { - cout << currentOsisID << ": tag expected" << endl; - exit(1); + cout << "FATAL(NESTING): " << currentOsisID << ": tag expected" << endl; + exit(EXIT_BAD_NESTING); } - XMLTag* topToken = 0; - if (!token->isEmpty()) { - topToken = tagStack.top(); + // Note: empty end tags have the eID attribute + if (!token.isEmpty()) { + XMLTag topToken = tagStack.top(); tagDepth = tagStack.size(); -#ifdef DEBUG_STACK - cout << currentOsisID << ": pop(" << tagDepth << ") " << topToken->getName() << endl; +#ifdef DEBUG + if (debug & DEBUG_STACK) { + cout << "DEBUG(STACK): " << currentOsisID << ": pop(" << tagDepth << ") " << topToken.getName() << endl; + } #endif tagStack.pop(); - if (strcmp(topToken->getName(), tokenName)) { - cout << "Error: " << currentOsisID << ": Expected " << topToken->getName() << " found " << tokenName << endl; -// exit(1); // I'm sure this validity check is a good idea, but there's a but somewhere that's killing the converter here. + if (strcmp(topToken.getName(), tokenName)) { + cout << "FATAL(NESTING): " << currentOsisID << ": Expected " << topToken.getName() << " found " << tokenName << endl; +// exit(EXIT_BAD_NESTING); // (OSK) I'm sure this validity check is a good idea, but there's a but somewhere that's killing the converter here. // So I'm disabling this line. Unvalidated OSIS files shouldn't be run through the converter anyway. + // (DM) This has nothing to do with well-form or valid. It checks milestoned elements for proper nesting. } } + // We haven't seen the first div so there is nothing to do. + if (!firstDiv) { + // Collect the content so it can be used to suggest the module's conf. + return false; + } + // VERSE and COMMENTARY END if (!strcmp(tokenName, "verse") || (inVerse && !strcmp(tokenName, "div"))) { - inVerse = false; if (tagDepth != verseDepth) { - cout << "Warning verse " << currentOsisID << " is not well formed:(" << verseDepth << "," << tagDepth << ")" << endl; + cout << "WARNING(NESTING): verse " << currentOsisID << " is not well formed:(" << verseDepth << "," << tagDepth << ")" << endl; } - if (lastTitle.length()) { - const char* end = strchr(lastTitle, '>'); + // If we are in WOC then we need to terminate the <q who="Jesus" marker=""> that was added earlier in the verse. + if (inWOC) { + text.append("</q>"); + } + + + // Include the token if it is not a verse + if (strcmp(tokenName, "verse")) { + text.append(token); + } #ifdef DEBUG - cout << currentOsisID << ":" << endl; - cout << "\t" << lastTitle << endl; - cout << "\tlength=" << int(end+1 - lastTitle.c_str()) << ", tag:" << lastTitle.c_str() << endl; + else if (debug & DEBUG_VERSE) + { + // transform the verse into a milestone + XMLTag t = "<milestone resp=\"v\" />"; + // copy all the attributes of the verse element to the milestone + StringList attrNames = token.getAttributeNames(); + for (StringList::iterator loop = attrNames.begin(); loop != attrNames.end(); loop++) { + const char* attr = (*loop).c_str(); + t.setAttribute(attr, token.getAttribute(attr)); + } + text.append(t); + } #endif - SWBuf titleTagText; - titleTagText.append(lastTitle.c_str(), end+1 - lastTitle.c_str()); + writeEntry(text); + + inVerse = false; + inPreVerse = false; + verseDepth = 0; + + return true; + } + + // Handle WOC quotes. + // Note this requires transformBSP to make them into milestones + // Otherwise have to manage it here + if (!strcmp(tokenName, "q")) { + XMLTag topToken = quoteStack.top(); #ifdef DEBUG - cout << currentOsisID << ": tagText: " << titleTagText.c_str() << endl;; + if (debug & DEBUG_QUOTE) { + cout << "DEBUG(QUOTE): " << currentOsisID << ": quote pop(" << quoteStack.size() << ") " << topToken << " -- " << token << endl; + } #endif + quoteStack.pop(); - XMLTag titleTag(titleTagText); - titleTag.setAttribute("type", "section"); - titleTag.setAttribute("subType", "x-preverse"); - - //we insert the title into the text again - make sure to remove the old title text - const char* pos = strstr(text, lastTitle); - if (pos) { - SWBuf temp; - temp.append(text, pos-text.c_str()); - temp.append(pos+lastTitle.length()); - text = temp; + // If we have found an end tag for a <q who="Jesus"> then we are done with the WOC + // and we need to terminate the <q who="Jesus" marker=""> that was added earlier in the verse. + if (token.getAttribute("who") && !strcmp(token.getAttribute("who"), "Jesus")) { +#ifdef DEBUG + if (debug & DEBUG_QUOTE) { + cout << "DEBUG(QUOTE): " << currentOsisID << ": (" << quoteStack.size() << ") " << topToken << " -- " << token << endl; } - - //if a title was already inserted at the beginning insert this one after that first title - int titlePos = 0; - if (!strncmp(text.c_str(),"<title ",7)) { - const char* tmp = strstr(text.c_str(), "</title>"); - if (tmp) { - titlePos = (tmp-text.c_str()) + 8; - } +#endif + inWOC = false; + const char *sID = topToken.getAttribute("sID"); + const char *eID = token.getAttribute("eID"); + if (!sID) { + sID = ""; } - text.insert(titlePos, end+1); - text.insert(titlePos, titleTag); - } - // text += token; - writeEntry(*currentVerse, text); - - // If we found an osisID like osisID="Gen.1.1 Gen.1.2 Gen.1.3" we have to link Gen.1.2 and Gen.1.3 to Gen.1.1 - VerseKey dest = *currentVerse; - VerseKey linkKey; - linkKey.AutoNormalize(0); - linkKey.Headings(1); // turn on mod/testmnt/book/chap headings - linkKey.Persist(1); - for (lastVerseIDs = TOP; !lastVerseIDs.Error(); lastVerseIDs++) { - linkKey = lastVerseIDs; - - if (linkKey.Verse() != dest.Verse() || - linkKey.Chapter() != dest.Chapter() || - linkKey.Book() != dest.Book() || - linkKey.Testament() != dest.Testament()) - { - *currentVerse = linkKey; - linkToEntry(dest); + if (!eID) { + eID = ""; + } + if (strcmp(sID, eID)) { + cout << "ERROR(NESTING): improper nesting " << currentOsisID << ": matching (sID,eID) not found. Looking at (" << sID << "," << eID << ")" << endl; } - } - lastTitle = ""; - text = ""; - verseDepth = 0; - return true; + + // Output the quotation mark if appropriate, inside the WOC. + // If there is no marker attribute, let the SWORD engine manufacture one. + // If there is a marker attribute and it has content, then output that. + // If the marker attribute is present and empty, then there is nothing to do. + // And have it within the WOC markup + if (!token.getAttribute("marker") || token.getAttribute("marker")[0]) { + token.setAttribute("who", 0); // remove the who="Jesus" + text.append(token); + } + + // Now close the WOC + text.append("</q>"); + return true; + } + return false; } - else if (!inTitle && !inVerse && !inBookHeader && !inChapterHeader) { + + // Look for the end of document, book and chapter + // Also for material that goes with last entry + if (!inVerse && !inBookHeader && !inChapterHeader) { // Is this the end of a chapter. if (tagDepth == chapterDepth && (!strcmp(tokenName, "div") || !strcmp(tokenName, "chapter"))) { + text.append(token); + writeEntry(text); + inChapter = false; chapterDepth = 0; - verseDepth = 0; - text = ""; + verseDepth = 0; return true; } - // Or is it the end of a book - else if (tagDepth == bookDepth && (!strcmp(tokenName, "div"))) { - bookDepth = 0; + + // Is it the end of a book + if (tagDepth == bookDepth && (!strcmp(tokenName, "div"))) { + text.append(token); + writeEntry(text); + bookDepth = 0; chapterDepth = 0; - verseDepth = 0; - text = ""; + verseDepth = 0; return true; } - // Or is it the end of an osis document - else if (!strcmp(tokenName, "osisText") || !strcmp(tokenName, "osis")) { - bookDepth = 0; + + // Do not include the end of an osis document + if (!strcmp(tokenName, "osisText") || !strcmp(tokenName, "osis")) { + bookDepth = 0; chapterDepth = 0; - verseDepth = 0; - text = ""; + verseDepth = 0; + text = ""; return true; } - // OTHER MISC END TAGS WHEN !INVERSE - // Test that is between verses, or after the last is appended to the preceeding verse. - else if (!strcmp(tokenName, "p") || - !strcmp(tokenName, "div") || - !strcmp(tokenName, "q") || - !strcmp(tokenName, "l") || - !strcmp(tokenName, "lb") || - !strcmp(tokenName, "lg") - ) { - text.append(*token); - writeEntry(*currentVerse, text); - text = ""; + + // When we are not inPreVerse, the interverse tags get appended to the preceeding verse. + if (!inPreVerse) { + text.append(token); + writeEntry(text); #ifdef DEBUG - cout << currentOsisID << ": appending interverse end tag: " << tokenName << "(" << tagDepth << "," << chapterDepth << "," << bookDepth << ")" << endl; + if (debug & DEBUG_INTERVERSE) { + cout << "DEBUG(INTERVERSE): " << currentOsisID << ": appending interverse end tag: " << tokenName << "(" << tagDepth << "," << chapterDepth << "," << bookDepth << ")" << endl; + } #endif return true; } + #ifdef DEBUG - cout << currentOsisID << ": interverse end tag: " << tokenName << "(" << tagDepth << "," << chapterDepth << "," << bookDepth << ")" << endl; + if (debug & DEBUG_INTERVERSE) { + cout << "DEBUG(INTERVERSE): " << currentOsisID << ": interverse end tag: " << tokenName << "(" << tagDepth << "," << chapterDepth << "," << bookDepth << ")" << endl; + } #endif + return false; + } - } + + return false; + } // done with Processing end tags + return false; } -XMLTag* transform(XMLTag* t) { - static std::stack<XMLTag*> tagStack; +/** + * Support normalizations necessary for a SWORD module. + * OSIS allows for document structure (Book, Section, Paragraph or BSP) + * to overlap Bible versification (Book, Chapter, Verse). + * Most SWORD applications need to display verses in isolation or in HTML table cells, + * requiring each stored entry (i.e. verses) to be well-formed xml. + * This routine normalizes container elements which could cross verse boundaries into milestones. + * For most of these OSIS elements, there is a milestone form. However, p is not milestoneable. + * For this reason, p is transformed into lb elements. + * param t the tag to transform + * return the transformed tag or the original one + */ +XMLTag transformBSP(XMLTag t) { + static std::stack<XMLTag> bspTagStack; static int sID = 1; char buf[11]; // Support simplification transformations - if (!t->isEmpty()) { - if (!t->isEndTag()) { - tagStack.push(t); -#ifdef DEBUG_XFORM - cout << currentOsisID << ": xform push (" << tagStack.size() << ") " << t->getName() << endl; + if (t.isEmpty()) { +#ifdef DEBUG + if (debug & DEBUG_XFORM) { + cout << "DEBUG(XFORM): " << currentOsisID << ": xform empty " << t << endl; + } #endif - // Transform <q> into <q sID=""/> except for <q who="Jesus"> - if ((!strcmp(t->getName(), "q")) && (!t->getAttribute("who") || strcmp(t->getAttribute("who"), "Jesus"))) { - t->setEmpty(true); - sprintf(buf, "q%d", sID++); - t->setAttribute("sID", buf); - } + return t; + } - // Transform <p> into <lb type="x-begin-paragraph"/> - else if (!strcmp(t->getName(), "p")) { - // note there is no process that should care about type, it is there for reversability - t->setText("<lb type=\"x-begin-paragraph\" />"); - } + const char* tagName = t.getName(); + if (!t.isEndTag()) { + // Transform <p> into <div type="paragraph"> and milestone it + if (!strcmp(tagName, "p")) { + t.setText("<div type=\"paragraph\" />"); + sprintf(buf, "gen%d", sID++); + t.setAttribute("sID", buf); + } + + // Transform <tag> into <tag sID="">, where tag is a milestoneable element. + // The following containers are milestoneable. + // abbr, closer, div, foreign, l, lg, salute, signed, speech + // Leaving out: + // abbr When would this ever cross a boundary? + // seg as it is used for a divineName hack + // foreign so that it can be easily italicized + else if (!strcmp(tagName, "chapter") || + !strcmp(tagName, "closer") || + !strcmp(tagName, "div") || + !strcmp(tagName, "l") || + !strcmp(tagName, "lg") || + !strcmp(tagName, "q") || + !strcmp(tagName, "salute") || + !strcmp(tagName, "signed") || + !strcmp(tagName, "speech") || + !strcmp(tagName, "verse") + ) { + t.setEmpty(true); + sprintf(buf, "gen%d", sID++); + t.setAttribute("sID", buf); + } + bspTagStack.push(t); +#ifdef DEBUG + if (debug & DEBUG_XFORM) { + cout << "DEBUG(XFORM): " << currentOsisID << ": xform push (" << bspTagStack.size() << ") " << t << " (tagname=" << tagName << ")" << endl; + XMLTag topToken = bspTagStack.top(); + cout << "DEBUG(XFORM): " << currentOsisID << ": xform top(" << bspTagStack.size() << ") " << topToken << endl; } - else { - XMLTag *topToken = tagStack.top(); -#ifdef DEBUG_XFORM - cout << currentOsisID << ": xform pop(" << tagStack.size() << ") " << topToken->getName() << endl; #endif - tagStack.pop(); + } + else { + XMLTag topToken = bspTagStack.top(); +#ifdef DEBUG + if (debug & DEBUG_XFORM) { + cout << "DEBUG(XFORM): " << currentOsisID << ": xform pop(" << bspTagStack.size() << ") " << topToken << endl; + } +#endif + bspTagStack.pop(); + + // Look for the milestoneable container tags handled above. + if (!strcmp(tagName, "chapter") || + !strcmp(tagName, "closer") || + !strcmp(tagName, "div") || + !strcmp(tagName, "l") || + !strcmp(tagName, "lg") || + !strcmp(tagName, "p") || + !strcmp(tagName, "q") || + !strcmp(tagName, "salute") || + !strcmp(tagName, "signed") || + !strcmp(tagName, "speech") || + !strcmp(tagName, "verse") + ) { + // make this a clone of the start tag with sID changed to eID + // Note: in the case of </p> the topToken is a <div type="paragraph"> + t = topToken; + t.setAttribute("eID", t.getAttribute("sID")); + t.setAttribute("sID", 0); + } + } - // If we have found an end tag for a <q> that was transformed then transform this one as well. - if ((!strcmp(t->getName(), "q")) && (!strcmp(topToken->getName(), "q")) && (!topToken->getAttribute("who") || strcmp(topToken->getAttribute("who"), "Jesus"))) { - // make this a clone of the start tag with sID changed to eID - *t = *topToken; - t->setAttribute("eID", t->getAttribute("sID")); - t->setAttribute("sID", 0); - } + return t; +} - // Look for paragraph tags. - // If we have found an end tag for a <p> that was transformed then transform this as well. - else if ((!strcmp(t->getName(), "p")) && (!strcmp(topToken->getName(), "lb"))) { - t->setText("<lb type=\"x-end-paragraph\" />"); - } +/** + * Write out all links in the module. + * Waiting is necessary because writeEntry might ultimately append + * text to a verse moving it's offset in the data file. + * While we are minimizing it by postponing the write until we have + * gathered the next verse, the following scenario is happening: + * A module is using linked verses and has some verses that are not + * in the chosen versification. If the out-of-canon verse happens following + * a linked verse, the out-of-canon verse is appended to the prior + * verse. Care has to be taken that the linked verses all point to + * the first of the set. + */ +void writeLinks() +{ + // Link all the verses + VerseKey destKey; + destKey.setVersificationSystem(currentVerse.getVersificationSystem()); + destKey.AutoNormalize(0); + destKey.Headings(1); + + VerseKey linkKey; + linkKey.setVersificationSystem(currentVerse.getVersificationSystem()); + linkKey.AutoNormalize(0); + linkKey.Headings(1); + for (unsigned int i = 0; i < linkedVerses.size(); i++) { + // The verseKeys is a list of verses + // where the first is the real verse + // and the others link to it. + ListKey verseKeys = linkedVerses[i]; + verseKeys.setPosition(TOP); + destKey = verseKeys.getElement(); + verseKeys.increment(1); + + while (!verseKeys.Error()) { + linkKey = verseKeys.getElement(); + verseKeys.increment(1); + linkToEntry(linkKey, destKey); } } - return t; } void usage(const char *app, const char *error = 0) { @@ -875,6 +1262,8 @@ void usage(const char *app, const char *error = 0) { if (error) fprintf(stderr, "\n%s: %s\n", app, error); fprintf(stderr, "\nusage: %s <output/path> <osisDoc> [OPTIONS]\n", app); + fprintf(stderr, " <output/path>\t\t an existing folder that the module will be written\n"); + fprintf(stderr, " <osisDoc>\t\t path to the validated OSIS document, or '-' to read from standard input\n"); fprintf(stderr, " -a\t\t\t augment module if exists (default is to create new)\n"); fprintf(stderr, " -z\t\t\t use ZIP compression (default no compression)\n"); fprintf(stderr, " -Z\t\t\t use LZSS compression (default no compression)\n"); @@ -882,15 +1271,133 @@ void usage(const char *app, const char *error = 0) { fprintf(stderr, "\t\t\t\t 2 - verse; 3 - chapter; 4 - book\n"); fprintf(stderr, " -c <cipher_key>\t encipher module using supplied key\n"); fprintf(stderr, "\t\t\t\t (default no enciphering)\n"); - fprintf(stderr, " -N\t\t\t Do not convert UTF-8 or normalize UTF-8 to NFC\n"); - fprintf(stderr, "\t\t\t\t (default is to convert to UTF-8, if needed, and then normalize to NFC"); - fprintf(stderr, "\t\t\t\t Note: all UTF-8 texts should be normalized to NFC\n"); - exit(-1); + fprintf(stderr, " -N\t\t\t do not convert UTF-8 or normalize UTF-8 to NFC\n"); + fprintf(stderr, "\t\t\t\t (default is to convert to UTF-8, if needed,\n"); + fprintf(stderr, "\t\t\t\t and then normalize to NFC)\n"); + fprintf(stderr, "\t\t\t\t Note: UTF-8 texts should be normalized to NFC.\n"); + fprintf(stderr, " -s <2|4>\t\t max text size per entry (default is 2).\n"); + fprintf(stderr, "\t\t\t\t Note: useful for commentaries with very large entries\n"); + fprintf(stderr, "\t\t\t\t in uncompressed modules (default is 65535 bytes)\n"); + fprintf(stderr, " -v <v11n>\t\t specify a versification scheme to use (default is KJV)\n"); + fprintf(stderr, "\t\t\t\t Note: The following are valid values for v11n:\n"); + VerseMgr *vmgr = VerseMgr::getSystemVerseMgr(); + StringList av11n = vmgr->getVersificationSystems(); + for (StringList::iterator loop = av11n.begin(); loop != av11n.end(); loop++) { + fprintf(stderr, "\t\t\t\t\t%s\n", (*loop).c_str()); + } +#ifdef DEBUG + fprintf(stderr, " -d <flags>\t\t turn on debugging (default is 0)\n"); + fprintf(stderr, "\t\t\t\t Note: This flag may change in the future.\n"); + fprintf(stderr, "\t\t\t\t Flags: The following are valid values:\n"); + fprintf(stderr, "\t\t\t\t\t0 - no debugging\n"); + fprintf(stderr, "\t\t\t\t\t1 - writes to module, very verbose\n"); + fprintf(stderr, "\t\t\t\t\t2 - verse start and end\n"); + fprintf(stderr, "\t\t\t\t\t4 - quotes, especially Words of Christ (WOC)\n"); + fprintf(stderr, "\t\t\t\t\t8 - titles\n"); + fprintf(stderr, "\t\t\t\t\t16 - inter-verse material\n"); + fprintf(stderr, "\t\t\t\t\t32 - BSP to BCV transformations\n"); + fprintf(stderr, "\t\t\t\t\t64 - v11n exceptions\n"); + fprintf(stderr, "\t\t\t\t\t128 - parsing of osisID and osisRef\n"); + fprintf(stderr, "\t\t\t\t\t256 - internal stack\n"); + fprintf(stderr, "\t\t\t\t\t512 - miscellaneous\n"); + fprintf(stderr, "\t\t\t\t This flag can be used more than once.\n"); +#endif + fprintf(stderr, "\n"); + fprintf(stderr, "See http://www.crosswire.org/wiki/osis2mod for more details.\n"); + fprintf(stderr, "\n"); + exit(EXIT_BAD_ARG); +} + +void processOSIS(istream& infile) { + activeOsisID[0] = '\0'; + + strcpy(currentOsisID,"N/A"); + + currentVerse.setVersificationSystem(v11n); + currentVerse.AutoNormalize(0); + currentVerse.Headings(1); // turn on mod/testmnt/book/chap headings + currentVerse.Persist(1); + + module->setKey(currentVerse); + module->setPosition(TOP); + + SWBuf token; + SWBuf text; + bool intoken = false; + bool inWhitespace = false; + bool seeingSpace = false; + char curChar = '\0'; + + while (infile.good()) { + + curChar = infile.get(); + + // skip the character if it is bad. infile.good() will catch the problem + if (curChar == -1) { + continue; + } + + if (!intoken && curChar == '<') { + intoken = true; + token = "<"; + continue; + } + + // Outside of tokens merge adjacent whitespace + if (!intoken) { + seeingSpace = isspace(curChar); + if (seeingSpace) { + if (inWhitespace) { + continue; + } + // convert all whitespace to blanks + curChar = ' '; + } + inWhitespace = seeingSpace; + } + + if (intoken && curChar == '>') { + intoken = false; + inWhitespace = false; + token.append('>'); + // take this isalpha if out to check for bugs in text + if ((isalpha(token[1])) || (isalpha(token[2]))) { + //cout << "Handle:" << token.c_str() << endl; + XMLTag t = transformBSP(token.c_str()); + + if (!handleToken(text, t)) { + text.append(t); + } + } + continue; + } + + if (intoken) { + token.append(curChar); + } + else { + switch (curChar) { + case '>' : text.append(">"); break; + case '<' : text.append("<"); break; + default : text.append(curChar); break; + } + } + } + + // Force the last entry from the text buffer. + text = ""; + writeEntry(text, true); + writeLinks(); + +#ifdef _ICU_ + if (converted) fprintf(stderr, "osis2mod converted %d verses to UTF-8\n", converted); + if (normalized) fprintf(stderr, "osis2mod normalized %d verses to NFC\n", normalized); +#endif } int main(int argc, char **argv) { - fprintf(stderr, "You are running osis2mod: $Rev: 2169 $\n"); + fprintf(stderr, "You are running osis2mod: $Rev: 2400 $\n"); // Let's test our command line arguments if (argc < 3) { @@ -898,14 +1405,15 @@ int main(int argc, char **argv) { } // variables for arguments, holding defaults - const char* program = argv[0]; - const char* path = argv[1]; - const char* osisDoc = argv[2]; - int append = 0; - int compType = 0; - int iType = 4; - string cipherKey = ""; - + const char* program = argv[0]; + const char* path = argv[1]; + const char* osisDoc = argv[2]; + int append = 0; + SWBuf compType = ""; + bool isCommentary = false; + int iType = 4; + int entrySize = 0; + SWBuf cipherKey = ""; SWCompress *compressor = 0; for (int i = 3; i < argc; i++) { @@ -913,12 +1421,14 @@ int main(int argc, char **argv) { append = 1; } else if (!strcmp(argv[i], "-z")) { - if (compType) usage(*argv, "Cannot specify both -z and -Z"); - compType = 2; + if (compType.size()) usage(*argv, "Cannot specify both -z and -Z"); + if (entrySize) usage(*argv, "Cannot specify both -z and -s"); + compType = "ZIP"; } else if (!strcmp(argv[i], "-Z")) { - if (compType) usage(*argv, "Cannot specify both -z and -Z"); - compType = 1; + if (compType.size()) usage(*argv, "Cannot specify both -z and -Z"); + if (entrySize) usage(*argv, "Cannot specify both -Z and -s"); + compType = "LZSS"; } else if (!strcmp(argv[i], "-b")) { if (i+1 < argc) { @@ -934,62 +1444,127 @@ int main(int argc, char **argv) { if (i+1 < argc) cipherKey = argv[++i]; else usage(*argv, "-c requires <cipher_key>"); } + else if (!strcmp(argv[i], "-v")) { + if (i+1 < argc) v11n = argv[++i]; + else usage(*argv, "-v requires <v11n>"); + } + else if (!strcmp(argv[i], "-s")) { + if (compType.size()) usage(*argv, "Cannot specify -s and -z or -Z"); + if (i+1 < argc) { + entrySize = atoi(argv[++i]); + if (entrySize == 2 || entrySize == 4) { + continue; + } + } + usage(*argv, "-s requires one of <2|4>"); + } + else if (!strcmp(argv[i], "-C")) { + isCommentary = true; + } +#ifdef DEBUG + else if (!strcmp(argv[i], "-d")) { + if (i+1 < argc) debug |= atoi(argv[++i]); + else usage(*argv, "-d requires <flags>"); + } +#endif else usage(*argv, (((SWBuf)"Unknown argument: ")+ argv[i]).c_str()); } - switch (compType) { // these are deleted by zText - case 0: break; - case 1: compressor = new LZSSCompress(); break; - case 2: compressor = new ZipCompress(); break; - } + if (compType == "ZIP") { + compressor = new ZipCompress(); + } + else if (compType = "LZSS") { + compressor = new LZSSCompress(); + } #ifndef _ICU_ if (normalize) { normalize = false; - cout << program << " is not compiled with support for ICU. Ignoring -n flag." << endl; + cout << "WARNING(UTF8): " << program << " is not compiled with support for ICU. Assuming -N." << endl; } #endif #ifdef DEBUG - cout << "path: " << path << " osisDoc: " << osisDoc << " create: " << append << " compressType: " << compType << " blockType: " << iType << " cipherKey: " << cipherKey.c_str() << " normalize: " << normalize << "\n"; - cout << ""; -// exit(-3); + if (debug & DEBUG_OTHER) { + cout << "DEBUG(ARGS):\n\tpath: " << path << "\n\tosisDoc: " << osisDoc << "\n\tcreate: " << append << "\n\tcompressType: " << compType << "\n\tblockType: " << iType << "\n\tcipherKey: " << cipherKey.c_str() << "\n\tnormalize: " << normalize << endl; + } #endif - if (!append) { // == 0 then create module // Try to initialize a default set of datafiles and indicies at our // datapath location passed to us from the user. - if ( compressor ) { - if ( zText::createModule(path, iType) ) { - fprintf(stderr, "error: %s: couldn't create module at path: %s \n", program, path); - exit(-3); + if (compressor) { + if (zText::createModule(path, iType, v11n)) { + fprintf(stderr, "ERROR: %s: couldn't create module at path: %s \n", program, path); + exit(EXIT_NO_CREATE); + } + } + else if (entrySize == 4) { + if (RawText4::createModule(path, v11n)) { + fprintf(stderr, "ERROR: %s: couldn't create module at path: %s \n", program, path); + exit(EXIT_NO_CREATE); } } - else if (RawText::createModule(path)) { - fprintf(stderr, "error: %s: couldn't create module at path: %s \n", program, path); - exit(-3); + else { + if (RawText::createModule(path, v11n)) { + fprintf(stderr, "ERROR: %s: couldn't create module at path: %s \n", program, path); + exit(EXIT_NO_CREATE); + } } } - // Let's see if we can open our input file - ifstream infile(osisDoc); - if (infile.fail()) { - fprintf(stderr, "error: %s: couldn't open input file: %s \n", program, osisDoc); - exit(-2); - } - // Do some initialization stuff if (compressor) { - module = new zText(path, 0, 0, iType, compressor); + // Create a compressed text module allowing very large entries + // Taking defaults except for first, fourth, fifth and last argument + module = new zText( + path, // ipath + 0, // iname + 0, // idesc + iType, // iblockType + compressor, // icomp + 0, // idisp + ENC_UNKNOWN, // enc + DIRECTION_LTR, // dir + FMT_UNKNOWN, // markup + 0, // lang + v11n // versification + ); + } + else if (entrySize == 4) { + // Create a raw text module allowing very large entries + // Taking defaults except for first and last argument + module = new RawText4( + path, // ipath + 0, // iname + 0, // idesc + 0, // idisp + ENC_UNKNOWN, // encoding + DIRECTION_LTR, // dir + FMT_UNKNOWN, // markup + 0, // ilang + v11n // versification + ); } - else{ - module = new RawText(path); // open our datapath with our RawText driver. + else { + // Create a raw text module allowing reasonable sized entries + // Taking defaults except for first and last argument + module = new RawText( + path, // ipath + 0, // iname + 0, // idesc + 0, // idisp + ENC_UNKNOWN, // encoding + DIRECTION_LTR, // dir + FMT_UNKNOWN, // markup + 0, // ilang + v11n // versification + ); } SWFilter *cipherFilter = 0; - if (!cipherKey.empty()) { + if (cipherKey.length()) { fprintf(stderr, "Adding cipher filter with phrase: %s\n", cipherKey.c_str() ); cipherFilter = new CipherFilter(cipherKey.c_str()); module->AddRawFilter(cipherFilter); @@ -997,94 +1572,29 @@ int main(int argc, char **argv) { if (!module->isWritable()) { fprintf(stderr, "The module is not writable. Writing text to it will not work.\nExiting.\n" ); - exit(-1); + exit(EXIT_NO_WRITE); } - activeOsisID[0] = '\0'; - strcpy(currentOsisID,"N/A"); - - currentVerse = new VerseKey(); - currentVerse->AutoNormalize(0); - currentVerse->Headings(1); // turn on mod/testmnt/book/chap headings - currentVerse->Persist(1); - - module->setKey(*currentVerse); - - (*module) = TOP; - - SWBuf token; - SWBuf text; - bool intoken = false; - bool inWhitespace = false; - bool seeingSpace = false; - char curChar = '\0'; - - while (infile.good()) { - - curChar = infile.get(); - - // skip the character if it is bad. infile.good() will catch the problem - if (curChar == -1) { - continue; - } - - if (!intoken && curChar == '<') { - intoken = true; - token = "<"; - continue; - } - - // Outside of tokens merge adjacent whitespace - if (!intoken) { - seeingSpace = isspace(curChar); - if (seeingSpace) { - if (inWhitespace) { - continue; - } - // convert all whitespace to blanks - curChar = ' '; - } - inWhitespace = seeingSpace; - } - - if (intoken && curChar == '>') { - intoken = false; - inWhitespace = false; - token.append('>'); - // take this isalpha if out to check for bugs in text - if ((isalpha(token[1])) || (isalpha(token[2]))) { - //cout << "Handle:" << token.c_str() << endl; - XMLTag *t = new XMLTag(token.c_str()); - - if (!handleToken(text, transform(t))) { - text.append(*t); - } - } - continue; + // Either read from std::cin (aka stdin), when the argument is a '-' + // or from a specified file. + if (!strcmp(osisDoc, "-")) { + processOSIS(cin); + } + else { + // Let's see if we can open our input file + ifstream infile(osisDoc); + if (infile.fail()) { + fprintf(stderr, "ERROR: %s: couldn't open input file: %s \n", program, osisDoc); + exit(EXIT_NO_READ); } - - if (intoken) - token.append(curChar); - else - switch (curChar) { - case '>' : text.append(">"); break; - case '<' : text.append("<"); break; - default : text.append(curChar); break; - } + processOSIS(infile); + infile.close(); } - // Force the last entry from the text buffer. - text = ""; - writeEntry(*currentVerse, text, true); delete module; - delete currentVerse; if (cipherFilter) delete cipherFilter; - infile.close(); -#ifdef _ICU_ - if (converted) fprintf(stderr, "osis2mod converted %d verses to UTF-8\n", converted); - if (normalized) fprintf(stderr, "osis2mod normalized %d verses to NFC\n", normalized); -#endif + exit(0); // success } diff --git a/utilities/perl/cipherkeygen.pl b/utilities/perl/cipherkeygen.pl index db53d88..c3de452 100755 --- a/utilities/perl/cipherkeygen.pl +++ b/utilities/perl/cipherkeygen.pl @@ -1,10 +1,28 @@ #!/usr/bin/perl - +#****************************************************************************** +# # cipherkeygen.pl - +# # generates a cipher key of the format \d{4}[a-zA-Z]{4}\d{4}[a-zA-Z]{4}. # because I'm lazy and not random enough. # and because the utilities/perl directory is kinda bare... +# +# $Id: cipherkeygen.pl 2327 2009-04-22 11:42:33Z scribe $ +# +# Copyright 1998-2009 CrossWire Bible Society (http://www.crosswire.org) +# CrossWire Bible Society +# P. O. Box 2528 +# Tempe, AZ 85280-2528 +# +# This program is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation version 2. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# # let's get a base key of \d{4}[A-Z]{4}\d{4}[A-Z]{4} diff --git a/utilities/perl/linkvers.pl b/utilities/perl/linkvers.pl index caf3192..d1b6157 100755 --- a/utilities/perl/linkvers.pl +++ b/utilities/perl/linkvers.pl @@ -1,4 +1,22 @@ #!/usr/bin/perl +#****************************************************************************** +# +# $Id: linkvers.pl 2327 2009-04-22 11:42:33Z scribe $ +# +# Copyright 1998-2009 CrossWire Bible Society (http://www.crosswire.org) +# CrossWire Bible Society +# P. O. Box 2528 +# Tempe, AZ 85280-2528 +# +# This program is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation version 2. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# $vplfile = $ARGV[0]; diff --git a/utilities/perl/localecap.pl b/utilities/perl/localecap.pl index f5d846e..d73c539 100755 --- a/utilities/perl/localecap.pl +++ b/utilities/perl/localecap.pl @@ -1,6 +1,25 @@ #!/usr/bin/perl - +#****************************************************************************** +# # This tool is only for locales in Latin-1, not UTF-8 (should such locales be supported at a later date) +# +# $Id: localecap.pl 2327 2009-04-22 11:42:33Z scribe $ +# +# Copyright 1998-2009 CrossWire Bible Society (http://www.crosswire.org) +# CrossWire Bible Society +# P. O. Box 2528 +# Tempe, AZ 85280-2528 +# +# This program is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation version 2. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# + use locale; diff --git a/utilities/perl/mkvsmod.pl b/utilities/perl/mkvsmod.pl index e44c27d..bb997b2 100755 --- a/utilities/perl/mkvsmod.pl +++ b/utilities/perl/mkvsmod.pl @@ -1,4 +1,23 @@ #!/usr/bin/perl +#****************************************************************************** +#* +#* $Id: mkvsmod.pl 2327 2009-04-22 11:42:33Z scribe $ +#* +#* Copyright 1998-2009 CrossWire Bible Society (http://www.crosswire.org) +#* CrossWire Bible Society +#* P. O. Box 2528 +#* Tempe, AZ 85280-2528 +#* +#* This program is free software; you can redistribute it and/or modify it +#* under the terms of the GNU General Public License as published by the +#* Free Software Foundation version 2. +#* +#* This program is distributed in the hope that it will be useful, but +#* WITHOUT ANY WARRANTY; without even the implied warranty of +#* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +#* General Public License for more details. +#* +#*/ open (INF, $ARGV[0]); diff --git a/utilities/step2vpl.cpp b/utilities/step2vpl.cpp index b76dd6a..e1b00dc 100644 --- a/utilities/step2vpl.cpp +++ b/utilities/step2vpl.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <iostream> #include <string> #include <stdio.h> diff --git a/utilities/stepdump.cpp b/utilities/stepdump.cpp index b34bd0a..8d136ac 100644 --- a/utilities/stepdump.cpp +++ b/utilities/stepdump.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <iostream> #include <string> #include <sys/stat.h> diff --git a/utilities/sub.c b/utilities/sub.c new file mode 100644 index 0000000..f6eb6df --- /dev/null +++ b/utilities/sub.c @@ -0,0 +1,58 @@ +/****************************************************************************** + * This little utility substitutes all occurances of a string with another + * string. Is this useful? Maybe not. But it's been here since r2 so + * it seems a shame to remove it :) Currently not built by build system + * + * $Id: sub.c 2327 2009-04-22 11:42:33Z scribe $ + * + * Copyright 1998-2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + +#include <stdio.h> +#include <stdlib.h> + +main(int argc, char **argv) +{ + FILE *fp; + char *buf; + int size; + + if ((argc < 3) || (argc > 4)) { + fprintf(stderr, "usage: %s <string> <substitute string> [filename]\n", *argv); + exit(-1); + } + + if (argc > 3) + fp = fopen(argv[3], "r"); + else fp = stdin; + + size = strlen(argv[1]); + buf = (char *)calloc(size + 1, 1); + + while ((buf[size - 1] = fgetc(fp)) != EOF) { + if (!strcmp(buf, argv[1])) { + printf("\n%s", argv[2]); + memset(buf, 0, size); + continue; + } + if (*buf) { + printf("%c", *buf); + } + memmove(buf, &buf[1], size); + } + buf[size - 1] = 0; + printf("%s", buf); +} diff --git a/utilities/tei2mod.cpp b/utilities/tei2mod.cpp index a5ae6f4..e8c6e95 100644 --- a/utilities/tei2mod.cpp +++ b/utilities/tei2mod.cpp @@ -25,6 +25,24 @@ * * author DM Smith */ + +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <string> #include <vector> #include <fstream> @@ -58,11 +76,14 @@ Latin1UTF8 converter; int converted = 0; #endif -//#define DEBUG +#define DEBUG SWLD *module = NULL; SWKey *currentKey = NULL; bool normalize = true; +SWBuf keyStr; + +unsigned long entryCount = 0; /** * Determine whether the string contains a valid unicode sequence. @@ -172,7 +193,7 @@ void normalizeInput(SWKey &key, SWBuf &text) { void writeEntry(SWKey &key, SWBuf &text) { #ifdef DEBUG - cout << key << endl; + cout << "(" << entryCount << ") " << key << endl; #endif module->setKey(key); @@ -182,16 +203,12 @@ void writeEntry(SWKey &key, SWBuf &text) { module->setEntry(text); } -void linkToEntry(SWBuf &keyBuf, vector<string> &linkBuf) { - -/* - char links = linkBuf.size(); - for (int i = 0; i < links; i++) { - SWKey tmpkey = linkBuf[i].c_str(); - module->linkEntry(&tmpkey); - cout << "Linking: " << linkBuf[i] << endl; - } -*/ +void linkToEntry(const SWBuf &keyBuf, const SWBuf &linkBuf) { + SWKey tmpkey = linkBuf.c_str(); + module->linkEntry(&tmpkey); +#ifdef DEBUG + cout << "(" << entryCount << ") " << "Linking: " << linkBuf << endl; +#endif } // Return true if the content was handled or is to be ignored. @@ -199,7 +216,6 @@ void linkToEntry(SWBuf &keyBuf, vector<string> &linkBuf) { bool handleToken(SWBuf &text, XMLTag *token) { // The start token for the current entry; static XMLTag startTag; - static SWBuf keyBuf; // Flags to indicate whether we are in a entry, entryFree or superentry static bool inEntry = false; @@ -207,6 +223,10 @@ bool handleToken(SWBuf &text, XMLTag *token) { static bool inSuperEntry = false; const char *tokenName = token->getName(); + + static const char *splitPtr, *splitPtr2 = NULL; + static char *splitBuffer = new char[4096]; + static SWKey tmpKey; //-- START TAG ------------------------------------------------------------------------- if (!token->isEndTag()) { @@ -221,7 +241,14 @@ bool handleToken(SWBuf &text, XMLTag *token) { #endif startTag = *token; text = ""; - *currentKey = token->getAttribute("key"); + + keyStr = token->getAttribute("n"); // P5 with linking and/or non-URI chars + if (!strlen(keyStr)) { + keyStr = token->getAttribute("sortKey"); // P5 otherwise + if (!strlen(keyStr)) { + keyStr = token->getAttribute("key"); // P4 + } + } return false; // make tag be part of the output } @@ -245,7 +272,52 @@ bool handleToken(SWBuf &text, XMLTag *token) { inEntryFree = false; inSuperEntry = false; text += token->toString(); - writeEntry(*currentKey, text); + + entryCount++; +#ifdef DEBUG + cout << "keyStr: " << keyStr << endl; +#endif + splitPtr = strstr(keyStr, "|"); + if (splitPtr) { + strncpy (splitBuffer, keyStr.c_str(), splitPtr - keyStr.c_str()); + splitBuffer[splitPtr - keyStr.c_str()] = 0; + *currentKey = splitBuffer; +#ifdef DEBUG + cout << "splitBuffer: " << splitBuffer << endl; + cout << "currentKey: " << *currentKey << endl; +#endif + writeEntry(*currentKey, text); +#if 1 + while (splitPtr) { + splitPtr += 1; + splitPtr2 = strstr(splitPtr, "|"); + entryCount++; + if (splitPtr2) { + strncpy (splitBuffer, splitPtr, splitPtr2 - splitPtr); + splitBuffer[splitPtr2 - splitPtr] = 0; +#ifdef DEBUG + cout << "splitBuffer: " << splitBuffer << endl; + cout << "currentKey: " << *currentKey << endl; +#endif + linkToEntry(currentKey->getText(), splitBuffer); + splitPtr = splitPtr2; + } + else { + strcpy (splitBuffer, splitPtr); +#ifdef DEBUG + cout << "splitBuffer: " << splitBuffer << endl; + cout << "currentKey: " << *currentKey << endl; +#endif + linkToEntry(currentKey->getText(), splitBuffer); + splitPtr = 0; + } + } +#endif + } + else { + *currentKey = keyStr; + writeEntry(*currentKey, text); + } // Since we consumed the text, clear it // and tell the caller that the tag was consumed. @@ -448,6 +520,7 @@ int main(int argc, char **argv) { if (!handleToken(text, t)) { text.append(*t); } + delete t; continue; } diff --git a/utilities/treeidxutil.cpp b/utilities/treeidxutil.cpp index 7aa6a68..e6b1b5c 100644 --- a/utilities/treeidxutil.cpp +++ b/utilities/treeidxutil.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <entriesblk.h> #include <iostream> #include <string> diff --git a/utilities/vcppmake/addgb.vcproj b/utilities/vcppmake/addgb.vcproj new file mode 100644 index 0000000..e460afb --- /dev/null +++ b/utilities/vcppmake/addgb.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="addgb"
+ ProjectGUID="{76895767-61D0-41E6-B92D-FD541BB26D32}"
+ RootNamespace="addgb"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{25B20DE1-9768-4AE9-9FCC-4807B792F54E}"
+ >
+ <File
+ RelativePath="..\addgb.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{F6F4AABB-6B91-4406-A856-5EF6A5EB2292}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{4C1F8030-33F2-4796-9A08-CFB4EB47C3B9}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/addld.vcproj b/utilities/vcppmake/addld.vcproj new file mode 100644 index 0000000..a1f9c04 --- /dev/null +++ b/utilities/vcppmake/addld.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="addld"
+ ProjectGUID="{BBB6D2DE-D890-4758-85CF-8057B93CF6C2}"
+ RootNamespace="addld"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{BBB0482D-8A58-4BD6-A35B-C56C6DDE2C6C}"
+ >
+ <File
+ RelativePath="..\addld.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{0FDAB16D-25FC-4A20-B57F-7E424D1FE1F1}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{0DA13E0E-8428-4302-A5B7-B7731EA01A99}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/addvs.vcproj b/utilities/vcppmake/addvs.vcproj new file mode 100644 index 0000000..d2e9562 --- /dev/null +++ b/utilities/vcppmake/addvs.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="addvs"
+ ProjectGUID="{CFF1021E-B878-481A-851B-2B226701D525}"
+ RootNamespace="addvs"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{E3DD8C6A-FFD5-4182-BA1A-F79B4E87D86D}"
+ >
+ <File
+ RelativePath="..\addvs.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{D0EAA0F2-908C-4927-8778-EC45315C9D92}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{C79B0125-F80B-45C3-808F-9A63EF01B79A}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/cipherraw.vcproj b/utilities/vcppmake/cipherraw.vcproj new file mode 100644 index 0000000..b2c989f --- /dev/null +++ b/utilities/vcppmake/cipherraw.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="cipherraw"
+ ProjectGUID="{7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}"
+ RootNamespace="cipherraw"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{324618A6-9C6B-4342-BA6B-FAAC2FC47DB2}"
+ >
+ <File
+ RelativePath="..\cipherraw.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{68672E58-F296-46B7-815B-91225ACC37EA}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{5C82E2E5-561D-46D5-9412-42C970180987}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/emptyvss.vcproj b/utilities/vcppmake/emptyvss.vcproj new file mode 100644 index 0000000..9fcc9e8 --- /dev/null +++ b/utilities/vcppmake/emptyvss.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="emptyvss"
+ ProjectGUID="{A55BEE98-25BB-463D-9016-14CA4567DFBF}"
+ RootNamespace="emptyvss"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{56298DBE-F695-4E36-80E3-02532558B4A3}"
+ >
+ <File
+ RelativePath="..\emptyvss.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{A46AC04E-BDE9-4BFD-A6C3-BB232AFAC157}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{C5D9DDE5-F234-4264-97BE-5910CB2D0412}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/imp2gbs.vcproj b/utilities/vcppmake/imp2gbs.vcproj new file mode 100644 index 0000000..5bacc44 --- /dev/null +++ b/utilities/vcppmake/imp2gbs.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="imp2gbs"
+ ProjectGUID="{2066EC0D-98CC-43E7-8405-5156AF111B38}"
+ RootNamespace="imp2gbs"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{80F1AC21-72BC-4F58-A409-FF1FE6A0BE4D}"
+ >
+ <File
+ RelativePath="..\imp2gbs.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{0BC3868B-D7AD-48F4-A4D5-1ED31B3FBA47}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{001FB903-952C-4239-9BE9-7638AB2E0ECF}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/imp2ld.vcproj b/utilities/vcppmake/imp2ld.vcproj new file mode 100644 index 0000000..4552f02 --- /dev/null +++ b/utilities/vcppmake/imp2ld.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="imp2ld"
+ ProjectGUID="{BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}"
+ RootNamespace="imp2ld"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{EDB0C19E-7654-4C7E-93A6-063B2D6A5B98}"
+ >
+ <File
+ RelativePath="..\imp2ld.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{FD8608AD-8EF9-421E-B9A9-5320297C6EEE}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{48901745-6B6C-4237-ACF2-575C46F3F661}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/imp2vs.vcproj b/utilities/vcppmake/imp2vs.vcproj new file mode 100644 index 0000000..2288737 --- /dev/null +++ b/utilities/vcppmake/imp2vs.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="imp2vs"
+ ProjectGUID="{5637456D-5B83-4C12-A129-708FC8CF0B33}"
+ RootNamespace="imp2vs"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{C07A2DAB-E315-40B1-983F-DEB141497419}"
+ >
+ <File
+ RelativePath="..\imp2vs.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{906D769B-5656-42F9-9153-9D6AD5CE46E1}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{434B6DB0-A3D0-4474-A8ED-56CE5282677D}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/installmgr.vcproj b/utilities/vcppmake/installmgr.vcproj new file mode 100644 index 0000000..a643ec1 --- /dev/null +++ b/utilities/vcppmake/installmgr.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="installmgr"
+ ProjectGUID="{8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}"
+ RootNamespace="installmgr"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{9BA28E95-B1EC-4B74-BEAD-DF58618B6DA4}"
+ >
+ <File
+ RelativePath="..\installmgr.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{55076964-DDBC-443A-A69A-04772B41A081}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{238F22BB-DB96-4964-A271-DE1BCCB111E5}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/mkfastmod.vcproj b/utilities/vcppmake/mkfastmod.vcproj new file mode 100644 index 0000000..d887006 --- /dev/null +++ b/utilities/vcppmake/mkfastmod.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="mkfastmod"
+ ProjectGUID="{DB592F77-25DC-4005-BD49-6D0E50303844}"
+ RootNamespace="mkfastmod"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{DC36DC69-5F3B-44E0-9A8F-9E66BCCD774C}"
+ >
+ <File
+ RelativePath="..\mkfastmod.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{9ED8378C-0F52-43A3-9F97-739C698623ED}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{A5AD3C3A-0702-4FEB-B72E-E0A727E7E74E}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/mod2imp.vcproj b/utilities/vcppmake/mod2imp.vcproj new file mode 100644 index 0000000..18c489b --- /dev/null +++ b/utilities/vcppmake/mod2imp.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="mod2imp"
+ ProjectGUID="{95B74350-2DAB-4CA9-BAFB-A5EB264765A1}"
+ RootNamespace="mod2imp"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{98C9CD67-B919-4E6E-A7FC-725C538AAEB1}"
+ >
+ <File
+ RelativePath="..\mod2imp.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{432C885B-6044-4407-960A-B619C6746C35}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{8733104A-A029-4CBA-860B-07EC28A30C2D}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/mod2osis.vcproj b/utilities/vcppmake/mod2osis.vcproj new file mode 100644 index 0000000..6107fc2 --- /dev/null +++ b/utilities/vcppmake/mod2osis.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="mod2osis"
+ ProjectGUID="{B5D19969-5285-4B0E-B798-496A0B8DCA61}"
+ RootNamespace="mod2osis"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{C1BD58F4-66F3-402C-8739-4485DFAC44E3}"
+ >
+ <File
+ RelativePath="..\mod2osis.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{700A74CE-F1F6-4F00-BA5B-3A2B45E64213}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{6DD53AF8-5EC7-4AF6-BB55-961CCE6C27CA}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/mod2vpl.vcproj b/utilities/vcppmake/mod2vpl.vcproj new file mode 100644 index 0000000..61f32ab --- /dev/null +++ b/utilities/vcppmake/mod2vpl.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="mod2vpl"
+ ProjectGUID="{0C43604F-08D6-490C-BDFD-1B6CACB59740}"
+ RootNamespace="mod2vpl"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{DE27E955-EF56-40B4-9008-67FDE3E5BCEC}"
+ >
+ <File
+ RelativePath="..\mod2vpl.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{6B46E7CA-841A-4B7C-94F6-47C8D05DE5EC}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{FA712B69-B550-453A-B033-ED00E3097C0E}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/mod2zmod.vcproj b/utilities/vcppmake/mod2zmod.vcproj new file mode 100644 index 0000000..3c9d834 --- /dev/null +++ b/utilities/vcppmake/mod2zmod.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="mod2zmod"
+ ProjectGUID="{4E58EE7D-2B4B-42F0-8578-A23883CA6C31}"
+ RootNamespace="mod2zmod"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{43335304-A11D-4A07-BBDB-3D29A6397639}"
+ >
+ <File
+ RelativePath="..\mod2zmod.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{CD1C3801-5480-48F7-9449-6ED761E12DFB}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{01C2818C-6036-4CCD-AD29-74EEC7E97E57}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/osis2mod.vcproj b/utilities/vcppmake/osis2mod.vcproj new file mode 100644 index 0000000..00b25c9 --- /dev/null +++ b/utilities/vcppmake/osis2mod.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="osis2mod"
+ ProjectGUID="{3D885A23-DA8F-43C1-B241-7F44CA7AAF75}"
+ RootNamespace="osis2mod"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
+ >
+ <File
+ RelativePath="..\osis2mod.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/step2vpl.vcproj b/utilities/vcppmake/step2vpl.vcproj new file mode 100644 index 0000000..a0f08fd --- /dev/null +++ b/utilities/vcppmake/step2vpl.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="step2vpl"
+ ProjectGUID="{43B53430-3C91-4A11-8A1F-5873AEEE0926}"
+ RootNamespace="step2vpl"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{49125F1F-77E0-43A0-95E7-A2DBCCBB80B4}"
+ >
+ <File
+ RelativePath="..\step2vpl.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{AB8C32B3-369D-448D-98EF-D3677B569099}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{02D96DF0-116E-4796-BAFA-6576BCDD70DE}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/stepdump.vcproj b/utilities/vcppmake/stepdump.vcproj new file mode 100644 index 0000000..312e667 --- /dev/null +++ b/utilities/vcppmake/stepdump.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="stepdump"
+ ProjectGUID="{D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}"
+ RootNamespace="stepdump"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{AAC286F9-6845-49C4-B67C-FF0328CB6864}"
+ >
+ <File
+ RelativePath="..\stepdump.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{1AA5263B-9D6A-49E1-ACA5-FE8E4F77E84C}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{43212ACC-D0D0-4872-AAF9-2A72A5E98D83}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/tei2mod.vcproj b/utilities/vcppmake/tei2mod.vcproj new file mode 100644 index 0000000..a9271c6 --- /dev/null +++ b/utilities/vcppmake/tei2mod.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="tei2mod"
+ ProjectGUID="{86D28D9A-2D6A-49A3-A790-275C0CAE14C9}"
+ RootNamespace="tei2mod"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{D087C72F-EC9E-44E2-AFCD-653999552A0C}"
+ >
+ <File
+ RelativePath="..\tei2mod.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{1097CD3A-813F-4486-B07D-1A3AF10EA6DF}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{33554721-1A6C-4D8A-88B8-72E89D72A3C6}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/treeidxutil.vcproj b/utilities/vcppmake/treeidxutil.vcproj new file mode 100644 index 0000000..9a619de --- /dev/null +++ b/utilities/vcppmake/treeidxutil.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="treeidxutil"
+ ProjectGUID="{5638CD25-87F7-4A22-AF6D-EBECCD26B35B}"
+ RootNamespace="treeidxutil"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{8D333191-C9A5-44B0-B03C-1ED43BA11CFB}"
+ >
+ <File
+ RelativePath="..\treeidxutil.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{CC9CF264-BB60-40F1-9329-CC2DA896D442}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{8E4CC019-557A-4FD1-AAC8-6532D88ACC39}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/utilities.sln b/utilities/vcppmake/utilities.sln new file mode 100644 index 0000000..3875055 --- /dev/null +++ b/utilities/vcppmake/utilities.sln @@ -0,0 +1,246 @@ +
+Microsoft Visual Studio Solution File, Format Version 10.00
+# Visual Studio 2008
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libsword", "..\..\lib\vcppmake\vc8\libsword.vcproj", "{97449E5E-F880-4D22-933A-0D2FC32034D4}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "osis2mod", "osis2mod.vcproj", "{3D885A23-DA8F-43C1-B241-7F44CA7AAF75}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "addgb", "addgb.vcproj", "{76895767-61D0-41E6-B92D-FD541BB26D32}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "addld", "addld.vcproj", "{BBB6D2DE-D890-4758-85CF-8057B93CF6C2}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "addvs", "addvs.vcproj", "{CFF1021E-B878-481A-851B-2B226701D525}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cipherraw", "cipherraw.vcproj", "{7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "emptyvss", "emptyvss.vcproj", "{A55BEE98-25BB-463D-9016-14CA4567DFBF}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "imp2gbs", "imp2gbs.vcproj", "{2066EC0D-98CC-43E7-8405-5156AF111B38}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "imp2ld", "imp2ld.vcproj", "{BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "imp2vs", "imp2vs.vcproj", "{5637456D-5B83-4C12-A129-708FC8CF0B33}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "installmgr", "installmgr.vcproj", "{8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mkfastmod", "mkfastmod.vcproj", "{DB592F77-25DC-4005-BD49-6D0E50303844}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mod2imp", "mod2imp.vcproj", "{95B74350-2DAB-4CA9-BAFB-A5EB264765A1}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mod2osis", "mod2osis.vcproj", "{B5D19969-5285-4B0E-B798-496A0B8DCA61}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mod2vpl", "mod2vpl.vcproj", "{0C43604F-08D6-490C-BDFD-1B6CACB59740}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mod2zmod", "mod2zmod.vcproj", "{4E58EE7D-2B4B-42F0-8578-A23883CA6C31}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "step2vpl", "step2vpl.vcproj", "{43B53430-3C91-4A11-8A1F-5873AEEE0926}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "stepdump", "stepdump.vcproj", "{D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tei2mod", "tei2mod.vcproj", "{86D28D9A-2D6A-49A3-A790-275C0CAE14C9}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "treeidxutil", "treeidxutil.vcproj", "{5638CD25-87F7-4A22-AF6D-EBECCD26B35B}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vs2osisref", "vs2osisref.vcproj", "{DFDB8804-5D6C-448F-A935-DD85629E0554}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vs2osisreftxt", "vs2osisreftxt.vcproj", "{B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xml2gbs", "xml2gbs.vcproj", "{87116D0C-E498-4193-9F2D-301A8771B77D}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug with ICU|Win32 = Debug with ICU|Win32
+ Debug|Win32 = Debug|Win32
+ Release with ICU|Win32 = Release with ICU|Win32
+ Release|Win32 = Release|Win32
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Debug with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Debug with ICU|Win32.Build.0 = Release with ICU|Win32
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Debug|Win32.ActiveCfg = Debug|Win32
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Debug|Win32.Build.0 = Debug|Win32
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Release|Win32.ActiveCfg = Release|Win32
+ {97449E5E-F880-4D22-933A-0D2FC32034D4}.Release|Win32.Build.0 = Release|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {3D885A23-DA8F-43C1-B241-7F44CA7AAF75}.Release|Win32.Build.0 = Release with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {76895767-61D0-41E6-B92D-FD541BB26D32}.Release|Win32.Build.0 = Release with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {BBB6D2DE-D890-4758-85CF-8057B93CF6C2}.Release|Win32.Build.0 = Release with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {CFF1021E-B878-481A-851B-2B226701D525}.Release|Win32.Build.0 = Release with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {7A8F6247-7450-4BDF-A9FF-1BFA675EC83A}.Release|Win32.Build.0 = Release with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {A55BEE98-25BB-463D-9016-14CA4567DFBF}.Release|Win32.Build.0 = Release with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {2066EC0D-98CC-43E7-8405-5156AF111B38}.Release|Win32.Build.0 = Release with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {BD50701C-6BD3-4A02-9A2C-E9A3D5CC6A78}.Release|Win32.Build.0 = Release with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {5637456D-5B83-4C12-A129-708FC8CF0B33}.Release|Win32.Build.0 = Release with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {8EBC3D0A-F056-42BB-B18A-2FE18EAE5332}.Release|Win32.Build.0 = Release with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {DB592F77-25DC-4005-BD49-6D0E50303844}.Release|Win32.Build.0 = Release with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {95B74350-2DAB-4CA9-BAFB-A5EB264765A1}.Release|Win32.Build.0 = Release with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {B5D19969-5285-4B0E-B798-496A0B8DCA61}.Release|Win32.Build.0 = Release with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {0C43604F-08D6-490C-BDFD-1B6CACB59740}.Release|Win32.Build.0 = Release with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {4E58EE7D-2B4B-42F0-8578-A23883CA6C31}.Release|Win32.Build.0 = Release with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {43B53430-3C91-4A11-8A1F-5873AEEE0926}.Release|Win32.Build.0 = Release with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {D37BC2BB-E54F-4CA2-8CED-C8FCED4E57B9}.Release|Win32.Build.0 = Release with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {86D28D9A-2D6A-49A3-A790-275C0CAE14C9}.Release|Win32.Build.0 = Release with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {5638CD25-87F7-4A22-AF6D-EBECCD26B35B}.Release|Win32.Build.0 = Release with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {DFDB8804-5D6C-448F-A935-DD85629E0554}.Release|Win32.Build.0 = Release with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}.Release|Win32.Build.0 = Release with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Debug with ICU|Win32.ActiveCfg = Debug with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Debug with ICU|Win32.Build.0 = Debug with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Debug|Win32.ActiveCfg = Debug with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Debug|Win32.Build.0 = Debug with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Release with ICU|Win32.ActiveCfg = Release with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Release with ICU|Win32.Build.0 = Release with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Release|Win32.ActiveCfg = Release with ICU|Win32
+ {87116D0C-E498-4193-9F2D-301A8771B77D}.Release|Win32.Build.0 = Release with ICU|Win32
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
diff --git a/utilities/vcppmake/vs2osisref.vcproj b/utilities/vcppmake/vs2osisref.vcproj new file mode 100644 index 0000000..624c46a --- /dev/null +++ b/utilities/vcppmake/vs2osisref.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="vs2osisref"
+ ProjectGUID="{DFDB8804-5D6C-448F-A935-DD85629E0554}"
+ RootNamespace="vs2osisref"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{689570A4-F65B-4045-92FE-244E7FFB66FC}"
+ >
+ <File
+ RelativePath="..\vs2osisref.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{F87D280E-0702-487E-8C30-A9B489F902EE}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{84CCCA1B-E8E4-4501-994A-D16291BE3F37}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/vs2osisreftxt.vcproj b/utilities/vcppmake/vs2osisreftxt.vcproj new file mode 100644 index 0000000..9520b8f --- /dev/null +++ b/utilities/vcppmake/vs2osisreftxt.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="vs2osisreftxt"
+ ProjectGUID="{B3EB374E-A3C5-4C69-BAE5-B1030288E3B0}"
+ RootNamespace="vs2osisreftxt"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{6A6D7F3B-FCF6-48D2-B2AF-F575B083858A}"
+ >
+ <File
+ RelativePath="..\vs2osisreftxt.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{E1F38471-83DF-4E32-BB80-EC5FFD169E26}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{C7E0AF59-CB7E-4B40-80F6-97C1F66DC8BE}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vcppmake/xml2gbs.vcproj b/utilities/vcppmake/xml2gbs.vcproj new file mode 100644 index 0000000..c8ed4ed --- /dev/null +++ b/utilities/vcppmake/xml2gbs.vcproj @@ -0,0 +1,194 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9.00"
+ Name="xml2gbs"
+ ProjectGUID="{87116D0C-E498-4193-9F2D-301A8771B77D}"
+ RootNamespace="xml2gbs"
+ TargetFrameworkVersion="196613"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="_DEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ WarningLevel="3"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Debug\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICUDebug"
+ GenerateDebugInformation="true"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release with ICU|Win32"
+ OutputDirectory="$(SolutionDir)Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="1"
+ CharacterSet="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ EnableIntrinsicFunctions="true"
+ AdditionalIncludeDirectories="../../include,../../src/utilfuns/win32,../../../icu-sword/include"
+ PreprocessorDefinitions="NDEBUG;WIN32;_CONSOLE;_ICU_;_ICUSWORD_;SWUSINGDLL"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="true"
+ WarningLevel="3"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="libsword.lib icuuc.lib icuin.lib icudt.lib"
+ OutputFile="Release\$(ProjectName).exe"
+ AdditionalLibraryDirectories="../../../icu-sword/lib,../../lib/vcppmake/vc8/ICURelease"
+ GenerateDebugInformation="true"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{BFE8544C-CFE7-4E32-8912-D127AE76F7AC}"
+ >
+ <File
+ RelativePath="..\xml2gbs.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{106E5009-7DF8-4CAB-B807-73EBD81DF72E}"
+ >
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{DE1AAA6A-86D0-47F9-8C48-0AADB819D24B}"
+ >
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/utilities/vpl2mod.cpp b/utilities/vpl2mod.cpp index ee3831c..65cf718 100644 --- a/utilities/vpl2mod.cpp +++ b/utilities/vpl2mod.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <fcntl.h> @@ -143,6 +160,7 @@ int main(int argc, char **argv) { if (argc < 2) { // fprintf(stderr, "usage: %s <vpl_file> </path/to/mod> [0|1 - file includes prepended verse references]\n", argv[0]); fprintf(stderr, "usage: %s <source_vpl_file> </path/to/output/mod/> [0|1 - prepended verse refs] [0|1 - NT only]\n\n", argv[0]); + fprintf(stderr, "\tWARNING: THIS IS CURRENTLY A KJV-VERSIFICATION-ONLY UTILITY\n"); fprintf(stderr, "\tWith no verse refs, source file must contain exactly 31102 lines.\n"); fprintf(stderr, "\tThis is KJV verse count plus headings for MODULE,\n"); fprintf(stderr, "\tTESTAMENT, BOOK, CHAPTER. An example snippet follows:\n\n"); diff --git a/utilities/vpl2zmod2.cpp b/utilities/vpl2zmod2.cpp deleted file mode 100644 index 61e4f24..0000000 --- a/utilities/vpl2zmod2.cpp +++ /dev/null @@ -1,293 +0,0 @@ -#include <ctype.h> -#include <stdio.h> -#include <fcntl.h> -#include <errno.h> -#include <stdlib.h> -#include <sys/stat.h> - -#ifndef __GNUC__ -#include <io.h> -#else -#include <unistd.h> -#endif - -#include <swmgr.h> -#include <ztext2.h> -#include <iostream> -#include <swbuf.h> -#include <lzsscomprs.h> -#include <zipcomprs.h> -#include <versekey2.h> - -#ifndef NO_SWORD_NAMESPACE -using sword::SWMgr; -using sword::SWBuf; -using sword::zText2; -using sword::VerseKey2; -using sword::SW_POSITION; -using sword::SWCompress; -//using sword::CipherFilter; -using sword::zText2; -using sword::ZipCompress; -using sword::LZSSCompress; -#endif - -using std::string; - -char readline(int fd, char **buf) { - char ch; - if (*buf) - delete [] *buf; - *buf = 0; - int len; - - - long index = lseek(fd, 0, SEEK_CUR); - // clean up any preceding white space - while ((len = read(fd, &ch, 1)) == 1) { - if ((ch != 13) && (ch != ' ') && (ch != '\t')) - break; - else index++; - } - - - while (ch != 10) { - if ((len = read(fd, &ch, 1)) != 1) - break; - } - - int size = (lseek(fd, 0, SEEK_CUR) - index) - 1; - - *buf = new char [ size + 1 ]; - - if (size > 0) { - lseek(fd, index, SEEK_SET); - read(fd, *buf, size); - read(fd, &ch, 1); //pop terminating char - (*buf)[size] = 0; - - // clean up any trailing junk on buf - for (char *it = *buf+(strlen(*buf)-1); it > *buf; it--) { - if ((*it != 10) && (*it != 13) && (*it != ' ') && (*it != '\t')) - break; - else *it = 0; - } - } - else **buf = 0; - return !len; -} - - -char *parseVReg(char *buf) { - char stage = 0; - - while (*buf) { - switch (stage) { - case 0: - if (isalpha(*buf)) - stage++; - break; - case 1: - if (isdigit(*buf)) - stage++; - break; - case 2: - if (*buf == ':') - stage++; - break; - case 3: - if (isdigit(*buf)) - stage++; - break; - case 4: - if (*buf == ' ') { - *buf = 0; - return ++buf; - } - break; - } - buf++; - } - return (stage == 4) ? buf : 0; // if we got to stage 4 return after key buf, else return 0; -} - - -bool isKJVRef(const char *buf) { - VerseKey2 vk, test; - vk.AutoNormalize(0); - vk.Headings(1); // turn on mod/testmnt/book/chap headings - vk.Persist(1); - // lets do some tests on the verse -------------- - vk = buf; - test = buf; - - if (vk.Book() && vk.Chapter() && vk.Verse()) { // if we're not a heading - //std::cerr << (const char*)vk << " == " << (const char*)test << std::endl; - return (vk == test); - } - else return true; // no check if we're a heading... Probably bad. -} - - -void fixText(char *text) { - char *to = text; - while(*text) { - *to++ = *text++; - *to++ = *text++; - if (!*text) - break; - if (*text != ' ') - std::cerr << "problem\n"; - else text++; - } - *to = 0; -} - -int main(int argc, char **argv) { - int iType = 3; - int iPerBlock = 7; - int compType = 2; - SWBuf cipherKey = ""; - SWCompress *compressor = 0; - - // Let's test our command line arguments - if (argc < 2) { -// fprintf(stderr, "usage: %s <vpl_file> </path/to/mod> [0|1 - file includes prepended verse references]\n", argv[0]); - fprintf(stderr, "usage: %s <source_vpl_file> </path/to/output/mod/> [0|1 - prepended verse refs] [0|1 - NT only]\n\n", argv[0]); - fprintf(stderr, "\tWith no verse refs, source file must contain exactly 31102 lines.\n"); - fprintf(stderr, "\tThis is KJV verse count plus headings for MODULE,\n"); - fprintf(stderr, "\tTESTAMENT, BOOK, CHAPTER. An example snippet follows:\n\n"); - fprintf(stderr, "\t\tMODULE HEADER\n"); - fprintf(stderr, "\t\tOLD TESTAMENT HEADER\n"); - fprintf(stderr, "\t\tGENESIS HEADER\n"); - fprintf(stderr, "\t\tCHAPTER 1 HEADER\n"); - fprintf(stderr, "\t\tIn the beginning...\n\n"); - fprintf(stderr, "\t... implying there must also be a CHAPTER2 HEADER,\n"); - fprintf(stderr, "\tEXODUS HEADER, NEW TESTAMENT HEADER, etc. If there is no text for\n"); - fprintf(stderr, "\tthe header, a blank line must, at least, hold place.\n\n"); - fprintf(stderr, "\tWith verse refs, source file must simply contain any number of lines,\n"); - fprintf(stderr, "\tthat begin with the verse reference for which it is an entry. e.g.:\n\n"); - fprintf(stderr, "\t\tgen 1:0 CHAPTER 1 HEADER\n"); - fprintf(stderr, "\t\tgen 1:1 In the beginning...\n\n"); - exit(-1); - } - - // Let's see if we can open our input file - int fd = FileMgr::openFileReadOnly(argv[1]); - if (fd < 0) { - fprintf(stderr, "error: %s: couldn't open input file: %s \n", argv[0], argv[1]); - exit(-2); - } - - // not used yet, but for future support of a vpl file with each line - // prepended with verse reference, eg. "Gen 1:1 In the beginning..." - bool vref = false; - - // if 'nt' is the 4th arg, our vpl file only has the NT - bool ntonly = false; - - if (argc > 3) { - vref = (argv[3][0] == '0') ? false : true; - if (argc > 4) { - ntonly = (argv[4][0] == '0') ? false : true; - if (argc > 5) { - iType = atoi(argv[5]); - if (argc > 6) { - iPerBlock = atoi(argv[6]); - if (argc > 7) { - compType = atoi(argv[7]); - if (argc > 8) { - cipherKey = argv[8]; - } - } - } - } - } - } - - // Try to initialize a default set of datafiles and indicies at our - // datapath location passed to us from the user. - if (zText2::createModule(argv[2], iType)) { - fprintf(stderr, "error: %s: couldn't create module at path: %s \n", argv[0], argv[2]); - exit(-3); - } - switch (compType) { // these are deleted by zText - case 1: compressor = new LZSSCompress(); break; - case 2: compressor = new ZipCompress(); break; - } - - // Do some initialization stuff - char *buffer = 0; - zText2 mod(argv[2], 0, 0, iType, iPerBlock, compressor); // open our datapath with our zText2 driver. - VerseKey2 vk; - vk.AutoNormalize(0); - vk.Headings(1); // turn on mod/testmnt/book/chap headings - vk.Persist(1); - - mod.setKey(vk); - - // Loop through module from TOP to BOTTOM and set next line from - // input file as text for this entry in the module - mod = TOP; - if (ntonly) vk = "Matthew 1:1"; - - int successive = 0; //part of hack below - while ((!mod.Error()) && (!readline(fd, &buffer))) { - if (*buffer == '|') // comments, ignore line - continue; - if (vref) { - const char *verseText = parseVReg(buffer); - if (!verseText) { // if we didn't find a valid verse ref - std::cerr << "No valid verse ref found on line: " << buffer << "\n"; - exit(-4); - } - - vk = buffer; - if (vk.Error()) { - std::cerr << "Error parsing key: " << buffer << "\n"; - exit(-5); - } - string orig = mod.getRawEntry(); - - if (!isKJVRef(buffer)) { - VerseKey2 origVK = vk; - /* This block is functioning improperly -- problem with AutoNormalize??? - do { - vk--; - } - while (!vk.Error() && !isKJVRef(vk)); */ - //hack to replace above: - successive++; - vk -= successive; - orig = mod.getRawEntry(); - - std::cerr << "Not a valid KJV ref: " << origVK << "\n"; - std::cerr << "appending to ref: " << vk << "\n"; - orig += " [ ("; - orig += origVK; - orig += ") "; - orig += verseText; - orig += " ] "; - verseText = orig.c_str(); - } - else { - successive = 0; - } - - if (orig.length() > 1) - std::cerr << "Warning, overwriting verse: " << vk << std::endl; - - // ------------- End verse tests ----------------- - mod << verseText; // save text to module at current position - } - else { - fixText(buffer); - mod << buffer; // save text to module at current position - mod++; // increment module position - } - } - - // clear up our buffer that readline might have allocated - if (buffer) - delete [] buffer; -} diff --git a/utilities/vs2osisref.cpp b/utilities/vs2osisref.cpp index 220e743..bdff592 100644 --- a/utilities/vs2osisref.cpp +++ b/utilities/vs2osisref.cpp @@ -1,25 +1,23 @@ -// Compression on variable granularity -#include <fcntl.h> -#include <iostream> -#include <fstream> - -#ifndef __GNUC__ -#include <io.h> -#else -#include <unistd.h> -#endif +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ -#include <ztext.h> -#include <zld.h> -#include <zcom.h> -#include <swmgr.h> -#include <lzsscomprs.h> -#include <zipcomprs.h> +#include <iostream> #include <versekey.h> -#include <thmlosis.h> -#include <stdio.h> -#include <markupfiltmgr.h> -#include <algorithm> +#include <localemgr.h> #ifndef NO_SWORD_NAMESPACE using namespace sword; @@ -32,25 +30,20 @@ using std::cout; int main(int argc, char **argv) { if (argc < 2) { - cerr << argv[0] << " - a tool to convert verse references from English to OSIS\n"; - cerr << "usage: "<< argv[0] << " <verse ref> [verse context]\n"; + cerr << argv[0] << " - parse verse reference to OSISRef markup\n"; + cerr << "usage: "<< argv[0] << " <verse ref> [verse context] [locale]\n"; cerr << "\n\n"; exit(-1); } - VerseKey verseKey; - int i = strlen(argv[1]) + 1; - char * verseString = new char[i]; - strcpy (verseString, argv[1]); - verseString[i - 1] = 0; - - if (argc > 2) { - verseKey = argv[2]; - } - else { - verseKey = "Gen 1:1"; - } - std::cout << VerseKey::convertToOSIS(verseString, &verseKey) << "\n"; + + if (argc > 3) { + LocaleMgr::getSystemLocaleMgr()->setDefaultLocaleName(argv[3]); + } + + VerseKey verseKey = (argc > 2) ? argv[2] : "Gen 1:1"; + + std::cout << VerseKey::convertToOSIS(argv[1], &verseKey) << "\n"; return 0; } diff --git a/utilities/vs2osisreftxt.cpp b/utilities/vs2osisreftxt.cpp new file mode 100644 index 0000000..a62daa0 --- /dev/null +++ b/utilities/vs2osisreftxt.cpp @@ -0,0 +1,50 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + +#include <iostream> +#include <stdio.h> + +#include <versekey.h> +#include <localemgr.h> +#ifndef NO_SWORD_NAMESPACE +using namespace sword; +#endif + +int main(int argc, char **argv) { + if ((argc < 2) || (argc > 4)) { + fprintf(stderr, "usage: %s <\"string to parse\"> [locale_name] [test-in-set-verse]\n", *argv); + exit(-1); + } + + if (argc > 2) + LocaleMgr::getSystemLocaleMgr()->setDefaultLocaleName(argv[2]); + + VerseKey DefaultVSKey; + + DefaultVSKey = "jas3:1"; + + ListKey verses = DefaultVSKey.ParseVerseList(argv[1], DefaultVSKey, true); + + std::cout << verses.getOSISRefRangeText() << "\n"; + + if (argc > 3) { + verses.setText(argv[3]); + std::cout << "Verse is" << ((verses.Error()) ? " NOT" : "") << " in set.\n\n"; + } + + return 0; +} diff --git a/utilities/xml2gbs.cpp b/utilities/xml2gbs.cpp index 45ec256..62a22ab 100644 --- a/utilities/xml2gbs.cpp +++ b/utilities/xml2gbs.cpp @@ -1,3 +1,20 @@ +/* + * Copyright 2009 CrossWire Bible Society (http://www.crosswire.org) + * CrossWire Bible Society + * P. O. Box 2528 + * Tempe, AZ 85280-2528 + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation version 2. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + */ + #include <ctype.h> #include <stdio.h> #include <fcntl.h> |