diff --git a/src/irc/appveyor.cpp b/src/ircc/appveyor.cpp similarity index 100% rename from src/irc/appveyor.cpp rename to src/ircc/appveyor.cpp diff --git a/src/smpackage/ZipArchive/Linux/Makefile b/src/smpackage/ZipArchive/Linux/Makefile deleted file mode 100644 index 3afd97a2cc..0000000000 --- a/src/smpackage/ZipArchive/Linux/Makefile +++ /dev/null @@ -1,86 +0,0 @@ -# Makefile for ZipArchive library -# Copyright (C) 2000-2003 Tadeusz Dracz -# For conditions of distribution and use, see copyright notice in License.txt -# To install to /usr/lib and /usr/include, type: -# make install -# to install to a different directory change prefix - - - -CC=g++ -CCC=cc - -#FLAGSD = -g -FLAGSD = - -ZIPARCHLIB = libziparch.a - -ZIPPIELOCATION = stl/zippie/ - -prefix = /usr -libdir = ${prefix}/lib -includedir = ${prefix}/include -zipardir = $(includedir)/ziparchive - -AR=ar rc -RANLIB=ranlib - -.SUFFIXES: .c .cpp -.c.o: - $(CCC) -c -I. -o $*.o $< -.cpp.o: - $(CC) $(FLAGSD) -c -I. $< - -OBJS = ZipArchive.o ZipAutoBuffer.o ZipCentralDir.o \ -ZipCompatibility.o ZipException.o ZipFile.o ZipFileHeader.o \ -ZipMemFile.o ZipPathComponent.o ZipPlatform.o ZipPlatformComm.o \ -ZipStorage.o ZipString.o - -#OBJSZLIB = zlib/adler32.o zlib/compress.o zlib/crc32.o zlib/uncompr.o zlib/deflate.o zlib/trees.o \ -zlib/zutil.o zlib/inflate.o zlib/infblock.o zlib/inftrees.o zlib/infcodes.o zlib/infutil.o zlib/inffast.o - -OBJSZLIB = - -$(ZIPARCHLIB): $(OBJS) $(OBJSZLIB) - $(AR) $@ $(OBJS) $(OBJSZLIB) - -@ ($(RANLIB) $@ || true) >/dev/null 2>&1 - -ZipArchive.o: ZipArchive.h -ZipAutoBuffer.o: ZipAutoBuffer.h -ZipCentralDir.o: ZipCentralDir.h -ZipCompatibility.o: ZipCompatibility.h -ZipException.o: ZipException.h -ZipFile.o: ZipFile.h -ZipFileHeader.o: ZipFileHeader.h -ZipMemFile.o: ZipMemFile.h -ZipPathComponent.o: ZipPathComponent.h -ZipPlatform.o: ZipPlatform.h -ZipStorage.o: ZipStorage.h -ZipString.o: ZipString.h - -clean: - -rm -f *.o *~ $(ZIPARCHLIB) - -zippie: - - $(CC) -I$(zipardir) $(FLAGSD) -o zippie $(ZIPPIELOCATION)zippie.cpp $(ZIPPIELOCATION)CmdLine.cpp -lz -lstdc++ -lziparch -# $(CC) -I$(zipardir) $(FLAGSD) -o zippie ZIPPIELOCATION)zippie.cpp $(ZIPPIELOCATION)CmdLine.cpp -lstdc++ -lziparch -cleanzippie: - -rm -f zippie - -install: - -@if [ ! -d $(includedir) ]; then mkdir $(includedir); fi - -@if [ ! -d $(libdir) ]; then mkdir $(libdir); fi - -@if [ ! -d $(zipardir) ]; then mkdir $(zipardir); fi - cp libziparch.a $(libdir) - chmod 755 $(libdir)/$(ZIPARCHLIB) - cp *.h $(zipardir) - chmod 644 $(zipardir)/*h - -uninstall: - rm -f $(zipardir)/*h - rm -f $(libdir)/$(ZIPARCHLIB) - rmdir $(zipardir) - - - diff --git a/src/smpackage/ChangeGameSettings.cpp b/src/smpackagee/ChangeGameSettings.cpp similarity index 100% rename from src/smpackage/ChangeGameSettings.cpp rename to src/smpackagee/ChangeGameSettings.cpp diff --git a/src/smpackage/ChangeGameSettings.h b/src/smpackagee/ChangeGameSettings.h similarity index 100% rename from src/smpackage/ChangeGameSettings.h rename to src/smpackagee/ChangeGameSettings.h diff --git a/src/smpackage/CreateLanguageDlg.cpp b/src/smpackagee/CreateLanguageDlg.cpp similarity index 100% rename from src/smpackage/CreateLanguageDlg.cpp rename to src/smpackagee/CreateLanguageDlg.cpp diff --git a/src/smpackage/CreateLanguageDlg.h b/src/smpackagee/CreateLanguageDlg.h similarity index 100% rename from src/smpackage/CreateLanguageDlg.h rename to src/smpackagee/CreateLanguageDlg.h diff --git a/src/smpackage/EditInsallations.cpp b/src/smpackagee/EditInsallations.cpp similarity index 100% rename from src/smpackage/EditInsallations.cpp rename to src/smpackagee/EditInsallations.cpp diff --git a/src/smpackage/EditInsallations.h b/src/smpackagee/EditInsallations.h similarity index 100% rename from src/smpackage/EditInsallations.h rename to src/smpackagee/EditInsallations.h diff --git a/src/smpackage/EnterComment.cpp b/src/smpackagee/EnterComment.cpp similarity index 100% rename from src/smpackage/EnterComment.cpp rename to src/smpackagee/EnterComment.cpp diff --git a/src/smpackage/EnterComment.h b/src/smpackagee/EnterComment.h similarity index 100% rename from src/smpackage/EnterComment.h rename to src/smpackagee/EnterComment.h diff --git a/src/smpackage/EnterName.cpp b/src/smpackagee/EnterName.cpp similarity index 100% rename from src/smpackage/EnterName.cpp rename to src/smpackagee/EnterName.cpp diff --git a/src/smpackage/EnterName.h b/src/smpackagee/EnterName.h similarity index 100% rename from src/smpackage/EnterName.h rename to src/smpackagee/EnterName.h diff --git a/src/smpackage/LanguagesDlg.cpp b/src/smpackagee/LanguagesDlg.cpp similarity index 100% rename from src/smpackage/LanguagesDlg.cpp rename to src/smpackagee/LanguagesDlg.cpp diff --git a/src/smpackage/LanguagesDlg.h b/src/smpackagee/LanguagesDlg.h similarity index 100% rename from src/smpackage/LanguagesDlg.h rename to src/smpackagee/LanguagesDlg.h diff --git a/src/smpackage/MainMenuDlg.cpp b/src/smpackagee/MainMenuDlg.cpp similarity index 100% rename from src/smpackage/MainMenuDlg.cpp rename to src/smpackagee/MainMenuDlg.cpp diff --git a/src/smpackage/MainMenuDlg.h b/src/smpackagee/MainMenuDlg.h similarity index 100% rename from src/smpackage/MainMenuDlg.h rename to src/smpackagee/MainMenuDlg.h diff --git a/src/smpackage/SMPackageInstallDlg.cpp b/src/smpackagee/SMPackageInstallDlg.cpp similarity index 100% rename from src/smpackage/SMPackageInstallDlg.cpp rename to src/smpackagee/SMPackageInstallDlg.cpp diff --git a/src/smpackage/SMPackageInstallDlg.h b/src/smpackagee/SMPackageInstallDlg.h similarity index 100% rename from src/smpackage/SMPackageInstallDlg.h rename to src/smpackagee/SMPackageInstallDlg.h diff --git a/src/smpackage/SMPackageUtil.cpp b/src/smpackagee/SMPackageUtil.cpp similarity index 100% rename from src/smpackage/SMPackageUtil.cpp rename to src/smpackagee/SMPackageUtil.cpp diff --git a/src/smpackage/ShowComment.cpp b/src/smpackagee/ShowComment.cpp similarity index 100% rename from src/smpackage/ShowComment.cpp rename to src/smpackagee/ShowComment.cpp diff --git a/src/smpackage/ShowComment.h b/src/smpackagee/ShowComment.h similarity index 100% rename from src/smpackage/ShowComment.h rename to src/smpackagee/ShowComment.h diff --git a/src/smpackage/SmpackageExportDlg.cpp b/src/smpackagee/SmpackageExportDlg.cpp similarity index 100% rename from src/smpackage/SmpackageExportDlg.cpp rename to src/smpackagee/SmpackageExportDlg.cpp diff --git a/src/smpackage/SmpackageExportDlg.h b/src/smpackagee/SmpackageExportDlg.h similarity index 100% rename from src/smpackage/SmpackageExportDlg.h rename to src/smpackagee/SmpackageExportDlg.h diff --git a/src/smpackage/StdAfx.cpp b/src/smpackagee/StdAfx.cpp similarity index 100% rename from src/smpackage/StdAfx.cpp rename to src/smpackagee/StdAfx.cpp diff --git a/src/smpackage/StdAfx.h b/src/smpackagee/StdAfx.h similarity index 100% rename from src/smpackage/StdAfx.h rename to src/smpackagee/StdAfx.h diff --git a/src/smpackage/TreeCtrlEx.cpp b/src/smpackagee/TreeCtrlEx.cpp similarity index 100% rename from src/smpackage/TreeCtrlEx.cpp rename to src/smpackagee/TreeCtrlEx.cpp diff --git a/src/smpackage/TreeCtrlEx.h b/src/smpackagee/TreeCtrlEx.h similarity index 100% rename from src/smpackage/TreeCtrlEx.h rename to src/smpackagee/TreeCtrlEx.h diff --git a/src/smpackage/UninstallOld.cpp b/src/smpackagee/UninstallOld.cpp similarity index 100% rename from src/smpackage/UninstallOld.cpp rename to src/smpackagee/UninstallOld.cpp diff --git a/src/smpackage/UninstallOld.h b/src/smpackagee/UninstallOld.h similarity index 100% rename from src/smpackage/UninstallOld.h rename to src/smpackagee/UninstallOld.h diff --git a/src/smpackage/ZipArchive/Appnote.txt b/src/smpackagee/ZipArchive/Appnote.txt similarity index 100% rename from src/smpackage/ZipArchive/Appnote.txt rename to src/smpackagee/ZipArchive/Appnote.txt diff --git a/src/smpackage/ZipArchive/ChangeLog.txt b/src/smpackagee/ZipArchive/ChangeLog.txt similarity index 100% rename from src/smpackage/ZipArchive/ChangeLog.txt rename to src/smpackagee/ZipArchive/ChangeLog.txt diff --git a/src/smpackage/ZipArchive/License.txt b/src/smpackagee/ZipArchive/License.txt similarity index 100% rename from src/smpackage/ZipArchive/License.txt rename to src/smpackagee/ZipArchive/License.txt diff --git a/src/smpackage/ZipArchive/Linux/ZipFileMapping.h b/src/smpackagee/ZipArchive/Linux/ZipFileMapping.h similarity index 100% rename from src/smpackage/ZipArchive/Linux/ZipFileMapping.h rename to src/smpackagee/ZipArchive/Linux/ZipFileMapping.h diff --git a/src/smpackage/ZipArchive/Linux/ZipPathComponent.cpp b/src/smpackagee/ZipArchive/Linux/ZipPathComponent.cpp similarity index 100% rename from src/smpackage/ZipArchive/Linux/ZipPathComponent.cpp rename to src/smpackagee/ZipArchive/Linux/ZipPathComponent.cpp diff --git a/src/smpackage/ZipArchive/Linux/ZipPlatform.cpp b/src/smpackagee/ZipArchive/Linux/ZipPlatform.cpp similarity index 100% rename from src/smpackage/ZipArchive/Linux/ZipPlatform.cpp rename to src/smpackagee/ZipArchive/Linux/ZipPlatform.cpp diff --git a/src/smpackage/ZipArchive/Readme.txt b/src/smpackagee/ZipArchive/Readme.txt similarity index 100% rename from src/smpackage/ZipArchive/Readme.txt rename to src/smpackagee/ZipArchive/Readme.txt diff --git a/src/smpackage/ZipArchive/StdAfx.cpp b/src/smpackagee/ZipArchive/StdAfx.cpp similarity index 100% rename from src/smpackage/ZipArchive/StdAfx.cpp rename to src/smpackagee/ZipArchive/StdAfx.cpp diff --git a/src/smpackage/ZipArchive/StdAfx.h b/src/smpackagee/ZipArchive/StdAfx.h similarity index 100% rename from src/smpackage/ZipArchive/StdAfx.h rename to src/smpackagee/ZipArchive/StdAfx.h diff --git a/src/smpackage/ZipArchive/Windows/ZipFileMapping.h b/src/smpackagee/ZipArchive/Windows/ZipFileMapping.h similarity index 100% rename from src/smpackage/ZipArchive/Windows/ZipFileMapping.h rename to src/smpackagee/ZipArchive/Windows/ZipFileMapping.h diff --git a/src/smpackage/ZipArchive/Windows/ZipPathComponent.cpp b/src/smpackagee/ZipArchive/Windows/ZipPathComponent.cpp similarity index 100% rename from src/smpackage/ZipArchive/Windows/ZipPathComponent.cpp rename to src/smpackagee/ZipArchive/Windows/ZipPathComponent.cpp diff --git a/src/smpackage/ZipArchive/Windows/ZipPlatform.cpp b/src/smpackagee/ZipArchive/Windows/ZipPlatform.cpp similarity index 100% rename from src/smpackage/ZipArchive/Windows/ZipPlatform.cpp rename to src/smpackagee/ZipArchive/Windows/ZipPlatform.cpp diff --git a/src/smpackage/ZipArchive/ZipAbstractFile.h b/src/smpackagee/ZipArchive/ZipAbstractFile.h similarity index 100% rename from src/smpackage/ZipArchive/ZipAbstractFile.h rename to src/smpackagee/ZipArchive/ZipAbstractFile.h diff --git a/src/smpackage/ZipArchive/ZipArchive-net2003.vcproj b/src/smpackagee/ZipArchive/ZipArchive-net2003.vcproj similarity index 96% rename from src/smpackage/ZipArchive/ZipArchive-net2003.vcproj rename to src/smpackagee/ZipArchive/ZipArchive-net2003.vcproj index 0770070d68..174388a48a 100644 --- a/src/smpackage/ZipArchive/ZipArchive-net2003.vcproj +++ b/src/smpackagee/ZipArchive/ZipArchive-net2003.vcproj @@ -1,1285 +1,1285 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/smpackage/ZipArchive/ZipArchive-net2008.vcproj b/src/smpackagee/ZipArchive/ZipArchive-net2008.vcproj similarity index 96% rename from src/smpackage/ZipArchive/ZipArchive-net2008.vcproj rename to src/smpackagee/ZipArchive/ZipArchive-net2008.vcproj index dc15524a56..1874a384db 100644 --- a/src/smpackage/ZipArchive/ZipArchive-net2008.vcproj +++ b/src/smpackagee/ZipArchive/ZipArchive-net2008.vcproj @@ -1,1686 +1,1686 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/smpackage/ZipArchive/ZipArchive.cpp b/src/smpackagee/ZipArchive/ZipArchive.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipArchive.cpp rename to src/smpackagee/ZipArchive/ZipArchive.cpp diff --git a/src/smpackage/ZipArchive/ZipArchive.dox b/src/smpackagee/ZipArchive/ZipArchive.dox similarity index 97% rename from src/smpackage/ZipArchive/ZipArchive.dox rename to src/smpackagee/ZipArchive/ZipArchive.dox index 4fe506a5e8..394c02ddcb 100644 --- a/src/smpackage/ZipArchive/ZipArchive.dox +++ b/src/smpackagee/ZipArchive/ZipArchive.dox @@ -1,221 +1,221 @@ -# Doxyfile 1.3.2 - -#--------------------------------------------------------------------------- -# General configuration options -#--------------------------------------------------------------------------- -PROJECT_NAME = ZipArchive -PROJECT_NUMBER = -OUTPUT_DIRECTORY = .\Doc -OUTPUT_LANGUAGE = English -USE_WINDOWS_ENCODING = YES -EXTRACT_ALL = NO -EXTRACT_PRIVATE = NO -EXTRACT_STATIC = NO -EXTRACT_LOCAL_CLASSES = YES -HIDE_UNDOC_MEMBERS = NO -HIDE_UNDOC_CLASSES = NO -HIDE_FRIEND_COMPOUNDS = NO -HIDE_IN_BODY_DOCS = NO -BRIEF_MEMBER_DESC = YES -REPEAT_BRIEF = YES -ALWAYS_DETAILED_SEC = NO -INLINE_INHERITED_MEMB = NO -FULL_PATH_NAMES = NO -STRIP_FROM_PATH = $(PWD)/ -INTERNAL_DOCS = NO -CASE_SENSE_NAMES = YES -SHORT_NAMES = NO -HIDE_SCOPE_NAMES = NO -SHOW_INCLUDE_FILES = YES -JAVADOC_AUTOBRIEF = YES -MULTILINE_CPP_IS_BRIEF = NO -DETAILS_AT_TOP = NO -INHERIT_DOCS = YES -INLINE_INFO = YES -SORT_MEMBER_DOCS = YES -DISTRIBUTE_GROUP_DOC = NO -TAB_SIZE = 1 -GENERATE_TODOLIST = YES -GENERATE_TESTLIST = YES -GENERATE_BUGLIST = YES -GENERATE_DEPRECATEDLIST= YES -ALIASES = -ENABLED_SECTIONS = YES -MAX_INITIALIZER_LINES = 30 -OPTIMIZE_OUTPUT_FOR_C = NO -OPTIMIZE_OUTPUT_JAVA = NO -SHOW_USED_FILES = YES -#--------------------------------------------------------------------------- -# configuration options related to warning and progress messages -#--------------------------------------------------------------------------- -QUIET = NO -WARNINGS = YES -WARN_IF_UNDOCUMENTED = NO -WARN_IF_DOC_ERROR = YES -WARN_FORMAT = "$file:$line: $text" -WARN_LOGFILE = -#--------------------------------------------------------------------------- -# configuration options related to the input files -#--------------------------------------------------------------------------- -INPUT = .\ZipArchive.h \ - .\ZipAutoBuffer.h \ - .\ZipCentralDir.h \ - .\ZipCompatibility.h \ - .\ZipException.h \ - .\ZipFileHeader.h \ - .\ZipPlatform.h \ - .\ZipMemFile.h \ - .\ZipPathComponent.h \ - .\ZipStorage.h \ - .\changelog.txt \ - .\faq.txt \ - .\License.txt \ - .\gpl.txt \ - .\Readme.txt -FILE_PATTERNS = -RECURSIVE = NO -EXCLUDE = -EXCLUDE_SYMLINKS = NO -EXCLUDE_PATTERNS = -EXAMPLE_PATH = -EXAMPLE_PATTERNS = -EXAMPLE_RECURSIVE = NO -IMAGE_PATH = -INPUT_FILTER = -FILTER_SOURCE_FILES = NO -#--------------------------------------------------------------------------- -# configuration options related to source browsing -#--------------------------------------------------------------------------- -SOURCE_BROWSER = YES -INLINE_SOURCES = NO -STRIP_CODE_COMMENTS = YES -REFERENCED_BY_RELATION = YES -REFERENCES_RELATION = YES -VERBATIM_HEADERS = YES -#--------------------------------------------------------------------------- -# configuration options related to the alphabetical class index -#--------------------------------------------------------------------------- -ALPHABETICAL_INDEX = YES -COLS_IN_ALPHA_INDEX = 5 -IGNORE_PREFIX = CZip -#--------------------------------------------------------------------------- -# configuration options related to the HTML output -#--------------------------------------------------------------------------- -GENERATE_HTML = YES -HTML_OUTPUT = . -HTML_FILE_EXTENSION = .html -HTML_HEADER = "c:\Program Files\Doxygen\header.html" -HTML_FOOTER = "c:\Program Files\Doxygen\footer.html" -HTML_STYLESHEET = -HTML_ALIGN_MEMBERS = YES -GENERATE_HTMLHELP = YES -CHM_FILE = -HHC_LOCATION = -GENERATE_CHI = YES -BINARY_TOC = YES -TOC_EXPAND = YES -DISABLE_INDEX = NO -ENUM_VALUES_PER_LINE = 4 -GENERATE_TREEVIEW = NO -TREEVIEW_WIDTH = 250 -#--------------------------------------------------------------------------- -# configuration options related to the LaTeX output -#--------------------------------------------------------------------------- -GENERATE_LATEX = NO -LATEX_OUTPUT = -LATEX_CMD_NAME = latex -MAKEINDEX_CMD_NAME = makeindex -COMPACT_LATEX = NO -PAPER_TYPE = a4wide -EXTRA_PACKAGES = -LATEX_HEADER = -PDF_HYPERLINKS = NO -USE_PDFLATEX = NO -LATEX_BATCHMODE = NO -LATEX_HIDE_INDICES = NO -#--------------------------------------------------------------------------- -# configuration options related to the RTF output -#--------------------------------------------------------------------------- -GENERATE_RTF = NO -RTF_OUTPUT = -COMPACT_RTF = NO -RTF_HYPERLINKS = NO -RTF_STYLESHEET_FILE = -RTF_EXTENSIONS_FILE = -#--------------------------------------------------------------------------- -# configuration options related to the man page output -#--------------------------------------------------------------------------- -GENERATE_MAN = NO -MAN_OUTPUT = -MAN_EXTENSION = .3 -MAN_LINKS = NO -#--------------------------------------------------------------------------- -# configuration options related to the XML output -#--------------------------------------------------------------------------- -GENERATE_XML = NO -XML_OUTPUT = xml -XML_SCHEMA = -XML_DTD = -#--------------------------------------------------------------------------- -# configuration options for the AutoGen Definitions output -#--------------------------------------------------------------------------- -GENERATE_AUTOGEN_DEF = NO -#--------------------------------------------------------------------------- -# configuration options related to the Perl module output -#--------------------------------------------------------------------------- -GENERATE_PERLMOD = NO -PERLMOD_LATEX = NO -PERLMOD_PRETTY = YES -PERLMOD_MAKEVAR_PREFIX = -#--------------------------------------------------------------------------- -# Configuration options related to the preprocessor -#--------------------------------------------------------------------------- -ENABLE_PREPROCESSING = NO -MACRO_EXPANSION = NO -EXPAND_ONLY_PREDEF = YES -SEARCH_INCLUDES = YES -INCLUDE_PATH = -INCLUDE_FILE_PATTERNS = -PREDEFINED = -EXPAND_AS_DEFINED = -SKIP_FUNCTION_MACROS = YES -#--------------------------------------------------------------------------- -# Configuration::addtions related to external references -#--------------------------------------------------------------------------- -TAGFILES = -GENERATE_TAGFILE = NO -ALLEXTERNALS = YES -EXTERNAL_GROUPS = YES -PERL_PATH = /usr/bin/perl -#--------------------------------------------------------------------------- -# Configuration options related to the dot tool -#--------------------------------------------------------------------------- -CLASS_DIAGRAMS = YES -HIDE_UNDOC_RELATIONS = YES -HAVE_DOT = YES -CLASS_GRAPH = YES -COLLABORATION_GRAPH = NO -UML_LOOK = YES -TEMPLATE_RELATIONS = YES -INCLUDE_GRAPH = NO -INCLUDED_BY_GRAPH = NO -CALL_GRAPH = NO -GRAPHICAL_HIERARCHY = YES -DOT_IMAGE_FORMAT = gif -DOT_PATH = "c:/Program Files/ATT/Graphviz/bin/" -DOTFILE_DIRS = -MAX_DOT_GRAPH_WIDTH = 1024 -MAX_DOT_GRAPH_HEIGHT = 1024 -MAX_DOT_GRAPH_DEPTH = 0 -GENERATE_LEGEND = YES -DOT_CLEANUP = YES -#--------------------------------------------------------------------------- -# Configuration::addtions related to the search engine -#--------------------------------------------------------------------------- -SEARCHENGINE = NO -CGI_NAME = search.cgi -CGI_URL = -DOC_URL = -DOC_ABSPATH = -BIN_ABSPATH = /usr/local/bin/ -EXT_DOC_PATHS = +# Doxyfile 1.3.2 + +#--------------------------------------------------------------------------- +# General configuration options +#--------------------------------------------------------------------------- +PROJECT_NAME = ZipArchive +PROJECT_NUMBER = +OUTPUT_DIRECTORY = .\Doc +OUTPUT_LANGUAGE = English +USE_WINDOWS_ENCODING = YES +EXTRACT_ALL = NO +EXTRACT_PRIVATE = NO +EXTRACT_STATIC = NO +EXTRACT_LOCAL_CLASSES = YES +HIDE_UNDOC_MEMBERS = NO +HIDE_UNDOC_CLASSES = NO +HIDE_FRIEND_COMPOUNDS = NO +HIDE_IN_BODY_DOCS = NO +BRIEF_MEMBER_DESC = YES +REPEAT_BRIEF = YES +ALWAYS_DETAILED_SEC = NO +INLINE_INHERITED_MEMB = NO +FULL_PATH_NAMES = NO +STRIP_FROM_PATH = $(PWD)/ +INTERNAL_DOCS = NO +CASE_SENSE_NAMES = YES +SHORT_NAMES = NO +HIDE_SCOPE_NAMES = NO +SHOW_INCLUDE_FILES = YES +JAVADOC_AUTOBRIEF = YES +MULTILINE_CPP_IS_BRIEF = NO +DETAILS_AT_TOP = NO +INHERIT_DOCS = YES +INLINE_INFO = YES +SORT_MEMBER_DOCS = YES +DISTRIBUTE_GROUP_DOC = NO +TAB_SIZE = 1 +GENERATE_TODOLIST = YES +GENERATE_TESTLIST = YES +GENERATE_BUGLIST = YES +GENERATE_DEPRECATEDLIST= YES +ALIASES = +ENABLED_SECTIONS = YES +MAX_INITIALIZER_LINES = 30 +OPTIMIZE_OUTPUT_FOR_C = NO +OPTIMIZE_OUTPUT_JAVA = NO +SHOW_USED_FILES = YES +#--------------------------------------------------------------------------- +# configuration options related to warning and progress messages +#--------------------------------------------------------------------------- +QUIET = NO +WARNINGS = YES +WARN_IF_UNDOCUMENTED = NO +WARN_IF_DOC_ERROR = YES +WARN_FORMAT = "$file:$line: $text" +WARN_LOGFILE = +#--------------------------------------------------------------------------- +# configuration options related to the input files +#--------------------------------------------------------------------------- +INPUT = .\ZipArchive.h \ + .\ZipAutoBuffer.h \ + .\ZipCentralDir.h \ + .\ZipCompatibility.h \ + .\ZipException.h \ + .\ZipFileHeader.h \ + .\ZipPlatform.h \ + .\ZipMemFile.h \ + .\ZipPathComponent.h \ + .\ZipStorage.h \ + .\changelog.txt \ + .\faq.txt \ + .\License.txt \ + .\gpl.txt \ + .\Readme.txt +FILE_PATTERNS = +RECURSIVE = NO +EXCLUDE = +EXCLUDE_SYMLINKS = NO +EXCLUDE_PATTERNS = +EXAMPLE_PATH = +EXAMPLE_PATTERNS = +EXAMPLE_RECURSIVE = NO +IMAGE_PATH = +INPUT_FILTER = +FILTER_SOURCE_FILES = NO +#--------------------------------------------------------------------------- +# configuration options related to source browsing +#--------------------------------------------------------------------------- +SOURCE_BROWSER = YES +INLINE_SOURCES = NO +STRIP_CODE_COMMENTS = YES +REFERENCED_BY_RELATION = YES +REFERENCES_RELATION = YES +VERBATIM_HEADERS = YES +#--------------------------------------------------------------------------- +# configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- +ALPHABETICAL_INDEX = YES +COLS_IN_ALPHA_INDEX = 5 +IGNORE_PREFIX = CZip +#--------------------------------------------------------------------------- +# configuration options related to the HTML output +#--------------------------------------------------------------------------- +GENERATE_HTML = YES +HTML_OUTPUT = . +HTML_FILE_EXTENSION = .html +HTML_HEADER = "c:\Program Files\Doxygen\header.html" +HTML_FOOTER = "c:\Program Files\Doxygen\footer.html" +HTML_STYLESHEET = +HTML_ALIGN_MEMBERS = YES +GENERATE_HTMLHELP = YES +CHM_FILE = +HHC_LOCATION = +GENERATE_CHI = YES +BINARY_TOC = YES +TOC_EXPAND = YES +DISABLE_INDEX = NO +ENUM_VALUES_PER_LINE = 4 +GENERATE_TREEVIEW = NO +TREEVIEW_WIDTH = 250 +#--------------------------------------------------------------------------- +# configuration options related to the LaTeX output +#--------------------------------------------------------------------------- +GENERATE_LATEX = NO +LATEX_OUTPUT = +LATEX_CMD_NAME = latex +MAKEINDEX_CMD_NAME = makeindex +COMPACT_LATEX = NO +PAPER_TYPE = a4wide +EXTRA_PACKAGES = +LATEX_HEADER = +PDF_HYPERLINKS = NO +USE_PDFLATEX = NO +LATEX_BATCHMODE = NO +LATEX_HIDE_INDICES = NO +#--------------------------------------------------------------------------- +# configuration options related to the RTF output +#--------------------------------------------------------------------------- +GENERATE_RTF = NO +RTF_OUTPUT = +COMPACT_RTF = NO +RTF_HYPERLINKS = NO +RTF_STYLESHEET_FILE = +RTF_EXTENSIONS_FILE = +#--------------------------------------------------------------------------- +# configuration options related to the man page output +#--------------------------------------------------------------------------- +GENERATE_MAN = NO +MAN_OUTPUT = +MAN_EXTENSION = .3 +MAN_LINKS = NO +#--------------------------------------------------------------------------- +# configuration options related to the XML output +#--------------------------------------------------------------------------- +GENERATE_XML = NO +XML_OUTPUT = xml +XML_SCHEMA = +XML_DTD = +#--------------------------------------------------------------------------- +# configuration options for the AutoGen Definitions output +#--------------------------------------------------------------------------- +GENERATE_AUTOGEN_DEF = NO +#--------------------------------------------------------------------------- +# configuration options related to the Perl module output +#--------------------------------------------------------------------------- +GENERATE_PERLMOD = NO +PERLMOD_LATEX = NO +PERLMOD_PRETTY = YES +PERLMOD_MAKEVAR_PREFIX = +#--------------------------------------------------------------------------- +# Configuration options related to the preprocessor +#--------------------------------------------------------------------------- +ENABLE_PREPROCESSING = NO +MACRO_EXPANSION = NO +EXPAND_ONLY_PREDEF = YES +SEARCH_INCLUDES = YES +INCLUDE_PATH = +INCLUDE_FILE_PATTERNS = +PREDEFINED = +EXPAND_AS_DEFINED = +SKIP_FUNCTION_MACROS = YES +#--------------------------------------------------------------------------- +# Configuration::addtions related to external references +#--------------------------------------------------------------------------- +TAGFILES = +GENERATE_TAGFILE = NO +ALLEXTERNALS = YES +EXTERNAL_GROUPS = YES +PERL_PATH = /usr/bin/perl +#--------------------------------------------------------------------------- +# Configuration options related to the dot tool +#--------------------------------------------------------------------------- +CLASS_DIAGRAMS = YES +HIDE_UNDOC_RELATIONS = YES +HAVE_DOT = YES +CLASS_GRAPH = YES +COLLABORATION_GRAPH = NO +UML_LOOK = YES +TEMPLATE_RELATIONS = YES +INCLUDE_GRAPH = NO +INCLUDED_BY_GRAPH = NO +CALL_GRAPH = NO +GRAPHICAL_HIERARCHY = YES +DOT_IMAGE_FORMAT = gif +DOT_PATH = "c:/Program Files/ATT/Graphviz/bin/" +DOTFILE_DIRS = +MAX_DOT_GRAPH_WIDTH = 1024 +MAX_DOT_GRAPH_HEIGHT = 1024 +MAX_DOT_GRAPH_DEPTH = 0 +GENERATE_LEGEND = YES +DOT_CLEANUP = YES +#--------------------------------------------------------------------------- +# Configuration::addtions related to the search engine +#--------------------------------------------------------------------------- +SEARCHENGINE = NO +CGI_NAME = search.cgi +CGI_URL = +DOC_URL = +DOC_ABSPATH = +BIN_ABSPATH = /usr/local/bin/ +EXT_DOC_PATHS = diff --git a/src/smpackage/ZipArchive/ZipArchive.h b/src/smpackagee/ZipArchive/ZipArchive.h similarity index 100% rename from src/smpackage/ZipArchive/ZipArchive.h rename to src/smpackagee/ZipArchive/ZipArchive.h diff --git a/src/smpackage/ZipArchive/ZipArchive.rc b/src/smpackagee/ZipArchive/ZipArchive.rc similarity index 95% rename from src/smpackage/ZipArchive/ZipArchive.rc rename to src/smpackagee/ZipArchive/ZipArchive.rc index 7ac09bb6cc..6d9ca8bc5b 100644 --- a/src/smpackage/ZipArchive/ZipArchive.rc +++ b/src/smpackagee/ZipArchive/ZipArchive.rc @@ -1,109 +1,109 @@ -//Microsoft Developer Studio generated resource script. -// -#include "resource.h" - -#define APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 2 resource. -// -#include "afxres.h" - -///////////////////////////////////////////////////////////////////////////// -#undef APSTUDIO_READONLY_SYMBOLS - -///////////////////////////////////////////////////////////////////////////// -// Polish resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_PLK) -#ifdef _WIN32 -LANGUAGE LANG_POLISH, SUBLANG_DEFAULT -#pragma code_page(1250) -#endif //_WIN32 - -#ifndef _MAC -///////////////////////////////////////////////////////////////////////////// -// -// Version -// - -VS_VERSION_INFO VERSIONINFO - FILEVERSION 2,3,0,0 - PRODUCTVERSION 2,3,0,0 - FILEFLAGSMASK 0x3fL -#ifdef _DEBUG - FILEFLAGS 0x1L -#else - FILEFLAGS 0x0L -#endif - FILEOS 0x40004L - FILETYPE 0x2L - FILESUBTYPE 0x0L -BEGIN - BLOCK "StringFileInfo" - BEGIN - BLOCK "040904b0" - BEGIN - VALUE "Comments", "http://www.artpol-software.com\0" - VALUE "CompanyName", "Artpol Software\0" - VALUE "FileDescription", "ZipArchive - zip compression library\0" - VALUE "FileVersion", "2.3\0" - VALUE "InternalName", "ZipArchive\0" - VALUE "LegalCopyright", "Copyright © 2000 - 2003 Tadeusz Dracz\0" - VALUE "LegalTrademarks", "\0" - VALUE "OriginalFilename", "ZipArchive.dll\0" - VALUE "PrivateBuild", "\0" - VALUE "ProductName", " ZipArchive library\0" - VALUE "ProductVersion", "2, 3, 0, 0\0" - VALUE "SpecialBuild", "\0" - END - END - BLOCK "VarFileInfo" - BEGIN - VALUE "Translation", 0x409, 1200 - END -END - -#endif // !_MAC - - -#ifdef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// TEXTINCLUDE -// - -1 TEXTINCLUDE DISCARDABLE -BEGIN - "resource.h\0" -END - -2 TEXTINCLUDE DISCARDABLE -BEGIN - "#include ""afxres.h""\r\n" - "\0" -END - -3 TEXTINCLUDE DISCARDABLE -BEGIN - "\r\n" - "\0" -END - -#endif // APSTUDIO_INVOKED - -#endif // Polish resources -///////////////////////////////////////////////////////////////////////////// - - - -#ifndef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 3 resource. -// - - -///////////////////////////////////////////////////////////////////////////// -#endif // not APSTUDIO_INVOKED - +//Microsoft Developer Studio generated resource script. +// +#include "resource.h" + +#define APSTUDIO_READONLY_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 2 resource. +// +#include "afxres.h" + +///////////////////////////////////////////////////////////////////////////// +#undef APSTUDIO_READONLY_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +// Polish resources + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_PLK) +#ifdef _WIN32 +LANGUAGE LANG_POLISH, SUBLANG_DEFAULT +#pragma code_page(1250) +#endif //_WIN32 + +#ifndef _MAC +///////////////////////////////////////////////////////////////////////////// +// +// Version +// + +VS_VERSION_INFO VERSIONINFO + FILEVERSION 2,3,0,0 + PRODUCTVERSION 2,3,0,0 + FILEFLAGSMASK 0x3fL +#ifdef _DEBUG + FILEFLAGS 0x1L +#else + FILEFLAGS 0x0L +#endif + FILEOS 0x40004L + FILETYPE 0x2L + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904b0" + BEGIN + VALUE "Comments", "http://www.artpol-software.com\0" + VALUE "CompanyName", "Artpol Software\0" + VALUE "FileDescription", "ZipArchive - zip compression library\0" + VALUE "FileVersion", "2.3\0" + VALUE "InternalName", "ZipArchive\0" + VALUE "LegalCopyright", "Copyright © 2000 - 2003 Tadeusz Dracz\0" + VALUE "LegalTrademarks", "\0" + VALUE "OriginalFilename", "ZipArchive.dll\0" + VALUE "PrivateBuild", "\0" + VALUE "ProductName", " ZipArchive library\0" + VALUE "ProductVersion", "2, 3, 0, 0\0" + VALUE "SpecialBuild", "\0" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END + +#endif // !_MAC + + +#ifdef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// TEXTINCLUDE +// + +1 TEXTINCLUDE DISCARDABLE +BEGIN + "resource.h\0" +END + +2 TEXTINCLUDE DISCARDABLE +BEGIN + "#include ""afxres.h""\r\n" + "\0" +END + +3 TEXTINCLUDE DISCARDABLE +BEGIN + "\r\n" + "\0" +END + +#endif // APSTUDIO_INVOKED + +#endif // Polish resources +///////////////////////////////////////////////////////////////////////////// + + + +#ifndef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 3 resource. +// + + +///////////////////////////////////////////////////////////////////////////// +#endif // not APSTUDIO_INVOKED + diff --git a/src/smpackage/ZipArchive/ZipAutoBuffer.cpp b/src/smpackagee/ZipArchive/ZipAutoBuffer.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipAutoBuffer.cpp rename to src/smpackagee/ZipArchive/ZipAutoBuffer.cpp diff --git a/src/smpackage/ZipArchive/ZipAutoBuffer.h b/src/smpackagee/ZipArchive/ZipAutoBuffer.h similarity index 100% rename from src/smpackage/ZipArchive/ZipAutoBuffer.h rename to src/smpackagee/ZipArchive/ZipAutoBuffer.h diff --git a/src/smpackage/ZipArchive/ZipBaseException.h b/src/smpackagee/ZipArchive/ZipBaseException.h similarity index 100% rename from src/smpackage/ZipArchive/ZipBaseException.h rename to src/smpackagee/ZipArchive/ZipBaseException.h diff --git a/src/smpackage/ZipArchive/ZipCentralDir.cpp b/src/smpackagee/ZipArchive/ZipCentralDir.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipCentralDir.cpp rename to src/smpackagee/ZipArchive/ZipCentralDir.cpp diff --git a/src/smpackage/ZipArchive/ZipCentralDir.h b/src/smpackagee/ZipArchive/ZipCentralDir.h similarity index 100% rename from src/smpackage/ZipArchive/ZipCentralDir.h rename to src/smpackagee/ZipArchive/ZipCentralDir.h diff --git a/src/smpackage/ZipArchive/ZipCollections.h b/src/smpackagee/ZipArchive/ZipCollections.h similarity index 100% rename from src/smpackage/ZipArchive/ZipCollections.h rename to src/smpackagee/ZipArchive/ZipCollections.h diff --git a/src/smpackage/ZipArchive/ZipCompatibility.cpp b/src/smpackagee/ZipArchive/ZipCompatibility.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipCompatibility.cpp rename to src/smpackagee/ZipArchive/ZipCompatibility.cpp diff --git a/src/smpackage/ZipArchive/ZipCompatibility.h b/src/smpackagee/ZipArchive/ZipCompatibility.h similarity index 100% rename from src/smpackage/ZipArchive/ZipCompatibility.h rename to src/smpackagee/ZipArchive/ZipCompatibility.h diff --git a/src/smpackage/ZipArchive/ZipException.cpp b/src/smpackagee/ZipArchive/ZipException.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipException.cpp rename to src/smpackagee/ZipArchive/ZipException.cpp diff --git a/src/smpackage/ZipArchive/ZipException.h b/src/smpackagee/ZipArchive/ZipException.h similarity index 100% rename from src/smpackage/ZipArchive/ZipException.h rename to src/smpackagee/ZipArchive/ZipException.h diff --git a/src/smpackage/ZipArchive/ZipExport.h b/src/smpackagee/ZipArchive/ZipExport.h similarity index 100% rename from src/smpackage/ZipArchive/ZipExport.h rename to src/smpackagee/ZipArchive/ZipExport.h diff --git a/src/smpackage/ZipArchive/ZipFile.cpp b/src/smpackagee/ZipArchive/ZipFile.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipFile.cpp rename to src/smpackagee/ZipArchive/ZipFile.cpp diff --git a/src/smpackage/ZipArchive/ZipFile.h b/src/smpackagee/ZipArchive/ZipFile.h similarity index 100% rename from src/smpackage/ZipArchive/ZipFile.h rename to src/smpackagee/ZipArchive/ZipFile.h diff --git a/src/smpackage/ZipArchive/ZipFileHeader.cpp b/src/smpackagee/ZipArchive/ZipFileHeader.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipFileHeader.cpp rename to src/smpackagee/ZipArchive/ZipFileHeader.cpp diff --git a/src/smpackage/ZipArchive/ZipFileHeader.h b/src/smpackagee/ZipArchive/ZipFileHeader.h similarity index 100% rename from src/smpackage/ZipArchive/ZipFileHeader.h rename to src/smpackagee/ZipArchive/ZipFileHeader.h diff --git a/src/smpackage/ZipArchive/ZipFileMapping.h b/src/smpackagee/ZipArchive/ZipFileMapping.h similarity index 100% rename from src/smpackage/ZipArchive/ZipFileMapping.h rename to src/smpackagee/ZipArchive/ZipFileMapping.h diff --git a/src/smpackage/ZipArchive/ZipMemFile.cpp b/src/smpackagee/ZipArchive/ZipMemFile.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipMemFile.cpp rename to src/smpackagee/ZipArchive/ZipMemFile.cpp diff --git a/src/smpackage/ZipArchive/ZipMemFile.h b/src/smpackagee/ZipArchive/ZipMemFile.h similarity index 100% rename from src/smpackage/ZipArchive/ZipMemFile.h rename to src/smpackagee/ZipArchive/ZipMemFile.h diff --git a/src/smpackage/ZipArchive/ZipPathComponent.cpp b/src/smpackagee/ZipArchive/ZipPathComponent.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipPathComponent.cpp rename to src/smpackagee/ZipArchive/ZipPathComponent.cpp diff --git a/src/smpackage/ZipArchive/ZipPathComponent.h b/src/smpackagee/ZipArchive/ZipPathComponent.h similarity index 100% rename from src/smpackage/ZipArchive/ZipPathComponent.h rename to src/smpackagee/ZipArchive/ZipPathComponent.h diff --git a/src/smpackage/ZipArchive/ZipPlatform.cpp b/src/smpackagee/ZipArchive/ZipPlatform.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipPlatform.cpp rename to src/smpackagee/ZipArchive/ZipPlatform.cpp diff --git a/src/smpackage/ZipArchive/ZipPlatform.h b/src/smpackagee/ZipArchive/ZipPlatform.h similarity index 100% rename from src/smpackage/ZipArchive/ZipPlatform.h rename to src/smpackagee/ZipArchive/ZipPlatform.h diff --git a/src/smpackage/ZipArchive/ZipPlatformComm.cpp b/src/smpackagee/ZipArchive/ZipPlatformComm.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipPlatformComm.cpp rename to src/smpackagee/ZipArchive/ZipPlatformComm.cpp diff --git a/src/smpackage/ZipArchive/ZipStorage.cpp b/src/smpackagee/ZipArchive/ZipStorage.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipStorage.cpp rename to src/smpackagee/ZipArchive/ZipStorage.cpp diff --git a/src/smpackage/ZipArchive/ZipStorage.h b/src/smpackagee/ZipArchive/ZipStorage.h similarity index 100% rename from src/smpackage/ZipArchive/ZipStorage.h rename to src/smpackagee/ZipArchive/ZipStorage.h diff --git a/src/smpackage/ZipArchive/ZipString.cpp b/src/smpackagee/ZipArchive/ZipString.cpp similarity index 100% rename from src/smpackage/ZipArchive/ZipString.cpp rename to src/smpackagee/ZipArchive/ZipString.cpp diff --git a/src/smpackage/ZipArchive/ZipString.h b/src/smpackagee/ZipArchive/ZipString.h similarity index 100% rename from src/smpackage/ZipArchive/ZipString.h rename to src/smpackagee/ZipArchive/ZipString.h diff --git a/src/smpackage/ZipArchive/__Windows_MFC.zcfg b/src/smpackagee/ZipArchive/__Windows_MFC.zcfg similarity index 92% rename from src/smpackage/ZipArchive/__Windows_MFC.zcfg rename to src/smpackagee/ZipArchive/__Windows_MFC.zcfg index e00a2183a5..dc711df027 100644 --- a/src/smpackage/ZipArchive/__Windows_MFC.zcfg +++ b/src/smpackagee/ZipArchive/__Windows_MFC.zcfg @@ -1 +1 @@ -Windows MFC +Windows MFC diff --git a/src/smpackage/ZipArchive/_copy_from_Win-MFC.bat b/src/smpackagee/ZipArchive/_copy_from_Win-MFC.bat similarity index 95% rename from src/smpackage/ZipArchive/_copy_from_Win-MFC.bat rename to src/smpackagee/ZipArchive/_copy_from_Win-MFC.bat index 855f39f5b2..adac7df4d9 100644 --- a/src/smpackage/ZipArchive/_copy_from_Win-MFC.bat +++ b/src/smpackagee/ZipArchive/_copy_from_Win-MFC.bat @@ -1,5 +1,5 @@ -@echo off -copy Windows\*.* *.* -copy mfc\*.* *.* -del __*.zcfg -echo Windows MFC > __Windows_MFC.zcfg +@echo off +copy Windows\*.* *.* +copy mfc\*.* *.* +del __*.zcfg +echo Windows MFC > __Windows_MFC.zcfg diff --git a/src/smpackage/ZipArchive/_copy_from_Win-STL.bat b/src/smpackagee/ZipArchive/_copy_from_Win-STL.bat similarity index 95% rename from src/smpackage/ZipArchive/_copy_from_Win-STL.bat rename to src/smpackagee/ZipArchive/_copy_from_Win-STL.bat index 89ed06bb89..88f426740b 100644 --- a/src/smpackage/ZipArchive/_copy_from_Win-STL.bat +++ b/src/smpackagee/ZipArchive/_copy_from_Win-STL.bat @@ -1,5 +1,5 @@ -@echo off -copy Windows\*.* *.* -copy stl\*.* *.* -del __*.zcfg -echo Windows STL > __Windows_STL.zcfg +@echo off +copy Windows\*.* *.* +copy stl\*.* *.* +del __*.zcfg +echo Windows STL > __Windows_STL.zcfg diff --git a/src/smpackage/ZipArchive/_version.txt b/src/smpackagee/ZipArchive/_version.txt similarity index 100% rename from src/smpackage/ZipArchive/_version.txt rename to src/smpackagee/ZipArchive/_version.txt diff --git a/src/smpackage/ZipArchive/borland.zip b/src/smpackagee/ZipArchive/borland.zip similarity index 100% rename from src/smpackage/ZipArchive/borland.zip rename to src/smpackagee/ZipArchive/borland.zip diff --git a/src/smpackage/ZipArchive/faq.txt b/src/smpackagee/ZipArchive/faq.txt similarity index 100% rename from src/smpackage/ZipArchive/faq.txt rename to src/smpackagee/ZipArchive/faq.txt diff --git a/src/smpackage/ZipArchive/gpl.txt b/src/smpackagee/ZipArchive/gpl.txt similarity index 100% rename from src/smpackage/ZipArchive/gpl.txt rename to src/smpackagee/ZipArchive/gpl.txt diff --git a/src/smpackage/ZipArchive/mfc/ZipBaseException.h b/src/smpackagee/ZipArchive/mfc/ZipBaseException.h similarity index 100% rename from src/smpackage/ZipArchive/mfc/ZipBaseException.h rename to src/smpackagee/ZipArchive/mfc/ZipBaseException.h diff --git a/src/smpackage/ZipArchive/mfc/ZipCollections.h b/src/smpackagee/ZipArchive/mfc/ZipCollections.h similarity index 100% rename from src/smpackage/ZipArchive/mfc/ZipCollections.h rename to src/smpackagee/ZipArchive/mfc/ZipCollections.h diff --git a/src/smpackage/ZipArchive/mfc/ZipFile.cpp b/src/smpackagee/ZipArchive/mfc/ZipFile.cpp similarity index 100% rename from src/smpackage/ZipArchive/mfc/ZipFile.cpp rename to src/smpackagee/ZipArchive/mfc/ZipFile.cpp diff --git a/src/smpackage/ZipArchive/mfc/ZipFile.h b/src/smpackagee/ZipArchive/mfc/ZipFile.h similarity index 100% rename from src/smpackage/ZipArchive/mfc/ZipFile.h rename to src/smpackagee/ZipArchive/mfc/ZipFile.h diff --git a/src/smpackage/ZipArchive/mfc/ZipString.h b/src/smpackagee/ZipArchive/mfc/ZipString.h similarity index 100% rename from src/smpackage/ZipArchive/mfc/ZipString.h rename to src/smpackagee/ZipArchive/mfc/ZipString.h diff --git a/src/smpackage/ZipArchive/mfc/stdafx.h b/src/smpackagee/ZipArchive/mfc/stdafx.h similarity index 100% rename from src/smpackage/ZipArchive/mfc/stdafx.h rename to src/smpackagee/ZipArchive/mfc/stdafx.h diff --git a/src/smpackage/ZipArchive/resource.h b/src/smpackagee/ZipArchive/resource.h similarity index 100% rename from src/smpackage/ZipArchive/resource.h rename to src/smpackagee/ZipArchive/resource.h diff --git a/src/smpackage/ZipArchive/stl/ZipBaseException.h b/src/smpackagee/ZipArchive/stl/ZipBaseException.h similarity index 100% rename from src/smpackage/ZipArchive/stl/ZipBaseException.h rename to src/smpackagee/ZipArchive/stl/ZipBaseException.h diff --git a/src/smpackage/ZipArchive/stl/ZipCollections.h b/src/smpackagee/ZipArchive/stl/ZipCollections.h similarity index 100% rename from src/smpackage/ZipArchive/stl/ZipCollections.h rename to src/smpackagee/ZipArchive/stl/ZipCollections.h diff --git a/src/smpackage/ZipArchive/stl/ZipFile.cpp b/src/smpackagee/ZipArchive/stl/ZipFile.cpp similarity index 100% rename from src/smpackage/ZipArchive/stl/ZipFile.cpp rename to src/smpackagee/ZipArchive/stl/ZipFile.cpp diff --git a/src/smpackage/ZipArchive/stl/ZipFile.h b/src/smpackagee/ZipArchive/stl/ZipFile.h similarity index 100% rename from src/smpackage/ZipArchive/stl/ZipFile.h rename to src/smpackagee/ZipArchive/stl/ZipFile.h diff --git a/src/smpackage/ZipArchive/stl/ZipString.h b/src/smpackagee/ZipArchive/stl/ZipString.h similarity index 100% rename from src/smpackage/ZipArchive/stl/ZipString.h rename to src/smpackagee/ZipArchive/stl/ZipString.h diff --git a/src/smpackage/ZipArchive/stl/stdafx.h b/src/smpackagee/ZipArchive/stl/stdafx.h similarity index 100% rename from src/smpackage/ZipArchive/stl/stdafx.h rename to src/smpackagee/ZipArchive/stl/stdafx.h diff --git a/src/smpackage/ZipArchive/stl/zippie/CmdLine.cpp b/src/smpackagee/ZipArchive/stl/zippie/CmdLine.cpp similarity index 100% rename from src/smpackage/ZipArchive/stl/zippie/CmdLine.cpp rename to src/smpackagee/ZipArchive/stl/zippie/CmdLine.cpp diff --git a/src/smpackage/ZipArchive/stl/zippie/CmdLine.h b/src/smpackagee/ZipArchive/stl/zippie/CmdLine.h similarity index 100% rename from src/smpackage/ZipArchive/stl/zippie/CmdLine.h rename to src/smpackagee/ZipArchive/stl/zippie/CmdLine.h diff --git a/src/smpackage/ZipArchive/stl/zippie/zippie.cpp b/src/smpackagee/ZipArchive/stl/zippie/zippie.cpp similarity index 100% rename from src/smpackage/ZipArchive/stl/zippie/zippie.cpp rename to src/smpackagee/ZipArchive/stl/zippie/zippie.cpp diff --git a/src/smpackage/ZipArchive/stl/zippie/zippie.dsp b/src/smpackagee/ZipArchive/stl/zippie/zippie.dsp similarity index 97% rename from src/smpackage/ZipArchive/stl/zippie/zippie.dsp rename to src/smpackagee/ZipArchive/stl/zippie/zippie.dsp index 0405e14370..288dc3bfb6 100644 --- a/src/smpackage/ZipArchive/stl/zippie/zippie.dsp +++ b/src/smpackagee/ZipArchive/stl/zippie/zippie.dsp @@ -1,111 +1,111 @@ -# Microsoft Developer Studio Project File - Name="zippie" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Console Application" 0x0103 - -CFG=zippie - Win32 Debug -!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 "zippie.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 "zippie.mak" CFG="zippie - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "zippie - Win32 Release" (based on "Win32 (x86) Console Application") -!MESSAGE "zippie - Win32 Debug" (based on "Win32 (x86) Console Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName ""$/zippie", BGAAAAAA" -# PROP Scc_LocalPath "." -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "zippie - 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" /Yu"stdafx.h" /FD /c -# ADD CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c -# SUBTRACT CPP /YX /Yc /Yu -# ADD BASE RSC /l 0x415 /d "NDEBUG" -# ADD RSC /l 0x415 /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 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 - -!ELSEIF "$(CFG)" == "zippie - 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 Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c -# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c -# SUBTRACT CPP /YX /Yc /Yu -# ADD BASE RSC /l 0x415 /d "_DEBUG" -# ADD RSC /l 0x415 /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 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 - -!ENDIF - -# Begin Target - -# Name "zippie - Win32 Release" -# Name "zippie - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\CmdLine.cpp -# End Source File -# Begin Source File - -SOURCE=.\zippie.cpp -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\CmdLine.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 +# Microsoft Developer Studio Project File - Name="zippie" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Console Application" 0x0103 + +CFG=zippie - Win32 Debug +!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 "zippie.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 "zippie.mak" CFG="zippie - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "zippie - Win32 Release" (based on "Win32 (x86) Console Application") +!MESSAGE "zippie - Win32 Debug" (based on "Win32 (x86) Console Application") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName ""$/zippie", BGAAAAAA" +# PROP Scc_LocalPath "." +CPP=cl.exe +RSC=rc.exe + +!IF "$(CFG)" == "zippie - 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" /Yu"stdafx.h" /FD /c +# ADD CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c +# SUBTRACT CPP /YX /Yc /Yu +# ADD BASE RSC /l 0x415 /d "NDEBUG" +# ADD RSC /l 0x415 /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 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 + +!ELSEIF "$(CFG)" == "zippie - 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 Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c +# SUBTRACT CPP /YX /Yc /Yu +# ADD BASE RSC /l 0x415 /d "_DEBUG" +# ADD RSC /l 0x415 /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 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 + +!ENDIF + +# Begin Target + +# Name "zippie - Win32 Release" +# Name "zippie - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\CmdLine.cpp +# End Source File +# Begin Source File + +SOURCE=.\zippie.cpp +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\CmdLine.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/src/smpackage/ZipArchive/stl/zippie/zippie.dsw b/src/smpackagee/ZipArchive/stl/zippie/zippie.dsw similarity index 94% rename from src/smpackage/ZipArchive/stl/zippie/zippie.dsw rename to src/smpackagee/ZipArchive/stl/zippie/zippie.dsw index 60781cfa09..032bc18743 100644 --- a/src/smpackage/ZipArchive/stl/zippie/zippie.dsw +++ b/src/smpackagee/ZipArchive/stl/zippie/zippie.dsw @@ -1,44 +1,44 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "ZipArchive"="..\..\ZipArchive_STL.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Project: "zippie"=".\zippie.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name ZipArchive - End Project Dependency -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - +Microsoft Developer Studio Workspace File, Format Version 6.00 +# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! + +############################################################################### + +Project: "ZipArchive"="..\..\ZipArchive_STL.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Project: "zippie"=".\zippie.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ + Begin Project Dependency + Project_Dep_Name ZipArchive + End Project Dependency +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/src/smpackage/ZipArchive/stl/zippie/zippie_DLL.dsp b/src/smpackagee/ZipArchive/stl/zippie/zippie_DLL.dsp similarity index 97% rename from src/smpackage/ZipArchive/stl/zippie/zippie_DLL.dsp rename to src/smpackagee/ZipArchive/stl/zippie/zippie_DLL.dsp index 695e782fbe..6af7af75a5 100644 --- a/src/smpackage/ZipArchive/stl/zippie/zippie_DLL.dsp +++ b/src/smpackagee/ZipArchive/stl/zippie/zippie_DLL.dsp @@ -1,112 +1,112 @@ -# Microsoft Developer Studio Project File - Name="zippie" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Console Application" 0x0103 - -CFG=zippie - Win32 Debug -!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 "zippie_DLL.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 "zippie_DLL.mak" CFG="zippie - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "zippie - Win32 Release" (based on "Win32 (x86) Console Application") -!MESSAGE "zippie - Win32 Debug" (based on "Win32 (x86) Console Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName ""$/zippie", BGAAAAAA" -# PROP Scc_LocalPath "." -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "zippie - 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" /Yu"stdafx.h" /FD /c -# ADD CPP /nologo /MD /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "ZIP_HAS_DLL" /FD /c -# SUBTRACT CPP /YX /Yc /Yu -# ADD BASE RSC /l 0x415 /d "NDEBUG" -# ADD RSC /l 0x415 /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 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 - -!ELSEIF "$(CFG)" == "zippie - 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" /Yu"stdafx.h" /FD /GZ /c -# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "ZIP_HAS_DLL" /FR /FD /GZ /c -# SUBTRACT CPP /YX /Yc /Yu -# ADD BASE RSC /l 0x415 /d "_DEBUG" -# ADD RSC /l 0x415 /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 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 - -!ENDIF - -# Begin Target - -# Name "zippie - Win32 Release" -# Name "zippie - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\CmdLine.cpp -# End Source File -# Begin Source File - -SOURCE=.\zippie.cpp -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\CmdLine.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 +# Microsoft Developer Studio Project File - Name="zippie" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Console Application" 0x0103 + +CFG=zippie - Win32 Debug +!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 "zippie_DLL.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 "zippie_DLL.mak" CFG="zippie - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "zippie - Win32 Release" (based on "Win32 (x86) Console Application") +!MESSAGE "zippie - Win32 Debug" (based on "Win32 (x86) Console Application") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName ""$/zippie", BGAAAAAA" +# PROP Scc_LocalPath "." +CPP=cl.exe +RSC=rc.exe + +!IF "$(CFG)" == "zippie - 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" /Yu"stdafx.h" /FD /c +# ADD CPP /nologo /MD /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "ZIP_HAS_DLL" /FD /c +# SUBTRACT CPP /YX /Yc /Yu +# ADD BASE RSC /l 0x415 /d "NDEBUG" +# ADD RSC /l 0x415 /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 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 + +!ELSEIF "$(CFG)" == "zippie - 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" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "ZIP_HAS_DLL" /FR /FD /GZ /c +# SUBTRACT CPP /YX /Yc /Yu +# ADD BASE RSC /l 0x415 /d "_DEBUG" +# ADD RSC /l 0x415 /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 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 + +!ENDIF + +# Begin Target + +# Name "zippie - Win32 Release" +# Name "zippie - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\CmdLine.cpp +# End Source File +# Begin Source File + +SOURCE=.\zippie.cpp +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\CmdLine.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/src/smpackage/ZipArchive/stl/zippie/zippie_DLL.dsw b/src/smpackagee/ZipArchive/stl/zippie/zippie_DLL.dsw similarity index 94% rename from src/smpackage/ZipArchive/stl/zippie/zippie_DLL.dsw rename to src/smpackagee/ZipArchive/stl/zippie/zippie_DLL.dsw index 6227d073b4..c78c2339c5 100644 --- a/src/smpackage/ZipArchive/stl/zippie/zippie_DLL.dsw +++ b/src/smpackagee/ZipArchive/stl/zippie/zippie_DLL.dsw @@ -1,59 +1,59 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "ZipArchive"="..\..\ZipArchive_STL_DLL.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name zlib - End Project Dependency -}}} - -############################################################################### - -Project: "zippie"=".\zippie_DLL.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name ZipArchive - End Project Dependency -}}} - -############################################################################### - -Project: "zlib"="..\..\zlib\zlib.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - +Microsoft Developer Studio Workspace File, Format Version 6.00 +# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! + +############################################################################### + +Project: "ZipArchive"="..\..\ZipArchive_STL_DLL.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ + Begin Project Dependency + Project_Dep_Name zlib + End Project Dependency +}}} + +############################################################################### + +Project: "zippie"=".\zippie_DLL.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ + Begin Project Dependency + Project_Dep_Name ZipArchive + End Project Dependency +}}} + +############################################################################### + +Project: "zlib"="..\..\zlib\zlib.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/src/smpackage/res/smpackage.ico b/src/smpackagee/res/smpackage.ico similarity index 100% rename from src/smpackage/res/smpackage.ico rename to src/smpackagee/res/smpackage.ico diff --git a/src/smpackage/res/smpackage.rc2 b/src/smpackagee/res/smpackage.rc2 similarity index 96% rename from src/smpackage/res/smpackage.rc2 rename to src/smpackagee/res/smpackage.rc2 index a74b918e89..50a7391dbf 100644 --- a/src/smpackage/res/smpackage.rc2 +++ b/src/smpackagee/res/smpackage.rc2 @@ -1,13 +1,13 @@ -// -// SMPACKAGE.RC2 - resources Microsoft Visual C++ does not edit directly -// - -#ifdef APSTUDIO_INVOKED - #error this file is not editable by Microsoft Visual C++ -#endif //APSTUDIO_INVOKED - - -///////////////////////////////////////////////////////////////////////////// -// Add manually edited resources here... - -///////////////////////////////////////////////////////////////////////////// +// +// SMPACKAGE.RC2 - resources Microsoft Visual C++ does not edit directly +// + +#ifdef APSTUDIO_INVOKED + #error this file is not editable by Microsoft Visual C++ +#endif //APSTUDIO_INVOKED + + +///////////////////////////////////////////////////////////////////////////// +// Add manually edited resources here... + +///////////////////////////////////////////////////////////////////////////// diff --git a/src/smpackage/resource.h b/src/smpackagee/resource.h similarity index 100% rename from src/smpackage/resource.h rename to src/smpackagee/resource.h diff --git a/src/smpackage/smpackage.ICO b/src/smpackagee/smpackage.ICO similarity index 100% rename from src/smpackage/smpackage.ICO rename to src/smpackagee/smpackage.ICO diff --git a/src/smpackage/smpackage.clw b/src/smpackagee/smpackage.clw similarity index 96% rename from src/smpackage/smpackage.clw rename to src/smpackagee/smpackage.clw index bd2520f18e..ef17bb3487 100644 --- a/src/smpackage/smpackage.clw +++ b/src/smpackagee/smpackage.clw @@ -1,321 +1,321 @@ -; CLW file contains information for the MFC ClassWizard - -[General Info] -Version=1 -LastClass=MainMenuDlg -LastTemplate=CDialog -NewFileInclude1=#include "stdafx.h" -NewFileInclude2=#include "smpackage.h" - -ClassCount=12 -Class1=CSmpackageApp -Class2=CSmpackageDlg - -ResourceCount=13 -Resource1=IDR_MAINFRAME -Resource2=IDD_ENTER_STRING -Class3=CSMPackageInstallDlg -Class4=CSmpackageExportDlg -Resource3=IDD_EXPORTER -Class5=EnterName -Resource4=IDD_EDIT_METRICS -Class6=EditInsallations -Resource5=IDD_CONVERT_THEME -Class7=MainMenuDlg -Resource6=IDD_MENU -Class8=ConvertThemeDlg -Resource7=IDD_SHOW_COMMENT -Class9=EditMetricsDlg -Resource8=IDD_ENTER_COMMENT -Resource9=IDD_DIALOG_NAME -Class10=EnterComment -Resource10=IDD_INSTALL -Class11=ShowComment -Resource11=IDD_UNINSTALL_OLD_PACKAGES -Resource12=IDD_EDIT_INSTALLATIONS -Class12=ChangeGameSettings -Resource13=IDD_CHANGE_GAME_SETTINGS - -[CLS:CSmpackageApp] -Type=0 -HeaderFile=smpackage.h -ImplementationFile=smpackage.cpp -Filter=N -LastObject=CSmpackageApp -BaseClass=CWinApp -VirtualFilter=AC - -[CLS:CSmpackageDlg] -Type=0 -HeaderFile=smpackageDlg.h -ImplementationFile=smpackageDlg.cpp -Filter=D -LastObject=CSmpackageDlg -BaseClass=CDialog -VirtualFilter=dWC - - - -[DLG:IDD_INSTALL] -Type=1 -Class=CSMPackageInstallDlg -ControlCount=10 -Control1=IDC_EDIT_MESSAGE1,edit,1342179460 -Control2=IDOK,button,1342242817 -Control3=IDCANCEL,button,1342242816 -Control4=IDC_BUTTON_BACK,button,1476460544 -Control5=IDC_STATIC,static,1342177294 -Control6=IDC_EDIT_MESSAGE3,edit,1342179460 -Control7=IDC_EDIT_MESSAGE2,edit,1352665220 -Control8=IDC_COMBO_DIR,combobox,1344339971 -Control9=IDC_BUTTON_EDIT,button,1342242816 -Control10=IDC_PROGRESS1,msctls_progress32,1082130432 - -[CLS:CSMPackageInstallDlg] -Type=0 -HeaderFile=SMPackageInstallDlg.h -ImplementationFile=SMPackageInstallDlg.cpp -BaseClass=CDialog -Filter=D -LastObject=CSMPackageInstallDlg -VirtualFilter=dWC - -[DLG:IDD_EXPORTER] -Type=1 -Class=CSmpackageExportDlg -ControlCount=10 -Control1=IDOK,button,1342242817 -Control2=IDC_BUTTON_PLAY,button,1342242816 -Control3=IDC_BUTTON_EXPORT_AS_ONE,button,1342242816 -Control4=IDC_STATIC,static,1342177294 -Control5=IDC_BUTTON_EXPORT_AS_INDIVIDUAL,button,1342242816 -Control6=IDC_TREE,SysTreeView32,1350631687 -Control7=IDC_COMBO_DIR,combobox,1344339971 -Control8=IDC_BUTTON_EDIT,button,1342242816 -Control9=IDC_STATIC,static,1342308352 -Control10=IDC_BUTTON_OPEN,button,1342242816 - -[CLS:CSmpackageExportDlg] -Type=0 -HeaderFile=SmpackageExportDlg.h -ImplementationFile=SmpackageExportDlg.cpp -BaseClass=CDialog -Filter=D -LastObject=CSmpackageExportDlg -VirtualFilter=dWC - -[CLS:EnterName] -Type=0 -HeaderFile=EnterName.h -ImplementationFile=EnterName.cpp -BaseClass=CDialog -Filter=D -VirtualFilter=dWC -LastObject=IDC_EDIT - -[DLG:IDD_EDIT_INSTALLATIONS] -Type=1 -Class=EditInsallations -ControlCount=10 -Control1=IDOK,button,1342242817 -Control2=IDCANCEL,button,1342242816 -Control3=IDC_LIST,listbox,1352728833 -Control4=IDC_EDIT,edit,1350631552 -Control5=IDC_BUTTON_ADD,button,1342242816 -Control6=IDC_BUTTON_REMOVE,button,1342242816 -Control7=IDC_BUTTON_MAKE_DEFAULT,button,1342242816 -Control8=IDC_STATIC,button,1342177287 -Control9=IDC_STATIC,button,1342177287 -Control10=IDC_STATIC,static,1342308352 - -[CLS:EditInsallations] -Type=0 -HeaderFile=EditInsallations.h -ImplementationFile=EditInsallations.cpp -BaseClass=CDialog -Filter=D -VirtualFilter=dWC -LastObject=EditInsallations - -[DLG:IDD_MENU] -Type=1 -Class=MainMenuDlg -ControlCount=20 -Control1=IDOK,button,1342242817 -Control2=IDC_STATIC,static,1342177294 -Control3=IDC_STATIC,static,1342308354 -Control4=IDC_EDIT_INSTALLATION,edit,1350633600 -Control5=IDC_STATIC,button,1342177287 -Control6=IDC_EDIT_INSTALLATIONS,button,1342242816 -Control7=IDC_STATIC,static,1342308352 -Control8=IDC_STATIC,button,1342177287 -Control9=IDC_EXPORT_PACKAGES,button,1342242816 -Control10=IDC_STATIC,static,1342308352 -Control11=IDC_STATIC,button,1342177287 -Control12=IDC_ANALYZE_ELEMENTS,button,1342242816 -Control13=IDC_STATIC,static,1342308352 -Control14=IDC_STATIC,button,1342177287 -Control15=IDC_CHANGE_API,button,1342242816 -Control16=IDC_OPEN_STEPMANIA_INI,button,1342242816 -Control17=IDC_STATIC,static,1342308352 -Control18=IDC_STATIC,button,1342177287 -Control19=IDC_CREATE_SONG,button,1342242816 -Control20=IDC_STATIC,static,1342308352 - -[CLS:MainMenuDlg] -Type=0 -HeaderFile=MainMenuDlg.h -ImplementationFile=MainMenuDlg.cpp -BaseClass=CDialog -Filter=D -VirtualFilter=dWC -LastObject=MainMenuDlg - -[DLG:IDD_CONVERT_THEME] -Type=1 -Class=ConvertThemeDlg -ControlCount=13 -Control1=IDOK,button,1342242817 -Control2=IDC_STATIC,static,1342177294 -Control3=IDC_LIST_THEMES,listbox,1352728835 -Control4=IDC_BUTTON_CONVERT,button,1476460544 -Control5=IDC_STATIC,static,1342308352 -Control6=IDC_STATIC,button,1342177287 -Control7=IDC_STATIC,static,1342308352 -Control8=IDC_BUTTON_ANALYZE,button,1476460544 -Control9=IDC_STATIC,button,1342177287 -Control10=IDC_STATIC,static,1342308352 -Control11=IDC_BUTTON_EDIT_METRICS,button,1476460544 -Control12=IDC_STATIC,static,1342308352 -Control13=IDC_BUTTON_ANALYZE_METRICS,button,1476460544 - -[CLS:ConvertThemeDlg] -Type=0 -HeaderFile=onvertThemeDlg.h -ImplementationFile=onvertThemeDlg.cpp -BaseClass=CDialog -Filter=D -LastObject=IDC_LIST_THEMES -VirtualFilter=dWC - -[DLG:IDD_EDIT_METRICS] -Type=1 -Class=EditMetricsDlg -ControlCount=11 -Control1=IDC_BUTTON_CLOSE,button,1342242816 -Control2=IDC_STATIC,static,1342177294 -Control3=IDC_EDIT_VALUE,edit,1484849220 -Control4=IDC_STATIC,static,1342308352 -Control5=IDC_EDIT_DEFAULT,edit,1350633540 -Control6=IDC_STATIC,static,1342308352 -Control7=IDC_BUTTON_OVERRIDE,button,1476460544 -Control8=IDC_BUTTON_REMOVE,button,1476460544 -Control9=IDC_TREE,SysTreeView32,1350631461 -Control10=IDC_BUTTON_SAVE,button,1342242816 -Control11=IDC_BUTTON_HELP,button,1342242816 - -[CLS:EditMetricsDlg] -Type=0 -HeaderFile=EditMetricsDlg.h -ImplementationFile=EditMetricsDlg.cpp -BaseClass=CDialog -Filter=D -VirtualFilter=dWC -LastObject=EditMetricsDlg - -[DLG:IDD_ENTER_STRING] -Type=1 -Class=EnterName -ControlCount=4 -Control1=IDC_STATIC,static,1342308352 -Control2=IDC_EDIT,edit,1350631552 -Control3=IDOK,button,1342242817 -Control4=IDCANCEL,button,1342242816 - -[DLG:IDD_ENTER_COMMENT] -Type=1 -Class=EnterComment -ControlCount=5 -Control1=65535,static,1342308352 -Control2=IDC_EDIT,edit,1350631556 -Control3=IDOK,button,1342242817 -Control4=IDCANCEL,button,1342242816 -Control5=IDC_DONTASK,button,1342242819 - -[DLG:IDD_DIALOG_NAME] -Type=1 -Class=? -ControlCount=5 -Control1=IDC_STATIC,static,1342308352 -Control2=IDC_EDIT,edit,1350631552 -Control3=IDOK,button,1342242817 -Control4=IDCANCEL,button,1342242816 -Control5=IDC_STATIC,static,1342308352 - -[CLS:EnterComment] -Type=0 -HeaderFile=EnterComment.h -ImplementationFile=EnterComment.cpp -BaseClass=CDialog -Filter=D -LastObject=IDC_EDIT -VirtualFilter=dWC - -[DLG:IDD_SHOW_COMMENT] -Type=1 -Class=ShowComment -ControlCount=4 -Control1=IDC_EDIT,edit,1350633604 -Control2=IDOK,button,1342242817 -Control3=IDCANCEL,button,1342242816 -Control4=IDC_DONTSHOW,button,1342242819 - -[CLS:ShowComment] -Type=0 -HeaderFile=ShowComment.h -ImplementationFile=ShowComment.cpp -BaseClass=CDialog -Filter=D -VirtualFilter=dWC -LastObject=IDC_DONTSHOW - -[DLG:IDD_UNINSTALL_OLD_PACKAGES] -Type=1 -Class=? -ControlCount=6 -Control1=IDOK,button,1342242817 -Control2=IDCANCEL,button,1342242816 -Control3=IDC_STATIC,static,1342308352 -Control4=IDC_PACKAGES,edit,1352730756 -Control5=IDC_BUTTON1,button,1342242816 -Control6=IDC_STATIC,static,1342308353 - -[DLG:IDD_CHANGE_GAME_SETTINGS] -Type=1 -Class=ChangeGameSettings -ControlCount=15 -Control1=IDOK,button,1342242817 -Control2=IDCANCEL,button,1342242816 -Control3=IDC_STATIC,button,1342177287 -Control4=IDC_RADIO_DEFAULT,button,1342308361 -Control5=IDC_RADIO_OPENGL,button,1342177289 -Control6=IDC_RADIO_DIRECT3D,button,1342177289 -Control7=IDC_STATIC,button,1342177287 -Control8=IDC_RADIO_SOUND_DEFAULT,button,1342308361 -Control9=IDC_RADIO_SOUND_DIRECTSOUND_HARDWARE,button,1342177289 -Control10=IDC_RADIO_SOUND_DIRECTSOUND_SOFTWARE,button,1342177289 -Control11=IDC_RADIO_SOUND_NULL,button,1342177289 -Control12=IDC_STATIC,button,1342177287 -Control13=IDC_CHECK_LOG_TO_DISK,button,1342242819 -Control14=IDC_CHECK_SHOW_LOG_WINDOW,button,1342242819 -Control15=IDC_STATIC,static,1342308352 - -[CLS:ChangeGameSettings] -Type=0 -HeaderFile=ChangeGameSettings.h -ImplementationFile=ChangeGameSettings.cpp -BaseClass=CDialog -Filter=D -LastObject=IDCANCEL -VirtualFilter=dWC - +; CLW file contains information for the MFC ClassWizard + +[General Info] +Version=1 +LastClass=MainMenuDlg +LastTemplate=CDialog +NewFileInclude1=#include "stdafx.h" +NewFileInclude2=#include "smpackage.h" + +ClassCount=12 +Class1=CSmpackageApp +Class2=CSmpackageDlg + +ResourceCount=13 +Resource1=IDR_MAINFRAME +Resource2=IDD_ENTER_STRING +Class3=CSMPackageInstallDlg +Class4=CSmpackageExportDlg +Resource3=IDD_EXPORTER +Class5=EnterName +Resource4=IDD_EDIT_METRICS +Class6=EditInsallations +Resource5=IDD_CONVERT_THEME +Class7=MainMenuDlg +Resource6=IDD_MENU +Class8=ConvertThemeDlg +Resource7=IDD_SHOW_COMMENT +Class9=EditMetricsDlg +Resource8=IDD_ENTER_COMMENT +Resource9=IDD_DIALOG_NAME +Class10=EnterComment +Resource10=IDD_INSTALL +Class11=ShowComment +Resource11=IDD_UNINSTALL_OLD_PACKAGES +Resource12=IDD_EDIT_INSTALLATIONS +Class12=ChangeGameSettings +Resource13=IDD_CHANGE_GAME_SETTINGS + +[CLS:CSmpackageApp] +Type=0 +HeaderFile=smpackage.h +ImplementationFile=smpackage.cpp +Filter=N +LastObject=CSmpackageApp +BaseClass=CWinApp +VirtualFilter=AC + +[CLS:CSmpackageDlg] +Type=0 +HeaderFile=smpackageDlg.h +ImplementationFile=smpackageDlg.cpp +Filter=D +LastObject=CSmpackageDlg +BaseClass=CDialog +VirtualFilter=dWC + + + +[DLG:IDD_INSTALL] +Type=1 +Class=CSMPackageInstallDlg +ControlCount=10 +Control1=IDC_EDIT_MESSAGE1,edit,1342179460 +Control2=IDOK,button,1342242817 +Control3=IDCANCEL,button,1342242816 +Control4=IDC_BUTTON_BACK,button,1476460544 +Control5=IDC_STATIC,static,1342177294 +Control6=IDC_EDIT_MESSAGE3,edit,1342179460 +Control7=IDC_EDIT_MESSAGE2,edit,1352665220 +Control8=IDC_COMBO_DIR,combobox,1344339971 +Control9=IDC_BUTTON_EDIT,button,1342242816 +Control10=IDC_PROGRESS1,msctls_progress32,1082130432 + +[CLS:CSMPackageInstallDlg] +Type=0 +HeaderFile=SMPackageInstallDlg.h +ImplementationFile=SMPackageInstallDlg.cpp +BaseClass=CDialog +Filter=D +LastObject=CSMPackageInstallDlg +VirtualFilter=dWC + +[DLG:IDD_EXPORTER] +Type=1 +Class=CSmpackageExportDlg +ControlCount=10 +Control1=IDOK,button,1342242817 +Control2=IDC_BUTTON_PLAY,button,1342242816 +Control3=IDC_BUTTON_EXPORT_AS_ONE,button,1342242816 +Control4=IDC_STATIC,static,1342177294 +Control5=IDC_BUTTON_EXPORT_AS_INDIVIDUAL,button,1342242816 +Control6=IDC_TREE,SysTreeView32,1350631687 +Control7=IDC_COMBO_DIR,combobox,1344339971 +Control8=IDC_BUTTON_EDIT,button,1342242816 +Control9=IDC_STATIC,static,1342308352 +Control10=IDC_BUTTON_OPEN,button,1342242816 + +[CLS:CSmpackageExportDlg] +Type=0 +HeaderFile=SmpackageExportDlg.h +ImplementationFile=SmpackageExportDlg.cpp +BaseClass=CDialog +Filter=D +LastObject=CSmpackageExportDlg +VirtualFilter=dWC + +[CLS:EnterName] +Type=0 +HeaderFile=EnterName.h +ImplementationFile=EnterName.cpp +BaseClass=CDialog +Filter=D +VirtualFilter=dWC +LastObject=IDC_EDIT + +[DLG:IDD_EDIT_INSTALLATIONS] +Type=1 +Class=EditInsallations +ControlCount=10 +Control1=IDOK,button,1342242817 +Control2=IDCANCEL,button,1342242816 +Control3=IDC_LIST,listbox,1352728833 +Control4=IDC_EDIT,edit,1350631552 +Control5=IDC_BUTTON_ADD,button,1342242816 +Control6=IDC_BUTTON_REMOVE,button,1342242816 +Control7=IDC_BUTTON_MAKE_DEFAULT,button,1342242816 +Control8=IDC_STATIC,button,1342177287 +Control9=IDC_STATIC,button,1342177287 +Control10=IDC_STATIC,static,1342308352 + +[CLS:EditInsallations] +Type=0 +HeaderFile=EditInsallations.h +ImplementationFile=EditInsallations.cpp +BaseClass=CDialog +Filter=D +VirtualFilter=dWC +LastObject=EditInsallations + +[DLG:IDD_MENU] +Type=1 +Class=MainMenuDlg +ControlCount=20 +Control1=IDOK,button,1342242817 +Control2=IDC_STATIC,static,1342177294 +Control3=IDC_STATIC,static,1342308354 +Control4=IDC_EDIT_INSTALLATION,edit,1350633600 +Control5=IDC_STATIC,button,1342177287 +Control6=IDC_EDIT_INSTALLATIONS,button,1342242816 +Control7=IDC_STATIC,static,1342308352 +Control8=IDC_STATIC,button,1342177287 +Control9=IDC_EXPORT_PACKAGES,button,1342242816 +Control10=IDC_STATIC,static,1342308352 +Control11=IDC_STATIC,button,1342177287 +Control12=IDC_ANALYZE_ELEMENTS,button,1342242816 +Control13=IDC_STATIC,static,1342308352 +Control14=IDC_STATIC,button,1342177287 +Control15=IDC_CHANGE_API,button,1342242816 +Control16=IDC_OPEN_STEPMANIA_INI,button,1342242816 +Control17=IDC_STATIC,static,1342308352 +Control18=IDC_STATIC,button,1342177287 +Control19=IDC_CREATE_SONG,button,1342242816 +Control20=IDC_STATIC,static,1342308352 + +[CLS:MainMenuDlg] +Type=0 +HeaderFile=MainMenuDlg.h +ImplementationFile=MainMenuDlg.cpp +BaseClass=CDialog +Filter=D +VirtualFilter=dWC +LastObject=MainMenuDlg + +[DLG:IDD_CONVERT_THEME] +Type=1 +Class=ConvertThemeDlg +ControlCount=13 +Control1=IDOK,button,1342242817 +Control2=IDC_STATIC,static,1342177294 +Control3=IDC_LIST_THEMES,listbox,1352728835 +Control4=IDC_BUTTON_CONVERT,button,1476460544 +Control5=IDC_STATIC,static,1342308352 +Control6=IDC_STATIC,button,1342177287 +Control7=IDC_STATIC,static,1342308352 +Control8=IDC_BUTTON_ANALYZE,button,1476460544 +Control9=IDC_STATIC,button,1342177287 +Control10=IDC_STATIC,static,1342308352 +Control11=IDC_BUTTON_EDIT_METRICS,button,1476460544 +Control12=IDC_STATIC,static,1342308352 +Control13=IDC_BUTTON_ANALYZE_METRICS,button,1476460544 + +[CLS:ConvertThemeDlg] +Type=0 +HeaderFile=onvertThemeDlg.h +ImplementationFile=onvertThemeDlg.cpp +BaseClass=CDialog +Filter=D +LastObject=IDC_LIST_THEMES +VirtualFilter=dWC + +[DLG:IDD_EDIT_METRICS] +Type=1 +Class=EditMetricsDlg +ControlCount=11 +Control1=IDC_BUTTON_CLOSE,button,1342242816 +Control2=IDC_STATIC,static,1342177294 +Control3=IDC_EDIT_VALUE,edit,1484849220 +Control4=IDC_STATIC,static,1342308352 +Control5=IDC_EDIT_DEFAULT,edit,1350633540 +Control6=IDC_STATIC,static,1342308352 +Control7=IDC_BUTTON_OVERRIDE,button,1476460544 +Control8=IDC_BUTTON_REMOVE,button,1476460544 +Control9=IDC_TREE,SysTreeView32,1350631461 +Control10=IDC_BUTTON_SAVE,button,1342242816 +Control11=IDC_BUTTON_HELP,button,1342242816 + +[CLS:EditMetricsDlg] +Type=0 +HeaderFile=EditMetricsDlg.h +ImplementationFile=EditMetricsDlg.cpp +BaseClass=CDialog +Filter=D +VirtualFilter=dWC +LastObject=EditMetricsDlg + +[DLG:IDD_ENTER_STRING] +Type=1 +Class=EnterName +ControlCount=4 +Control1=IDC_STATIC,static,1342308352 +Control2=IDC_EDIT,edit,1350631552 +Control3=IDOK,button,1342242817 +Control4=IDCANCEL,button,1342242816 + +[DLG:IDD_ENTER_COMMENT] +Type=1 +Class=EnterComment +ControlCount=5 +Control1=65535,static,1342308352 +Control2=IDC_EDIT,edit,1350631556 +Control3=IDOK,button,1342242817 +Control4=IDCANCEL,button,1342242816 +Control5=IDC_DONTASK,button,1342242819 + +[DLG:IDD_DIALOG_NAME] +Type=1 +Class=? +ControlCount=5 +Control1=IDC_STATIC,static,1342308352 +Control2=IDC_EDIT,edit,1350631552 +Control3=IDOK,button,1342242817 +Control4=IDCANCEL,button,1342242816 +Control5=IDC_STATIC,static,1342308352 + +[CLS:EnterComment] +Type=0 +HeaderFile=EnterComment.h +ImplementationFile=EnterComment.cpp +BaseClass=CDialog +Filter=D +LastObject=IDC_EDIT +VirtualFilter=dWC + +[DLG:IDD_SHOW_COMMENT] +Type=1 +Class=ShowComment +ControlCount=4 +Control1=IDC_EDIT,edit,1350633604 +Control2=IDOK,button,1342242817 +Control3=IDCANCEL,button,1342242816 +Control4=IDC_DONTSHOW,button,1342242819 + +[CLS:ShowComment] +Type=0 +HeaderFile=ShowComment.h +ImplementationFile=ShowComment.cpp +BaseClass=CDialog +Filter=D +VirtualFilter=dWC +LastObject=IDC_DONTSHOW + +[DLG:IDD_UNINSTALL_OLD_PACKAGES] +Type=1 +Class=? +ControlCount=6 +Control1=IDOK,button,1342242817 +Control2=IDCANCEL,button,1342242816 +Control3=IDC_STATIC,static,1342308352 +Control4=IDC_PACKAGES,edit,1352730756 +Control5=IDC_BUTTON1,button,1342242816 +Control6=IDC_STATIC,static,1342308353 + +[DLG:IDD_CHANGE_GAME_SETTINGS] +Type=1 +Class=ChangeGameSettings +ControlCount=15 +Control1=IDOK,button,1342242817 +Control2=IDCANCEL,button,1342242816 +Control3=IDC_STATIC,button,1342177287 +Control4=IDC_RADIO_DEFAULT,button,1342308361 +Control5=IDC_RADIO_OPENGL,button,1342177289 +Control6=IDC_RADIO_DIRECT3D,button,1342177289 +Control7=IDC_STATIC,button,1342177287 +Control8=IDC_RADIO_SOUND_DEFAULT,button,1342308361 +Control9=IDC_RADIO_SOUND_DIRECTSOUND_HARDWARE,button,1342177289 +Control10=IDC_RADIO_SOUND_DIRECTSOUND_SOFTWARE,button,1342177289 +Control11=IDC_RADIO_SOUND_NULL,button,1342177289 +Control12=IDC_STATIC,button,1342177287 +Control13=IDC_CHECK_LOG_TO_DISK,button,1342242819 +Control14=IDC_CHECK_SHOW_LOG_WINDOW,button,1342242819 +Control15=IDC_STATIC,static,1342308352 + +[CLS:ChangeGameSettings] +Type=0 +HeaderFile=ChangeGameSettings.h +ImplementationFile=ChangeGameSettings.cpp +BaseClass=CDialog +Filter=D +LastObject=IDCANCEL +VirtualFilter=dWC + diff --git a/src/smpackage/smpackage.cpp b/src/smpackagee/smpackage.cpp similarity index 100% rename from src/smpackage/smpackage.cpp rename to src/smpackagee/smpackage.cpp diff --git a/src/smpackage/smpackage.h b/src/smpackagee/smpackage.h similarity index 100% rename from src/smpackage/smpackage.h rename to src/smpackagee/smpackage.h diff --git a/src/smpackage/smpackage.rc b/src/smpackagee/smpackage.rc similarity index 97% rename from src/smpackage/smpackage.rc rename to src/smpackagee/smpackage.rc index 9a3428c8a0..eb7dfc6c03 100644 --- a/src/smpackage/smpackage.rc +++ b/src/smpackagee/smpackage.rc @@ -1,499 +1,499 @@ -// Microsoft Visual C++ generated resource script. -// -#include "resource.h" - -#define APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 2 resource. -// -#include "afxres.h" - -///////////////////////////////////////////////////////////////////////////// -#undef APSTUDIO_READONLY_SYMBOLS - -///////////////////////////////////////////////////////////////////////////// -// English (U.S.) resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) -#ifdef _WIN32 -LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US -#pragma code_page(1252) -#endif //_WIN32 - -#ifdef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// TEXTINCLUDE -// - -1 TEXTINCLUDE -BEGIN - "resource.h\0" -END - -2 TEXTINCLUDE -BEGIN - "#include ""afxres.h""\r\n" - "\0" -END - -3 TEXTINCLUDE -BEGIN - "#define _AFX_NO_SPLITTER_RESOURCES\r\n" - "#define _AFX_NO_OLE_RESOURCES\r\n" - "#define _AFX_NO_TRACKER_RESOURCES\r\n" - "#define _AFX_NO_PROPERTY_RESOURCES\r\n" - "\r\n" - "#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)\r\n" - "#ifdef _WIN32\r\n" - "LANGUAGE 9, 1\r\n" - "#pragma code_page(1252)\r\n" - "#endif //_WIN32\r\n" - "#include ""res\\smpackage.rc2"" // non-Microsoft Visual C++ edited resources\r\n" - "#include ""afxres.rc"" // Standard components\r\n" - "#endif\r\n" - "\0" -END - -#endif // APSTUDIO_INVOKED - - -///////////////////////////////////////////////////////////////////////////// -// -// Icon -// - -// Icon with lowest ID value placed first to ensure application icon -// remains consistent on all systems. -IDR_MAINFRAME ICON "smpackage.ICO" - -///////////////////////////////////////////////////////////////////////////// -// -// Dialog -// - -IDD_INSTALL DIALOGEX 0, 0, 332, 234 -STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION -CAPTION "Install a package" -FONT 8, "MS Sans Serif", 0, 0, 0x1 -BEGIN - EDITTEXT IDC_EDIT_MESSAGE1,7,57,320,14,ES_MULTILINE | - ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER | NOT - WS_TABSTOP - DEFPUSHBUTTON "Finish >",IDOK,200,215,55,15 - PUSHBUTTON "Cancel",IDCANCEL,275,215,50,15 - PUSHBUTTON "< Back",IDC_BUTTON_BACK,145,215,55,15,WS_DISABLED - EDITTEXT IDC_EDIT_MESSAGE2,5,90,320,87,ES_MULTILINE | - ES_AUTOHSCROLL | ES_READONLY | WS_VSCROLL | NOT - WS_TABSTOP - COMBOBOX IDC_COMBO_DIR,22,195,204,105,CBS_DROPDOWNLIST | - WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Edit Installations",IDC_BUTTON_EDIT,233,194,85,14 - CONTROL "",IDC_PROGRESS1,"msctls_progress32",NOT WS_VISIBLE | - WS_BORDER,7,72,318,14 - LTEXT "You have chosen to install the package:", - IDC_STATIC_MESSAGE1,7,41,318,10 - LTEXT "This package contains the following files:", - IDC_STATIC_MESSAGE2,7,76,318,10 - LTEXT "The package will be installed in the following program folder:", - IDC_STATIC,7,181,318,10 - CONTROL "",IDC_STATIC,"Static",SS_WHITERECT,0,0,331,33 - LTEXT "Install a package",IDC_STATIC_HEADER_TEXT,6,4,273,20 - CONTROL "",IDC_STATIC,"Static",SS_ETCHEDFRAME,0,33,331,1 - ICON IDR_MAINFRAME,IDC_STATIC_ICON,295,6,21,20,0, - WS_EX_TRANSPARENT -END - -IDD_EXPORTER DIALOGEX 0, 0, 349, 222 -STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | - WS_VISIBLE | WS_CAPTION | WS_SYSMENU -EXSTYLE WS_EX_APPWINDOW -CAPTION "Export Packages" -FONT 8, "MS Sans Serif", 0, 0, 0x1 -BEGIN - DEFPUSHBUTTON "Close",IDOK,284,201,57,14 - PUSHBUTTON "Launch Game",IDC_BUTTON_PLAY,7,200,70,15 - PUSHBUTTON "Export As One",IDC_BUTTON_EXPORT_AS_ONE,255,87,86,15 - PUSHBUTTON "Export As Individual",IDC_BUTTON_EXPORT_AS_INDIVIDUAL, - 255,120,86,15 - CONTROL "Tree2",IDC_TREE,"SysTreeView32",TVS_HASBUTTONS | - TVS_HASLINES | TVS_LINESATROOT | TVS_CHECKBOXES | - WS_BORDER | WS_TABSTOP,7,43,239,151 - COMBOBOX IDC_COMBO_DIR,16,17,229,105,CBS_DROPDOWNLIST | - WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Edit Installations",IDC_BUTTON_EDIT,250,16,85,14 - PUSHBUTTON "Open Program Folder",IDC_BUTTON_OPEN,88,200,93,15 - GROUPBOX "Installation",IDC_STATIC,7,7,334,29 -END - -IDD_DIALOG_NAME DIALOGEX 0, 0, 261, 58 -STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Name Your Package" -FONT 8, "MS Sans Serif", 0, 0, 0x0 -BEGIN - LTEXT "Enter a name for your new package:",IDC_STATIC,7,7,188, - 12 - EDITTEXT IDC_EDIT,17,20,178,13,ES_AUTOHSCROLL - DEFPUSHBUTTON "OK",IDOK,200,7,54,14 - PUSHBUTTON "Cancel",IDCANCEL,200,24,54,14 - LTEXT "Note: leave off the "".smzip"" extension",IDC_STATIC,18, - 38,179,12 -END - -IDD_EDIT_INSTALLATIONS DIALOGEX 0, 0, 243, 221 -STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Edit Installations" -FONT 8, "MS Sans Serif", 0, 0, 0x0 -BEGIN - DEFPUSHBUTTON "OK",IDOK,125,199,50,14 - PUSHBUTTON "Cancel",IDCANCEL,185,199,50,14 - LISTBOX IDC_LIST,17,30,136,80,LBS_NOINTEGRALHEIGHT | WS_VSCROLL | - WS_TABSTOP - EDITTEXT IDC_EDIT,19,167,136,13,ES_AUTOHSCROLL - PUSHBUTTON "Add",IDC_BUTTON_ADD,165,167,50,14 - PUSHBUTTON "Remove",IDC_BUTTON_REMOVE,160,54,68,15,WS_DISABLED - PUSHBUTTON "Make Default",IDC_BUTTON_MAKE_DEFAULT,160,34,68,15, - WS_DISABLED - GROUPBOX "Add New Installation",IDC_STATIC,7,130,228,59 - GROUPBOX "Current Installations",IDC_STATIC,7,7,228,114 - LTEXT "Enter the complete path to a StepMania or DWI installation\r\ne.g. ""C:\\Program Files\\StepMania""", - IDC_STATIC,18,144,196,17 - LTEXT "The top installation is the default.",IDC_STATIC,19,17, - 196,12 -END - -IDD_MENU DIALOGEX 0, 0, 332, 284 -STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "StepMania Tools Main Menu" -FONT 8, "MS Sans Serif", 0, 0, 0x1 -BEGIN - CONTROL "",IDC_STATIC,"Static",SS_WHITERECT,0,0,331,33 - LTEXT "StepMania Tools Main Menu",IDC_STATIC_HEADER_TEXT,6,4, - 273,20 - DEFPUSHBUTTON "Exit",IDOK,275,263,50,14 - GROUPBOX "Installation",IDC_STATIC,7,41,318,28 - PUSHBUTTON "Edit Installations",IDC_EDIT_INSTALLATIONS,233,49,83,15 - GROUPBOX "Create and Share",IDC_STATIC,7,176,318,78 - PUSHBUTTON "Export Packages",IDC_EXPORT_PACKAGES,14,190,91,15 - LTEXT "Create .smzip package files to share with other users.", - IDC_STATIC,109,190,213,18 - PUSHBUTTON "Create Song",IDC_CREATE_SONG,14,211,91,15 - LTEXT "Create a new song in from your favorite mp3 or ogg music file.", - IDC_STATIC,109,211,213,20 - GROUPBOX "Troubleshooting",IDC_STATIC,7,73,318,99 - PUSHBUTTON "Change Preferences",IDC_CHANGE_PREFERENCES,14,85,91,15 - PUSHBUTTON "Open Preferences",IDC_OPEN_PREFERENCES,14,127,91,15 - LTEXT "Change the graphics API, sound API, and other settings that the game will use.", - IDC_STATIC,110,85,213,18 - PUSHBUTTON "Clear Preferences",IDC_CLEAR_PREFERENCES,14,106,91,15 - PUSHBUTTON "Clear Mappings",IDC_CLEAR_KEYMAPS,14,148,91,15 - EDITTEXT IDC_EDIT_INSTALLATION,16,51,210,12,ES_AUTOHSCROLL | - ES_READONLY - LTEXT "Erase all of your keyboard and joystick mappings if you've made a mistake.", - IDC_STATIC,109,148,213,18 - PUSHBUTTON "Launch Game",IDC_BUTTON_LAUNCH_GAME,183,263,76,14 - PUSHBUTTON "Languages",IDC_LANGUAGES,14,232,91,15 - LTEXT "Create a new or manage existing language translations.", - IDC_STATIC,109,232,213,20 - LTEXT "Open the preferences file to make changes by hand.", - IDC_STATIC,109,127,213,18 - LTEXT "Clear all preferences if you've made changes and the game won't start.", - IDC_STATIC,109,106,213,18 - CONTROL "",IDC_STATIC,"Static",SS_ETCHEDFRAME,0,33,331,1 - ICON IDR_MAINFRAME,IDC_STATIC_ICON,295,6,21,20,0, - WS_EX_TRANSPARENT -END - -IDD_ENTER_COMMENT DIALOGEX 0, 0, 324, 203 -STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Add A Comment" -FONT 8, "MS Sans Serif", 0, 0, 0x1 -BEGIN - LTEXT "You can add a message to display before a user installs your package.", - IDC_STATIC,7,7,252,18 - CONTROL "Show a comment",IDC_SHOW_A_COMMENT,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,19,39,185,12 - EDITTEXT IDC_EDIT,17,53,232,123,ES_MULTILINE | ES_AUTOHSCROLL - CONTROL "Don't display this dialog in the future",IDC_DONTASK, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,185,145,11 - DEFPUSHBUTTON "OK",IDOK,267,7,50,14 - PUSHBUTTON "Cancel",IDCANCEL,267,24,50,14 - GROUPBOX "Package Comment",IDC_STATIC,7,29,252,152 -END - -IDD_SHOW_COMMENT DIALOGEX 0, 0, 246, 186 -STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Package Comment" -FONT 8, "MS Sans Serif", 0, 0, 0x1 -BEGIN - EDITTEXT IDC_EDIT,7,7,232,137,ES_MULTILINE | ES_AUTOHSCROLL | - ES_READONLY - DEFPUSHBUTTON "OK",IDOK,72,165,50,14 - PUSHBUTTON "Cancel",IDCANCEL,128,165,50,14 - CONTROL "Don't display this dialog in the future",IDC_DONTSHOW, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,10,149,145,11 -END - -IDD_UNINSTALL_OLD_PACKAGES DIALOGEX 0, 0, 228, 152 -STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | - WS_SYSMENU -CAPTION "Uninstall Old Packages" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - DEFPUSHBUTTON "&Yes",IDOK,31,131,50,14 - PUSHBUTTON "Cancel",IDCANCEL,147,131,50,14 - LTEXT "The following packages are already installed. It is strongly recommended that they be deleted before installing this package.", - IDC_STATIC,7,7,214,27 - EDITTEXT IDC_PACKAGES,31,36,165,77,ES_MULTILINE | ES_AUTOHSCROLL | - ES_READONLY | WS_VSCROLL - PUSHBUTTON "&No",IDC_BUTTON1,87,131,49,14 - CTEXT "Delete old packages?",IDC_STATIC,31,117,166,12 -END - -IDD_CHANGE_GAME_SETTINGS DIALOGEX 0, 0, 162, 298 -STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Change Game Settings" -FONT 8, "MS Sans Serif", 0, 0, 0x0 -BEGIN - DEFPUSHBUTTON "OK",IDOK,49,276,50,14 - PUSHBUTTON "Cancel",IDCANCEL,104,276,50,14 - GROUPBOX "Graphics API",IDC_STATIC,7,7,147,66 - CONTROL "Default (recommended)",IDC_RADIO_DEFAULT,"Button", - BS_AUTORADIOBUTTON | WS_GROUP,21,22,129,12 - CONTROL "OpenGL",IDC_RADIO_OPENGL,"Button",BS_AUTORADIOBUTTON,21, - 38,129,12 - CONTROL "Direct3D",IDC_RADIO_DIRECT3D,"Button", - BS_AUTORADIOBUTTON,21,54,129,12 - GROUPBOX "Sound API",IDC_STATIC,7,77,147,100 - CONTROL "Default (recommended)",IDC_RADIO_SOUND_DEFAULT,"Button", - BS_AUTORADIOBUTTON | WS_GROUP,21,92,129,12 - CONTROL "DirectSound Hardware", - IDC_RADIO_SOUND_DIRECTSOUND_HARDWARE,"Button", - BS_AUTORADIOBUTTON,21,108,129,12 - CONTROL "DirectSound Software", - IDC_RADIO_SOUND_DIRECTSOUND_SOFTWARE,"Button", - BS_AUTORADIOBUTTON,21,124,129,12 - CONTROL "WaveOut",IDC_RADIO_SOUND_WAVEOUT,"Button", - BS_AUTORADIOBUTTON,21,140,129,12 - CONTROL "Null (no sound)",IDC_RADIO_SOUND_NULL,"Button", - BS_AUTORADIOBUTTON,21,156,129,12 - GROUPBOX "Other",IDC_STATIC,7,181,147,62 - CONTROL "Log to Disk",IDC_CHECK_LOG_TO_DISK,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,21,210,129,10 - CONTROL "Show Log Window",IDC_CHECK_SHOW_LOG_WINDOW,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,21,225,129,10 - LTEXT "Tip: Change these only if you experience problems when using the default settings.", - IDC_STATIC,7,247,147,26 - CONTROL "Force 60Hz Refresh",IDC_CHECK_FORCE_60HZ,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,21,195,129,10 -END - -IDD_LANGUAGES DIALOGEX 0, 0, 337, 189 -STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | - WS_SYSMENU -CAPTION "Language Translations" -FONT 8, "MS Shell Dlg", 400, 0, 0x1 -BEGIN - DEFPUSHBUTTON "Close",IDOK,280,168,50,14 - LTEXT "Themes",IDC_STATIC,7,7,101,10 - LTEXT "Languages",IDC_STATIC,118,7,98,10 - PUSHBUTTON "Create Language",IDC_BUTTON_CREATE,230,41,91,15 - PUSHBUTTON "Delete Language",IDC_BUTTON_DELETE,230,62,91,15 - PUSHBUTTON "Export CSV",IDC_BUTTON_EXPORT,230,83,91,15 - PUSHBUTTON "Import CSV",IDC_BUTTON_IMPORT,230,123,91,15 - LTEXT "1) Create a new language\n2) Export the theme strings to a CSV\n3) Edit the CSV using Excel or a text editor\n4) Import the CSV file back into the same language", - IDC_STATIC,7,145,258,37 - LTEXT "Selection details",IDC_STATIC,230,7,100,9 - LTEXT "Total Strings:",IDC_STATIC,221,17,89,10 - LTEXT "Need translation:",IDC_STATIC,221,28,89,10 - LTEXT "",IDC_STATIC_TOTAL_STRINGS,307,18,26,10 - LTEXT "",IDC_STATIC_NEED_TRANSLATION,307,27,26,10 - LISTBOX IDC_LIST_THEMES,7,18,102,121,LBS_SORT | - LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP - LISTBOX IDC_LIST_LANGUAGES,116,17,100,121,LBS_SORT | - LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP - CONTROL "Export already translated strings", - IDC_CHECK_EXPORT_ALREADY_TRANSLATED,"Button", - BS_AUTOCHECKBOX | BS_MULTILINE | WS_TABSTOP,221,100,109, - 16 - PUSHBUTTON "Check Language",IDC_CHECK_LANGUAGE,230,143,91,13 -END - -IDD_CREATE_LANGUAGE DIALOGEX 0, 0, 191, 47 -STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | - WS_SYSMENU -CAPTION "Create Language" -FONT 8, "MS Shell Dlg", 400, 0, 0x1 -BEGIN - DEFPUSHBUTTON "OK",IDOK,128,7,56,14 - PUSHBUTTON "Cancel",IDCANCEL,128,27,56,14 - LTEXT "Choose a language",IDC_STATIC,7,7,110,11 - COMBOBOX IDC_COMBO_LANGUAGES,17,24,100,110,CBS_DROPDOWNLIST | - CBS_SORT | WS_VSCROLL | WS_TABSTOP -END - - -///////////////////////////////////////////////////////////////////////////// -// -// Version -// - -VS_VERSION_INFO VERSIONINFO - FILEVERSION 1,0,0,1 - PRODUCTVERSION 1,0,0,1 - FILEFLAGSMASK 0x3fL -#ifdef _DEBUG - FILEFLAGS 0x1L -#else - FILEFLAGS 0x0L -#endif - FILEOS 0x4L - FILETYPE 0x1L - FILESUBTYPE 0x0L -BEGIN - BLOCK "StringFileInfo" - BEGIN - BLOCK "040904b0" - BEGIN - VALUE "FileDescription", "StepMania Tools" - VALUE "FileVersion", "1, 0, 0, 1" - VALUE "InternalName", "smpackage" - VALUE "LegalCopyright", "Copyright (C) StepMania team" - VALUE "OriginalFilename", "tools.exe" - VALUE "ProductName", "StepMania Tools" - VALUE "ProductVersion", "1, 0, 0, 1" - END - END - BLOCK "VarFileInfo" - BEGIN - VALUE "Translation", 0x409, 1200 - END -END - - -///////////////////////////////////////////////////////////////////////////// -// -// DESIGNINFO -// - -#ifdef APSTUDIO_INVOKED -GUIDELINES DESIGNINFO -BEGIN - IDD_INSTALL, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 325 - TOPMARGIN, 7 - BOTTOMMARGIN, 227 - END - - IDD_EXPORTER, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 341 - TOPMARGIN, 7 - BOTTOMMARGIN, 215 - END - - IDD_DIALOG_NAME, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 254 - TOPMARGIN, 7 - BOTTOMMARGIN, 51 - END - - IDD_EDIT_INSTALLATIONS, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 235 - TOPMARGIN, 7 - BOTTOMMARGIN, 213 - END - - IDD_MENU, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 325 - TOPMARGIN, 7 - BOTTOMMARGIN, 277 - END - - IDD_ENTER_COMMENT, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 317 - TOPMARGIN, 7 - BOTTOMMARGIN, 196 - END - - IDD_SHOW_COMMENT, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 239 - TOPMARGIN, 7 - BOTTOMMARGIN, 179 - END - - IDD_UNINSTALL_OLD_PACKAGES, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 221 - TOPMARGIN, 7 - BOTTOMMARGIN, 145 - END - - IDD_CHANGE_GAME_SETTINGS, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 154 - TOPMARGIN, 7 - BOTTOMMARGIN, 290 - END - - IDD_LANGUAGES, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 330 - TOPMARGIN, 7 - BOTTOMMARGIN, 182 - END - - IDD_CREATE_LANGUAGE, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 184 - TOPMARGIN, 7 - BOTTOMMARGIN, 40 - END -END -#endif // APSTUDIO_INVOKED - -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// - - - -#ifndef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 3 resource. -// -#define _AFX_NO_SPLITTER_RESOURCES -#define _AFX_NO_OLE_RESOURCES -#define _AFX_NO_TRACKER_RESOURCES -#define _AFX_NO_PROPERTY_RESOURCES - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) -#ifdef _WIN32 -LANGUAGE 9, 1 -#pragma code_page(1252) -#endif //_WIN32 -#include "res\smpackage.rc2" // non-Microsoft Visual C++ edited resources -#include "afxres.rc" // Standard components -#endif - -///////////////////////////////////////////////////////////////////////////// -#endif // not APSTUDIO_INVOKED - +// Microsoft Visual C++ generated resource script. +// +#include "resource.h" + +#define APSTUDIO_READONLY_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 2 resource. +// +#include "afxres.h" + +///////////////////////////////////////////////////////////////////////////// +#undef APSTUDIO_READONLY_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +// English (U.S.) resources + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) +#ifdef _WIN32 +LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US +#pragma code_page(1252) +#endif //_WIN32 + +#ifdef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// TEXTINCLUDE +// + +1 TEXTINCLUDE +BEGIN + "resource.h\0" +END + +2 TEXTINCLUDE +BEGIN + "#include ""afxres.h""\r\n" + "\0" +END + +3 TEXTINCLUDE +BEGIN + "#define _AFX_NO_SPLITTER_RESOURCES\r\n" + "#define _AFX_NO_OLE_RESOURCES\r\n" + "#define _AFX_NO_TRACKER_RESOURCES\r\n" + "#define _AFX_NO_PROPERTY_RESOURCES\r\n" + "\r\n" + "#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)\r\n" + "#ifdef _WIN32\r\n" + "LANGUAGE 9, 1\r\n" + "#pragma code_page(1252)\r\n" + "#endif //_WIN32\r\n" + "#include ""res\\smpackage.rc2"" // non-Microsoft Visual C++ edited resources\r\n" + "#include ""afxres.rc"" // Standard components\r\n" + "#endif\r\n" + "\0" +END + +#endif // APSTUDIO_INVOKED + + +///////////////////////////////////////////////////////////////////////////// +// +// Icon +// + +// Icon with lowest ID value placed first to ensure application icon +// remains consistent on all systems. +IDR_MAINFRAME ICON "smpackage.ICO" + +///////////////////////////////////////////////////////////////////////////// +// +// Dialog +// + +IDD_INSTALL DIALOGEX 0, 0, 332, 234 +STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION +CAPTION "Install a package" +FONT 8, "MS Sans Serif", 0, 0, 0x1 +BEGIN + EDITTEXT IDC_EDIT_MESSAGE1,7,57,320,14,ES_MULTILINE | + ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER | NOT + WS_TABSTOP + DEFPUSHBUTTON "Finish >",IDOK,200,215,55,15 + PUSHBUTTON "Cancel",IDCANCEL,275,215,50,15 + PUSHBUTTON "< Back",IDC_BUTTON_BACK,145,215,55,15,WS_DISABLED + EDITTEXT IDC_EDIT_MESSAGE2,5,90,320,87,ES_MULTILINE | + ES_AUTOHSCROLL | ES_READONLY | WS_VSCROLL | NOT + WS_TABSTOP + COMBOBOX IDC_COMBO_DIR,22,195,204,105,CBS_DROPDOWNLIST | + WS_VSCROLL | WS_TABSTOP + PUSHBUTTON "Edit Installations",IDC_BUTTON_EDIT,233,194,85,14 + CONTROL "",IDC_PROGRESS1,"msctls_progress32",NOT WS_VISIBLE | + WS_BORDER,7,72,318,14 + LTEXT "You have chosen to install the package:", + IDC_STATIC_MESSAGE1,7,41,318,10 + LTEXT "This package contains the following files:", + IDC_STATIC_MESSAGE2,7,76,318,10 + LTEXT "The package will be installed in the following program folder:", + IDC_STATIC,7,181,318,10 + CONTROL "",IDC_STATIC,"Static",SS_WHITERECT,0,0,331,33 + LTEXT "Install a package",IDC_STATIC_HEADER_TEXT,6,4,273,20 + CONTROL "",IDC_STATIC,"Static",SS_ETCHEDFRAME,0,33,331,1 + ICON IDR_MAINFRAME,IDC_STATIC_ICON,295,6,21,20,0, + WS_EX_TRANSPARENT +END + +IDD_EXPORTER DIALOGEX 0, 0, 349, 222 +STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | + WS_VISIBLE | WS_CAPTION | WS_SYSMENU +EXSTYLE WS_EX_APPWINDOW +CAPTION "Export Packages" +FONT 8, "MS Sans Serif", 0, 0, 0x1 +BEGIN + DEFPUSHBUTTON "Close",IDOK,284,201,57,14 + PUSHBUTTON "Launch Game",IDC_BUTTON_PLAY,7,200,70,15 + PUSHBUTTON "Export As One",IDC_BUTTON_EXPORT_AS_ONE,255,87,86,15 + PUSHBUTTON "Export As Individual",IDC_BUTTON_EXPORT_AS_INDIVIDUAL, + 255,120,86,15 + CONTROL "Tree2",IDC_TREE,"SysTreeView32",TVS_HASBUTTONS | + TVS_HASLINES | TVS_LINESATROOT | TVS_CHECKBOXES | + WS_BORDER | WS_TABSTOP,7,43,239,151 + COMBOBOX IDC_COMBO_DIR,16,17,229,105,CBS_DROPDOWNLIST | + WS_VSCROLL | WS_TABSTOP + PUSHBUTTON "Edit Installations",IDC_BUTTON_EDIT,250,16,85,14 + PUSHBUTTON "Open Program Folder",IDC_BUTTON_OPEN,88,200,93,15 + GROUPBOX "Installation",IDC_STATIC,7,7,334,29 +END + +IDD_DIALOG_NAME DIALOGEX 0, 0, 261, 58 +STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Name Your Package" +FONT 8, "MS Sans Serif", 0, 0, 0x0 +BEGIN + LTEXT "Enter a name for your new package:",IDC_STATIC,7,7,188, + 12 + EDITTEXT IDC_EDIT,17,20,178,13,ES_AUTOHSCROLL + DEFPUSHBUTTON "OK",IDOK,200,7,54,14 + PUSHBUTTON "Cancel",IDCANCEL,200,24,54,14 + LTEXT "Note: leave off the "".smzip"" extension",IDC_STATIC,18, + 38,179,12 +END + +IDD_EDIT_INSTALLATIONS DIALOGEX 0, 0, 243, 221 +STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Edit Installations" +FONT 8, "MS Sans Serif", 0, 0, 0x0 +BEGIN + DEFPUSHBUTTON "OK",IDOK,125,199,50,14 + PUSHBUTTON "Cancel",IDCANCEL,185,199,50,14 + LISTBOX IDC_LIST,17,30,136,80,LBS_NOINTEGRALHEIGHT | WS_VSCROLL | + WS_TABSTOP + EDITTEXT IDC_EDIT,19,167,136,13,ES_AUTOHSCROLL + PUSHBUTTON "Add",IDC_BUTTON_ADD,165,167,50,14 + PUSHBUTTON "Remove",IDC_BUTTON_REMOVE,160,54,68,15,WS_DISABLED + PUSHBUTTON "Make Default",IDC_BUTTON_MAKE_DEFAULT,160,34,68,15, + WS_DISABLED + GROUPBOX "Add New Installation",IDC_STATIC,7,130,228,59 + GROUPBOX "Current Installations",IDC_STATIC,7,7,228,114 + LTEXT "Enter the complete path to a StepMania or DWI installation\r\ne.g. ""C:\\Program Files\\StepMania""", + IDC_STATIC,18,144,196,17 + LTEXT "The top installation is the default.",IDC_STATIC,19,17, + 196,12 +END + +IDD_MENU DIALOGEX 0, 0, 332, 284 +STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "StepMania Tools Main Menu" +FONT 8, "MS Sans Serif", 0, 0, 0x1 +BEGIN + CONTROL "",IDC_STATIC,"Static",SS_WHITERECT,0,0,331,33 + LTEXT "StepMania Tools Main Menu",IDC_STATIC_HEADER_TEXT,6,4, + 273,20 + DEFPUSHBUTTON "Exit",IDOK,275,263,50,14 + GROUPBOX "Installation",IDC_STATIC,7,41,318,28 + PUSHBUTTON "Edit Installations",IDC_EDIT_INSTALLATIONS,233,49,83,15 + GROUPBOX "Create and Share",IDC_STATIC,7,176,318,78 + PUSHBUTTON "Export Packages",IDC_EXPORT_PACKAGES,14,190,91,15 + LTEXT "Create .smzip package files to share with other users.", + IDC_STATIC,109,190,213,18 + PUSHBUTTON "Create Song",IDC_CREATE_SONG,14,211,91,15 + LTEXT "Create a new song in from your favorite mp3 or ogg music file.", + IDC_STATIC,109,211,213,20 + GROUPBOX "Troubleshooting",IDC_STATIC,7,73,318,99 + PUSHBUTTON "Change Preferences",IDC_CHANGE_PREFERENCES,14,85,91,15 + PUSHBUTTON "Open Preferences",IDC_OPEN_PREFERENCES,14,127,91,15 + LTEXT "Change the graphics API, sound API, and other settings that the game will use.", + IDC_STATIC,110,85,213,18 + PUSHBUTTON "Clear Preferences",IDC_CLEAR_PREFERENCES,14,106,91,15 + PUSHBUTTON "Clear Mappings",IDC_CLEAR_KEYMAPS,14,148,91,15 + EDITTEXT IDC_EDIT_INSTALLATION,16,51,210,12,ES_AUTOHSCROLL | + ES_READONLY + LTEXT "Erase all of your keyboard and joystick mappings if you've made a mistake.", + IDC_STATIC,109,148,213,18 + PUSHBUTTON "Launch Game",IDC_BUTTON_LAUNCH_GAME,183,263,76,14 + PUSHBUTTON "Languages",IDC_LANGUAGES,14,232,91,15 + LTEXT "Create a new or manage existing language translations.", + IDC_STATIC,109,232,213,20 + LTEXT "Open the preferences file to make changes by hand.", + IDC_STATIC,109,127,213,18 + LTEXT "Clear all preferences if you've made changes and the game won't start.", + IDC_STATIC,109,106,213,18 + CONTROL "",IDC_STATIC,"Static",SS_ETCHEDFRAME,0,33,331,1 + ICON IDR_MAINFRAME,IDC_STATIC_ICON,295,6,21,20,0, + WS_EX_TRANSPARENT +END + +IDD_ENTER_COMMENT DIALOGEX 0, 0, 324, 203 +STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Add A Comment" +FONT 8, "MS Sans Serif", 0, 0, 0x1 +BEGIN + LTEXT "You can add a message to display before a user installs your package.", + IDC_STATIC,7,7,252,18 + CONTROL "Show a comment",IDC_SHOW_A_COMMENT,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,19,39,185,12 + EDITTEXT IDC_EDIT,17,53,232,123,ES_MULTILINE | ES_AUTOHSCROLL + CONTROL "Don't display this dialog in the future",IDC_DONTASK, + "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,185,145,11 + DEFPUSHBUTTON "OK",IDOK,267,7,50,14 + PUSHBUTTON "Cancel",IDCANCEL,267,24,50,14 + GROUPBOX "Package Comment",IDC_STATIC,7,29,252,152 +END + +IDD_SHOW_COMMENT DIALOGEX 0, 0, 246, 186 +STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Package Comment" +FONT 8, "MS Sans Serif", 0, 0, 0x1 +BEGIN + EDITTEXT IDC_EDIT,7,7,232,137,ES_MULTILINE | ES_AUTOHSCROLL | + ES_READONLY + DEFPUSHBUTTON "OK",IDOK,72,165,50,14 + PUSHBUTTON "Cancel",IDCANCEL,128,165,50,14 + CONTROL "Don't display this dialog in the future",IDC_DONTSHOW, + "Button",BS_AUTOCHECKBOX | WS_TABSTOP,10,149,145,11 +END + +IDD_UNINSTALL_OLD_PACKAGES DIALOGEX 0, 0, 228, 152 +STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | + WS_SYSMENU +CAPTION "Uninstall Old Packages" +FONT 8, "MS Shell Dlg", 0, 0, 0x0 +BEGIN + DEFPUSHBUTTON "&Yes",IDOK,31,131,50,14 + PUSHBUTTON "Cancel",IDCANCEL,147,131,50,14 + LTEXT "The following packages are already installed. It is strongly recommended that they be deleted before installing this package.", + IDC_STATIC,7,7,214,27 + EDITTEXT IDC_PACKAGES,31,36,165,77,ES_MULTILINE | ES_AUTOHSCROLL | + ES_READONLY | WS_VSCROLL + PUSHBUTTON "&No",IDC_BUTTON1,87,131,49,14 + CTEXT "Delete old packages?",IDC_STATIC,31,117,166,12 +END + +IDD_CHANGE_GAME_SETTINGS DIALOGEX 0, 0, 162, 298 +STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Change Game Settings" +FONT 8, "MS Sans Serif", 0, 0, 0x0 +BEGIN + DEFPUSHBUTTON "OK",IDOK,49,276,50,14 + PUSHBUTTON "Cancel",IDCANCEL,104,276,50,14 + GROUPBOX "Graphics API",IDC_STATIC,7,7,147,66 + CONTROL "Default (recommended)",IDC_RADIO_DEFAULT,"Button", + BS_AUTORADIOBUTTON | WS_GROUP,21,22,129,12 + CONTROL "OpenGL",IDC_RADIO_OPENGL,"Button",BS_AUTORADIOBUTTON,21, + 38,129,12 + CONTROL "Direct3D",IDC_RADIO_DIRECT3D,"Button", + BS_AUTORADIOBUTTON,21,54,129,12 + GROUPBOX "Sound API",IDC_STATIC,7,77,147,100 + CONTROL "Default (recommended)",IDC_RADIO_SOUND_DEFAULT,"Button", + BS_AUTORADIOBUTTON | WS_GROUP,21,92,129,12 + CONTROL "DirectSound Hardware", + IDC_RADIO_SOUND_DIRECTSOUND_HARDWARE,"Button", + BS_AUTORADIOBUTTON,21,108,129,12 + CONTROL "DirectSound Software", + IDC_RADIO_SOUND_DIRECTSOUND_SOFTWARE,"Button", + BS_AUTORADIOBUTTON,21,124,129,12 + CONTROL "WaveOut",IDC_RADIO_SOUND_WAVEOUT,"Button", + BS_AUTORADIOBUTTON,21,140,129,12 + CONTROL "Null (no sound)",IDC_RADIO_SOUND_NULL,"Button", + BS_AUTORADIOBUTTON,21,156,129,12 + GROUPBOX "Other",IDC_STATIC,7,181,147,62 + CONTROL "Log to Disk",IDC_CHECK_LOG_TO_DISK,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,21,210,129,10 + CONTROL "Show Log Window",IDC_CHECK_SHOW_LOG_WINDOW,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,21,225,129,10 + LTEXT "Tip: Change these only if you experience problems when using the default settings.", + IDC_STATIC,7,247,147,26 + CONTROL "Force 60Hz Refresh",IDC_CHECK_FORCE_60HZ,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,21,195,129,10 +END + +IDD_LANGUAGES DIALOGEX 0, 0, 337, 189 +STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | + WS_SYSMENU +CAPTION "Language Translations" +FONT 8, "MS Shell Dlg", 400, 0, 0x1 +BEGIN + DEFPUSHBUTTON "Close",IDOK,280,168,50,14 + LTEXT "Themes",IDC_STATIC,7,7,101,10 + LTEXT "Languages",IDC_STATIC,118,7,98,10 + PUSHBUTTON "Create Language",IDC_BUTTON_CREATE,230,41,91,15 + PUSHBUTTON "Delete Language",IDC_BUTTON_DELETE,230,62,91,15 + PUSHBUTTON "Export CSV",IDC_BUTTON_EXPORT,230,83,91,15 + PUSHBUTTON "Import CSV",IDC_BUTTON_IMPORT,230,123,91,15 + LTEXT "1) Create a new language\n2) Export the theme strings to a CSV\n3) Edit the CSV using Excel or a text editor\n4) Import the CSV file back into the same language", + IDC_STATIC,7,145,258,37 + LTEXT "Selection details",IDC_STATIC,230,7,100,9 + LTEXT "Total Strings:",IDC_STATIC,221,17,89,10 + LTEXT "Need translation:",IDC_STATIC,221,28,89,10 + LTEXT "",IDC_STATIC_TOTAL_STRINGS,307,18,26,10 + LTEXT "",IDC_STATIC_NEED_TRANSLATION,307,27,26,10 + LISTBOX IDC_LIST_THEMES,7,18,102,121,LBS_SORT | + LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP + LISTBOX IDC_LIST_LANGUAGES,116,17,100,121,LBS_SORT | + LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP + CONTROL "Export already translated strings", + IDC_CHECK_EXPORT_ALREADY_TRANSLATED,"Button", + BS_AUTOCHECKBOX | BS_MULTILINE | WS_TABSTOP,221,100,109, + 16 + PUSHBUTTON "Check Language",IDC_CHECK_LANGUAGE,230,143,91,13 +END + +IDD_CREATE_LANGUAGE DIALOGEX 0, 0, 191, 47 +STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | + WS_SYSMENU +CAPTION "Create Language" +FONT 8, "MS Shell Dlg", 400, 0, 0x1 +BEGIN + DEFPUSHBUTTON "OK",IDOK,128,7,56,14 + PUSHBUTTON "Cancel",IDCANCEL,128,27,56,14 + LTEXT "Choose a language",IDC_STATIC,7,7,110,11 + COMBOBOX IDC_COMBO_LANGUAGES,17,24,100,110,CBS_DROPDOWNLIST | + CBS_SORT | WS_VSCROLL | WS_TABSTOP +END + + +///////////////////////////////////////////////////////////////////////////// +// +// Version +// + +VS_VERSION_INFO VERSIONINFO + FILEVERSION 1,0,0,1 + PRODUCTVERSION 1,0,0,1 + FILEFLAGSMASK 0x3fL +#ifdef _DEBUG + FILEFLAGS 0x1L +#else + FILEFLAGS 0x0L +#endif + FILEOS 0x4L + FILETYPE 0x1L + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904b0" + BEGIN + VALUE "FileDescription", "StepMania Tools" + VALUE "FileVersion", "1, 0, 0, 1" + VALUE "InternalName", "smpackage" + VALUE "LegalCopyright", "Copyright (C) StepMania team" + VALUE "OriginalFilename", "tools.exe" + VALUE "ProductName", "StepMania Tools" + VALUE "ProductVersion", "1, 0, 0, 1" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END + + +///////////////////////////////////////////////////////////////////////////// +// +// DESIGNINFO +// + +#ifdef APSTUDIO_INVOKED +GUIDELINES DESIGNINFO +BEGIN + IDD_INSTALL, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 325 + TOPMARGIN, 7 + BOTTOMMARGIN, 227 + END + + IDD_EXPORTER, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 341 + TOPMARGIN, 7 + BOTTOMMARGIN, 215 + END + + IDD_DIALOG_NAME, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 254 + TOPMARGIN, 7 + BOTTOMMARGIN, 51 + END + + IDD_EDIT_INSTALLATIONS, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 235 + TOPMARGIN, 7 + BOTTOMMARGIN, 213 + END + + IDD_MENU, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 325 + TOPMARGIN, 7 + BOTTOMMARGIN, 277 + END + + IDD_ENTER_COMMENT, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 317 + TOPMARGIN, 7 + BOTTOMMARGIN, 196 + END + + IDD_SHOW_COMMENT, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 239 + TOPMARGIN, 7 + BOTTOMMARGIN, 179 + END + + IDD_UNINSTALL_OLD_PACKAGES, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 221 + TOPMARGIN, 7 + BOTTOMMARGIN, 145 + END + + IDD_CHANGE_GAME_SETTINGS, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 154 + TOPMARGIN, 7 + BOTTOMMARGIN, 290 + END + + IDD_LANGUAGES, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 330 + TOPMARGIN, 7 + BOTTOMMARGIN, 182 + END + + IDD_CREATE_LANGUAGE, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 184 + TOPMARGIN, 7 + BOTTOMMARGIN, 40 + END +END +#endif // APSTUDIO_INVOKED + +#endif // English (U.S.) resources +///////////////////////////////////////////////////////////////////////////// + + + +#ifndef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 3 resource. +// +#define _AFX_NO_SPLITTER_RESOURCES +#define _AFX_NO_OLE_RESOURCES +#define _AFX_NO_TRACKER_RESOURCES +#define _AFX_NO_PROPERTY_RESOURCES + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) +#ifdef _WIN32 +LANGUAGE 9, 1 +#pragma code_page(1252) +#endif //_WIN32 +#include "res\smpackage.rc2" // non-Microsoft Visual C++ edited resources +#include "afxres.rc" // Standard components +#endif + +///////////////////////////////////////////////////////////////////////////// +#endif // not APSTUDIO_INVOKED + diff --git a/src/smpackage/smpackageUtil.h b/src/smpackagee/smpackageUtil.h similarity index 100% rename from src/smpackage/smpackageUtil.h rename to src/smpackagee/smpackageUtil.h diff --git a/src/tests/00 README b/src/tests/00 README deleted file mode 100644 index c647e972ea..0000000000 --- a/src/tests/00 README +++ /dev/null @@ -1,15 +0,0 @@ -This file contains test sets. - -Currently, all we have is test_audio_readers, which tests the MP3, WAV and Ogg -file readers. - -Once I create smaller test inputs, I'll commit them; the current set is about -30 megs. Until then, if you want to try this, edit the source to point it at -files you have. - -This is only compiled in the Unix build environment. - -test_vector is for testing VectorHelper against the reference scalar -code. It can be compiled using: -g++ -g -I.. ../archutils/Darwin/VectorHelper.cpp test_vector.cpp -faltivec -You can replace -faltivec with -msse2 on intel. Might requires -O3 to inline. diff --git a/src/tests/test_audio_readers.cpp b/src/tests/test_audio_readers.cpp deleted file mode 100644 index c56300968a..0000000000 --- a/src/tests/test_audio_readers.cpp +++ /dev/null @@ -1,646 +0,0 @@ -#include "global.h" -#include "RageLog.h" -#include "RageSoundReader_MP3.h" -#include "RageTimer.h" -#include "RageUtil.h" -#include "RageSoundReader_Preload.h" -#include "RageSoundReader_Resample_Good.h" - -#include "test_misc.h" -#include -#include -#include -#include - -void -ReadData(RageSoundReader* pReader, - int iFrame, /* start */ - float* pBuf, /* out */ - int iFrames) -{ - if (iFrame != -1) - pReader->SetPosition(iFrame); - int got = pReader->Read(pBuf, iFrames); - ASSERT_M(got == iFrames, ssprintf("%i, %i", got, iFrames)); -} - -void -find(const char* haystack, int hs, const char* needle, int ns) -{ - for (int i = 0; i <= hs - ns; ++i) { - if (!memcmp(haystack + i, needle, ns)) { - printf("xx %i\n", i); - return; - } - } -} - -void -dump_bin(const char* fn, const char* buf, int size) -{ - int fd = open(fn, O_WRONLY | O_CREAT | O_TRUNC); - ASSERT(fd != -1); - write(fd, buf, size); - close(fd); -} - -void -dump(const char* fn, const int16_t* buf, int samples) -{ - FILE* f = fopen(fn, "w+"); - ASSERT(f); - - int cnt = 0; - for (int i = 0; i < samples; ++i) { - fprintf(f, "0x%04hx,", buf[i]); - if (cnt++ == 16) { - fprintf(f, "\n"); - cnt = 0; - } - } - - fclose(f); -} - -void -dump(const char* buf, int size) -{ - for (int i = 0; i < size; ++i) - printf("%-2.2x ", ((unsigned char*)buf)[i]); - printf("\n\n"); -} - -void -dump(const int16_t* buf, int samples) -{ - for (int i = 0; i < samples; ++i) - printf("0x%04hx,", buf[i]); - printf("\n"); -} - -void -dump(const float* buf, int samples) -{ - for (int i = 0; i < samples; ++i) - printf("0x%04lx,", lrintf(buf[i] * 32768)); - printf("\n"); -} - -bool -compare(const float* m1, const int16_t* m2, int iSamples) -{ - for (int i = 0; i < iSamples; ++i) { - int16_t iSample1 = lrintf(m1[i] * 32768); - if (iSample1 != m2[i]) - return false; - } - - return true; -} - -void -compare_buffers(const int16_t* expect, - const int16_t* got, - int frames, - int& NumInaccurateSamplesAtStart, - int& NumInaccurateSamples) -{ - bool InaccurateSinceStart = true; - - NumInaccurateSamplesAtStart = 0; - NumInaccurateSamples = 0; - - for (int i = 0; i < frames; ++i) { - int diff = abs(expect[i] - got[i]); - if (diff > 200) { - printf("%i\n", diff); - ++NumInaccurateSamples; - if (InaccurateSinceStart) - ++NumInaccurateSamplesAtStart; - } else - InaccurateSinceStart = false; - } -} - -bool -compare_buffers(const int16_t* expect, - const int16_t* got, - int frames, - int channels) -{ - /* - * Compare each channel separately. Try to figure out if - * the data is exactly the same, - * - * 2: either the source or dest data starts out around 0 and converges - * quickly on the other; this happens with resamplers after a seek, since - * they're missing data before the seeked position (could be fixed) - * - * When seeking, resamplers should ideally seek slightly before the - * requested position, read the extra data, feed it to the resampling - * engine, and discard the extra data. Otherwise, the resampler is starting - * with no data, and will give some low samples. (The amount of incorrect - * data depends on the window size of the resampler.) Detect if this - * happens: determine if the data starts very inaccurately and quickly - * converges. - * - * Determine if data is identical, but offset. - * - */ - - int NumInaccurateSamples; - int NumInaccurateSamplesAtStart; - compare_buffers( - expect, got, frames, NumInaccurateSamplesAtStart, NumInaccurateSamples); - - printf("%i/%i off, %i at start\n", - NumInaccurateSamples, - frames, - NumInaccurateSamplesAtStart); - return NumInaccurateSamples == 0; -} - -bool -test_read(RageSoundReader* snd, float* expected_data, int frames) -{ - int samples = frames * snd->GetNumChannels(); - float buf[samples]; - int got = snd->Read(buf, frames); - ASSERT(got == frames); - - // compare_buffers( (const int16_t *) expected_data, - // (const int16_t *) buf, - // bytes/2, - // 2 ); - - bool bMatches = true; - for (int i = 0; i < samples; ++i) - if (fabsf(buf[i] - expected_data[i]) > 0.00001f) - bMatches = false; - if (bMatches) - return true; - - dump(expected_data, min(100, samples)); - dump(buf, min(100, samples)); - return false; -} - -bool -must_be_eof(RageSoundReader* snd) -{ - float buf[16]; - int got = snd->Read(buf, 1); - return got == RageSoundReader::END_OF_FILE; -} - -const int FILTER_NONE = 0; -const int FILTER_PRELOAD = 1 << 0; -const int FILTER_RESAMPLE_FAST = 1 << 1; - -RageSoundReader* -ApplyFilters(RageSoundReader* s, int filters) -{ - if (filters & FILTER_PRELOAD) { - RageSoundReader_Preload* r = new RageSoundReader_Preload(); - if (r->Open(s)) - s = r; - else { - printf("Didn't preload\n"); - delete r; - } - } - - if (filters & FILTER_RESAMPLE_FAST) { - RageSoundReader_Resample_Good* r = - new RageSoundReader_Resample_Good(s, 10000); - s = r; - } - - return s; -} - -bool -CheckSetPositionAccurate(RageSoundReader* snd) -{ - snd->SetProperty("AccurateSync", true); - - const int one_second = snd->GetSampleRate(); - float data[one_second * snd->GetNumChannels()]; - - int iFrame = snd->GetSampleRate() * 100 / 1000; // 100ms - ReadData(snd, iFrame, data, one_second / 10); - - snd->SetPosition(iFrame * 100); - snd->SetPosition(iFrame); - if (!test_read(snd, data, one_second / 10)) { - LOG->Warn("Fail: rewind didn't work"); - return false; - } - - return true; -} - -int -FramesOfSilence(const float* data, int frames, int iChannels) -{ - int SilentFrames = 0; - while (SilentFrames < frames) { - for (int c = 0; c < iChannels; ++c) - if (fabsf(*data++) > (1 / 65536.0f)) - return SilentFrames; - ++SilentFrames; - } - return SilentFrames; -} - -/* The number of frames we compare against expected data: */ -const int TestDataSize = 2; - -/* Find "haystack" in "needle". Start looking at "expect" and move outward; - * find the closest. */ -void* -xmemsearch(const float* haystack, - size_t iHaystackSamples, - const int16_t* needle, - size_t iNeedleSamples, - int expect) -{ - if (!iNeedleSamples) - return (void*)haystack; - - const float* pHaystackEnd = haystack + iHaystackSamples; - - int out_len = 0; - while (1) { - const float* hay_early = haystack + expect - out_len; - const float* hay_late = haystack + expect + out_len; - if (hay_early >= haystack && - hay_early + iNeedleSamples < pHaystackEnd) { - if (compare(hay_early, needle, iNeedleSamples)) - return (void*)hay_early; - } - - if (hay_late >= haystack && hay_late + iNeedleSamples < pHaystackEnd) { - if (compare(hay_late, needle, iNeedleSamples)) - return (void*)hay_late; - } - - if (hay_early < haystack && hay_late + iNeedleSamples >= pHaystackEnd) - break; - - ++out_len; - } - - return NULL; -} - -struct TestFile -{ - const char* fn; - - /* The number of silent frames we expect: */ - int SilentFrames; - - /* The first two frames (four samples): */ - int16_t initial[TestDataSize * 2]; - - /* Frames of data half a second in: */ - int16_t later[TestDataSize * 2]; -}; -const int channels = 2; - -bool -RunTests(RageSoundReader* snd, const TestFile& tf) -{ - const char* fn = tf.fn; - { - float len = snd->GetLength(); - // printf("%f\n", len); - if (len < 1000.0f) { - LOG->Warn("Test file %s is too short", fn); - return false; - } - } - - /* Read the first second of the file. Do this without calling any - * seek functions. */ - const int one_second_frames = snd->GetSampleRate(); - const int one_second_samples = one_second_frames * snd->GetNumChannels(); - const int one_second_bytes = one_second_samples * sizeof(float); - float sdata[one_second_frames * snd->GetNumChannels()]; - char* data = (char*)sdata; - memset(data, 0x42, one_second_bytes); - ReadData(snd, -1, sdata, one_second_frames); - - { - /* Find out how many frames of silence we have. */ - int SilentFrames = - FramesOfSilence(sdata, one_second_frames, snd->GetNumChannels()); - - const float* InitialData = sdata + SilentFrames * snd->GetNumChannels(); - const int InitialDataSize = one_second_frames - SilentFrames; - - if (InitialDataSize < (int)sizeof(tf.initial)) { - LOG->Warn( - "Not enough (%i<%i) data to check after %i frames of silence", - InitialDataSize, - sizeof(tf.initial), - SilentFrames); - return false; - } - - bool bFailed = false; - if (SilentFrames != tf.SilentFrames) { - LOG->Trace("Expected %i silence, got %i (%i too high)", - tf.SilentFrames, - SilentFrames, - SilentFrames - tf.SilentFrames); - bFailed = true; - } - - bool Identical = !compare(InitialData, tf.initial, sizeof(tf.initial)); - if (!Identical) { - LOG->Trace("Expected data:"); - dump(tf.initial, ARRAYLEN(tf.initial)); - LOG->Trace(" "); - bFailed = true; - } - - if (bFailed) { - LOG->Trace("Got data:"); - dump(InitialData, min(16, 2 * InitialDataSize)); - } - - const int LaterOffsetFrames = one_second_frames / 2; /* half second */ - const int LaterOffsetSamples = - LaterOffsetFrames * snd->GetNumChannels(); - const float* LaterData = sdata + LaterOffsetSamples; - Identical = !compare(LaterData, tf.later, sizeof(tf.later)); - if (!Identical) { - LOG->Trace("Expected half second data:"); - dump(tf.later, ARRAYLEN(tf.later)); - LOG->Trace("Got half second data:"); - dump(LaterData, 16); - - /* See if we can find the half second data. */ - float* p = (float*)xmemsearch(sdata, - one_second_bytes, - tf.later, - sizeof(tf.later), - LaterOffsetSamples * sizeof(int16_t)); - if (p) { - int SamplesOff = p - sdata; - int FramesOff = SamplesOff / 2; - LOG->Trace("Found half second data at frame %i (wanted %i), " - "ahead by %i samples", - FramesOff, - LaterOffsetFrames, - FramesOff - LaterOffsetFrames); - } - // else - // dump( "foo", sdata, one_second/sizeof(int16_t) ); - } - } - - /* Make sure we're getting non-null data. */ - { - bool bAllNull = true; - bool bAll42 = true; - - for (int i = 0; i < one_second_bytes; ++i) { - if (data[i] != 0) - bAllNull = false; - if (data[i] != 0x42) - bAll42 = false; - } - - if (bAllNull || bAll42) { - LOG->Warn( - "'%s': sanity check failed (%i %i)", fn, bAllNull, bAll42); - return false; - } - } - - /* Read to EOF, discarding the data. */ - while (1) { - float buf[4096]; - int got = snd->Read(buf, ARRAYLEN(buf) / snd->GetNumChannels()); - if (got == RageSoundReader::END_OF_FILE) - break; - ASSERT(got >= 0); - } - - /* Now, make sure reading after an EOF returns another EOF. */ - if (!must_be_eof(snd)) { - LOG->Warn("Fail: Reading past EOF didn't EOF"); - return false; - } - - if (!must_be_eof(snd)) { - LOG->Warn("Fail: Reading past EOF twice didn't EOF"); - return false; - } - - for (int i = 0; i < 2; ++i) { - const char* szMode = i == 0 ? "accurate" : "fast"; - snd->SetProperty("AccurateSync", i == 0 ? true : false); - - /* SetPosition(0) must always reset properly. */ - int iRet = snd->SetPosition(0); - if (iRet != 1) { - LOG->Warn("Fail: SetPosition(0) (%s) returned %i, expected 1", - szMode, - iRet); - return false; - } - - if (!test_read(snd, sdata, one_second_frames)) { - LOG->Warn("Fail: SetPosition(0) (%s) didn't work", szMode); - return false; - } - - /* Make sure seeking past end of file returns 0. */ - int ret2 = snd->SetPosition(10000000); - if (ret2 != 0) { - LOG->Warn( - "Fail: SetPosition(1000000) (%s) returned %i instead of 0", - szMode, - ret2); - return false; - } - - /* Make sure that reading after a seek past EOF returns EOF. */ - if (!must_be_eof(snd)) { - LOG->Warn("Fail: SetPosition(EOF) (%s) didn't EOF", szMode); - return false; - } - } - - /* Seek to 1ms and make sure it gives us the correct data. */ - snd->SetProperty("AccurateSync", true); - int iFrame = snd->GetSampleRate() * 1 / 1000; // 1ms - snd->SetPosition(iFrame); - if (!test_read(snd, - sdata + one_second_samples * 1 / 1000, - one_second_frames * 1 / 1000)) - LOG->Warn("Fail: SetPosition(1) (accurate) didn't work"); - - /* Seek to 500ms and make sure it gives us the correct data. */ - iFrame = snd->GetSampleRate() * 500 / 1000; // 500ms - snd->SetPosition(iFrame); - if (!test_read(snd, - sdata + one_second_samples * 500 / 1000, - one_second_frames * 500 / 1000)) - LOG->Warn("Fail: seek(500) (accurate) didn't work"); - - return true; -} - -bool -test_file(const TestFile& tf, int filters) -{ - const char* fn = tf.fn; - - LOG->Trace("Testing: %s", fn); - RString error; - RageSoundReader* s = SoundReader_FileReader::OpenFile(fn, error); - s = ApplyFilters(s, filters); - - if (s == NULL) { - LOG->Trace("File '%s' failed to open: %s", fn, error.c_str()); - return false; - } - // RageSoundReader *snd = s; - RageSoundReader* snd = s->Copy(); - delete s; - - bool ret = RunTests(snd, tf); - - delete snd; - - /* - * Check SetPosition consistency: - * - * Reopen the file from scratch, seek to 100ms, read some data, do some - * operations that would result in the internal TOC being filled (seek - * to the end), then re-read the data at 100ms and make sure it's the same. - */ - - snd = SoundReader_FileReader::OpenFile(fn, error); - snd = ApplyFilters(snd, filters); - - if (snd == NULL) { - LOG->Trace("File '%s' failed to open: %s", fn, error.c_str()); - return false; - } - - if (!CheckSetPositionAccurate(snd)) - ret = false; - - delete snd; - return ret; -} - -int -main(int argc, char* argv[]) -{ - test_handle_args(argc, argv); - test_init(); - - TestFile files[] = { - /* These are all the same data, but they're encoded with different - * amounts of lossage, so the values are all similar but, unlike the - * header tests below, not identical. */ - /* { "test PCM 44100 stereo.wav", 0, - {0xfb6b,0x0076,0xf82b,0x0028}, {0xf598,0xf630,0xf2bd,0xf11d} }, { - "test ADPCM 44100 stereo.wav",0, {0xfb6b,0x0076,0xf82b,0x0028}, - {0xf6d7,0xf54f,0xf300,0xf19e} }, - // { "test ADPCM 22050 mono.wav", 1, - {0xfc2a,0xf4a8,0xf2bb,0xec98}, {0xf329,0xf1c2,0xf44f,0xff82} }, { - "test PCM8bit 44100 stereo.wav", 0, - {0xfb7b,0x0080,0xf878,0x0080}, {0xf575,0xf676,0xf272,0xf171} }, - // XXX: add MP3-in-WAV test - { "test OGG 44100 stereo.ogg", 0, - {0xfb90,0x00b6,0xf84c,0x00ec}, {0xf794,0xf6c4,0xf34e,0xf2cd} }, { - "test MP3 first frame corrupt.mp3", 2343, - {0x0001,0x0000,0x0001,0x0000}, {0xe12f,0xfe36,0xf337,0x0778} }, { - "test BASS first frame corrupt.wav", 2343, - {0x0001,0x0000,0x0001,0x0000}, {0xe12f,0xfe36,0xf337,0x0778} }, - */ - /* "BASS" is the results of decoding each MP3 with BASS's "writewav" - * program, in order to test compatibility with DWI. */ - - /* The following all contain the same data; they simply have - different tags and headers. */ - { "test MP3 44100 stereo CBR.mp3", - 592, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xef22, 0x0cd6, 0xee84, 0x0bb6 } }, - { "test MP3 44100 stereo CBR (ID3V1).mp3", - 592, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xef22, 0x0cd6, 0xee84, 0x0bb6 } }, - { "test MP3 44100 stereo CBR (ID3V2).mp3", - 592, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xef22, 0x0cd6, 0xee84, 0x0bb6 } }, - { "test MP3 44100 stereo CBR (INFO, LAME).mp3", - 1744, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xfc71, 0x23ee, 0xfb74, 0x2141 } }, - - { "test BASS 44100 stereo CBR.wav", - 592, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xef22, 0x0cd6, 0xee84, 0x0bb6 } }, - { "test BASS 44100 stereo CBR (ID3V1).wav", - 592, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xef22, 0x0cd6, 0xee84, 0x0bb6 } }, - { "test BASS 44100 stereo CBR (ID3V2).wav", - 592, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xef22, 0x0cd6, 0xee84, 0x0bb6 } }, - { "test BASS 44100 stereo CBR (INFO, LAME).wav", - 1744, - { 0x0000, 0x0001, 0x0000, 0x0001 }, - { 0xfc71, 0x23ee, 0xfb74, 0x2141 } }, - - /* The following all contain the same data; they simply have - different tags and headers. */ - { "test MP3 44100 stereo VBR (INFO, LAME).mp3", - 1774, - { 0xffff, 0x0000, 0xffff, 0x0000 }, - { 0xfe43, 0x262a, 0xfd0c, 0x22bc } }, - { "test MP3 44100 stereo VBR (XING, LAME).mp3", - 622, - { 0xffff, 0x0000, 0xffff, 0x0000 }, - { 0xef6c, 0x0cb8, 0xef10, 0x0bd2 } }, - { "test MP3 44100 stereo VBR (XING, LAME, ID3V1, ID3V2).mp3", - 622, - { 0xffff, 0x0000, 0xffff, 0x0000 }, - { 0xef6c, 0x0cb8, 0xef10, 0x0bd2 } }, - - { "test BASS 44100 stereo VBR (INFO, LAME).wav", - 1774, - { 0xffff, 0x0000, 0xffff, 0x0000 }, - { 0xfe43, 0x262a, 0xfd0c, 0x22bc } }, - { "test BASS 44100 stereo VBR (XING, LAME).wav", - 622, - { 0xffff, 0x0000, 0xffff, 0x0000 }, - { 0xef6c, 0x0cb8, 0xef10, 0x0bd2 } }, - { "test BASS 44100 stereo VBR (XING, LAME, ID3V1, ID3V2).wav", - 622, - { 0xffff, 0x0000, 0xffff, 0x0000 }, - { 0xef6c, 0x0cb8, 0xef10, 0x0bd2 } }, - { NULL, 0, { 0, 0, 0, 0 }, { 0, 0, 0, 0 } } - }; - - for (int i = 0; files[i].fn; ++i) { - if (!test_file(files[i], 0)) - LOG->Trace(" "); - } - - test_deinit(); - exit(0); -} diff --git a/src/tests/test_file_errors.cpp b/src/tests/test_file_errors.cpp deleted file mode 100644 index 3720a2173b..0000000000 --- a/src/tests/test_file_errors.cpp +++ /dev/null @@ -1,459 +0,0 @@ -#include "global.h" -#include "PrefsManager.h" -#include "RageLog.h" -#include "RageFile.h" -#include "RageFileDriver.h" -#include "RageUtil.h" -#include "RageUtil_FileDB.h" -#include "test_misc.h" - -#include - -static RString g_TestFile; -static RString g_TestFilename; -static int g_BytesUntilError = 6; - -/* - * This driver - * 1: reads from a single "file", contained in g_TestFile, with fn - * g_TestFilename; 2: writes to the bit bucket, 3: triggers an error when - * g_BytesUntilError reaches 0. - */ -class RageFileDriverTest : public RageFileDriver -{ - public: - RageFileDriverTest(RString root); - - RageFileObj* Open(const RString& path, int mode, int& err); - bool Remove(const RString& sPath) { return false; } - bool Ready() { return true; } - - private: - RString root; -}; - -static struct FileDriverEntry_TEST : public FileDriverEntry -{ - FileDriverEntry_TEST() - : FileDriverEntry("TEST") - { - } - RageFileDriver* Create(const RString& sRoot) const - { - return new RageFileDriverTest(sRoot); - } -} const g_RegisterDriver; - -class TestFilenameDB : public FilenameDB -{ - protected: - virtual void PopulateFileSet(FileSet& fs, const RString& sPath) - { - if (sPath != ".") - return; - if (g_TestFile == "") - return; - - fs.files.clear(); - - File f; - f.SetName(g_TestFilename); - f.dir = false; - f.size = g_TestFile.size(); - f.hash = GetHashForString(g_TestFile); - fs.files.insert(f); - } - - RString root; - - public: - TestFilenameDB(RString root_) - { - root = root_; - if (root == "./") - root = ""; - } -}; - -class RageFileObjTest : public RageFileObj -{ - public: - RageFileObjTest(const RString& path); - RageFileObjTest(const RageFileObjTest& cpy); - int ReadInternal(void* buffer, size_t bytes); - int WriteInternal(const void* buffer, size_t bytes); - int Flush(); - void Rewind() { pos = 0; } - int Seek(int offset) - { - pos = min(offset, (int)g_TestFile.size()); - return pos; - } - RageFileObj* Copy() const; - RString GetDisplayPath() const { return path; } - int GetFileSize() const { return g_TestFile.size(); } - - private: - RString path; /* for Copy */ - int pos; -}; - -RageFileDriverTest::RageFileDriverTest(RString root_) - : RageFileDriver(new TestFilenameDB(root_)) - , root(root_) -{ - if (root.Right(1) != "/") - root += '/'; -} - -RageFileObjTest::RageFileObjTest(const RageFileObjTest& cpy) - : RageFileObj(cpy) -{ - path = cpy.path; - pos = cpy.pos; -} - -RageFileObj* -RageFileDriverTest::Open(const RString& path, int mode, int& err) -{ - if (path != g_TestFilename) { - err = ENOENT; - return NULL; - } - - return new RageFileObjTest(root + path); -} - -RageFileObj* -RageFileObjTest::Copy() const -{ - return new RageFileObjTest(*this); -} - -static const unsigned int BUFSIZE = 1024 * 64; -RageFileObjTest::RageFileObjTest(const RString& path_) -{ - path = path_; - pos = 0; -} - -int -RageFileObjTest::ReadInternal(void* buf, size_t bytes) -{ - bytes = min(bytes, g_TestFile.size() - pos); - - if (g_BytesUntilError != -1) { - if ((int)bytes > g_BytesUntilError) { - SetError("Fake error"); - g_BytesUntilError = -1; - return -1; - } - - g_BytesUntilError -= min(g_BytesUntilError, (int)bytes); - } - - memcpy(buf, g_TestFile.data() + pos, bytes); - pos += bytes; - return bytes; -} - -int -RageFileObjTest::WriteInternal(const void* buf, size_t bytes) -{ - if (g_BytesUntilError != -1) { - if ((int)bytes > g_BytesUntilError) { - SetError("Fake error"); - g_BytesUntilError = -1; - return -1; - } - - g_BytesUntilError -= min(g_BytesUntilError, (int)bytes); - } - - return bytes; -} - -/* - * Testing Flush() is important. Writing may buffer. That buffer will be - * flushed, at the latest, when the file is closed in the RageFile dtor. - * However, if you wait until then, there's no way to check for an error; the - * file is going away. The primary purpose of Flush() is to give the user a - * chance to check for these errors. (Flush() is only intended to flush our - * buffers; it is *not* intended to sync data to disk.) - */ -int -RageFileObjTest::Flush() -{ - if (g_BytesUntilError != -1) { - SetError("Fake error"); - g_BytesUntilError = -1; - return -1; - } - - return 0; -} - -#define Fail(s...) \ - { \ - LOG->Warn(s); \ - break; \ - } - -void -SanityCheck() -{ - /* Read sanity check. */ - do { - g_TestFile = "hello"; - g_TestFilename = "file"; - - RageFile test; - if (!test.Open("/test/file", RageFile::READ)) - Fail("Sanity check Open() failed: %s", test.GetError().c_str()); - - RString str; - int got = test.GetLine(str); - if (got <= 0) - Fail("Sanity check GetLine(): got %i", got); - - if (str != "hello") - Fail("Sanity check Read(): expected \"hello\", got \"%s\"", - str.c_str()); - } while (false); - - /* Read error sanity check. */ - do { - g_TestFile = "hello world"; - g_TestFilename = "file"; - g_BytesUntilError = 5; - - RageFile test; - if (!test.Open("/test/file", RageFile::READ)) - Fail("Sanity check 2 Open() failed: %s", test.GetError().c_str()); - - RString str; - int got = test.Read(str, 5); - if (got != 5) - Fail("Sanity check 2 Read(): got %i", got); - - if (str != "hello") - Fail("Sanity check 2 Read(): expected \"hello\", got \"%s\"", - str.c_str()); - - got = test.Read(str, 5); - if (got != -1) - Fail("Sanity check 2 GetLine(): expected -1, got %i", got); - - if (test.GetError() != "Fake error") - Fail( - "Sanity check 2 GetError(): expected \"Fake error\", got \"%s\"", - test.GetError().c_str()); - } while (false); - - /* Write error sanity check. */ - do { - g_TestFilename = "file"; - g_BytesUntilError = 5; - - RageFile test; - if (!test.Open("/test/file", RageFile::WRITE)) - Fail("Write error check Open() failed: %s", - test.GetError().c_str()); - - int wrote = test.Write("test", 4); - if (wrote != 4) - Fail("Write error check Write(): wrote %i", wrote); - - wrote = test.Write("ing", 3); - if (wrote != -1) - Fail("Write error check Write(): expected -1, got %i", wrote); - - if (test.GetError() != "Fake error") - Fail("Write error check GetError(): expected \"Fake error\", got " - "\"%s\"", - test.GetError().c_str()); - } while (false); -} - -#include "IniFile.h" -void -IniTest() -{ - g_TestFilename = "file"; - - /* Read check. */ - do { - g_TestFile = "[test]\n" - "abc=def"; - - g_BytesUntilError = -1; - - IniFile test; - if (!test.ReadFile("test/file")) - Fail("INI: ReadFile failed: %s", test.GetError().c_str()); - - RString sStr; - if (!test.GetValue("test", "abc", sStr)) - Fail("INI: GetValue failed"); - if (sStr != "def") - Fail("INI: GetValue failed: expected \"def\", got \"%s\"", - sStr.c_str()); - } while (false); - - /* Read error check. */ - do { - g_TestFile = "[test]\n" - "abc=def"; - - g_BytesUntilError = 5; - - IniFile test; - if (test.ReadFile("test/file")) - Fail("INI: ReadFile should have failed"); - - if (test.GetError() != "Fake error") - Fail("INI: ReadFile error check: wrong error return: got \"%s\"", - test.GetError().c_str()); - } while (false); - - /* Write error check. */ - do { - g_BytesUntilError = 5; - - IniFile test; - test.SetValue("foo", "bar", RString("baz")); - if (test.WriteFile("test/file")) - Fail("INI: WriteFile should have failed"); - - if (test.GetError() != "Fake error") - Fail("INI: ReadFile error check: wrong error return: got \"%s\"", - test.GetError().c_str()); - } while (false); -} - -#include "MsdFile.h" -void -MsdTest() -{ - g_TestFilename = "file"; - - /* Read check. */ - do { - g_TestFile = "#FOO;"; - - g_BytesUntilError = -1; - - MsdFile test; - if (!test.ReadFile("test/file", false)) - Fail("MSD: ReadFile failed: %s", test.GetError().c_str()); - - if (test.GetNumValues() != 1) - Fail("MSD: GetNumValues: expected 1, got %i", test.GetNumValues()); - if (test.GetNumParams(0) != 1) - Fail("MSD: GetNumParams(0): expected 1, got %i", - test.GetNumParams(0)); - RString sStr = test.GetValue(0)[0]; - if (sStr != "FOO") - Fail("MSD: GetValue failed: expected \"FOO\", got \"%s\"", - sStr.c_str()); - } while (false); - - /* Read error check. */ - do { - g_TestFile = "#FOO:BAR:BAZ;"; - g_BytesUntilError = 5; - - MsdFile test; - if (test.ReadFile("test/file", false)) - Fail("MSD: ReadFile should have failed"); - - if (test.GetError() != "Fake error") - Fail("MSD: ReadFile error check: wrong error return: got \"%s\"", - test.GetError().c_str()); - } while (false); -} - -#include "CryptManager.h" -void -CryptoTest() -{ - PREFSMAN = new PrefsManager; /* CRYPTMAN needs PREFSMAN */ - PREFSMAN->m_bSignProfileData.Set(true); - - CRYPTMAN = new CryptManager; - - g_TestFile = "hello world"; - g_TestFilename = "file"; - FlushDirCache(); - - do { - g_BytesUntilError = -1; - CRYPTMAN->SignFileToFile("test/file", "output"); - - FlushDirCache(); - - if (!CRYPTMAN->VerifyFileWithFile("test/file", "output")) - Fail("Crypto: VerifyFileWithFile failed"); - } while (false); - - /* Write error check. */ - do { - g_BytesUntilError = 5; - CRYPTMAN->SignFileToFile("test/file", "output"); - } while (false); - - /* Read error check. */ - do { - g_BytesUntilError = 5; - CRYPTMAN->SignFileToFile("output", "test/file"); - } while (false); - - delete PREFSMAN; - delete CRYPTMAN; -} - -int -main(int argc, char* argv[]) -{ - test_handle_args(argc, argv); - - test_init(); - - /* Setup. */ - FILEMAN->Mount("TEST", ".", "/test"); - - SanityCheck(); - - IniTest(); - MsdTest(); - CryptoTest(); - - test_deinit(); - - exit(0); -} - -/* - * Copyright (c) 2004 Glenn Maynard - * All rights reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the - * "Software"), to deal in the Software without restriction, including - * without limitation the rights to use, copy, modify, merge, publish, - * distribute, and/or sell copies of the Software, and to permit persons to - * whom the Software is furnished to do so, provided that the above - * copyright notice(s) and this permission notice appear in all copies of - * the Software and that both the above copyright notice(s) and this - * permission notice appear in supporting documentation. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS - * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF - * THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS - * INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT - * OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS - * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR - * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ diff --git a/src/tests/test_file_readers.cpp b/src/tests/test_file_readers.cpp deleted file mode 100644 index f0abbfd255..0000000000 --- a/src/tests/test_file_readers.cpp +++ /dev/null @@ -1,451 +0,0 @@ -#include "global.h" -#include "RageLog.h" -#include "RageFile.h" -#include "RageUtil.h" -#include "RageUtil_FileDB.h" -#include "test_misc.h" - -bool CreateTestFiles = false; - -void -CreateBinaryTestFile(RageFile& f, int size) -{ - char c = 0; - while (size--) { - f.Write(ssprintf("%c", c)); - ++c; - } -} - -void -CreateBinaryTestFile(RString fn, int size) -{ - RageFile f; - f.Open(fn, RageFile::WRITE); - CreateBinaryTestFile(f, size); - f.Close(); - - if (!f.Open(fn)) { - LOG->Warn("CreateBinaryTestFile: error reopening %s: %s", - fn.c_str(), - f.GetError().c_str()); - return; - } - - int test = f.GetFileSize(); - if (test != size) - LOG->Warn( - "CreateBinaryTestFile: f.GetFileSize ret %i, exp %i", test, size); -} - -bool -CheckData(const RString& buf, int offset) -{ - char c = offset % 256; - - for (unsigned i = 0; i < buf.size(); ++i) { - if (buf[i] != c) - return false; - ++c; - } - return true; -} - -int -TestBinaryRead(RageFile& test, - int size, - bool AllowEOF, - int ExpectedFilePos, - int TestDataPos) -{ - char buf[4096]; - ASSERT(size <= (int)sizeof(buf)); - int ret = test.Read(buf, size); - if (ret != size) { - if (AllowEOF) - return 0; - LOG->Warn("FAIL"); - return -1; - } - - if (!CheckData(RString(buf, ret), TestDataPos)) { - LOG->Warn("TestBinaryRead: check failed (size %i, %i,%i)", - size, - ExpectedFilePos, - TestDataPos); - return -1; - } - - if (test.Tell() != ExpectedFilePos + ret) { - LOG->Warn( - "Simple Tell() failed (got %i, expected %i)", test.Tell(), ret); - return -1; - } - return 1; -} - -RString -MakeTextTestLine(int line, int size) -{ - RString ret = ssprintf("%02i", line); - ret.append(RString(size - ret.size(), 'x')); - return ret; -} - -bool -CheckTextData(const RString& buf, int LineSize, int size) -{ - return buf == MakeTextTestLine(LineSize, size); -} - -void -TestText(int LineSize, bool DOS) -{ - const unsigned NumLines = 50; - - RString filename = "test.text"; - if (DOS) - filename += ".DOS"; - filename += ssprintf(".%i", LineSize); - if (CreateTestFiles) { - RageFile f; - f.Open(filename, RageFile::WRITE); - - for (unsigned line = 0; line < NumLines; ++line) { - const RString TestLine = MakeTextTestLine(line, LineSize); - f.Write(TestLine); - if (DOS) - f.Write("\r"); - f.Write("\n"); - } - - /* Write a binary test block at the end. */ - CreateBinaryTestFile(f, 4096); - - /* Write a text line, with no NL. */ - f.Write("final"); - - return; - } - - RageFile test; - if (!test.Open(filename)) { - LOG->Warn( - "Open \"%s\" failed: %s", filename.c_str(), test.GetError().c_str()); - exit(1); - } - - int ExpectedPos = 0; - for (unsigned line = 0; line < NumLines; ++line) { - RString buf; - if (test.GetLine(buf) <= 0) { - LOG->Warn("Text read failure, line %i, size %i, DOS %i", - line, - LineSize, - DOS); - return; - } - - /* If we successfully got data, we should not be at EOF. */ - if (test.AtEOF()) { - LOG->Warn("Unexpected EOF in text read, line %i, size %i, DOS %i", - line, - LineSize, - DOS); - return; - } - - if (!CheckTextData(buf, line, LineSize)) { - LOG->Warn("Text read check failure, line %i, size %i, DOS %i: '%s'", - line, - LineSize, - DOS, - buf.c_str()); - return; - } - ExpectedPos += buf.size() + 1; - if (DOS) - ++ExpectedPos; - } - if (ExpectedPos != test.Tell()) { - LOG->Warn("Text read pos failure, size %i, DOS %i: exp %i, got %i", - LineSize, - DOS, - ExpectedPos, - test.Tell()); - return; - } - - /* Test the binary block. Do it in a couple reads, to force it to read from - * the buffer and the file more than once. */ - TestBinaryRead(test, 1024, true, test.Tell(), 1024 * 0); - TestBinaryRead(test, 1024, true, test.Tell(), 1024 * 1); - TestBinaryRead(test, 1024, true, test.Tell(), 1024 * 2); - TestBinaryRead(test, 1024, true, test.Tell(), 1024 * 3); - - { - RString buf; - if (test.GetLine(buf) <= 0) { - LOG->Warn("Unexpected EOF in final line read, DOS %i", DOS); - return; - } - - if (buf != "final") { - LOG->Warn( - "Final text read check failure, DOS %i: '%s'", DOS, buf.c_str()); - return; - } - if (test.AtEOF()) { - LOG->Warn("Unexpected EOF (2) in final text read, DOS %i", DOS); - return; - } - } - - { - RString buf; - if (test.GetLine(buf) != 0) { - LOG->Warn("Expected EOF in final text read, but didn't get it"); - return; - } - - if (!test.AtEOF()) { - LOG->Warn("Expected EOF (2) in final text read, but didn't get it"); - return; - } - } -} - -void -TestText() -{ - /* Test with these line sizes. The internal buffer size is 256, so test - * line sizes around there carefully. */ - int sizes[] = { 4, 7, 100, 200, 254, 255, 256, 257, 258, 500, -1 }; - - for (int s = 0; sizes[s] != -1; ++s) { - TestText(sizes[s], false); - TestText(sizes[s], true); - } -} - -void -TestSeek(bool relative) -{ - const RString TestLine = "Hello World\n"; - /* Print a couple kb of text. Make sure this is big enough that the binary - * test data after it won't start in the buffer; if that happens, the seek - * will be optimized out. */ - RString junk; - for (int lines = 0; lines < 128; ++lines) - junk += "XXXXXXXXX\n"; - - if (CreateTestFiles) { - /* Output a line of text, followed by some junk, followed by binary - * test data. */ - RageFile f; - f.Open("test.seek", RageFile::WRITE); - f.Write(TestLine); - f.Write(junk); - CreateBinaryTestFile(f, 1024); - return; - } - - /* Read the line of text. This will result in some of the junk being - * read into the buffer. */ - RageFile test; - test.Open("test.seek"); - RString line; - test.GetLine(line); - - /* Run the absolute seek test twice. */ - for (int pass = 0; pass < 2; ++pass) { - /* Seek to the binary test data. */ - if (relative && pass > 0) - break; - - int ret; - if (relative) - ret = test.Seek(test.Tell() + junk.size()); - else - ret = test.Seek(TestLine.size() + junk.size()); - - if (ret != int(TestLine.size() + junk.size())) { - LOG->Warn( - "Seek(%i) failed: got %i", TestLine.size() + junk.size(), ret); - return; - } - - /* Check the binary test data (making sure we don't get any junk). */ - TestBinaryRead(test, 256, false, test.Tell(), 256 * 0); - TestBinaryRead(test, 256, false, test.Tell(), 256 * 1); - TestBinaryRead(test, 256, false, test.Tell(), 256 * 2); - TestBinaryRead(test, 256, false, test.Tell(), 256 * 3); - - /* Check EOF. */ - char c; - ret = test.Read(&c, 1); - if (ret != 0) { - LOG->Warn("Read(1) failed: got %i, expected 0", ret); - return; - } - if (!test.AtEOF()) { - LOG->Warn("AtEOF returned false, expected true"); - return; - } - } - - test.Seek(5); - if (test.AtEOF()) { - LOG->Warn("AtEOF returned true, expected false"); - return; - } - - /* Make sure a read after seeking far past EOF returns 0. */ - test.Seek(9999999); - char c; - int ret = test.Read(&c, 1); - if (ret != 0) { - LOG->Warn("Read(1) failed: got %i, expected 0", ret); - return; - } - if (!test.AtEOF()) { - LOG->Warn("AtEOF returned false, expected true"); - return; - } -} - -#include "RageFileDriverMemory.h" -#include "RageFileDriverDeflate.h" -void -CheckDeflate(RageFileObjMem& data, - int iSize, - unsigned iInputCRC, - int iBlockSize) -{ - data.Seek(0); - - RString foo2; - - RageFileObjInflate infl(&data, iSize); - infl.EnableCRC32(); - int iGot = 0; - while (iGot < iSize) { - int iRet = infl.Read(foo2, iBlockSize); - if (iRet == 0) { - LOG->Warn( - "Premature EOF (iSize %i, iBlockSize %i)", iSize, iBlockSize); - return; - } - - iGot += iRet; - } - - unsigned iOutputCRC; - if (!infl.GetCRC32(&iOutputCRC)) { - LOG->Warn("Inflate GetCRC32 failed"); - return; - } - if (iInputCRC != iOutputCRC) { - LOG->Warn("Expected CRC %08x, got %08x", iInputCRC, iOutputCRC); - return; - } - - if (iSize != iGot) { - LOG->Warn("Expected %i, got %i", iSize, iGot); - return; - } -} - -void -TestDeflate() -{ - RageFileObjMem data; - RageFileObjDeflate defl(&data); - defl.EnableCRC32(); - - int iSize = 0; - while (iSize < 1024 * 512) - iSize += defl.Write("test foo bar fah"); - defl.Flush(); - - unsigned iOutputCRC; - if (!defl.GetCRC32(&iOutputCRC)) { - LOG->Warn("Deflate GetCRC32 failed"); - return; - } - - CheckDeflate(data, iSize, iOutputCRC, 1); - CheckDeflate(data, iSize, iOutputCRC, 1024); - CheckDeflate(data, iSize, iOutputCRC, 1024 * 4); - CheckDeflate(data, iSize, iOutputCRC, iSize - 1); - CheckDeflate(data, iSize, iOutputCRC, iSize); -} - -int -main(int argc, char* argv[]) -{ - test_handle_args(argc, argv); - - optind = 0; // force getopt to reset - while (1) { - opterr = 0; - int opt = getopt(argc, argv, "c"); - if (opt == -1) - break; - switch (opt) { - case 'c': - CreateTestFiles = true; - break; - } - } - - test_init(); - - if (GetCommandlineArgument("zlib")) { - TestDeflate(); - test_deinit(); - return 0; - } - - if (CreateTestFiles) - CreateBinaryTestFile("test.binary", 4096); - else { - /* Test binary reading. */ - RageFile test; - if (!test.Open("test.binary")) { - LOG->Warn("Open \"test.binary\" failed: %s", - test.GetError().c_str()); - exit(1); - } - - TestBinaryRead(test, 256, false, 0, 0); - - /* Test simple re-opening. */ - test.Close(); - test.Open("test.binary"); - - /* We should now be back at 0. */ - if (test.Tell() != 0) { - LOG->Warn("Simple Tell() after reopen failed (got %i, expected 0)", - test.Tell()); - exit(1); - } - - /* Test reading further, with various block sizes. */ - while (1) { - if (TestBinaryRead(test, 85, true, test.Tell(), test.Tell()) == 0) - break; - } - } - - /* Test text reading. */ - TestText(); - - /* Test seeking. */ - TestSeek(true); - TestSeek(false); - - test_deinit(); - - exit(0); -} diff --git a/src/tests/test_misc.cpp b/src/tests/test_misc.cpp deleted file mode 100644 index 63f1d23ff0..0000000000 --- a/src/tests/test_misc.cpp +++ /dev/null @@ -1,64 +0,0 @@ -#include "global.h" -#include "test_misc.h" - -#include "RageFileManager.h" -#include "RageLog.h" -#include "RageUtil.h" -#include "arch/ArchHooks/ArchHooks.h" - -RString g_Driver = "dir", g_Root = "."; - -RString argv0; - -void -test_handle_args(int argc, char* argv[]) -{ - SetCommandlineArguments(argc, argv); - argv0 = argv[0]; - - while (1) { - opterr = 0; - int opt = getopt(argc, argv, "cd:r:h"); - if (opt == -1) - break; - switch (opt) { - case 'd': - g_Driver = optarg; - break; - case 'r': - g_Root = optarg; - break; - - case 'h': - printf("options:\n"); - printf(" -c: create test files\n"); - printf( - " -d driver: choose file driver to test (default \"Dir\")\n"); - printf(" -r root: set file driver root (default \".\")\n"); - exit(1); - } - } -} - -void -test_init() -{ - HOOKS = ArchHooks::Create(); - HOOKS->Init(); - - FILEMAN = new RageFileManager(argv0); - FILEMAN->Mount(g_Driver, g_Root, "/"); - - LOG = new RageLog; - LOG->SetLogToDisk(false); - LOG->SetShowLogOutput(true); - LOG->SetFlushing(true); -} - -void -test_deinit() -{ - delete LOG; - delete FILEMAN; - delete HOOKS; -} diff --git a/src/tests/test_misc.h b/src/tests/test_misc.h deleted file mode 100644 index 7a09f813b8..0000000000 --- a/src/tests/test_misc.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef TEST_HELPERS_H -#define TEST_HELPERS_H - -void -test_handle_args(int argc, char* argv[]); -void -test_init(); -void -test_deinit(); - -#endif diff --git a/src/tests/test_threads.cpp b/src/tests/test_threads.cpp deleted file mode 100644 index e26d4f0854..0000000000 --- a/src/tests/test_threads.cpp +++ /dev/null @@ -1,330 +0,0 @@ -#include "global.h" -#include "RageLog.h" -#include "RageUtil.h" -#include "RageThreads.h" -#include "archutils/Unix/Backtrace.h" -#include "archutils/Unix/BacktraceNames.h" -#include "test_misc.h" - -#include -#include "archutils/Common/PthreadHelpers.h" - -/* These are volatile, so writes to them aren't optimized. */ -volatile uint64_t g_ThreadId = (uint64_t)-1; -volatile int g_Counter = 0; -volatile bool g_Finish = false; - -void -TestSuspendIncrLoop() -{ - while (!g_Finish) - ++g_Counter; -} - -int -TestSuspendThread(void* p) -{ - printf("Test thread started\n"); - - g_ThreadId = GetCurrentThreadId(); - TestSuspendIncrLoop(); - - return 0; -} - -void -test_suspend_threadid(uint64_t ThreadId) -{ - /* Wait for g_Counter to increment a bit. */ - usleep(100000); - - /* Stop the thread. */ - SuspendThread(ThreadId); - - int OldCounter = g_Counter; - - /* Wait a while. g_Counter shouldn't change. */ - usleep(100000); - - ASSERT(g_Counter == OldCounter); - - /* Start it again, and wait. */ - ResumeThread(ThreadId); - usleep(100000); - - /* g_Counter should change. */ - ASSERT(g_Counter != OldCounter); - - /* Stop all other threads. */ - RageThread::HaltAllThreads(); - - OldCounter = g_Counter; - - /* Wait a while. g_Counter shouldn't change. */ - usleep(100000); - ASSERT(g_Counter == OldCounter); - - /* Start it again, and wait. */ - RageThread::ResumeAllThreads(); - usleep(100000); - - /* g_Counter should change. */ - ASSERT(g_Counter != OldCounter); -} - -/* Test whether suspending a child thread works. */ -void -test_suspend_secondary_thread() -{ - ASSERT(!g_Finish); - ASSERT(g_ThreadId == (uint64_t)-1); - - RageThread testing; - testing.SetName("TestSuspend"); - testing.Create(TestSuspendThread, NULL); - - while (g_ThreadId == (uint64_t)-1) - ; - - test_suspend_threadid(g_ThreadId); - - g_Finish = true; - testing.Wait(); - g_Finish = false; - g_ThreadId = (uint64_t)-1; -} - -int -TestSuspendMainThread(void* p) -{ - ASSERT(!g_Finish); - - printf("Test thread started\n"); - - ASSERT(g_ThreadId != (uint64_t)-1); - test_suspend_threadid(g_ThreadId); - g_Finish = true; - - return 0; -} - -/* Test whether suspending the main thread works. */ -void -test_suspend_main_thread() -{ - ASSERT(!g_Finish); - ASSERT(g_ThreadId == (uint64_t)-1); - - g_ThreadId = GetCurrentThreadId(); - - RageThread testing; - testing.SetName("TestSuspend"); - testing.Create(TestSuspendMainThread, NULL); - - TestSuspendIncrLoop(); - - testing.Wait(); - g_Finish = false; - g_ThreadId = (uint64_t)-1; -} - -/* Run a second function, so we have two symbols to search for. */ -void -TestBacktraceThreadLoop() __attribute__((__noinline__)); -void -TestBacktraceThreadLoop() -{ - g_ThreadId = GetCurrentThreadId(); - while (!g_Finish) - ; -} - -int -TestBacktraceThread(void* p) __attribute__((__noinline__)); -int -TestBacktraceThread(void* p) -{ - TestBacktraceThreadLoop(); - return 0; -} - -bool -test_thread_backtrace(int ThreadId, const void* expect1, const void* expect2) -{ - BacktraceContext ctx; - int ret = GetThreadBacktraceContext(ThreadId, &ctx); - ASSERT(ret); - - const void* BacktracePointers[1024]; - GetBacktrace(BacktracePointers, 1024, &ctx); - - ResumeThread(ThreadId); - - bool bFound1 = false, bFound2 = false; - for (int i = 0; BacktracePointers[i]; ++i) { - BacktraceNames bn; - bn.FromAddr(BacktracePointers[i]); - - // printf("want %p, %p: %p, %p\n", expect1, expect2, - // bn.Address-bn.Offset, BacktracePointers[i] ); printf(" - //%s\n", bn.Format().c_str() ); - - /* bn.Address is the current address; Offset is the distance to the - * beginning of the symbol, so bn.Address-bn.Offset is the actual - * symbol. */ - if (bn.Address - bn.Offset == (int)expect1) - bFound1 = true; - if (bn.Address - bn.Offset == (int)expect2) - bFound2 = true; - } - - return bFound1 && bFound2; -} - -void -test_backtracing_secondary_thread() -{ - ASSERT(!g_Finish); - - RageThread testing; - testing.SetName("TestBacktrace"); - testing.Create(TestBacktraceThread, NULL); - - while (g_ThreadId == (uint64_t)-1) - ; - - if (!test_thread_backtrace(g_ThreadId, - (void*)TestBacktraceThread, - (void*)TestBacktraceThreadLoop)) { - printf("test_backtracing_secondary_thread failed\n"); - exit(1); - } - - g_Finish = true; - testing.Wait(); - g_Finish = false; - g_ThreadId = (uint64_t)-1; -} - -int -TestBacktraceMainThread(void* p) -{ - printf("Test thread started\n"); - - while (g_ThreadId == (uint64_t)-1) - ; - - if (!test_thread_backtrace(g_ThreadId, - (void*)TestBacktraceThread, - (void*)TestBacktraceThreadLoop)) { - printf("test_backtracing_main_thread failed\n"); - exit(1); - } - - g_Finish = true; - - return 0; -} - -void -test_backtracing_main_thread() -{ - ASSERT(!g_Finish); - ASSERT(g_ThreadId == (uint64_t)-1); - - RageThread testing; - testing.SetName("TestBacktrace"); - testing.Create(TestBacktraceMainThread, NULL); - - TestBacktraceThread(NULL); - - testing.Wait(); - g_Finish = false; - g_ThreadId = (uint64_t)-1; -} - -static RageMutex g_Mutex("test"); - -int -TestLocksThread(void* p) -{ - printf("Test thread started\n"); - - g_ThreadId = GetCurrentThreadId(); - - while (!g_Finish) { - g_Mutex.Lock(); - ++g_Counter; - g_Mutex.Unlock(); - } - - return 0; -} - -void -test_locks() -{ - ASSERT(!g_Finish); - ASSERT(g_ThreadId == (uint64_t)-1); - - RageThread testing; - testing.SetName("TestLocks"); - testing.Create(TestLocksThread, NULL); - - while (g_ThreadId == (uint64_t)-1) - ; - - /* Stop the thread. */ - g_Mutex.Lock(); - - int OldCounter = g_Counter; - - /* Wait a while. g_Counter shouldn't change. */ - usleep(100000); - - ASSERT(g_Counter == OldCounter); - - /* Start it again, and wait. */ - g_Mutex.Unlock(); - usleep(100000); - - /* g_Counter should change. */ - ASSERT(g_Counter != OldCounter); - - g_Finish = true; - testing.Wait(); - g_Finish = false; - g_ThreadId = (uint64_t)-1; -} - -void -go() -{ - /* Test the main thread suspending a secondary thread, and vice versa. */ - test_suspend_secondary_thread(); - test_suspend_main_thread(); - - /* Test the main thread backtracing a secondary thread, and vice versa. */ - test_backtracing_secondary_thread(); - test_backtracing_main_thread(); - - test_locks(); -} - -int -main(int argc, char* argv[]) -{ - test_handle_args(argc, argv); - - test_init(); - - InitializeBacktrace(); - - printf("'%s'\n", ThreadsVersion().c_str()); - - go(); - - test_deinit(); - - exit(0); -} diff --git a/src/tests/test_timing_data.cpp b/src/tests/test_timing_data.cpp deleted file mode 100644 index 41ead479a4..0000000000 --- a/src/tests/test_timing_data.cpp +++ /dev/null @@ -1,161 +0,0 @@ -#include "global.h" -#include "RageLog.h" -#include "RageFile.h" -#include "RageUtil.h" -#include "RageUtil_FileDB.h" -#include "PrefsManager.h" -#include "RageFileManager.h" -#include "TimingData.h" - -void -run() -{ -#define CHECK(call, exp) \ - \ -{ \ - float ret = call; \ - if (call != exp) { \ - LOG->Warn("Line %i: Got %f, expected %f", __LINE__, ret, exp); \ - return; \ - } \ - \ -} - - TimingData test; - test.AddBPMSegment(BPMSegment(0, 60)); - - /* First, trivial sanity checks. */ - CHECK(test.GetBeatFromElapsedTime(60), 60.0f); - CHECK(test.GetElapsedTimeFromBeat(60), 60.0f); - - /* The first BPM segment extends backwards in time. */ - CHECK(test.GetBeatFromElapsedTime(-60), -60.0f); - CHECK(test.GetElapsedTimeFromBeat(-60), -60.0f); - - CHECK(test.GetBeatFromElapsedTime(100000), 100000.0f); - CHECK(test.GetElapsedTimeFromBeat(100000), 100000.0f); - CHECK(test.GetBeatFromElapsedTime(-100000), -100000.0f); - CHECK(test.GetElapsedTimeFromBeat(-100000), -100000.0f); - - CHECK(test.GetBPMAtBeat(0), 60.0f); - CHECK(test.GetBPMAtBeat(100000), 60.0f); - CHECK(test.GetBPMAtBeat(-100000), 60.0f); - - /* 120BPM at beat 10: */ - test.AddBPMSegment(BPMSegment(10, 120)); - CHECK(test.GetBPMAtBeat(9.99), 60.0f); - CHECK(test.GetBPMAtBeat(10), 120.0f); - - CHECK(test.GetBeatFromElapsedTime(9), 9.0f); - CHECK(test.GetBeatFromElapsedTime(10), 10.0f); - CHECK(test.GetBeatFromElapsedTime(10.5), 11.0f); - - CHECK(test.GetElapsedTimeFromBeat(9), 9.0f); - CHECK(test.GetElapsedTimeFromBeat(10), 10.0f); - CHECK(test.GetElapsedTimeFromBeat(11), 10.5f); - - /* Add a 5-second stop at beat 10. */ - test.AddStopSegment(StopSegment(10, 5)); - - /* The stop shouldn't affect GetBPMAtBeat at all. */ - CHECK(test.GetBPMAtBeat(9.99), 60.0f); - CHECK(test.GetBPMAtBeat(10), 120.0f); - - CHECK(test.GetBeatFromElapsedTime(9), 9.0f); - CHECK(test.GetBeatFromElapsedTime(10), 10.0f); - CHECK(test.GetBeatFromElapsedTime(12), 10.0f); - CHECK(test.GetBeatFromElapsedTime(14), 10.0f); - CHECK(test.GetBeatFromElapsedTime(15), 10.0f); - CHECK(test.GetBeatFromElapsedTime(15.5), 11.0f); - - CHECK(test.GetElapsedTimeFromBeat(9), 9.0f); - CHECK(test.GetElapsedTimeFromBeat(10), 10.0f); - CHECK(test.GetElapsedTimeFromBeat(11), 15.5f); - - /* Add a 2-second stop at beat 5 and a 5-second stop at beat 15. */ - test.m_StopSegments.clear(); - test.AddStopSegment(StopSegment(5, 2)); - test.AddStopSegment(StopSegment(15, 5)); - CHECK(test.GetBPMAtBeat(9.99), 60.0f); - CHECK(test.GetBPMAtBeat(10), 120.0f); - - CHECK(test.GetBeatFromElapsedTime(1), 1.0f); - CHECK(test.GetBeatFromElapsedTime(2), 2.0f); - CHECK(test.GetBeatFromElapsedTime(5), 5.0f); // stopped - CHECK(test.GetBeatFromElapsedTime(6), 5.0f); // stopped - CHECK(test.GetBeatFromElapsedTime(7), 5.0f); // stop finished - CHECK(test.GetBeatFromElapsedTime(8), 6.0f); - CHECK(test.GetBeatFromElapsedTime(12), 10.0f); // bpm changes to 120 - CHECK(test.GetBeatFromElapsedTime(13), 12.0f); - CHECK(test.GetBeatFromElapsedTime(14), 14.0f); - CHECK(test.GetBeatFromElapsedTime(14.5f), 15.0f); // stopped - CHECK(test.GetBeatFromElapsedTime(15), 15.0f); // stopped - CHECK(test.GetBeatFromElapsedTime(17), 15.0f); // stopped - CHECK(test.GetBeatFromElapsedTime(19.5f), 15.0f); // stop finished - CHECK(test.GetBeatFromElapsedTime(20), 16.0f); - - CHECK(test.GetElapsedTimeFromBeat(1), 1.0f); - CHECK(test.GetElapsedTimeFromBeat(2), 2.0f); - CHECK(test.GetElapsedTimeFromBeat(5), 5.0f); // stopped - CHECK(test.GetElapsedTimeFromBeat(6), 8.0f); - CHECK(test.GetElapsedTimeFromBeat(10), 12.0f); // bpm changes to 120 - CHECK(test.GetElapsedTimeFromBeat(12), 13.0f); - CHECK(test.GetElapsedTimeFromBeat(14), 14.0f); - CHECK(test.GetElapsedTimeFromBeat(15.0f), 14.5f); // stopped - CHECK(test.GetElapsedTimeFromBeat(16), 20.0f); - - // todo: add warp tests -aj - - RageTimer foobar; - /* We can look up the time of any given beat, then look up the beat of that - * time and get the original value. (We can't do this in reverse; the beat - * doesn't move during stop segments.) */ - int q = 0; - for (float f = -10; f < 250; f += 0.002) { - ++q; - // const float t = test.GetElapsedTimeFromBeat( f ); - const float b = test.GetBeatFromElapsedTime(f); - - /* b == f */ - - // if( fabsf(b-f) > 0.001 ) - // { - // LOG->Warn( "%f != %f", b, f ); - // return; - // } - } - LOG->Trace("... %i in %f", q, foobar.GetDeltaTime()); - - TimingData test2; - test2.AddBPMSegment(BPMSegment(0, 60)); - test2.AddStopSegment(StopSegment(0, 1)); - // test2.AddWarpSegment( WarpSegment() ); - CHECK(test2.GetBeatFromElapsedTime(-1), -1.0f); - CHECK(test2.GetBeatFromElapsedTime(0), 0.0f); - CHECK(test2.GetBeatFromElapsedTime(1), 0.0f); - CHECK(test2.GetBeatFromElapsedTime(2), 1.0f); - CHECK(test2.GetElapsedTimeFromBeat(-1), -1.0f); - CHECK(test2.GetElapsedTimeFromBeat(0), 0.0f); - CHECK(test2.GetElapsedTimeFromBeat(1), 2.0f); - CHECK(test2.GetElapsedTimeFromBeat(2), 3.0f); -} - -int -main(int argc, char* argv[]) -{ - FILEMAN = new RageFileManager(argv[0]); - FILEMAN->Mount("dir", ".", ""); - LOG = new RageLog(); - PREFSMAN = - new PrefsManager; // TimingData needs PREFSMAN; it probably shouldn't - LOG->SetShowLogOutput(true); - LOG->SetFlushing(true); - - run(); - - delete PREFSMAN; - delete LOG; - delete FILEMAN; - - exit(0); -} diff --git a/src/tests/test_vector.cpp b/src/tests/test_vector.cpp deleted file mode 100644 index 49fa54ca3b..0000000000 --- a/src/tests/test_vector.cpp +++ /dev/null @@ -1,330 +0,0 @@ -#define _XOPEN_SOURCE 600 -#include -#include -#include -#include -#include -#include - -#if 0 -#error This depends on OS X and Apple's gcc. -#endif -#ifndef USE_VEC -#error Enable altivec or sse. -#endif -#define SCALE(x, l1, h1, l2, h2) \ - (((x) - (l1)) * ((h2) - (l2)) / ((h1) - (l1)) + (l2)) - -using namespace std; - -// This requires that allocated memory be 16 byte aligned. Apple's new -// (and malloc) ensures this but most others only ensure that the -// memory is type size aligned. Hack in posix_memalign. We could also -// override the global new, but that's even more hassle. -#ifdef __APPLE_CC__ -#define NEW(t, s) new t[(s)] -#define DELETE(x) delete[] x -#else -static void* pStupid; -#define NEW(t, s) (posix_memalign(&pStupid, 16, s * sizeof(t)), (t*)pStupid) -#define DELETE(x) free((x)) -#endif - -// The reference values. -static void -ScalarWrite(float* pDestBuf, const float* pSrcBuf, size_t iSize) -{ - for (unsigned iPos = 0; iPos < iSize; ++iPos) - pDestBuf[iPos] += pSrcBuf[iPos]; -} - -#if 0 -static void ScalarRead( int16_t *pDestBuf, const int32_t *pSrcBuf, unsigned iSize ) -{ - for( unsigned iPos = 0; iPos < iSize; ++iPos ) - pDestBuf[iPos] = max( -32768, min(pSrcBuf[iPos]/256, 32767) ); -} -#endif - -static void -RandBuffer(float* pBuffer, unsigned iSize) -{ - while (iSize--) - *pBuffer++ = float(rand()) / RAND_MAX; -} - -template -static void -Diagnostic(const T* pDestBuf, const T* pRefBuf, size_t size) -{ - const int num = 10; - for (int i = 0; i < num; ++i) - fprintf(stderr, "%0*x ", sizeof(T) * 2, pDestBuf[i]); - puts(""); - for (int i = 0; i < num; ++i) - fprintf(stderr, "%0*x ", sizeof(T) * 2, pRefBuf[i]); - puts(""); - for (size_t i = size - num; i < size; ++i) - fprintf(stderr, "%0*x ", sizeof(T) * 2, pDestBuf[i]); - puts(""); - for (size_t i = size - num; i < size; ++i) - fprintf(stderr, "%0*x ", sizeof(T) * 2, pRefBuf[i]); - puts(""); -} - -template<> -static void -Diagnostic(const float* pDestBuf, const float* pRefBuf, size_t size) - -{ - const int num = 10; - for (int i = 0; i < num; ++i) - fprintf(stderr, "%f ", pDestBuf[i]); - puts(""); - for (int i = 0; i < num; ++i) - fprintf(stderr, "%f ", pRefBuf[i]); - puts(""); - for (size_t i = size - num; i < size; ++i) - fprintf(stderr, "%f ", pDestBuf[i]); - puts(""); - for (size_t i = size - num; i < size; ++i) - fprintf(stderr, "%f ", pRefBuf[i]); - puts(""); -} - -static bool -TestWrite(float* pSrcBuf, float* pDestBuf, float* pRefBuf, size_t iSize) -{ - RandBuffer(pSrcBuf, iSize); - memset(pDestBuf, 0, iSize * 4); - memset(pRefBuf, 0, iSize * 4); - Vector::FastSoundWrite(pDestBuf, pSrcBuf, iSize); - ScalarWrite(pRefBuf, pSrcBuf, iSize); - return !memcmp(pRefBuf, pDestBuf, iSize * 4); -} - -static bool -CheckAlignedWrite() -{ - const size_t size = 1024; - float* pSrcBuf = NEW(float, size); - float* pDestBuf = NEW(float, size); - float* pRefBuf = NEW(float, size); - bool ret = true; - size_t s; - - // Test unaligned ends - for (int i = 0; i < 16 && ret; ++i) { - s = size - i; - ret = TestWrite(pSrcBuf, pDestBuf, pRefBuf, s); - } - if (!ret) - Diagnostic(pDestBuf, pRefBuf, s); - DELETE(pSrcBuf); - DELETE(pDestBuf); - DELETE(pRefBuf); - return ret; -} - -static bool -CheckMisalignedSrcWrite() -{ - const size_t size = 1024; - float* pSrcBuf = NEW(float, size); - float* pDestBuf = NEW(float, size); - float* pRefBuf = NEW(float, size); - bool ret = true; - - for (int j = 0; j < 8 && ret; ++j) { - size_t s; - for (int i = 0; i < 8 && ret; ++i) { - s = size - i - j; // Source buffer is shrinking. - ret = TestWrite(pSrcBuf + j, pDestBuf, pRefBuf, s); - } - if (!ret) - Diagnostic(pDestBuf, pRefBuf, s); - } - DELETE(pSrcBuf); - DELETE(pDestBuf); - DELETE(pRefBuf); - return ret; -} - -static bool -CheckMisalignedDestWrite() -{ - const size_t size = 1024; - float* pSrcBuf = NEW(float, size); - float* pDestBuf = NEW(float, size); - float* pRefBuf = NEW(float, size); - bool ret = true; - - for (int j = 0; j < 4 && ret; ++j) { - size_t s; - for (int i = 0; i < 8 && ret; ++i) { - s = size - i - j; // Dest buffer is shrinking. - ret = TestWrite(pSrcBuf, pDestBuf + j, pRefBuf + j, s); - } - if (!ret) - Diagnostic(pDestBuf + j, pRefBuf + j, s); - } - DELETE(pSrcBuf); - DELETE(pDestBuf); - DELETE(pRefBuf); - return ret; -} - -static bool -CheckMisalignedBothWrite() -{ - const size_t size = 1024; - float* pSrcBuf = NEW(float, size); - float* pDestBuf = NEW(float, size); - float* pRefBuf = NEW(float, size); - bool ret = true; - size_t s; - - for (int j = 0; j < 4 && ret; ++j) { - for (int i = 0; i < 8 && ret; ++i) { - for (int k = 0; k < 8 && ret; ++k) { - s = size - i - j - k; // Both buffers are shrinking. - ret = TestWrite(pSrcBuf + i, pDestBuf + j, pRefBuf + j, s); - } - } - if (!ret) - Diagnostic(pDestBuf + j, pRefBuf + j, s); - } - DELETE(pSrcBuf); - DELETE(pDestBuf); - DELETE(pRefBuf); - return ret; -} - -static bool -cmp(const int16_t* p1, const int16_t* p2, size_t size) -{ - return !memcmp(p1, p2, size * 2); -} - -static bool -cmp(const float* p1, const float* p2, size_t size) -{ - const float epsilon = 0.000001; - ++size; - while (--size) - if (fabs(*p1++ - *p2++) >= epsilon) - return false; - return true; -} -#if 0 -template -static bool CheckAlignedRead() -{ - const size_t size = 1024; - int32_t *pSrcBuf = NEW( int32_t, size ); - T *pDestBuf = NEW( T, size ); - T *pRefBuf = NEW( T, size ); - bool ret = true; - - for( int i = 0; i < 8; ++i ) - { - RandBuffer( pSrcBuf, size-i ); - Vector::FastSoundRead( pDestBuf, pSrcBuf, size-i ); - ScalarRead( pRefBuf, pSrcBuf, size-i ); - - if( !(ret = cmp(pRefBuf, pDestBuf, size-i)) ) - { - fprintf( stderr, "%d: \n", i ); - Diagnostic( pDestBuf, pRefBuf, size-i ); - break; - } - } - - DELETE( pSrcBuf ); - DELETE( pDestBuf ); - DELETE( pRefBuf ); - return ret; -} - -template -static bool CheckMisalignedRead() -{ - const size_t size = 1024; - int32_t *pSrcBuf = NEW( int32_t, size ); - T *pDestBuf = NEW( T, size ); - T *pRefBuf = NEW( T, size ); - bool ret = true; - - for( int j = 0; j < 8; ++j ) - { - for( int i = 0; i < 8; ++i ) - { - RandBuffer( pSrcBuf, size-i ); - Vector::FastSoundRead( pDestBuf+j, pSrcBuf, size-i-j ); - ScalarRead( pRefBuf+j, pSrcBuf, size-i-j ); - - if( !(ret = cmp(pRefBuf+j, pDestBuf+j, size-i-j)) ) - { - fprintf( stderr, "%d, %d: \n", j, i ); - Diagnostic( pDestBuf+j, pRefBuf+j, size-i-j ); - break; - } - } - } - - DELETE( pSrcBuf ); - DELETE( pDestBuf ); - DELETE( pRefBuf ); - return ret; -} -#endif - -int -main() -{ - srand(time(NULL)); - if (!Vector::CheckForVector()) { - fputs("No vector unit accessable.\n", stderr); - return 1; - } - if (!CheckAlignedWrite()) { - fputs("Failed aligned write.\n", stderr); - return 1; - } - if (!CheckMisalignedSrcWrite()) { - fputs("Failed misaligned source write.\n", stderr); - return 1; - } - if (!CheckMisalignedDestWrite()) { - fputs("Failed misaligned destination write\n", stderr); - return 1; - } - if (!CheckMisalignedBothWrite()) { - fputs("Failed misaligned source and destination write.\n", stderr); - return 1; - } -#if 0 - if( !CheckAlignedRead() ) - { - fputs( "Failed aligned read.\n", stderr ); - return 1; - } - if( !CheckAlignedRead() ) - { - fputs( "Failed aligned float read.\n", stderr ); - return 1; - } - if( !CheckMisalignedRead() ) - { - fputs( "Failed misaligned read.\n", stderr ); - return 1; - } - if( !CheckMisalignedRead() ) - { - fputs( "Failed misaligned float read.\n", stderr ); - return 1; - } -#endif - puts("Passed."); - return 0; -} diff --git a/src/update_check/check_sm5.php b/src/update_check/check_sm5.php deleted file mode 100644 index cc077a0b1a..0000000000 --- a/src/update_check/check_sm5.php +++ /dev/null @@ -1,12 +0,0 @@ - diff --git a/src/verify_signature/cpp_cryptopp/test.cpp b/src/verify_signature/cpp_cryptopp/test.cpp deleted file mode 100644 index eb8decfe05..0000000000 --- a/src/verify_signature/cpp_cryptopp/test.cpp +++ /dev/null @@ -1,102 +0,0 @@ -// Based on test.cpp from crypto++ -// Parameters: -// public_key - X.509 standard SubjectPublicKeyInfo key in binary format -// data_file - the data file whose signature to verify -// signature - the signature of data_file in binary format -// test.cpp - written and placed in the public domain by Wei Dai - -#include "sha.h" -#include "files.h" -#include "rsa.h" - -#include -#include - -#ifdef CRYPTOPP_WIN32_AVAILABLE -#include -#endif - -#if (_MSC_VER >= 1000) -#include // for the debug heap -#endif - -#if defined(__MWERKS__) && defined(macintosh) -#include -#endif - -USING_NAMESPACE(CryptoPP) -USING_NAMESPACE(std) - -bool -RSAVerifyFile(const char* pubFilename, - const char* messageFilename, - const char* signatureFilename); - -int (*AdhocTest)(int argc, char* argv[]) = NULL; - -#ifdef __BCPLUSPLUS__ -int -cmain(int argc, char* argv[]) -#elif defined(_MSC_VER) -int __cdecl main(int argc, char* argv[]) -#else -int -main(int argc, char* argv[]) -#endif -{ -#ifdef _CRTDBG_LEAK_CHECK_DF - // Turn on leak-checking - int tempflag = _CrtSetDbgFlag(_CRTDBG_REPORT_FLAG); - tempflag |= _CRTDBG_LEAK_CHECK_DF; - _CrtSetDbgFlag(tempflag); -#endif - -#if defined(__MWERKS__) && defined(macintosh) - argc = ccommand(&argv); -#endif - - try { - std::string command, executableName, edcFilename; - - if (argc != 4) { - cout << "\nUsage: RSAPubKeyData.exe publickey_fn data_fn " - "signature_fn" - << endl; - return -1; - } - - if (RSAVerifyFile(argv[2], argv[3], argv[4])) { - cout << "The signature is valid." << endl; - } else { - cout << "The signature is not valid." << endl; - } - return 0; - } catch (CryptoPP::Exception& e) { - cout << "\nCryptoPP::Exception caught: " << e.what() << endl; - return -1; - } catch (std::exception& e) { - cout << "\nstd::exception caught: " << e.what() << endl; - return -2; - } -} - -bool -RSAVerifyFile(const char* pubFilename, - const char* messageFilename, - const char* signatureFilename) -{ - FileSource pubFile(pubFilename, true); - RSASSA_PKCS1v15_SHA_Verifier pub(pubFile); - - FileSource signatureFile(signatureFilename, true); - if (signatureFile.MaxRetrievable() != pub.SignatureLength()) - return false; - SecByteBlock signature(pub.SignatureLength()); - signatureFile.Get(signature, signature.size()); - - VerifierFilter* verifierFilter = new VerifierFilter(pub); - verifierFilter->Put(signature, pub.SignatureLength()); - FileSource f(messageFilename, true, verifierFilter); - - return verifierFilter->GetLastResult(); -} diff --git a/src/verify_signature/csharp/VerifySignature.cs b/src/verify_signature/csharp/VerifySignature.cs deleted file mode 100644 index c4413a66e8..0000000000 --- a/src/verify_signature/csharp/VerifySignature.cs +++ /dev/null @@ -1,395 +0,0 @@ -// Based on http://www.jensign.com/VerifySignature/dotnet/JKeyNet/ -// Parameters: -// public_key - X.509 standard SubjectPublicKeyInfo key in binary format -// data_file - the data file whose signature to verify -// signature - the signature of data_file in binary format -using System; -using System.IO; -using System.Text; -using System.Security; -using System.Security.Cryptography; -using System.Security.Cryptography.X509Certificates; -using System.Runtime.InteropServices; - -namespace VerifySignature -{ - - //--- P/Invoke CryptoAPI wrapper classes ----- - public class Win32 - { - - [DllImport("crypt32.dll")] - public static extern bool CryptDecodeObject( - uint CertEncodingType, - uint lpszStructType, - byte[] pbEncoded, - uint cbEncoded, - uint flags, - [In, Out] byte[] pvStructInfo, - ref uint cbStructInfo); - - - [DllImport("crypt32.dll")] - public static extern bool CryptDecodeObject( - uint CertEncodingType, - uint lpszStructType, - byte[] pbEncoded, - uint cbEncoded, - uint flags, - IntPtr pvStructInfo, - ref uint cbStructInfo); - } - - - [StructLayout(LayoutKind.Sequential)] - public struct PUBKEYBLOBHEADERS - { - public byte bType; //BLOBHEADER - public byte bVersion; //BLOBHEADER - public short reserved; //BLOBHEADER - public uint aiKeyAlg; //BLOBHEADER - public uint magic; //RSAPUBKEY - public uint bitlen; //RSAPUBKEY - public uint pubexp; //RSAPUBKEY - } - - - [StructLayout(LayoutKind.Sequential)] - public struct CERT_PUBLIC_KEY_INFO - { - public IntPtr SubjPKIAlgpszObjId; - public int SubjPKIAlgParameterscbData; - public IntPtr SubjPKIAlgParameterspbData; - public int PublicKeycbData; - public IntPtr PublicKeypbData; - public int PublicKeycUnusedBits; - } - - - public class RSAPubKeyData - { - - const uint X509_ASN_ENCODING = 0x00000001; - const uint PKCS_7_ASN_ENCODING = 0x00010000; - - const uint RSA_CSP_PUBLICKEYBLOB = 19; - const uint X509_PUBLIC_KEY_INFO = 8; - - const int AT_KEYEXCHANGE = 1; //keyspec values - const int AT_SIGNATURE = 2; - static uint ENCODING_TYPE = PKCS_7_ASN_ENCODING | X509_ASN_ENCODING ; - - const byte PUBLICKEYBLOB = 0x06; - const byte CUR_BLOB_VERSION = 0x02; - const ushort reserved = 0x0000; - const uint CALG_RSA_KEYX = 0x0000a400; - const uint CALG_RSA_SIGN = 0x00002400; - - - private byte[] keyModulus; // big-Endian - private byte[] keyExponent; // big-Endian - private byte[] publicKeyBlob; //Microsoft PUBLICKEYBLOB format - private uint keySize; //modulus size in bits - private bool verbose = false; - - - public uint keysize - { - get{return keySize;} - } - - public byte[] keymodulus - { - get{return keyModulus;} - } - - public byte[] keyexponent - { - get{return keyExponent;} - } - - public byte[] MSpublickeyblob - { - get{return publicKeyBlob;} - } - - public static string readFile(string file) - { - string finalStr=""; - try - { - // Create an instance of StreamReader to read from a file. - // The using statement also closes the StreamReader. - using (StreamReader sr = new StreamReader(file)) - { - String line; - // Read and display lines from the file until the end of - // the file is reached. - while ((line = sr.ReadLine()) != null) - { - //Console.WriteLine(line); - finalStr = finalStr+line; - } - return finalStr; - } - } - catch (Exception e) - { - // Let the user know what went wrong. - Console.WriteLine("The file could not be read:"); - Console.WriteLine(e.Message); - } - return null; - } - - public static void Main(String[] args) - { - RSAPubKeyData orsakey = new RSAPubKeyData(); - - if(args.Length<3) - { - Console.WriteLine("\nUsage: RSAPubKeyData.exe public_key data_fn signature_fn"); - return; - } - - String publickeyfn = args[0]; - String datafn = args[1]; - String signaturefn = args[2]; - - if (!File.Exists(publickeyfn)) - { - Console.WriteLine("File '{0}' not found.", publickeyfn); - return; - } - if (!File.Exists(datafn)) - { - Console.WriteLine("File '{0}' not found.", datafn); - return; - } - if (!File.Exists(signaturefn)) - { - Console.WriteLine("File '{0}' not found.", signaturefn); - return; - } - - Console.WriteLine("\n\n-------- Trying to decode keyfile as X.509 SubjectPublicKeyInfo format --------"); - if(!orsakey.DecodeSubjectPublicKeyInfo(publickeyfn)) - { - Console.WriteLine("FAILED to decode as X.509 SubjectPublicKeyInfo"); - return; - } - - Console.WriteLine("Decoded successfully as X.509 SubjectPublicKeyInfo"); - - RSAParameters RSAKeyInfo = new RSAParameters(); - RSACryptoServiceProvider RSA = new RSACryptoServiceProvider(); - - RSAKeyInfo.Modulus = orsakey.keymodulus; - RSAKeyInfo.Exponent = orsakey.keyexponent; - RSA.ImportParameters(RSAKeyInfo); - - byte[] data = GetFileBytes(datafn); - byte[] signature = GetFileBytes(signaturefn); - - if(RSA.VerifyData(data,"SHA1",signature)) - { - Console.WriteLine("The signature is valid."); - } - else - { - Console.WriteLine("The signature is not valid."); - } - } - - - //---- RSAPublicKey, PKCS #1 format ----- - public bool DecodeRSAPublicKey(String RSAPublicKeyfile) - { - if (!File.Exists(RSAPublicKeyfile)) - return false; - byte[] encodeddata = GetFileBytes(RSAPublicKeyfile); - return DecodeRSAPublicKey(encodeddata); - } - - - - - //---- SubjectPublicKeyInfo, X.509 standard format; e.g. Java getEncoded(); OpenSSL exported etc. - // --- decode first to RSAPublicKey encoded format ---- - public bool DecodeSubjectPublicKeyInfo(String SubjectPublicKeyInfoFile) - { - if (!File.Exists(SubjectPublicKeyInfoFile)) - return false; - byte[] subjectpublickeydata = GetFileBytes(SubjectPublicKeyInfoFile); - - IntPtr pcertpublickeyinfo = IntPtr.Zero ; - uint cbytes=0; - if(Win32.CryptDecodeObject(ENCODING_TYPE, X509_PUBLIC_KEY_INFO, subjectpublickeydata, (uint)subjectpublickeydata.Length, 0, IntPtr.Zero, ref cbytes)) - { - pcertpublickeyinfo = Marshal.AllocHGlobal((int)cbytes); - Win32.CryptDecodeObject(ENCODING_TYPE, X509_PUBLIC_KEY_INFO, subjectpublickeydata, (uint)subjectpublickeydata.Length, 0, pcertpublickeyinfo, ref cbytes); - CERT_PUBLIC_KEY_INFO pkinfo = (CERT_PUBLIC_KEY_INFO) Marshal.PtrToStructure(pcertpublickeyinfo, typeof(CERT_PUBLIC_KEY_INFO) ); - IntPtr pencodeddata = pkinfo.PublicKeypbData; - int cblob = pkinfo.PublicKeycbData ; - byte[] encodeddata = new byte[cblob]; - Marshal.Copy(pencodeddata, encodeddata, 0,cblob) ; //copy bytes from IntPtr to byte[] - Marshal.FreeHGlobal(pcertpublickeyinfo) ; - return DecodeRSAPublicKey(encodeddata); - } - else - { - return false; - } - } - - - - - - //----- decode public key and extract modulus and exponent from RSAPublicKey, PKCS #1 format byte[] ---- - public bool DecodeRSAPublicKey(byte[] encodedpubkey) - { - byte[] publickeyblob ; - - uint blobbytes=0; - if(Win32.CryptDecodeObject(ENCODING_TYPE, RSA_CSP_PUBLICKEYBLOB, encodedpubkey, (uint)encodedpubkey.Length, 0, null, ref blobbytes)) - { - publickeyblob = new byte[blobbytes]; - if(Win32.CryptDecodeObject(ENCODING_TYPE, RSA_CSP_PUBLICKEYBLOB, encodedpubkey, (uint)encodedpubkey.Length, 0, publickeyblob, ref blobbytes)) - if(verbose) - showBytes("CryptoAPI publickeyblob", publickeyblob); - } - else - { - return false; - } - this.publicKeyBlob = publickeyblob; - return DecodeMSPublicKeyBlob(publickeyblob); - } - - - - //---- Microsoft PUBLICKEYBLOB format ----- - public bool DecodeMSPublicKeyBlob(String publickeyblobfile) - { - if (!File.Exists(publickeyblobfile)) - return false; - byte[] publickeyblobdata = GetFileBytes(publickeyblobfile); - return DecodeMSPublicKeyBlob(publickeyblobdata); - } - - - - //----- Microsoft PUBLICKEYBLOB format ---- - public bool DecodeMSPublicKeyBlob(byte[] publickeyblob) - { - PUBKEYBLOBHEADERS pkheaders = new PUBKEYBLOBHEADERS() ; - int headerslength = Marshal.SizeOf(pkheaders); - IntPtr buffer = Marshal.AllocHGlobal( headerslength); - Marshal.Copy( publickeyblob, 0, buffer, headerslength ); - pkheaders = (PUBKEYBLOBHEADERS) Marshal.PtrToStructure( buffer, typeof(PUBKEYBLOBHEADERS) ); - Marshal.FreeHGlobal( buffer ); - - //----- basic sanity check of PUBLICKEYBLOB fields ------------ - if(pkheaders.bType != PUBLICKEYBLOB) - return false; - if(pkheaders.bVersion != CUR_BLOB_VERSION) - return false; - if(pkheaders.aiKeyAlg != CALG_RSA_KEYX && pkheaders.aiKeyAlg != CALG_RSA_SIGN) - return false; - - if(verbose) - { - Console.WriteLine("\n ---- PUBLICKEYBLOB headers ------"); - Console.WriteLine(" btype {0}", pkheaders.bType); - Console.WriteLine(" bversion {0}", pkheaders.bVersion); - Console.WriteLine(" reserved {0}", pkheaders.reserved); - Console.WriteLine(" aiKeyAlg 0x{0:x8}", pkheaders.aiKeyAlg); - String magicstring = (new ASCIIEncoding()).GetString(BitConverter.GetBytes(pkheaders.magic)) ; - Console.WriteLine(" magic 0x{0:x8} '{1}'", pkheaders.magic, magicstring); - Console.WriteLine(" bitlen {0}", pkheaders.bitlen); - Console.WriteLine(" pubexp {0}", pkheaders.pubexp); - Console.WriteLine(" --------------------------------"); - } - //----- Get public key size in bits ------------- - this.keySize = pkheaders.bitlen; - - //----- Get public exponent ------------- - byte[] exponent = BitConverter.GetBytes(pkheaders.pubexp); //little-endian ordered - Array.Reverse(exponent); //convert to big-endian order - this.keyExponent = exponent; - if(verbose) - showBytes("\nPublic key exponent (big-endian order):", exponent); - - //----- Get modulus ------------- - int modulusbytes = (int)pkheaders.bitlen/8 ; - byte[] modulus = new byte[modulusbytes]; - try - { - Array.Copy(publickeyblob, headerslength, modulus, 0, modulusbytes); - Array.Reverse(modulus); //convert from little to big-endian ordering. - this.keyModulus = modulus; - if(verbose) - showBytes("\nPublic key modulus (big-endian order):", modulus); - } - catch(Exception) - { - Console.WriteLine("Problem getting modulus from publickeyblob"); - return false; - } - return true; - } - - - private static byte[] GetFileBytes(String filename) - { - if(!File.Exists(filename)) - return null; - Stream stream=new FileStream(filename,FileMode.Open); - int datalen = (int)stream.Length; - byte[] filebytes =new byte[datalen]; - stream.Seek(0,SeekOrigin.Begin); - stream.Read(filebytes,0,datalen); - stream.Close(); - return filebytes; - } - - - private void PutFileBytes(String outfile, byte[] data, int bytes) - { - FileStream fs = null; - if(bytes > data.Length) - { - Console.WriteLine("Too many bytes"); - return; - } - try - { - fs = new FileStream(outfile, FileMode.Create); - fs.Write(data, 0, bytes); - } - catch(Exception e) - { - Console.WriteLine(e.Message) ; - } - finally - { - fs.Close(); - } - } - - - private static void showBytes(String info, byte[] data) - { - Console.WriteLine("{0} [{1} bytes]", info, data.Length); - for(int i=1; i<=data.Length; i++) - { - Console.Write("{0:X2} ", data[i-1]) ; - if(i%16 == 0) - Console.WriteLine(); - } - Console.WriteLine(); - } - - } -} diff --git a/src/verify_signature/java/VerifySignature.java b/src/verify_signature/java/VerifySignature.java deleted file mode 100644 index ff05569977..0000000000 --- a/src/verify_signature/java/VerifySignature.java +++ /dev/null @@ -1,218 +0,0 @@ -// Based on http://www.thecodeproject.com/useritems/Porting_Java_Public_Key.asp -// Parameters: -// public_key - X.509 standard SubjectPublicKeyInfo key in binary format -// data_file - the data file whose signature to verify -// signature - the signature of data_file in binary format - -/* - * Title: RSA Security - * Description: This class generates a RSA private and public key, reinstantiates - * the keys from the corresponding key files. It also generates compatible .Net Public Key, - * which we will read later in C# program using .Net Securtiy Framework - * The reinstantiated keys are used to sign and verify the given data.

- * - * @author Shaheryar - * @version 1.0 - */ - -import java.security.*; -import java.security.spec.*; -import java.io.*; -import java.security.interfaces.*; -import java.security.cert.*; -import javax.xml.transform.stream.*; -import javax.xml.transform.dom.*; -import javax.xml.transform.*; -import org.w3c.dom.*; -import javax.xml.parsers.*; - -public class VerifySignature -{ - private KeyPairGenerator keyGen; // Key pair generator for RSA - public PrivateKey privateKey; // Private Key Class - public PublicKey publicKey; // Public Key Class - public KeyPair keypair; // KeyPair Class - private Signature sign; // Signature, used to sign the data - /* Instantiates the key paths and signature algorithm. */ - public VerifySignature() - { - try { - // Get the instance of Signature Engine. - sign = Signature.getInstance("SHA1withRSA"); - } - catch (NoSuchAlgorithmException nsa) { - System.out.println("" + nsa.getMessage()); - } - } - - /* Initialize the public and private keys. */ - private void initializePublicKey(String publickey_fn) - { - try - { - // Read key files back and decode them from BASE64 - byte[] publicKeyBytes = readKeyBytesFromFile(publickey_fn); - - // Convert back to public and private key objects - KeyFactory keyFactory = KeyFactory.getInstance("RSA"); - EncodedKeySpec publicKeySpec = new X509EncodedKeySpec(publicKeyBytes); - publicKey = keyFactory.generatePublic(publicKeySpec); - } - catch (IOException io) { - System.out.println( "Public/Private key file not found."+ io.getCause() ); - } - catch (InvalidKeySpecException e) { - System.out.println( "Invalid Key Specs. Not valid key files."+ e.getCause() ); - } - catch (NoSuchAlgorithmException e) { - System.out.println( "There is no such algorithm. Please check the JDK ver."+ e.getCause() ); - } - } - - /* - * Verifies the signature for the given bytes using the public key. - * @param signature Signature - * @param data Data that was signed - * @return boolean True if valid signature else false - */ - public boolean verifySignature(String publickey_fn, byte[] signature, byte[] data) - { - try - { - initializePublicKey(publickey_fn); - sign.initVerify(publicKey); - sign.update(data); - return sign.verify(signature); - } - catch (SignatureException e) { - e.printStackTrace(); - } - catch (InvalidKeyException e) { - } - - return false; - } - - /** - * Returns the contents of the file in a byte array. - * @param fileName File Name - * @return byte[] The data read from a given file as a byte array. - */ - private byte[] readKeyBytesFromFile(String fileName) throws IOException - { - File file = new File(fileName); - InputStream is = new FileInputStream(file); - - // Get the size of the file - long length = file.length(); - - // You cannot create an array using a long type. - // It needs to be an int type. - // Before converting to an int type, check - // to ensure that file is not larger than Integer.MAX_VALUE. - if (length > Integer.MAX_VALUE) { - // File is too large - } - - // Create the byte array to hold the data - byte[] bytes = new byte[ (int) length]; - - // Read in the bytes - int offset = 0; - int numRead = 0; - while (offset < bytes.length - && (numRead = is.read(bytes, offset, bytes.length - offset)) >= 0) { - offset += numRead; - } - - // Ensure all the bytes have been read in - if (offset < bytes.length) { - throw new IOException("Key File Error: Could not completely read file " + file.getName()); - } - - // Close the input stream and return bytes - is.close(); - return bytes; - } - - - public static void main(String args[]) - { - VerifySignature sm = new VerifySignature(); - - /* - Uncomment next line for first time when you run the code,it will generate the keys. - Afterwards,the application will read the generated key files from the given location. - If you want to generate the key files each time, then you should keep it uncommented always. - */ - if( args.length != 3 ) - { - System.out.println("\nUsage: RSAPubKeyData.exe publickey_fn data_fn signature_fn"); - return; - } - - String publickeyfn = args[0]; - String datafn = args[1]; - String signaturefn = args[2]; - - - byte[] data = sm.readBytesFromFile(datafn); - byte[] signature = sm.readBytesFromFile(signaturefn); - - if( sm.verifySignature(publickeyfn,signature,data) ) - { - System.out.println("The signature is valid."); - } - else - { - System.out.println("The signature is not valid."); - } - } - - private byte[] readBytesFromFile(String fileName) - { - try - { - File file = new File(fileName); - InputStream is = new FileInputStream(file); - - // Get the size of the file - long length = file.length(); - - // You cannot create an array using a long type. - // It needs to be an int type. - // Before converting to an int type, check - // to ensure that file is not larger than Integer.MAX_VALUE. - if (length > Integer.MAX_VALUE) { - // File is too large - } - - // Create the byte array to hold the data - byte[] bytes = new byte[ (int) length]; - - // Read in the bytes - int offset = 0; - int numRead = 0; - while (offset < bytes.length - && (numRead = is.read(bytes, offset, bytes.length - offset)) >= 0) - { - offset += numRead; - } - - // Ensure all the bytes have been read in - if (offset < bytes.length) { - throw new IOException("Key File Error: Could not completely read file " + file.getName()); - } - - // Close the input stream and return bytes - is.close(); - return bytes; - } - catch(IOException ioe) - { - System.out.println("Exception occured while writing file"+ioe.getMessage()); - } - byte[] bytes = new byte[1]; - return bytes; - } -}