Initial import.
This commit is contained in:
parent
b46328de8a
commit
668a33395e
|
@ -0,0 +1,108 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?fileVersion 4.0.0?><cproject>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.settings">
|
||||
<cconfiguration id="converted.config.1240441408">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.core.defaultConfigDataProvider" id="converted.config.1240441408" moduleId="org.eclipse.cdt.core.settings" name="convertedConfig">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.PE" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.language.mapping"/>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
|
||||
</cconfiguration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="scannerConfiguration">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile"/>
|
||||
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile">
|
||||
<buildOutputProvider>
|
||||
<openAction enabled="true" filePath=""/>
|
||||
<parser enabled="true"/>
|
||||
</buildOutputProvider>
|
||||
<scannerInfoProvider id="specsFile">
|
||||
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
|
||||
<parser enabled="true"/>
|
||||
</scannerInfoProvider>
|
||||
</profile>
|
||||
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile">
|
||||
<buildOutputProvider>
|
||||
<openAction enabled="false" filePath=""/>
|
||||
<parser enabled="true"/>
|
||||
</buildOutputProvider>
|
||||
<scannerInfoProvider id="makefileGenerator">
|
||||
<runAction arguments="-f ${project_name}_scd.mk" command="make" useDefault="true"/>
|
||||
<parser enabled="false"/>
|
||||
</scannerInfoProvider>
|
||||
</profile>
|
||||
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile">
|
||||
<buildOutputProvider>
|
||||
<openAction enabled="false" filePath=""/>
|
||||
<parser enabled="true"/>
|
||||
</buildOutputProvider>
|
||||
<scannerInfoProvider id="specsFile">
|
||||
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
|
||||
<parser enabled="false"/>
|
||||
</scannerInfoProvider>
|
||||
</profile>
|
||||
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile">
|
||||
<buildOutputProvider>
|
||||
<openAction enabled="false" filePath=""/>
|
||||
<parser enabled="true"/>
|
||||
</buildOutputProvider>
|
||||
<scannerInfoProvider id="specsFile">
|
||||
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
|
||||
<parser enabled="false"/>
|
||||
</scannerInfoProvider>
|
||||
</profile>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.pathentry">
|
||||
<pathentry include="/usr/include/c++/4.3" kind="inc" path="" system="true"/>
|
||||
<pathentry include="/usr/include" kind="inc" path="" system="true"/>
|
||||
<pathentry kind="src" path=""/>
|
||||
<pathentry kind="out" path=""/>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets">
|
||||
<buildTargets>
|
||||
<target name="all" path="" targetID="org.eclipse.cdt.make.MakeTargetBuilder">
|
||||
<buildCommand>make</buildCommand>
|
||||
<buildTarget>all</buildTarget>
|
||||
<stopOnError>false</stopOnError>
|
||||
<useDefaultCommand>true</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
<target name="clean" path="" targetID="org.eclipse.cdt.make.MakeTargetBuilder">
|
||||
<buildCommand>make</buildCommand>
|
||||
<buildTarget>clean</buildTarget>
|
||||
<stopOnError>false</stopOnError>
|
||||
<useDefaultCommand>true</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
<target name="distclean" path="" targetID="org.eclipse.cdt.make.MakeTargetBuilder">
|
||||
<buildCommand>make</buildCommand>
|
||||
<buildTarget>distclean</buildTarget>
|
||||
<stopOnError>false</stopOnError>
|
||||
<useDefaultCommand>true</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
<target name="all" path="win32" targetID="org.eclipse.cdt.make.MakeTargetBuilder">
|
||||
<buildCommand>build_vc.cmd</buildCommand>
|
||||
<buildArguments/>
|
||||
<buildTarget>all</buildTarget>
|
||||
<stopOnError>false</stopOnError>
|
||||
<useDefaultCommand>false</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
<target name="clean" path="win32" targetID="org.eclipse.cdt.make.MakeTargetBuilder">
|
||||
<buildCommand>build_vc.cmd</buildCommand>
|
||||
<buildArguments/>
|
||||
<buildTarget>clean</buildTarget>
|
||||
<stopOnError>false</stopOnError>
|
||||
<useDefaultCommand>false</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
</buildTargets>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||
</cproject>
|
|
@ -0,0 +1,4 @@
|
|||
config.status
|
||||
.settings
|
||||
Makefile
|
||||
autom4te.cache
|
|
@ -0,0 +1,86 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>sfftobmp3</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.make.core.makeBuilder</name>
|
||||
<triggers>clean,full,incremental,</triggers>
|
||||
<arguments>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.core.errorOutputParser</key>
|
||||
<value>org.eclipse.cdt.core.MakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.VCErrorParser;</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.append_environment</key>
|
||||
<value>true</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.build.arguments</key>
|
||||
<value></value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.build.command</key>
|
||||
<value>make</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.build.location</key>
|
||||
<value></value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.build.target.auto</key>
|
||||
<value>all</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.build.target.clean</key>
|
||||
<value>clean</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.build.target.inc</key>
|
||||
<value>all</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.enableAutoBuild</key>
|
||||
<value>false</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.enableCleanBuild</key>
|
||||
<value>true</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.enableFullBuild</key>
|
||||
<value>true</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.enabledIncrementalBuild</key>
|
||||
<value>true</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.environment</key>
|
||||
<value></value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.stopOnError</key>
|
||||
<value>false</value>
|
||||
</dictionary>
|
||||
<dictionary>
|
||||
<key>org.eclipse.cdt.make.core.useDefaultBuildCmd</key>
|
||||
<value>true</value>
|
||||
</dictionary>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.make.core.ScannerConfigBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.cdt.core.cnature</nature>
|
||||
<nature>org.eclipse.cdt.make.core.makeNature</nature>
|
||||
<nature>org.eclipse.cdt.make.core.ScannerConfigNature</nature>
|
||||
<nature>org.eclipse.cdt.core.ccnature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
|
@ -0,0 +1,9 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<project>
|
||||
<configuration id="converted.config.1240441408" name="convertedConfig">
|
||||
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
|
||||
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
|
||||
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||
</extension>
|
||||
</configuration>
|
||||
</project>
|
|
@ -0,0 +1,3 @@
|
|||
## Makefile.am -- Process this file with automake to produce Makefile.in
|
||||
|
||||
SUBDIRS = src
|
|
@ -0,0 +1,662 @@
|
|||
# Makefile.in generated by automake 1.11.1 from Makefile.am.
|
||||
# @configure_input@
|
||||
|
||||
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
|
||||
# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
|
||||
# Inc.
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE.
|
||||
|
||||
@SET_MAKE@
|
||||
VPATH = @srcdir@
|
||||
pkgdatadir = $(datadir)/@PACKAGE@
|
||||
pkgincludedir = $(includedir)/@PACKAGE@
|
||||
pkglibdir = $(libdir)/@PACKAGE@
|
||||
pkglibexecdir = $(libexecdir)/@PACKAGE@
|
||||
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
|
||||
install_sh_DATA = $(install_sh) -c -m 644
|
||||
install_sh_PROGRAM = $(install_sh) -c
|
||||
install_sh_SCRIPT = $(install_sh) -c
|
||||
INSTALL_HEADER = $(INSTALL_DATA)
|
||||
transform = $(program_transform_name)
|
||||
NORMAL_INSTALL = :
|
||||
PRE_INSTALL = :
|
||||
POST_INSTALL = :
|
||||
NORMAL_UNINSTALL = :
|
||||
PRE_UNINSTALL = :
|
||||
POST_UNINSTALL = :
|
||||
subdir = .
|
||||
DIST_COMMON = $(am__configure_deps) $(srcdir)/Makefile.am \
|
||||
$(srcdir)/Makefile.in $(top_srcdir)/configure config/depcomp \
|
||||
config/install-sh config/missing config/mkinstalldirs
|
||||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||
am__aclocal_m4_deps = $(top_srcdir)/configure.ac
|
||||
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||
$(ACLOCAL_M4)
|
||||
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
|
||||
configure.lineno config.status.lineno
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/config/mkinstalldirs
|
||||
CONFIG_HEADER = $(top_builddir)/src/config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
CONFIG_CLEAN_VPATH_FILES =
|
||||
SOURCES =
|
||||
DIST_SOURCES =
|
||||
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
|
||||
html-recursive info-recursive install-data-recursive \
|
||||
install-dvi-recursive install-exec-recursive \
|
||||
install-html-recursive install-info-recursive \
|
||||
install-pdf-recursive install-ps-recursive install-recursive \
|
||||
installcheck-recursive installdirs-recursive pdf-recursive \
|
||||
ps-recursive uninstall-recursive
|
||||
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
|
||||
distclean-recursive maintainer-clean-recursive
|
||||
AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
|
||||
$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
|
||||
distdir dist dist-all distcheck
|
||||
ETAGS = etags
|
||||
CTAGS = ctags
|
||||
DIST_SUBDIRS = $(SUBDIRS)
|
||||
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||
distdir = $(PACKAGE)-$(VERSION)
|
||||
top_distdir = $(distdir)
|
||||
am__remove_distdir = \
|
||||
{ test ! -d "$(distdir)" \
|
||||
|| { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
|
||||
&& rm -fr "$(distdir)"; }; }
|
||||
am__relativize = \
|
||||
dir0=`pwd`; \
|
||||
sed_first='s,^\([^/]*\)/.*$$,\1,'; \
|
||||
sed_rest='s,^[^/]*/*,,'; \
|
||||
sed_last='s,^.*/\([^/]*\)$$,\1,'; \
|
||||
sed_butlast='s,/*[^/]*$$,,'; \
|
||||
while test -n "$$dir1"; do \
|
||||
first=`echo "$$dir1" | sed -e "$$sed_first"`; \
|
||||
if test "$$first" != "."; then \
|
||||
if test "$$first" = ".."; then \
|
||||
dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
|
||||
dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
|
||||
else \
|
||||
first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
|
||||
if test "$$first2" = "$$first"; then \
|
||||
dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
|
||||
else \
|
||||
dir2="../$$dir2"; \
|
||||
fi; \
|
||||
dir0="$$dir0"/"$$first"; \
|
||||
fi; \
|
||||
fi; \
|
||||
dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
|
||||
done; \
|
||||
reldir="$$dir2"
|
||||
DIST_ARCHIVES = $(distdir).tar.gz
|
||||
GZIP_ENV = --best
|
||||
distuninstallcheck_listfiles = find . -type f -print
|
||||
distcleancheck_listfiles = find . -type f -print
|
||||
ACLOCAL = @ACLOCAL@
|
||||
AMTAR = @AMTAR@
|
||||
AUTOCONF = @AUTOCONF@
|
||||
AUTOHEADER = @AUTOHEADER@
|
||||
AUTOMAKE = @AUTOMAKE@
|
||||
AWK = @AWK@
|
||||
CC = @CC@
|
||||
CCDEPMODE = @CCDEPMODE@
|
||||
CFLAGS = @CFLAGS@
|
||||
CPP = @CPP@
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
CXX = @CXX@
|
||||
CXXDEPMODE = @CXXDEPMODE@
|
||||
CXXFLAGS = @CXXFLAGS@
|
||||
CYGPATH_W = @CYGPATH_W@
|
||||
DEFS = @DEFS@
|
||||
DEPDIR = @DEPDIR@
|
||||
ECHO_C = @ECHO_C@
|
||||
ECHO_N = @ECHO_N@
|
||||
ECHO_T = @ECHO_T@
|
||||
EGREP = @EGREP@
|
||||
EXEEXT = @EXEEXT@
|
||||
GREP = @GREP@
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
|
||||
JPEG_LIB = @JPEG_LIB@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
LIBOBJS = @LIBOBJS@
|
||||
LIBS = @LIBS@
|
||||
LTLIBOBJS = @LTLIBOBJS@
|
||||
MAKEINFO = @MAKEINFO@
|
||||
MKDIR_P = @MKDIR_P@
|
||||
OBJEXT = @OBJEXT@
|
||||
PACKAGE = @PACKAGE@
|
||||
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
|
||||
PACKAGE_NAME = @PACKAGE_NAME@
|
||||
PACKAGE_STRING = @PACKAGE_STRING@
|
||||
PACKAGE_TARNAME = @PACKAGE_TARNAME@
|
||||
PACKAGE_URL = @PACKAGE_URL@
|
||||
PACKAGE_VERSION = @PACKAGE_VERSION@
|
||||
PATH_SEPARATOR = @PATH_SEPARATOR@
|
||||
SET_MAKE = @SET_MAKE@
|
||||
SHELL = @SHELL@
|
||||
STRIP = @STRIP@
|
||||
TIFF_LIB = @TIFF_LIB@
|
||||
VERSION = @VERSION@
|
||||
abs_builddir = @abs_builddir@
|
||||
abs_srcdir = @abs_srcdir@
|
||||
abs_top_builddir = @abs_top_builddir@
|
||||
abs_top_srcdir = @abs_top_srcdir@
|
||||
ac_ct_CC = @ac_ct_CC@
|
||||
ac_ct_CXX = @ac_ct_CXX@
|
||||
am__include = @am__include@
|
||||
am__leading_dot = @am__leading_dot@
|
||||
am__quote = @am__quote@
|
||||
am__tar = @am__tar@
|
||||
am__untar = @am__untar@
|
||||
bindir = @bindir@
|
||||
build_alias = @build_alias@
|
||||
builddir = @builddir@
|
||||
datadir = @datadir@
|
||||
datarootdir = @datarootdir@
|
||||
docdir = @docdir@
|
||||
dvidir = @dvidir@
|
||||
exec_prefix = @exec_prefix@
|
||||
host_alias = @host_alias@
|
||||
htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
localstatedir = @localstatedir@
|
||||
mandir = @mandir@
|
||||
mkdir_p = @mkdir_p@
|
||||
oldincludedir = @oldincludedir@
|
||||
pdfdir = @pdfdir@
|
||||
prefix = @prefix@
|
||||
program_transform_name = @program_transform_name@
|
||||
psdir = @psdir@
|
||||
sbindir = @sbindir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
srcdir = @srcdir@
|
||||
sysconfdir = @sysconfdir@
|
||||
target_alias = @target_alias@
|
||||
top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
SUBDIRS = src
|
||||
all: all-recursive
|
||||
|
||||
.SUFFIXES:
|
||||
am--refresh:
|
||||
@:
|
||||
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
|
||||
@for dep in $?; do \
|
||||
case '$(am__configure_deps)' in \
|
||||
*$$dep*) \
|
||||
echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \
|
||||
$(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \
|
||||
&& exit 0; \
|
||||
exit 1;; \
|
||||
esac; \
|
||||
done; \
|
||||
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
|
||||
$(am__cd) $(top_srcdir) && \
|
||||
$(AUTOMAKE) --foreign Makefile
|
||||
.PRECIOUS: Makefile
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||
@case '$?' in \
|
||||
*config.status*) \
|
||||
echo ' $(SHELL) ./config.status'; \
|
||||
$(SHELL) ./config.status;; \
|
||||
*) \
|
||||
echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
|
||||
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
|
||||
esac;
|
||||
|
||||
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
|
||||
$(SHELL) ./config.status --recheck
|
||||
|
||||
$(top_srcdir)/configure: $(am__configure_deps)
|
||||
$(am__cd) $(srcdir) && $(AUTOCONF)
|
||||
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
|
||||
$(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
|
||||
$(am__aclocal_m4_deps):
|
||||
|
||||
# This directory's subdirectories are mostly independent; you can cd
|
||||
# into them and run `make' without going through this Makefile.
|
||||
# To change the values of `make' variables: instead of editing Makefiles,
|
||||
# (1) if the variable is set in `config.status', edit `config.status'
|
||||
# (which will cause the Makefiles to be regenerated when you run `make');
|
||||
# (2) otherwise, pass the desired values on the `make' command line.
|
||||
$(RECURSIVE_TARGETS):
|
||||
@fail= failcom='exit 1'; \
|
||||
for f in x $$MAKEFLAGS; do \
|
||||
case $$f in \
|
||||
*=* | --[!k]*);; \
|
||||
*k*) failcom='fail=yes';; \
|
||||
esac; \
|
||||
done; \
|
||||
dot_seen=no; \
|
||||
target=`echo $@ | sed s/-recursive//`; \
|
||||
list='$(SUBDIRS)'; for subdir in $$list; do \
|
||||
echo "Making $$target in $$subdir"; \
|
||||
if test "$$subdir" = "."; then \
|
||||
dot_seen=yes; \
|
||||
local_target="$$target-am"; \
|
||||
else \
|
||||
local_target="$$target"; \
|
||||
fi; \
|
||||
($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|
||||
|| eval $$failcom; \
|
||||
done; \
|
||||
if test "$$dot_seen" = "no"; then \
|
||||
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
|
||||
fi; test -z "$$fail"
|
||||
|
||||
$(RECURSIVE_CLEAN_TARGETS):
|
||||
@fail= failcom='exit 1'; \
|
||||
for f in x $$MAKEFLAGS; do \
|
||||
case $$f in \
|
||||
*=* | --[!k]*);; \
|
||||
*k*) failcom='fail=yes';; \
|
||||
esac; \
|
||||
done; \
|
||||
dot_seen=no; \
|
||||
case "$@" in \
|
||||
distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
|
||||
*) list='$(SUBDIRS)' ;; \
|
||||
esac; \
|
||||
rev=''; for subdir in $$list; do \
|
||||
if test "$$subdir" = "."; then :; else \
|
||||
rev="$$subdir $$rev"; \
|
||||
fi; \
|
||||
done; \
|
||||
rev="$$rev ."; \
|
||||
target=`echo $@ | sed s/-recursive//`; \
|
||||
for subdir in $$rev; do \
|
||||
echo "Making $$target in $$subdir"; \
|
||||
if test "$$subdir" = "."; then \
|
||||
local_target="$$target-am"; \
|
||||
else \
|
||||
local_target="$$target"; \
|
||||
fi; \
|
||||
($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|
||||
|| eval $$failcom; \
|
||||
done && test -z "$$fail"
|
||||
tags-recursive:
|
||||
list='$(SUBDIRS)'; for subdir in $$list; do \
|
||||
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
|
||||
done
|
||||
ctags-recursive:
|
||||
list='$(SUBDIRS)'; for subdir in $$list; do \
|
||||
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
|
||||
done
|
||||
|
||||
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
|
||||
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
mkid -fID $$unique
|
||||
tags: TAGS
|
||||
|
||||
TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||
$(TAGS_FILES) $(LISP)
|
||||
set x; \
|
||||
here=`pwd`; \
|
||||
if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
|
||||
include_option=--etags-include; \
|
||||
empty_fix=.; \
|
||||
else \
|
||||
include_option=--include; \
|
||||
empty_fix=; \
|
||||
fi; \
|
||||
list='$(SUBDIRS)'; for subdir in $$list; do \
|
||||
if test "$$subdir" = .; then :; else \
|
||||
test ! -f $$subdir/TAGS || \
|
||||
set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
|
||||
fi; \
|
||||
done; \
|
||||
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
shift; \
|
||||
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
|
||||
test -n "$$unique" || unique=$$empty_fix; \
|
||||
if test $$# -gt 0; then \
|
||||
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||
"$$@" $$unique; \
|
||||
else \
|
||||
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||
$$unique; \
|
||||
fi; \
|
||||
fi
|
||||
ctags: CTAGS
|
||||
CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||
$(TAGS_FILES) $(LISP)
|
||||
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
test -z "$(CTAGS_ARGS)$$unique" \
|
||||
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
|
||||
$$unique
|
||||
|
||||
GTAGS:
|
||||
here=`$(am__cd) $(top_builddir) && pwd` \
|
||||
&& $(am__cd) $(top_srcdir) \
|
||||
&& gtags -i $(GTAGS_ARGS) "$$here"
|
||||
|
||||
distclean-tags:
|
||||
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
|
||||
|
||||
distdir: $(DISTFILES)
|
||||
$(am__remove_distdir)
|
||||
test -d "$(distdir)" || mkdir "$(distdir)"
|
||||
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
list='$(DISTFILES)'; \
|
||||
dist_files=`for file in $$list; do echo $$file; done | \
|
||||
sed -e "s|^$$srcdirstrip/||;t" \
|
||||
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
|
||||
case $$dist_files in \
|
||||
*/*) $(MKDIR_P) `echo "$$dist_files" | \
|
||||
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
|
||||
sort -u` ;; \
|
||||
esac; \
|
||||
for file in $$dist_files; do \
|
||||
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
|
||||
if test -d $$d/$$file; then \
|
||||
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
|
||||
if test -d "$(distdir)/$$file"; then \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
|
||||
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
|
||||
else \
|
||||
test -f "$(distdir)/$$file" \
|
||||
|| cp -p $$d/$$file "$(distdir)/$$file" \
|
||||
|| exit 1; \
|
||||
fi; \
|
||||
done
|
||||
@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
|
||||
if test "$$subdir" = .; then :; else \
|
||||
test -d "$(distdir)/$$subdir" \
|
||||
|| $(MKDIR_P) "$(distdir)/$$subdir" \
|
||||
|| exit 1; \
|
||||
fi; \
|
||||
done
|
||||
@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
|
||||
if test "$$subdir" = .; then :; else \
|
||||
dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
|
||||
$(am__relativize); \
|
||||
new_distdir=$$reldir; \
|
||||
dir1=$$subdir; dir2="$(top_distdir)"; \
|
||||
$(am__relativize); \
|
||||
new_top_distdir=$$reldir; \
|
||||
echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
|
||||
echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
|
||||
($(am__cd) $$subdir && \
|
||||
$(MAKE) $(AM_MAKEFLAGS) \
|
||||
top_distdir="$$new_top_distdir" \
|
||||
distdir="$$new_distdir" \
|
||||
am__remove_distdir=: \
|
||||
am__skip_length_check=: \
|
||||
am__skip_mode_fix=: \
|
||||
distdir) \
|
||||
|| exit 1; \
|
||||
fi; \
|
||||
done
|
||||
-test -n "$(am__skip_mode_fix)" \
|
||||
|| find "$(distdir)" -type d ! -perm -755 \
|
||||
-exec chmod u+rwx,go+rx {} \; -o \
|
||||
! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
|
||||
! -type d ! -perm -400 -exec chmod a+r {} \; -o \
|
||||
! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
|
||||
|| chmod -R a+r "$(distdir)"
|
||||
dist-gzip: distdir
|
||||
tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
|
||||
$(am__remove_distdir)
|
||||
|
||||
dist-bzip2: distdir
|
||||
tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2
|
||||
$(am__remove_distdir)
|
||||
|
||||
dist-lzma: distdir
|
||||
tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
|
||||
$(am__remove_distdir)
|
||||
|
||||
dist-xz: distdir
|
||||
tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz
|
||||
$(am__remove_distdir)
|
||||
|
||||
dist-tarZ: distdir
|
||||
tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
|
||||
$(am__remove_distdir)
|
||||
|
||||
dist-shar: distdir
|
||||
shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
|
||||
$(am__remove_distdir)
|
||||
|
||||
dist-zip: distdir
|
||||
-rm -f $(distdir).zip
|
||||
zip -rq $(distdir).zip $(distdir)
|
||||
$(am__remove_distdir)
|
||||
|
||||
dist dist-all: distdir
|
||||
tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
|
||||
$(am__remove_distdir)
|
||||
|
||||
# This target untars the dist file and tries a VPATH configuration. Then
|
||||
# it guarantees that the distribution is self-contained by making another
|
||||
# tarfile.
|
||||
distcheck: dist
|
||||
case '$(DIST_ARCHIVES)' in \
|
||||
*.tar.gz*) \
|
||||
GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
|
||||
*.tar.bz2*) \
|
||||
bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
|
||||
*.tar.lzma*) \
|
||||
lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\
|
||||
*.tar.xz*) \
|
||||
xz -dc $(distdir).tar.xz | $(am__untar) ;;\
|
||||
*.tar.Z*) \
|
||||
uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
|
||||
*.shar.gz*) \
|
||||
GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\
|
||||
*.zip*) \
|
||||
unzip $(distdir).zip ;;\
|
||||
esac
|
||||
chmod -R a-w $(distdir); chmod a+w $(distdir)
|
||||
mkdir $(distdir)/_build
|
||||
mkdir $(distdir)/_inst
|
||||
chmod a-w $(distdir)
|
||||
test -d $(distdir)/_build || exit 0; \
|
||||
dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
|
||||
&& dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
|
||||
&& am__cwd=`pwd` \
|
||||
&& $(am__cd) $(distdir)/_build \
|
||||
&& ../configure --srcdir=.. --prefix="$$dc_install_base" \
|
||||
$(DISTCHECK_CONFIGURE_FLAGS) \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) check \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) install \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) installcheck \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) uninstall \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \
|
||||
distuninstallcheck \
|
||||
&& chmod -R a-w "$$dc_install_base" \
|
||||
&& ({ \
|
||||
(cd ../.. && umask 077 && mkdir "$$dc_destdir") \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \
|
||||
distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \
|
||||
} || { rm -rf "$$dc_destdir"; exit 1; }) \
|
||||
&& rm -rf "$$dc_destdir" \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) dist \
|
||||
&& rm -rf $(DIST_ARCHIVES) \
|
||||
&& $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
|
||||
&& cd "$$am__cwd" \
|
||||
|| exit 1
|
||||
$(am__remove_distdir)
|
||||
@(echo "$(distdir) archives ready for distribution: "; \
|
||||
list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
|
||||
sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
|
||||
distuninstallcheck:
|
||||
@$(am__cd) '$(distuninstallcheck_dir)' \
|
||||
&& test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \
|
||||
|| { echo "ERROR: files left after uninstall:" ; \
|
||||
if test -n "$(DESTDIR)"; then \
|
||||
echo " (check DESTDIR support)"; \
|
||||
fi ; \
|
||||
$(distuninstallcheck_listfiles) ; \
|
||||
exit 1; } >&2
|
||||
distcleancheck: distclean
|
||||
@if test '$(srcdir)' = . ; then \
|
||||
echo "ERROR: distcleancheck can only run from a VPATH build" ; \
|
||||
exit 1 ; \
|
||||
fi
|
||||
@test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
|
||||
|| { echo "ERROR: files left in build directory after distclean:" ; \
|
||||
$(distcleancheck_listfiles) ; \
|
||||
exit 1; } >&2
|
||||
check-am: all-am
|
||||
check: check-recursive
|
||||
all-am: Makefile
|
||||
installdirs: installdirs-recursive
|
||||
installdirs-am:
|
||||
install: install-recursive
|
||||
install-exec: install-exec-recursive
|
||||
install-data: install-data-recursive
|
||||
uninstall: uninstall-recursive
|
||||
|
||||
install-am: all-am
|
||||
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
|
||||
|
||||
installcheck: installcheck-recursive
|
||||
install-strip:
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
`test -z '$(STRIP)' || \
|
||||
echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
|
||||
mostlyclean-generic:
|
||||
|
||||
clean-generic:
|
||||
|
||||
distclean-generic:
|
||||
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
|
||||
|
||||
maintainer-clean-generic:
|
||||
@echo "This command is intended for maintainers to use"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
clean: clean-recursive
|
||||
|
||||
clean-am: clean-generic mostlyclean-am
|
||||
|
||||
distclean: distclean-recursive
|
||||
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
|
||||
-rm -f Makefile
|
||||
distclean-am: clean-am distclean-generic distclean-tags
|
||||
|
||||
dvi: dvi-recursive
|
||||
|
||||
dvi-am:
|
||||
|
||||
html: html-recursive
|
||||
|
||||
html-am:
|
||||
|
||||
info: info-recursive
|
||||
|
||||
info-am:
|
||||
|
||||
install-data-am:
|
||||
|
||||
install-dvi: install-dvi-recursive
|
||||
|
||||
install-dvi-am:
|
||||
|
||||
install-exec-am:
|
||||
|
||||
install-html: install-html-recursive
|
||||
|
||||
install-html-am:
|
||||
|
||||
install-info: install-info-recursive
|
||||
|
||||
install-info-am:
|
||||
|
||||
install-man:
|
||||
|
||||
install-pdf: install-pdf-recursive
|
||||
|
||||
install-pdf-am:
|
||||
|
||||
install-ps: install-ps-recursive
|
||||
|
||||
install-ps-am:
|
||||
|
||||
installcheck-am:
|
||||
|
||||
maintainer-clean: maintainer-clean-recursive
|
||||
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
|
||||
-rm -rf $(top_srcdir)/autom4te.cache
|
||||
-rm -f Makefile
|
||||
maintainer-clean-am: distclean-am maintainer-clean-generic
|
||||
|
||||
mostlyclean: mostlyclean-recursive
|
||||
|
||||
mostlyclean-am: mostlyclean-generic
|
||||
|
||||
pdf: pdf-recursive
|
||||
|
||||
pdf-am:
|
||||
|
||||
ps: ps-recursive
|
||||
|
||||
ps-am:
|
||||
|
||||
uninstall-am:
|
||||
|
||||
.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
|
||||
install-am install-strip tags-recursive
|
||||
|
||||
.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
|
||||
all all-am am--refresh check check-am clean clean-generic \
|
||||
ctags ctags-recursive dist dist-all dist-bzip2 dist-gzip \
|
||||
dist-lzma dist-shar dist-tarZ dist-xz dist-zip distcheck \
|
||||
distclean distclean-generic distclean-tags distcleancheck \
|
||||
distdir distuninstallcheck dvi dvi-am html html-am info \
|
||||
info-am install install-am install-data install-data-am \
|
||||
install-dvi install-dvi-am install-exec install-exec-am \
|
||||
install-html install-html-am install-info install-info-am \
|
||||
install-man install-pdf install-pdf-am install-ps \
|
||||
install-ps-am install-strip installcheck installcheck-am \
|
||||
installdirs installdirs-am maintainer-clean \
|
||||
maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
|
||||
pdf-am ps ps-am tags tags-recursive uninstall uninstall-am
|
||||
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
|
@ -0,0 +1,963 @@
|
|||
# generated automatically by aclocal 1.11.1 -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
|
||||
# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE.
|
||||
|
||||
m4_ifndef([AC_AUTOCONF_VERSION],
|
||||
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
|
||||
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],,
|
||||
[m4_warning([this file was generated for autoconf 2.65.
|
||||
You have another version of autoconf. It may work, but is not guaranteed to.
|
||||
If you have problems, you may need to regenerate the build system entirely.
|
||||
To do so, use the procedure documented by the package, typically `autoreconf'.])])
|
||||
|
||||
# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# AM_AUTOMAKE_VERSION(VERSION)
|
||||
# ----------------------------
|
||||
# Automake X.Y traces this macro to ensure aclocal.m4 has been
|
||||
# generated from the m4 files accompanying Automake X.Y.
|
||||
# (This private macro should not be called outside this file.)
|
||||
AC_DEFUN([AM_AUTOMAKE_VERSION],
|
||||
[am__api_version='1.11'
|
||||
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
|
||||
dnl require some minimum version. Point them to the right macro.
|
||||
m4_if([$1], [1.11.1], [],
|
||||
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
|
||||
])
|
||||
|
||||
# _AM_AUTOCONF_VERSION(VERSION)
|
||||
# -----------------------------
|
||||
# aclocal traces this macro to find the Autoconf version.
|
||||
# This is a private macro too. Using m4_define simplifies
|
||||
# the logic in aclocal, which can simply ignore this definition.
|
||||
m4_define([_AM_AUTOCONF_VERSION], [])
|
||||
|
||||
# AM_SET_CURRENT_AUTOMAKE_VERSION
|
||||
# -------------------------------
|
||||
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
|
||||
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
|
||||
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
|
||||
[AM_AUTOMAKE_VERSION([1.11.1])dnl
|
||||
m4_ifndef([AC_AUTOCONF_VERSION],
|
||||
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
|
||||
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
|
||||
|
||||
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
|
||||
# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
|
||||
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
|
||||
#
|
||||
# Of course, Automake must honor this variable whenever it calls a
|
||||
# tool from the auxiliary directory. The problem is that $srcdir (and
|
||||
# therefore $ac_aux_dir as well) can be either absolute or relative,
|
||||
# depending on how configure is run. This is pretty annoying, since
|
||||
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
|
||||
# source directory, any form will work fine, but in subdirectories a
|
||||
# relative path needs to be adjusted first.
|
||||
#
|
||||
# $ac_aux_dir/missing
|
||||
# fails when called from a subdirectory if $ac_aux_dir is relative
|
||||
# $top_srcdir/$ac_aux_dir/missing
|
||||
# fails if $ac_aux_dir is absolute,
|
||||
# fails when called from a subdirectory in a VPATH build with
|
||||
# a relative $ac_aux_dir
|
||||
#
|
||||
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
|
||||
# are both prefixed by $srcdir. In an in-source build this is usually
|
||||
# harmless because $srcdir is `.', but things will broke when you
|
||||
# start a VPATH build or use an absolute $srcdir.
|
||||
#
|
||||
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
|
||||
# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
|
||||
# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
|
||||
# and then we would define $MISSING as
|
||||
# MISSING="\${SHELL} $am_aux_dir/missing"
|
||||
# This will work as long as MISSING is not called from configure, because
|
||||
# unfortunately $(top_srcdir) has no meaning in configure.
|
||||
# However there are other variables, like CC, which are often used in
|
||||
# configure, and could therefore not use this "fixed" $ac_aux_dir.
|
||||
#
|
||||
# Another solution, used here, is to always expand $ac_aux_dir to an
|
||||
# absolute PATH. The drawback is that using absolute paths prevent a
|
||||
# configured tree to be moved without reconfiguration.
|
||||
|
||||
AC_DEFUN([AM_AUX_DIR_EXPAND],
|
||||
[dnl Rely on autoconf to set up CDPATH properly.
|
||||
AC_PREREQ([2.50])dnl
|
||||
# expand $ac_aux_dir to an absolute path
|
||||
am_aux_dir=`cd $ac_aux_dir && pwd`
|
||||
])
|
||||
|
||||
# AM_CONDITIONAL -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
|
||||
# Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 9
|
||||
|
||||
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
|
||||
# -------------------------------------
|
||||
# Define a conditional.
|
||||
AC_DEFUN([AM_CONDITIONAL],
|
||||
[AC_PREREQ(2.52)dnl
|
||||
ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
|
||||
[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
|
||||
AC_SUBST([$1_TRUE])dnl
|
||||
AC_SUBST([$1_FALSE])dnl
|
||||
_AM_SUBST_NOTMAKE([$1_TRUE])dnl
|
||||
_AM_SUBST_NOTMAKE([$1_FALSE])dnl
|
||||
m4_define([_AM_COND_VALUE_$1], [$2])dnl
|
||||
if $2; then
|
||||
$1_TRUE=
|
||||
$1_FALSE='#'
|
||||
else
|
||||
$1_TRUE='#'
|
||||
$1_FALSE=
|
||||
fi
|
||||
AC_CONFIG_COMMANDS_PRE(
|
||||
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
|
||||
AC_MSG_ERROR([[conditional "$1" was never defined.
|
||||
Usually this means the macro was only invoked conditionally.]])
|
||||
fi])])
|
||||
|
||||
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009
|
||||
# Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 10
|
||||
|
||||
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
|
||||
# written in clear, in which case automake, when reading aclocal.m4,
|
||||
# will think it sees a *use*, and therefore will trigger all it's
|
||||
# C support machinery. Also note that it means that autoscan, seeing
|
||||
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
|
||||
|
||||
|
||||
# _AM_DEPENDENCIES(NAME)
|
||||
# ----------------------
|
||||
# See how the compiler implements dependency checking.
|
||||
# NAME is "CC", "CXX", "GCJ", or "OBJC".
|
||||
# We try a few techniques and use that to set a single cache variable.
|
||||
#
|
||||
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
|
||||
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
|
||||
# dependency, and given that the user is not expected to run this macro,
|
||||
# just rely on AC_PROG_CC.
|
||||
AC_DEFUN([_AM_DEPENDENCIES],
|
||||
[AC_REQUIRE([AM_SET_DEPDIR])dnl
|
||||
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
|
||||
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
|
||||
AC_REQUIRE([AM_DEP_TRACK])dnl
|
||||
|
||||
ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
|
||||
[$1], CXX, [depcc="$CXX" am_compiler_list=],
|
||||
[$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
|
||||
[$1], UPC, [depcc="$UPC" am_compiler_list=],
|
||||
[$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
|
||||
[depcc="$$1" am_compiler_list=])
|
||||
|
||||
AC_CACHE_CHECK([dependency style of $depcc],
|
||||
[am_cv_$1_dependencies_compiler_type],
|
||||
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
|
||||
# We make a subdir and do the tests there. Otherwise we can end up
|
||||
# making bogus files that we don't know about and never remove. For
|
||||
# instance it was reported that on HP-UX the gcc test will end up
|
||||
# making a dummy file named `D' -- because `-MD' means `put the output
|
||||
# in D'.
|
||||
mkdir conftest.dir
|
||||
# Copy depcomp to subdir because otherwise we won't find it if we're
|
||||
# using a relative directory.
|
||||
cp "$am_depcomp" conftest.dir
|
||||
cd conftest.dir
|
||||
# We will build objects and dependencies in a subdirectory because
|
||||
# it helps to detect inapplicable dependency modes. For instance
|
||||
# both Tru64's cc and ICC support -MD to output dependencies as a
|
||||
# side effect of compilation, but ICC will put the dependencies in
|
||||
# the current directory while Tru64 will put them in the object
|
||||
# directory.
|
||||
mkdir sub
|
||||
|
||||
am_cv_$1_dependencies_compiler_type=none
|
||||
if test "$am_compiler_list" = ""; then
|
||||
am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
|
||||
fi
|
||||
am__universal=false
|
||||
m4_case([$1], [CC],
|
||||
[case " $depcc " in #(
|
||||
*\ -arch\ *\ -arch\ *) am__universal=true ;;
|
||||
esac],
|
||||
[CXX],
|
||||
[case " $depcc " in #(
|
||||
*\ -arch\ *\ -arch\ *) am__universal=true ;;
|
||||
esac])
|
||||
|
||||
for depmode in $am_compiler_list; do
|
||||
# Setup a source with many dependencies, because some compilers
|
||||
# like to wrap large dependency lists on column 80 (with \), and
|
||||
# we should not choose a depcomp mode which is confused by this.
|
||||
#
|
||||
# We need to recreate these files for each test, as the compiler may
|
||||
# overwrite some of them when testing with obscure command lines.
|
||||
# This happens at least with the AIX C compiler.
|
||||
: > sub/conftest.c
|
||||
for i in 1 2 3 4 5 6; do
|
||||
echo '#include "conftst'$i'.h"' >> sub/conftest.c
|
||||
# Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
|
||||
# Solaris 8's {/usr,}/bin/sh.
|
||||
touch sub/conftst$i.h
|
||||
done
|
||||
echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
|
||||
|
||||
# We check with `-c' and `-o' for the sake of the "dashmstdout"
|
||||
# mode. It turns out that the SunPro C++ compiler does not properly
|
||||
# handle `-M -o', and we need to detect this. Also, some Intel
|
||||
# versions had trouble with output in subdirs
|
||||
am__obj=sub/conftest.${OBJEXT-o}
|
||||
am__minus_obj="-o $am__obj"
|
||||
case $depmode in
|
||||
gcc)
|
||||
# This depmode causes a compiler race in universal mode.
|
||||
test "$am__universal" = false || continue
|
||||
;;
|
||||
nosideeffect)
|
||||
# after this tag, mechanisms are not by side-effect, so they'll
|
||||
# only be used when explicitly requested
|
||||
if test "x$enable_dependency_tracking" = xyes; then
|
||||
continue
|
||||
else
|
||||
break
|
||||
fi
|
||||
;;
|
||||
msvisualcpp | msvcmsys)
|
||||
# This compiler won't grok `-c -o', but also, the minuso test has
|
||||
# not run yet. These depmodes are late enough in the game, and
|
||||
# so weak that their functioning should not be impacted.
|
||||
am__obj=conftest.${OBJEXT-o}
|
||||
am__minus_obj=
|
||||
;;
|
||||
none) break ;;
|
||||
esac
|
||||
if depmode=$depmode \
|
||||
source=sub/conftest.c object=$am__obj \
|
||||
depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
|
||||
$SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
|
||||
>/dev/null 2>conftest.err &&
|
||||
grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
|
||||
grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
|
||||
grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
|
||||
${MAKE-make} -s -f confmf > /dev/null 2>&1; then
|
||||
# icc doesn't choke on unknown options, it will just issue warnings
|
||||
# or remarks (even with -Werror). So we grep stderr for any message
|
||||
# that says an option was ignored or not supported.
|
||||
# When given -MP, icc 7.0 and 7.1 complain thusly:
|
||||
# icc: Command line warning: ignoring option '-M'; no argument required
|
||||
# The diagnosis changed in icc 8.0:
|
||||
# icc: Command line remark: option '-MP' not supported
|
||||
if (grep 'ignoring option' conftest.err ||
|
||||
grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
|
||||
am_cv_$1_dependencies_compiler_type=$depmode
|
||||
break
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
cd ..
|
||||
rm -rf conftest.dir
|
||||
else
|
||||
am_cv_$1_dependencies_compiler_type=none
|
||||
fi
|
||||
])
|
||||
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
|
||||
AM_CONDITIONAL([am__fastdep$1], [
|
||||
test "x$enable_dependency_tracking" != xno \
|
||||
&& test "$am_cv_$1_dependencies_compiler_type" = gcc3])
|
||||
])
|
||||
|
||||
|
||||
# AM_SET_DEPDIR
|
||||
# -------------
|
||||
# Choose a directory name for dependency files.
|
||||
# This macro is AC_REQUIREd in _AM_DEPENDENCIES
|
||||
AC_DEFUN([AM_SET_DEPDIR],
|
||||
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
|
||||
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
|
||||
])
|
||||
|
||||
|
||||
# AM_DEP_TRACK
|
||||
# ------------
|
||||
AC_DEFUN([AM_DEP_TRACK],
|
||||
[AC_ARG_ENABLE(dependency-tracking,
|
||||
[ --disable-dependency-tracking speeds up one-time build
|
||||
--enable-dependency-tracking do not reject slow dependency extractors])
|
||||
if test "x$enable_dependency_tracking" != xno; then
|
||||
am_depcomp="$ac_aux_dir/depcomp"
|
||||
AMDEPBACKSLASH='\'
|
||||
fi
|
||||
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
|
||||
AC_SUBST([AMDEPBACKSLASH])dnl
|
||||
_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
|
||||
])
|
||||
|
||||
# Generate code to set up dependency tracking. -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
|
||||
# Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
#serial 5
|
||||
|
||||
# _AM_OUTPUT_DEPENDENCY_COMMANDS
|
||||
# ------------------------------
|
||||
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
|
||||
[{
|
||||
# Autoconf 2.62 quotes --file arguments for eval, but not when files
|
||||
# are listed without --file. Let's play safe and only enable the eval
|
||||
# if we detect the quoting.
|
||||
case $CONFIG_FILES in
|
||||
*\'*) eval set x "$CONFIG_FILES" ;;
|
||||
*) set x $CONFIG_FILES ;;
|
||||
esac
|
||||
shift
|
||||
for mf
|
||||
do
|
||||
# Strip MF so we end up with the name of the file.
|
||||
mf=`echo "$mf" | sed -e 's/:.*$//'`
|
||||
# Check whether this is an Automake generated Makefile or not.
|
||||
# We used to match only the files named `Makefile.in', but
|
||||
# some people rename them; so instead we look at the file content.
|
||||
# Grep'ing the first line is not enough: some people post-process
|
||||
# each Makefile.in and add a new line on top of each file to say so.
|
||||
# Grep'ing the whole file is not good either: AIX grep has a line
|
||||
# limit of 2048, but all sed's we know have understand at least 4000.
|
||||
if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
|
||||
dirpart=`AS_DIRNAME("$mf")`
|
||||
else
|
||||
continue
|
||||
fi
|
||||
# Extract the definition of DEPDIR, am__include, and am__quote
|
||||
# from the Makefile without running `make'.
|
||||
DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
|
||||
test -z "$DEPDIR" && continue
|
||||
am__include=`sed -n 's/^am__include = //p' < "$mf"`
|
||||
test -z "am__include" && continue
|
||||
am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
|
||||
# When using ansi2knr, U may be empty or an underscore; expand it
|
||||
U=`sed -n 's/^U = //p' < "$mf"`
|
||||
# Find all dependency output files, they are included files with
|
||||
# $(DEPDIR) in their names. We invoke sed twice because it is the
|
||||
# simplest approach to changing $(DEPDIR) to its actual value in the
|
||||
# expansion.
|
||||
for file in `sed -n "
|
||||
s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
|
||||
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
|
||||
# Make sure the directory exists.
|
||||
test -f "$dirpart/$file" && continue
|
||||
fdir=`AS_DIRNAME(["$file"])`
|
||||
AS_MKDIR_P([$dirpart/$fdir])
|
||||
# echo "creating $dirpart/$file"
|
||||
echo '# dummy' > "$dirpart/$file"
|
||||
done
|
||||
done
|
||||
}
|
||||
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
|
||||
|
||||
|
||||
# AM_OUTPUT_DEPENDENCY_COMMANDS
|
||||
# -----------------------------
|
||||
# This macro should only be invoked once -- use via AC_REQUIRE.
|
||||
#
|
||||
# This code is only required when automatic dependency tracking
|
||||
# is enabled. FIXME. This creates each `.P' file that we will
|
||||
# need in order to bootstrap the dependency handling code.
|
||||
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
|
||||
[AC_CONFIG_COMMANDS([depfiles],
|
||||
[test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
|
||||
[AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
|
||||
])
|
||||
|
||||
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
|
||||
# Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 8
|
||||
|
||||
# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS.
|
||||
AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
|
||||
|
||||
# Do all the work for Automake. -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
|
||||
# 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 16
|
||||
|
||||
# This macro actually does too much. Some checks are only needed if
|
||||
# your package does certain things. But this isn't really a big deal.
|
||||
|
||||
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
|
||||
# AM_INIT_AUTOMAKE([OPTIONS])
|
||||
# -----------------------------------------------
|
||||
# The call with PACKAGE and VERSION arguments is the old style
|
||||
# call (pre autoconf-2.50), which is being phased out. PACKAGE
|
||||
# and VERSION should now be passed to AC_INIT and removed from
|
||||
# the call to AM_INIT_AUTOMAKE.
|
||||
# We support both call styles for the transition. After
|
||||
# the next Automake release, Autoconf can make the AC_INIT
|
||||
# arguments mandatory, and then we can depend on a new Autoconf
|
||||
# release and drop the old call support.
|
||||
AC_DEFUN([AM_INIT_AUTOMAKE],
|
||||
[AC_PREREQ([2.62])dnl
|
||||
dnl Autoconf wants to disallow AM_ names. We explicitly allow
|
||||
dnl the ones we care about.
|
||||
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
|
||||
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
|
||||
AC_REQUIRE([AC_PROG_INSTALL])dnl
|
||||
if test "`cd $srcdir && pwd`" != "`pwd`"; then
|
||||
# Use -I$(srcdir) only when $(srcdir) != ., so that make's output
|
||||
# is not polluted with repeated "-I."
|
||||
AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
|
||||
# test to see if srcdir already configured
|
||||
if test -f $srcdir/config.status; then
|
||||
AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
|
||||
fi
|
||||
fi
|
||||
|
||||
# test whether we have cygpath
|
||||
if test -z "$CYGPATH_W"; then
|
||||
if (cygpath --version) >/dev/null 2>/dev/null; then
|
||||
CYGPATH_W='cygpath -w'
|
||||
else
|
||||
CYGPATH_W=echo
|
||||
fi
|
||||
fi
|
||||
AC_SUBST([CYGPATH_W])
|
||||
|
||||
# Define the identity of the package.
|
||||
dnl Distinguish between old-style and new-style calls.
|
||||
m4_ifval([$2],
|
||||
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
|
||||
AC_SUBST([PACKAGE], [$1])dnl
|
||||
AC_SUBST([VERSION], [$2])],
|
||||
[_AM_SET_OPTIONS([$1])dnl
|
||||
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
|
||||
m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
|
||||
[m4_fatal([AC_INIT should be called with package and version arguments])])dnl
|
||||
AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
|
||||
AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
|
||||
|
||||
_AM_IF_OPTION([no-define],,
|
||||
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
|
||||
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
|
||||
|
||||
# Some tools Automake needs.
|
||||
AC_REQUIRE([AM_SANITY_CHECK])dnl
|
||||
AC_REQUIRE([AC_ARG_PROGRAM])dnl
|
||||
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
|
||||
AM_MISSING_PROG(AUTOCONF, autoconf)
|
||||
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
|
||||
AM_MISSING_PROG(AUTOHEADER, autoheader)
|
||||
AM_MISSING_PROG(MAKEINFO, makeinfo)
|
||||
AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
|
||||
AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
|
||||
AC_REQUIRE([AM_PROG_MKDIR_P])dnl
|
||||
# We need awk for the "check" target. The system "awk" is bad on
|
||||
# some platforms.
|
||||
AC_REQUIRE([AC_PROG_AWK])dnl
|
||||
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
|
||||
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
|
||||
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
|
||||
[_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
|
||||
[_AM_PROG_TAR([v7])])])
|
||||
_AM_IF_OPTION([no-dependencies],,
|
||||
[AC_PROVIDE_IFELSE([AC_PROG_CC],
|
||||
[_AM_DEPENDENCIES(CC)],
|
||||
[define([AC_PROG_CC],
|
||||
defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
|
||||
AC_PROVIDE_IFELSE([AC_PROG_CXX],
|
||||
[_AM_DEPENDENCIES(CXX)],
|
||||
[define([AC_PROG_CXX],
|
||||
defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
|
||||
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
|
||||
[_AM_DEPENDENCIES(OBJC)],
|
||||
[define([AC_PROG_OBJC],
|
||||
defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
|
||||
])
|
||||
_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
|
||||
dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
|
||||
dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro
|
||||
dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
|
||||
AC_CONFIG_COMMANDS_PRE(dnl
|
||||
[m4_provide_if([_AM_COMPILER_EXEEXT],
|
||||
[AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
|
||||
])
|
||||
|
||||
dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
|
||||
dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
|
||||
dnl mangled by Autoconf and run in a shell conditional statement.
|
||||
m4_define([_AC_COMPILER_EXEEXT],
|
||||
m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
|
||||
|
||||
|
||||
# When config.status generates a header, we must update the stamp-h file.
|
||||
# This file resides in the same directory as the config header
|
||||
# that is generated. The stamp files are numbered to have different names.
|
||||
|
||||
# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
|
||||
# loop where config.status creates the headers, so we can generate
|
||||
# our stamp files there.
|
||||
AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
|
||||
[# Compute $1's index in $config_headers.
|
||||
_am_arg=$1
|
||||
_am_stamp_count=1
|
||||
for _am_header in $config_headers :; do
|
||||
case $_am_header in
|
||||
$_am_arg | $_am_arg:* )
|
||||
break ;;
|
||||
* )
|
||||
_am_stamp_count=`expr $_am_stamp_count + 1` ;;
|
||||
esac
|
||||
done
|
||||
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
|
||||
|
||||
# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# AM_PROG_INSTALL_SH
|
||||
# ------------------
|
||||
# Define $install_sh.
|
||||
AC_DEFUN([AM_PROG_INSTALL_SH],
|
||||
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
|
||||
if test x"${install_sh}" != xset; then
|
||||
case $am_aux_dir in
|
||||
*\ * | *\ *)
|
||||
install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
|
||||
*)
|
||||
install_sh="\${SHELL} $am_aux_dir/install-sh"
|
||||
esac
|
||||
fi
|
||||
AC_SUBST(install_sh)])
|
||||
|
||||
# Copyright (C) 2003, 2005 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 2
|
||||
|
||||
# Check whether the underlying file-system supports filenames
|
||||
# with a leading dot. For instance MS-DOS doesn't.
|
||||
AC_DEFUN([AM_SET_LEADING_DOT],
|
||||
[rm -rf .tst 2>/dev/null
|
||||
mkdir .tst 2>/dev/null
|
||||
if test -d .tst; then
|
||||
am__leading_dot=.
|
||||
else
|
||||
am__leading_dot=_
|
||||
fi
|
||||
rmdir .tst 2>/dev/null
|
||||
AC_SUBST([am__leading_dot])])
|
||||
|
||||
# Check to see how 'make' treats includes. -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 4
|
||||
|
||||
# AM_MAKE_INCLUDE()
|
||||
# -----------------
|
||||
# Check to see how make treats includes.
|
||||
AC_DEFUN([AM_MAKE_INCLUDE],
|
||||
[am_make=${MAKE-make}
|
||||
cat > confinc << 'END'
|
||||
am__doit:
|
||||
@echo this is the am__doit target
|
||||
.PHONY: am__doit
|
||||
END
|
||||
# If we don't find an include directive, just comment out the code.
|
||||
AC_MSG_CHECKING([for style of include used by $am_make])
|
||||
am__include="#"
|
||||
am__quote=
|
||||
_am_result=none
|
||||
# First try GNU make style include.
|
||||
echo "include confinc" > confmf
|
||||
# Ignore all kinds of additional output from `make'.
|
||||
case `$am_make -s -f confmf 2> /dev/null` in #(
|
||||
*the\ am__doit\ target*)
|
||||
am__include=include
|
||||
am__quote=
|
||||
_am_result=GNU
|
||||
;;
|
||||
esac
|
||||
# Now try BSD make style include.
|
||||
if test "$am__include" = "#"; then
|
||||
echo '.include "confinc"' > confmf
|
||||
case `$am_make -s -f confmf 2> /dev/null` in #(
|
||||
*the\ am__doit\ target*)
|
||||
am__include=.include
|
||||
am__quote="\""
|
||||
_am_result=BSD
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
AC_SUBST([am__include])
|
||||
AC_SUBST([am__quote])
|
||||
AC_MSG_RESULT([$_am_result])
|
||||
rm -f confinc confmf
|
||||
])
|
||||
|
||||
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
|
||||
# Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 6
|
||||
|
||||
# AM_MISSING_PROG(NAME, PROGRAM)
|
||||
# ------------------------------
|
||||
AC_DEFUN([AM_MISSING_PROG],
|
||||
[AC_REQUIRE([AM_MISSING_HAS_RUN])
|
||||
$1=${$1-"${am_missing_run}$2"}
|
||||
AC_SUBST($1)])
|
||||
|
||||
|
||||
# AM_MISSING_HAS_RUN
|
||||
# ------------------
|
||||
# Define MISSING if not defined so far and test if it supports --run.
|
||||
# If it does, set am_missing_run to use it, otherwise, to nothing.
|
||||
AC_DEFUN([AM_MISSING_HAS_RUN],
|
||||
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
|
||||
AC_REQUIRE_AUX_FILE([missing])dnl
|
||||
if test x"${MISSING+set}" != xset; then
|
||||
case $am_aux_dir in
|
||||
*\ * | *\ *)
|
||||
MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
|
||||
*)
|
||||
MISSING="\${SHELL} $am_aux_dir/missing" ;;
|
||||
esac
|
||||
fi
|
||||
# Use eval to expand $SHELL
|
||||
if eval "$MISSING --run true"; then
|
||||
am_missing_run="$MISSING --run "
|
||||
else
|
||||
am_missing_run=
|
||||
AC_MSG_WARN([`missing' script is too old or missing])
|
||||
fi
|
||||
])
|
||||
|
||||
# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# AM_PROG_MKDIR_P
|
||||
# ---------------
|
||||
# Check for `mkdir -p'.
|
||||
AC_DEFUN([AM_PROG_MKDIR_P],
|
||||
[AC_PREREQ([2.60])dnl
|
||||
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
|
||||
dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
|
||||
dnl while keeping a definition of mkdir_p for backward compatibility.
|
||||
dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
|
||||
dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
|
||||
dnl Makefile.ins that do not define MKDIR_P, so we do our own
|
||||
dnl adjustment using top_builddir (which is defined more often than
|
||||
dnl MKDIR_P).
|
||||
AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
|
||||
case $mkdir_p in
|
||||
[[\\/$]]* | ?:[[\\/]]*) ;;
|
||||
*/*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
|
||||
esac
|
||||
])
|
||||
|
||||
# Helper functions for option handling. -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 4
|
||||
|
||||
# _AM_MANGLE_OPTION(NAME)
|
||||
# -----------------------
|
||||
AC_DEFUN([_AM_MANGLE_OPTION],
|
||||
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
|
||||
|
||||
# _AM_SET_OPTION(NAME)
|
||||
# ------------------------------
|
||||
# Set option NAME. Presently that only means defining a flag for this option.
|
||||
AC_DEFUN([_AM_SET_OPTION],
|
||||
[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
|
||||
|
||||
# _AM_SET_OPTIONS(OPTIONS)
|
||||
# ----------------------------------
|
||||
# OPTIONS is a space-separated list of Automake options.
|
||||
AC_DEFUN([_AM_SET_OPTIONS],
|
||||
[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
|
||||
|
||||
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
|
||||
# -------------------------------------------
|
||||
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
|
||||
AC_DEFUN([_AM_IF_OPTION],
|
||||
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
|
||||
|
||||
# Check to make sure that the build environment is sane. -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
|
||||
# Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 5
|
||||
|
||||
# AM_SANITY_CHECK
|
||||
# ---------------
|
||||
AC_DEFUN([AM_SANITY_CHECK],
|
||||
[AC_MSG_CHECKING([whether build environment is sane])
|
||||
# Just in case
|
||||
sleep 1
|
||||
echo timestamp > conftest.file
|
||||
# Reject unsafe characters in $srcdir or the absolute working directory
|
||||
# name. Accept space and tab only in the latter.
|
||||
am_lf='
|
||||
'
|
||||
case `pwd` in
|
||||
*[[\\\"\#\$\&\'\`$am_lf]]*)
|
||||
AC_MSG_ERROR([unsafe absolute working directory name]);;
|
||||
esac
|
||||
case $srcdir in
|
||||
*[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
|
||||
AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
|
||||
esac
|
||||
|
||||
# Do `set' in a subshell so we don't clobber the current shell's
|
||||
# arguments. Must try -L first in case configure is actually a
|
||||
# symlink; some systems play weird games with the mod time of symlinks
|
||||
# (eg FreeBSD returns the mod time of the symlink's containing
|
||||
# directory).
|
||||
if (
|
||||
set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
|
||||
if test "$[*]" = "X"; then
|
||||
# -L didn't work.
|
||||
set X `ls -t "$srcdir/configure" conftest.file`
|
||||
fi
|
||||
rm -f conftest.file
|
||||
if test "$[*]" != "X $srcdir/configure conftest.file" \
|
||||
&& test "$[*]" != "X conftest.file $srcdir/configure"; then
|
||||
|
||||
# If neither matched, then we have a broken ls. This can happen
|
||||
# if, for instance, CONFIG_SHELL is bash and it inherits a
|
||||
# broken ls alias from the environment. This has actually
|
||||
# happened. Such a system could not be considered "sane".
|
||||
AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
|
||||
alias in your environment])
|
||||
fi
|
||||
|
||||
test "$[2]" = conftest.file
|
||||
)
|
||||
then
|
||||
# Ok.
|
||||
:
|
||||
else
|
||||
AC_MSG_ERROR([newly created file is older than distributed files!
|
||||
Check your system clock])
|
||||
fi
|
||||
AC_MSG_RESULT(yes)])
|
||||
|
||||
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# AM_PROG_INSTALL_STRIP
|
||||
# ---------------------
|
||||
# One issue with vendor `install' (even GNU) is that you can't
|
||||
# specify the program used to strip binaries. This is especially
|
||||
# annoying in cross-compiling environments, where the build's strip
|
||||
# is unlikely to handle the host's binaries.
|
||||
# Fortunately install-sh will honor a STRIPPROG variable, so we
|
||||
# always use install-sh in `make install-strip', and initialize
|
||||
# STRIPPROG with the value of the STRIP variable (set by the user).
|
||||
AC_DEFUN([AM_PROG_INSTALL_STRIP],
|
||||
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
|
||||
# Installed binaries are usually stripped using `strip' when the user
|
||||
# run `make install-strip'. However `strip' might not be the right
|
||||
# tool to use in cross-compilation environments, therefore Automake
|
||||
# will honor the `STRIP' environment variable to overrule this program.
|
||||
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
|
||||
if test "$cross_compiling" != no; then
|
||||
AC_CHECK_TOOL([STRIP], [strip], :)
|
||||
fi
|
||||
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
|
||||
AC_SUBST([INSTALL_STRIP_PROGRAM])])
|
||||
|
||||
# Copyright (C) 2006, 2008 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 2
|
||||
|
||||
# _AM_SUBST_NOTMAKE(VARIABLE)
|
||||
# ---------------------------
|
||||
# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
|
||||
# This macro is traced by Automake.
|
||||
AC_DEFUN([_AM_SUBST_NOTMAKE])
|
||||
|
||||
# AM_SUBST_NOTMAKE(VARIABLE)
|
||||
# ---------------------------
|
||||
# Public sister of _AM_SUBST_NOTMAKE.
|
||||
AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
|
||||
|
||||
# Check how to create a tarball. -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 2004, 2005 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# serial 2
|
||||
|
||||
# _AM_PROG_TAR(FORMAT)
|
||||
# --------------------
|
||||
# Check how to create a tarball in format FORMAT.
|
||||
# FORMAT should be one of `v7', `ustar', or `pax'.
|
||||
#
|
||||
# Substitute a variable $(am__tar) that is a command
|
||||
# writing to stdout a FORMAT-tarball containing the directory
|
||||
# $tardir.
|
||||
# tardir=directory && $(am__tar) > result.tar
|
||||
#
|
||||
# Substitute a variable $(am__untar) that extract such
|
||||
# a tarball read from stdin.
|
||||
# $(am__untar) < result.tar
|
||||
AC_DEFUN([_AM_PROG_TAR],
|
||||
[# Always define AMTAR for backward compatibility.
|
||||
AM_MISSING_PROG([AMTAR], [tar])
|
||||
m4_if([$1], [v7],
|
||||
[am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
|
||||
[m4_case([$1], [ustar],, [pax],,
|
||||
[m4_fatal([Unknown tar format])])
|
||||
AC_MSG_CHECKING([how to create a $1 tar archive])
|
||||
# Loop over all known methods to create a tar archive until one works.
|
||||
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
|
||||
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
|
||||
# Do not fold the above two line into one, because Tru64 sh and
|
||||
# Solaris sh will not grok spaces in the rhs of `-'.
|
||||
for _am_tool in $_am_tools
|
||||
do
|
||||
case $_am_tool in
|
||||
gnutar)
|
||||
for _am_tar in tar gnutar gtar;
|
||||
do
|
||||
AM_RUN_LOG([$_am_tar --version]) && break
|
||||
done
|
||||
am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
|
||||
am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
|
||||
am__untar="$_am_tar -xf -"
|
||||
;;
|
||||
plaintar)
|
||||
# Must skip GNU tar: if it does not support --format= it doesn't create
|
||||
# ustar tarball either.
|
||||
(tar --version) >/dev/null 2>&1 && continue
|
||||
am__tar='tar chf - "$$tardir"'
|
||||
am__tar_='tar chf - "$tardir"'
|
||||
am__untar='tar xf -'
|
||||
;;
|
||||
pax)
|
||||
am__tar='pax -L -x $1 -w "$$tardir"'
|
||||
am__tar_='pax -L -x $1 -w "$tardir"'
|
||||
am__untar='pax -r'
|
||||
;;
|
||||
cpio)
|
||||
am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
|
||||
am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
|
||||
am__untar='cpio -i -H $1 -d'
|
||||
;;
|
||||
none)
|
||||
am__tar=false
|
||||
am__tar_=false
|
||||
am__untar=false
|
||||
;;
|
||||
esac
|
||||
|
||||
# If the value was cached, stop now. We just wanted to have am__tar
|
||||
# and am__untar set.
|
||||
test -n "${am_cv_prog_tar_$1}" && break
|
||||
|
||||
# tar/untar a dummy directory, and stop if the command works
|
||||
rm -rf conftest.dir
|
||||
mkdir conftest.dir
|
||||
echo GrepMe > conftest.dir/file
|
||||
AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
|
||||
rm -rf conftest.dir
|
||||
if test -s conftest.tar; then
|
||||
AM_RUN_LOG([$am__untar <conftest.tar])
|
||||
grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
|
||||
fi
|
||||
done
|
||||
rm -rf conftest.dir
|
||||
|
||||
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
|
||||
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
|
||||
AC_SUBST([am__tar])
|
||||
AC_SUBST([am__untar])
|
||||
]) # _AM_PROG_TAR
|
||||
|
|
@ -0,0 +1,423 @@
|
|||
#! /bin/sh
|
||||
|
||||
# depcomp - compile a program generating dependencies as side-effects
|
||||
# Copyright 1999, 2000 Free Software Foundation, Inc.
|
||||
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2, or (at your option)
|
||||
# any later version.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
# 02111-1307, USA.
|
||||
|
||||
# As a special exception to the GNU General Public License, if you
|
||||
# distribute this file as part of a program that contains a
|
||||
# configuration script generated by Autoconf, you may include it under
|
||||
# the same distribution terms that you use for the rest of that program.
|
||||
|
||||
# Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>.
|
||||
|
||||
if test -z "$depmode" || test -z "$source" || test -z "$object"; then
|
||||
echo "depcomp: Variables source, object and depmode must be set" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
# `libtool' can also be set to `yes' or `no'.
|
||||
|
||||
if test -z "$depfile"; then
|
||||
base=`echo "$object" | sed -e 's,^.*/,,' -e 's,\.\([^.]*\)$,.P\1,'`
|
||||
dir=`echo "$object" | sed 's,/.*$,/,'`
|
||||
if test "$dir" = "$object"; then
|
||||
dir=
|
||||
fi
|
||||
# FIXME: should be _deps on DOS.
|
||||
depfile="$dir.deps/$base"
|
||||
fi
|
||||
|
||||
tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
|
||||
|
||||
rm -f "$tmpdepfile"
|
||||
|
||||
# Some modes work just like other modes, but use different flags. We
|
||||
# parameterize here, but still list the modes in the big case below,
|
||||
# to make depend.m4 easier to write. Note that we *cannot* use a case
|
||||
# here, because this file can only contain one case statement.
|
||||
if test "$depmode" = hp; then
|
||||
# HP compiler uses -M and no extra arg.
|
||||
gccflag=-M
|
||||
depmode=gcc
|
||||
fi
|
||||
|
||||
if test "$depmode" = dashXmstdout; then
|
||||
# This is just like dashmstdout with a different argument.
|
||||
dashmflag=-xM
|
||||
depmode=dashmstdout
|
||||
fi
|
||||
|
||||
case "$depmode" in
|
||||
gcc3)
|
||||
## gcc 3 implements dependency tracking that does exactly what
|
||||
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
|
||||
## it if -MD -MP comes after the -MF stuff. Hmm.
|
||||
"$@" -MT "$object" -MD -MP -MF "$tmpdepfile"
|
||||
stat=$?
|
||||
if test $stat -eq 0; then :
|
||||
else
|
||||
rm -f "$tmpdepfile"
|
||||
exit $stat
|
||||
fi
|
||||
mv "$tmpdepfile" "$depfile"
|
||||
;;
|
||||
|
||||
gcc)
|
||||
## There are various ways to get dependency output from gcc. Here's
|
||||
## why we pick this rather obscure method:
|
||||
## - Don't want to use -MD because we'd like the dependencies to end
|
||||
## up in a subdir. Having to rename by hand is ugly.
|
||||
## (We might end up doing this anyway to support other compilers.)
|
||||
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
|
||||
## -MM, not -M (despite what the docs say).
|
||||
## - Using -M directly means running the compiler twice (even worse
|
||||
## than renaming).
|
||||
if test -z "$gccflag"; then
|
||||
gccflag=-MD,
|
||||
fi
|
||||
"$@" -Wp,"$gccflag$tmpdepfile"
|
||||
stat=$?
|
||||
if test $stat -eq 0; then :
|
||||
else
|
||||
rm -f "$tmpdepfile"
|
||||
exit $stat
|
||||
fi
|
||||
rm -f "$depfile"
|
||||
echo "$object : \\" > "$depfile"
|
||||
alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
|
||||
## The second -e expression handles DOS-style file names with drive letters.
|
||||
sed -e 's/^[^:]*: / /' \
|
||||
-e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
|
||||
## This next piece of magic avoids the `deleted header file' problem.
|
||||
## The problem is that when a header file which appears in a .P file
|
||||
## is deleted, the dependency causes make to die (because there is
|
||||
## typically no way to rebuild the header). We avoid this by adding
|
||||
## dummy dependencies for each header file. Too bad gcc doesn't do
|
||||
## this for us directly.
|
||||
tr ' ' '
|
||||
' < "$tmpdepfile" |
|
||||
## Some versions of gcc put a space before the `:'. On the theory
|
||||
## that the space means something, we add a space to the output as
|
||||
## well.
|
||||
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||
## correctly. Breaking it into two sed invocations is a workaround.
|
||||
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||
rm -f "$tmpdepfile"
|
||||
;;
|
||||
|
||||
hp)
|
||||
# This case exists only to let depend.m4 do its work. It works by
|
||||
# looking at the text of this script. This case will never be run,
|
||||
# since it is checked for above.
|
||||
exit 1
|
||||
;;
|
||||
|
||||
sgi)
|
||||
if test "$libtool" = yes; then
|
||||
"$@" "-Wp,-MDupdate,$tmpdepfile"
|
||||
else
|
||||
"$@" -MDupdate "$tmpdepfile"
|
||||
fi
|
||||
stat=$?
|
||||
if test $stat -eq 0; then :
|
||||
else
|
||||
rm -f "$tmpdepfile"
|
||||
exit $stat
|
||||
fi
|
||||
rm -f "$depfile"
|
||||
|
||||
if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
|
||||
echo "$object : \\" > "$depfile"
|
||||
|
||||
# Clip off the initial element (the dependent). Don't try to be
|
||||
# clever and replace this with sed code, as IRIX sed won't handle
|
||||
# lines with more than a fixed number of characters (4096 in
|
||||
# IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
|
||||
# the IRIX cc adds comments like `#:fec' to the end of the
|
||||
# dependency line.
|
||||
tr ' ' '
|
||||
' < "$tmpdepfile" \
|
||||
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
|
||||
tr '
|
||||
' ' ' >> $depfile
|
||||
echo >> $depfile
|
||||
|
||||
# The second pass generates a dummy entry for each header file.
|
||||
tr ' ' '
|
||||
' < "$tmpdepfile" \
|
||||
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
|
||||
>> $depfile
|
||||
else
|
||||
# The sourcefile does not contain any dependencies, so just
|
||||
# store a dummy comment line, to avoid errors with the Makefile
|
||||
# "include basename.Plo" scheme.
|
||||
echo "#dummy" > "$depfile"
|
||||
fi
|
||||
rm -f "$tmpdepfile"
|
||||
;;
|
||||
|
||||
aix)
|
||||
# The C for AIX Compiler uses -M and outputs the dependencies
|
||||
# in a .u file. This file always lives in the current directory.
|
||||
# Also, the AIX compiler puts `$object:' at the start of each line;
|
||||
# $object doesn't have directory information.
|
||||
stripped=`echo "$object" | sed -e 's,^.*/,,' -e 's/\(.*\)\..*$/\1/'`
|
||||
tmpdepfile="$stripped.u"
|
||||
outname="$stripped.o"
|
||||
if test "$libtool" = yes; then
|
||||
"$@" -Wc,-M
|
||||
else
|
||||
"$@" -M
|
||||
fi
|
||||
|
||||
stat=$?
|
||||
if test $stat -eq 0; then :
|
||||
else
|
||||
rm -f "$tmpdepfile"
|
||||
exit $stat
|
||||
fi
|
||||
|
||||
if test -f "$tmpdepfile"; then
|
||||
# Each line is of the form `foo.o: dependent.h'.
|
||||
# Do two passes, one to just change these to
|
||||
# `$object: dependent.h' and one to simply `dependent.h:'.
|
||||
sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile"
|
||||
sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile"
|
||||
else
|
||||
# The sourcefile does not contain any dependencies, so just
|
||||
# store a dummy comment line, to avoid errors with the Makefile
|
||||
# "include basename.Plo" scheme.
|
||||
echo "#dummy" > "$depfile"
|
||||
fi
|
||||
rm -f "$tmpdepfile"
|
||||
;;
|
||||
|
||||
tru64)
|
||||
# The Tru64 compiler uses -MD to generate dependencies as a side
|
||||
# effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'.
|
||||
# At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
|
||||
# dependencies in `foo.d' instead, so we check for that too.
|
||||
# Subdirectories are respected.
|
||||
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
|
||||
test "x$dir" = "x$object" && dir=
|
||||
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
|
||||
|
||||
if test "$libtool" = yes; then
|
||||
tmpdepfile1="$dir.libs/$base.lo.d"
|
||||
tmpdepfile2="$dir.libs/$base.d"
|
||||
"$@" -Wc,-MD
|
||||
else
|
||||
tmpdepfile1="$dir$base.o.d"
|
||||
tmpdepfile2="$dir$base.d"
|
||||
"$@" -MD
|
||||
fi
|
||||
|
||||
stat=$?
|
||||
if test $stat -eq 0; then :
|
||||
else
|
||||
rm -f "$tmpdepfile1" "$tmpdepfile2"
|
||||
exit $stat
|
||||
fi
|
||||
|
||||
if test -f "$tmpdepfile1"; then
|
||||
tmpdepfile="$tmpdepfile1"
|
||||
else
|
||||
tmpdepfile="$tmpdepfile2"
|
||||
fi
|
||||
if test -f "$tmpdepfile"; then
|
||||
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
|
||||
# That's a space and a tab in the [].
|
||||
sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
|
||||
else
|
||||
echo "#dummy" > "$depfile"
|
||||
fi
|
||||
rm -f "$tmpdepfile"
|
||||
;;
|
||||
|
||||
#nosideeffect)
|
||||
# This comment above is used by automake to tell side-effect
|
||||
# dependency tracking mechanisms from slower ones.
|
||||
|
||||
dashmstdout)
|
||||
# Important note: in order to support this mode, a compiler *must*
|
||||
# always write the proprocessed file to stdout, regardless of -o.
|
||||
"$@" || exit $?
|
||||
|
||||
# Remove the call to Libtool.
|
||||
if test "$libtool" = yes; then
|
||||
while test $1 != '--mode=compile'; do
|
||||
shift
|
||||
done
|
||||
shift
|
||||
fi
|
||||
|
||||
# Remove `-o $object'. We will use -o /dev/null later,
|
||||
# however we can't do the remplacement now because
|
||||
# `-o $object' might simply not be used
|
||||
IFS=" "
|
||||
for arg
|
||||
do
|
||||
case $arg in
|
||||
-o)
|
||||
shift
|
||||
;;
|
||||
$object)
|
||||
shift
|
||||
;;
|
||||
*)
|
||||
set fnord "$@" "$arg"
|
||||
shift # fnord
|
||||
shift # $arg
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
test -z "$dashmflag" && dashmflag=-M
|
||||
"$@" -o /dev/null $dashmflag | sed 's:^[^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile"
|
||||
rm -f "$depfile"
|
||||
cat < "$tmpdepfile" > "$depfile"
|
||||
tr ' ' '
|
||||
' < "$tmpdepfile" | \
|
||||
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||
## correctly. Breaking it into two sed invocations is a workaround.
|
||||
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||
rm -f "$tmpdepfile"
|
||||
;;
|
||||
|
||||
dashXmstdout)
|
||||
# This case only exists to satisfy depend.m4. It is never actually
|
||||
# run, as this mode is specially recognized in the preamble.
|
||||
exit 1
|
||||
;;
|
||||
|
||||
makedepend)
|
||||
"$@" || exit $?
|
||||
# X makedepend
|
||||
shift
|
||||
cleared=no
|
||||
for arg in "$@"; do
|
||||
case $cleared in
|
||||
no)
|
||||
set ""; shift
|
||||
cleared=yes ;;
|
||||
esac
|
||||
case "$arg" in
|
||||
-D*|-I*)
|
||||
set fnord "$@" "$arg"; shift ;;
|
||||
-*)
|
||||
;;
|
||||
*)
|
||||
set fnord "$@" "$arg"; shift ;;
|
||||
esac
|
||||
done
|
||||
obj_suffix="`echo $object | sed 's/^.*\././'`"
|
||||
touch "$tmpdepfile"
|
||||
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
|
||||
rm -f "$depfile"
|
||||
cat < "$tmpdepfile" > "$depfile"
|
||||
sed '1,2d' "$tmpdepfile" | tr ' ' '
|
||||
' | \
|
||||
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||
## correctly. Breaking it into two sed invocations is a workaround.
|
||||
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||
rm -f "$tmpdepfile" "$tmpdepfile".bak
|
||||
;;
|
||||
|
||||
cpp)
|
||||
# Important note: in order to support this mode, a compiler *must*
|
||||
# always write the proprocessed file to stdout.
|
||||
"$@" || exit $?
|
||||
|
||||
# Remove the call to Libtool.
|
||||
if test "$libtool" = yes; then
|
||||
while test $1 != '--mode=compile'; do
|
||||
shift
|
||||
done
|
||||
shift
|
||||
fi
|
||||
|
||||
# Remove `-o $object'.
|
||||
IFS=" "
|
||||
for arg
|
||||
do
|
||||
case $arg in
|
||||
-o)
|
||||
shift
|
||||
;;
|
||||
$object)
|
||||
shift
|
||||
;;
|
||||
*)
|
||||
set fnord "$@" "$arg"
|
||||
shift # fnord
|
||||
shift # $arg
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
"$@" -E |
|
||||
sed -n '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' |
|
||||
sed '$ s: \\$::' > "$tmpdepfile"
|
||||
rm -f "$depfile"
|
||||
echo "$object : \\" > "$depfile"
|
||||
cat < "$tmpdepfile" >> "$depfile"
|
||||
sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
|
||||
rm -f "$tmpdepfile"
|
||||
;;
|
||||
|
||||
msvisualcpp)
|
||||
# Important note: in order to support this mode, a compiler *must*
|
||||
# always write the proprocessed file to stdout, regardless of -o,
|
||||
# because we must use -o when running libtool.
|
||||
"$@" || exit $?
|
||||
IFS=" "
|
||||
for arg
|
||||
do
|
||||
case "$arg" in
|
||||
"-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
|
||||
set fnord "$@"
|
||||
shift
|
||||
shift
|
||||
;;
|
||||
*)
|
||||
set fnord "$@" "$arg"
|
||||
shift
|
||||
shift
|
||||
;;
|
||||
esac
|
||||
done
|
||||
"$@" -E |
|
||||
sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile"
|
||||
rm -f "$depfile"
|
||||
echo "$object : \\" > "$depfile"
|
||||
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile"
|
||||
echo " " >> "$depfile"
|
||||
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile"
|
||||
rm -f "$tmpdepfile"
|
||||
;;
|
||||
|
||||
none)
|
||||
exec "$@"
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "Unknown depmode $depmode" 1>&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
exit 0
|
|
@ -0,0 +1,269 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# install - install a program, script, or datafile
|
||||
#
|
||||
# This originates from X11R5 (mit/util/scripts/install.sh), which was
|
||||
# later released in X11R6 (xc/config/util/install.sh) with the
|
||||
# following copyright and license.
|
||||
#
|
||||
# Copyright (C) 1994 X Consortium
|
||||
#
|
||||
# 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, sublicense, and/or
|
||||
# sell copies of the Software, and to permit persons to whom the Software is
|
||||
# furnished to do so, subject to the following conditions:
|
||||
#
|
||||
# The above copyright notice and this permission notice shall be included in
|
||||
# all copies or substantial portions of the Software.
|
||||
#
|
||||
# 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. IN NO EVENT SHALL THE
|
||||
# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
|
||||
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
|
||||
# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
#
|
||||
# Except as contained in this notice, the name of the X Consortium shall not
|
||||
# be used in advertising or otherwise to promote the sale, use or other deal-
|
||||
# ings in this Software without prior written authorization from the X Consor-
|
||||
# tium.
|
||||
#
|
||||
#
|
||||
# FSF changes to this file are in the public domain.
|
||||
#
|
||||
# Calling this script install-sh is preferred over install.sh, to prevent
|
||||
# `make' implicit rules from creating a file called install from it
|
||||
# when there is no Makefile.
|
||||
#
|
||||
# This script is compatible with the BSD install script, but was written
|
||||
# from scratch. It can only install one file at a time, a restriction
|
||||
# shared with many OS's install programs.
|
||||
|
||||
|
||||
# set DOITPROG to echo to test this script
|
||||
|
||||
# Don't use :- since 4.3BSD and earlier shells don't like it.
|
||||
doit="${DOITPROG-}"
|
||||
|
||||
|
||||
# put in absolute paths if you don't have them in your path; or use env. vars.
|
||||
|
||||
mvprog="${MVPROG-mv}"
|
||||
cpprog="${CPPROG-cp}"
|
||||
chmodprog="${CHMODPROG-chmod}"
|
||||
chownprog="${CHOWNPROG-chown}"
|
||||
chgrpprog="${CHGRPPROG-chgrp}"
|
||||
stripprog="${STRIPPROG-strip}"
|
||||
rmprog="${RMPROG-rm}"
|
||||
mkdirprog="${MKDIRPROG-mkdir}"
|
||||
|
||||
transformbasename=""
|
||||
transform_arg=""
|
||||
instcmd="$mvprog"
|
||||
chmodcmd="$chmodprog 0755"
|
||||
chowncmd=""
|
||||
chgrpcmd=""
|
||||
stripcmd=""
|
||||
rmcmd="$rmprog -f"
|
||||
mvcmd="$mvprog"
|
||||
src=""
|
||||
dst=""
|
||||
dir_arg=""
|
||||
|
||||
while [ x"$1" != x ]; do
|
||||
case $1 in
|
||||
-c) instcmd="$cpprog"
|
||||
shift
|
||||
continue;;
|
||||
|
||||
-d) dir_arg=true
|
||||
shift
|
||||
continue;;
|
||||
|
||||
-m) chmodcmd="$chmodprog $2"
|
||||
shift
|
||||
shift
|
||||
continue;;
|
||||
|
||||
-o) chowncmd="$chownprog $2"
|
||||
shift
|
||||
shift
|
||||
continue;;
|
||||
|
||||
-g) chgrpcmd="$chgrpprog $2"
|
||||
shift
|
||||
shift
|
||||
continue;;
|
||||
|
||||
-s) stripcmd="$stripprog"
|
||||
shift
|
||||
continue;;
|
||||
|
||||
-t=*) transformarg=`echo $1 | sed 's/-t=//'`
|
||||
shift
|
||||
continue;;
|
||||
|
||||
-b=*) transformbasename=`echo $1 | sed 's/-b=//'`
|
||||
shift
|
||||
continue;;
|
||||
|
||||
*) if [ x"$src" = x ]
|
||||
then
|
||||
src=$1
|
||||
else
|
||||
# this colon is to work around a 386BSD /bin/sh bug
|
||||
:
|
||||
dst=$1
|
||||
fi
|
||||
shift
|
||||
continue;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ x"$src" = x ]
|
||||
then
|
||||
echo "install: no input file specified"
|
||||
exit 1
|
||||
else
|
||||
:
|
||||
fi
|
||||
|
||||
if [ x"$dir_arg" != x ]; then
|
||||
dst=$src
|
||||
src=""
|
||||
|
||||
if [ -d $dst ]; then
|
||||
instcmd=:
|
||||
chmodcmd=""
|
||||
else
|
||||
instcmd=$mkdirprog
|
||||
fi
|
||||
else
|
||||
|
||||
# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
|
||||
# might cause directories to be created, which would be especially bad
|
||||
# if $src (and thus $dsttmp) contains '*'.
|
||||
|
||||
if [ -f "$src" ] || [ -d "$src" ]
|
||||
then
|
||||
:
|
||||
else
|
||||
echo "install: $src does not exist"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ x"$dst" = x ]
|
||||
then
|
||||
echo "install: no destination specified"
|
||||
exit 1
|
||||
else
|
||||
:
|
||||
fi
|
||||
|
||||
# If destination is a directory, append the input filename; if your system
|
||||
# does not like double slashes in filenames, you may need to add some logic
|
||||
|
||||
if [ -d $dst ]
|
||||
then
|
||||
dst="$dst"/`basename $src`
|
||||
else
|
||||
:
|
||||
fi
|
||||
fi
|
||||
|
||||
## this sed command emulates the dirname command
|
||||
dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
|
||||
|
||||
# Make sure that the destination directory exists.
|
||||
# this part is taken from Noah Friedman's mkinstalldirs script
|
||||
|
||||
# Skip lots of stat calls in the usual case.
|
||||
if [ ! -d "$dstdir" ]; then
|
||||
defaultIFS='
|
||||
'
|
||||
IFS="${IFS-${defaultIFS}}"
|
||||
|
||||
oIFS="${IFS}"
|
||||
# Some sh's can't handle IFS=/ for some reason.
|
||||
IFS='%'
|
||||
set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'`
|
||||
IFS="${oIFS}"
|
||||
|
||||
pathcomp=''
|
||||
|
||||
while [ $# -ne 0 ] ; do
|
||||
pathcomp="${pathcomp}${1}"
|
||||
shift
|
||||
|
||||
if [ ! -d "${pathcomp}" ] ;
|
||||
then
|
||||
$mkdirprog "${pathcomp}"
|
||||
else
|
||||
:
|
||||
fi
|
||||
|
||||
pathcomp="${pathcomp}/"
|
||||
done
|
||||
fi
|
||||
|
||||
if [ x"$dir_arg" != x ]
|
||||
then
|
||||
$doit $instcmd $dst &&
|
||||
|
||||
if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else : ; fi &&
|
||||
if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else : ; fi &&
|
||||
if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else : ; fi &&
|
||||
if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else : ; fi
|
||||
else
|
||||
|
||||
# If we're going to rename the final executable, determine the name now.
|
||||
|
||||
if [ x"$transformarg" = x ]
|
||||
then
|
||||
dstfile=`basename $dst`
|
||||
else
|
||||
dstfile=`basename $dst $transformbasename |
|
||||
sed $transformarg`$transformbasename
|
||||
fi
|
||||
|
||||
# don't allow the sed command to completely eliminate the filename
|
||||
|
||||
if [ x"$dstfile" = x ]
|
||||
then
|
||||
dstfile=`basename $dst`
|
||||
else
|
||||
:
|
||||
fi
|
||||
|
||||
# Make a temp file name in the proper directory.
|
||||
|
||||
dsttmp=$dstdir/#inst.$$#
|
||||
|
||||
# Move or copy the file name to the temp name
|
||||
|
||||
$doit $instcmd $src $dsttmp &&
|
||||
|
||||
trap "rm -f ${dsttmp}" 0 &&
|
||||
|
||||
# and set any options; do chmod last to preserve setuid bits
|
||||
|
||||
# If any of these fail, we abort the whole thing. If we want to
|
||||
# ignore errors from any of these, just make sure not to ignore
|
||||
# errors from the above "$doit $instcmd $src $dsttmp" command.
|
||||
|
||||
if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else :;fi &&
|
||||
if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else :;fi &&
|
||||
if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else :;fi &&
|
||||
if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else :;fi &&
|
||||
|
||||
# Now rename the file to the real destination.
|
||||
|
||||
$doit $rmcmd -f $dstdir/$dstfile &&
|
||||
$doit $mvcmd $dsttmp $dstdir/$dstfile
|
||||
|
||||
fi &&
|
||||
|
||||
|
||||
exit 0
|
|
@ -0,0 +1,336 @@
|
|||
#! /bin/sh
|
||||
# Common stub for a few missing GNU programs while installing.
|
||||
# Copyright (C) 1996, 1997, 1999, 2000, 2002 Free Software Foundation, Inc.
|
||||
# Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
|
||||
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2, or (at your option)
|
||||
# any later version.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
# 02111-1307, USA.
|
||||
|
||||
# As a special exception to the GNU General Public License, if you
|
||||
# distribute this file as part of a program that contains a
|
||||
# configuration script generated by Autoconf, you may include it under
|
||||
# the same distribution terms that you use for the rest of that program.
|
||||
|
||||
if test $# -eq 0; then
|
||||
echo 1>&2 "Try \`$0 --help' for more information"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
run=:
|
||||
|
||||
# In the cases where this matters, `missing' is being run in the
|
||||
# srcdir already.
|
||||
if test -f configure.ac; then
|
||||
configure_ac=configure.ac
|
||||
else
|
||||
configure_ac=configure.in
|
||||
fi
|
||||
|
||||
case "$1" in
|
||||
--run)
|
||||
# Try to run requested program, and just exit if it succeeds.
|
||||
run=
|
||||
shift
|
||||
"$@" && exit 0
|
||||
;;
|
||||
esac
|
||||
|
||||
# If it does not exist, or fails to run (possibly an outdated version),
|
||||
# try to emulate it.
|
||||
case "$1" in
|
||||
|
||||
-h|--h|--he|--hel|--help)
|
||||
echo "\
|
||||
$0 [OPTION]... PROGRAM [ARGUMENT]...
|
||||
|
||||
Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an
|
||||
error status if there is no known handling for PROGRAM.
|
||||
|
||||
Options:
|
||||
-h, --help display this help and exit
|
||||
-v, --version output version information and exit
|
||||
--run try to run the given command, and emulate it if it fails
|
||||
|
||||
Supported PROGRAM values:
|
||||
aclocal touch file \`aclocal.m4'
|
||||
autoconf touch file \`configure'
|
||||
autoheader touch file \`config.h.in'
|
||||
automake touch all \`Makefile.in' files
|
||||
bison create \`y.tab.[ch]', if possible, from existing .[ch]
|
||||
flex create \`lex.yy.c', if possible, from existing .c
|
||||
help2man touch the output file
|
||||
lex create \`lex.yy.c', if possible, from existing .c
|
||||
makeinfo touch the output file
|
||||
tar try tar, gnutar, gtar, then tar without non-portable flags
|
||||
yacc create \`y.tab.[ch]', if possible, from existing .[ch]"
|
||||
;;
|
||||
|
||||
-v|--v|--ve|--ver|--vers|--versi|--versio|--version)
|
||||
echo "missing 0.4 - GNU automake"
|
||||
;;
|
||||
|
||||
-*)
|
||||
echo 1>&2 "$0: Unknown \`$1' option"
|
||||
echo 1>&2 "Try \`$0 --help' for more information"
|
||||
exit 1
|
||||
;;
|
||||
|
||||
aclocal*)
|
||||
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
|
||||
# We have it, but it failed.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified \`acinclude.m4' or \`${configure_ac}'. You might want
|
||||
to install the \`Automake' and \`Perl' packages. Grab them from
|
||||
any GNU archive site."
|
||||
touch aclocal.m4
|
||||
;;
|
||||
|
||||
autoconf)
|
||||
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
|
||||
# We have it, but it failed.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified \`${configure_ac}'. You might want to install the
|
||||
\`Autoconf' and \`GNU m4' packages. Grab them from any GNU
|
||||
archive site."
|
||||
touch configure
|
||||
;;
|
||||
|
||||
autoheader)
|
||||
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
|
||||
# We have it, but it failed.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified \`acconfig.h' or \`${configure_ac}'. You might want
|
||||
to install the \`Autoconf' and \`GNU m4' packages. Grab them
|
||||
from any GNU archive site."
|
||||
files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}`
|
||||
test -z "$files" && files="config.h"
|
||||
touch_files=
|
||||
for f in $files; do
|
||||
case "$f" in
|
||||
*:*) touch_files="$touch_files "`echo "$f" |
|
||||
sed -e 's/^[^:]*://' -e 's/:.*//'`;;
|
||||
*) touch_files="$touch_files $f.in";;
|
||||
esac
|
||||
done
|
||||
touch $touch_files
|
||||
;;
|
||||
|
||||
automake*)
|
||||
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
|
||||
# We have it, but it failed.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'.
|
||||
You might want to install the \`Automake' and \`Perl' packages.
|
||||
Grab them from any GNU archive site."
|
||||
find . -type f -name Makefile.am -print |
|
||||
sed 's/\.am$/.in/' |
|
||||
while read f; do touch "$f"; done
|
||||
;;
|
||||
|
||||
autom4te)
|
||||
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
|
||||
# We have it, but it failed.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is needed, and you do not seem to have it handy on your
|
||||
system. You might have modified some files without having the
|
||||
proper tools for further handling them.
|
||||
You can get \`$1Help2man' as part of \`Autoconf' from any GNU
|
||||
archive site."
|
||||
|
||||
file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'`
|
||||
test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'`
|
||||
if test -f "$file"; then
|
||||
touch $file
|
||||
else
|
||||
test -z "$file" || exec >$file
|
||||
echo "#! /bin/sh"
|
||||
echo "# Created by GNU Automake missing as a replacement of"
|
||||
echo "# $ $@"
|
||||
echo "exit 0"
|
||||
chmod +x $file
|
||||
exit 1
|
||||
fi
|
||||
;;
|
||||
|
||||
bison|yacc)
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified a \`.y' file. You may need the \`Bison' package
|
||||
in order for those modifications to take effect. You can get
|
||||
\`Bison' from any GNU archive site."
|
||||
rm -f y.tab.c y.tab.h
|
||||
if [ $# -ne 1 ]; then
|
||||
eval LASTARG="\${$#}"
|
||||
case "$LASTARG" in
|
||||
*.y)
|
||||
SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'`
|
||||
if [ -f "$SRCFILE" ]; then
|
||||
cp "$SRCFILE" y.tab.c
|
||||
fi
|
||||
SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'`
|
||||
if [ -f "$SRCFILE" ]; then
|
||||
cp "$SRCFILE" y.tab.h
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
if [ ! -f y.tab.h ]; then
|
||||
echo >y.tab.h
|
||||
fi
|
||||
if [ ! -f y.tab.c ]; then
|
||||
echo 'main() { return 0; }' >y.tab.c
|
||||
fi
|
||||
;;
|
||||
|
||||
lex|flex)
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified a \`.l' file. You may need the \`Flex' package
|
||||
in order for those modifications to take effect. You can get
|
||||
\`Flex' from any GNU archive site."
|
||||
rm -f lex.yy.c
|
||||
if [ $# -ne 1 ]; then
|
||||
eval LASTARG="\${$#}"
|
||||
case "$LASTARG" in
|
||||
*.l)
|
||||
SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`
|
||||
if [ -f "$SRCFILE" ]; then
|
||||
cp "$SRCFILE" lex.yy.c
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
if [ ! -f lex.yy.c ]; then
|
||||
echo 'main() { return 0; }' >lex.yy.c
|
||||
fi
|
||||
;;
|
||||
|
||||
help2man)
|
||||
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
|
||||
# We have it, but it failed.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified a dependency of a manual page. You may need the
|
||||
\`Help2man' package in order for those modifications to take
|
||||
effect. You can get \`Help2man' from any GNU archive site."
|
||||
|
||||
file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
|
||||
if test -z "$file"; then
|
||||
file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'`
|
||||
fi
|
||||
if [ -f "$file" ]; then
|
||||
touch $file
|
||||
else
|
||||
test -z "$file" || exec >$file
|
||||
echo ".ab help2man is required to generate this page"
|
||||
exit 1
|
||||
fi
|
||||
;;
|
||||
|
||||
makeinfo)
|
||||
if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then
|
||||
# We have makeinfo, but it failed.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is missing on your system. You should only need it if
|
||||
you modified a \`.texi' or \`.texinfo' file, or any other file
|
||||
indirectly affecting the aspect of the manual. The spurious
|
||||
call might also be the consequence of using a buggy \`make' (AIX,
|
||||
DU, IRIX). You might want to install the \`Texinfo' package or
|
||||
the \`GNU make' package. Grab either from any GNU archive site."
|
||||
file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
|
||||
if test -z "$file"; then
|
||||
file=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'`
|
||||
file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $file`
|
||||
fi
|
||||
touch $file
|
||||
;;
|
||||
|
||||
tar)
|
||||
shift
|
||||
if test -n "$run"; then
|
||||
echo 1>&2 "ERROR: \`tar' requires --run"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# We have already tried tar in the generic part.
|
||||
# Look for gnutar/gtar before invocation to avoid ugly error
|
||||
# messages.
|
||||
if (gnutar --version > /dev/null 2>&1); then
|
||||
gnutar "$@" && exit 0
|
||||
fi
|
||||
if (gtar --version > /dev/null 2>&1); then
|
||||
gtar "$@" && exit 0
|
||||
fi
|
||||
firstarg="$1"
|
||||
if shift; then
|
||||
case "$firstarg" in
|
||||
*o*)
|
||||
firstarg=`echo "$firstarg" | sed s/o//`
|
||||
tar "$firstarg" "$@" && exit 0
|
||||
;;
|
||||
esac
|
||||
case "$firstarg" in
|
||||
*h*)
|
||||
firstarg=`echo "$firstarg" | sed s/h//`
|
||||
tar "$firstarg" "$@" && exit 0
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
echo 1>&2 "\
|
||||
WARNING: I can't seem to be able to run \`tar' with the given arguments.
|
||||
You may want to install GNU tar or Free paxutils, or check the
|
||||
command line arguments."
|
||||
exit 1
|
||||
;;
|
||||
|
||||
*)
|
||||
echo 1>&2 "\
|
||||
WARNING: \`$1' is needed, and you do not seem to have it handy on your
|
||||
system. You might have modified some files without having the
|
||||
proper tools for further handling them. Check the \`README' file,
|
||||
it often tells you about the needed prerequirements for installing
|
||||
this package. You may also peek at any GNU archive site, in case
|
||||
some other package would contain this missing \`$1' program."
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
exit 0
|
|
@ -0,0 +1,99 @@
|
|||
#! /bin/sh
|
||||
# mkinstalldirs --- make directory hierarchy
|
||||
# Author: Noah Friedman <friedman@prep.ai.mit.edu>
|
||||
# Created: 1993-05-16
|
||||
# Public domain
|
||||
|
||||
errstatus=0
|
||||
dirmode=""
|
||||
|
||||
usage="\
|
||||
Usage: mkinstalldirs [-h] [--help] [-m mode] dir ..."
|
||||
|
||||
# process command line arguments
|
||||
while test $# -gt 0 ; do
|
||||
case "${1}" in
|
||||
-h | --help | --h* ) # -h for help
|
||||
echo "${usage}" 1>&2; exit 0 ;;
|
||||
-m ) # -m PERM arg
|
||||
shift
|
||||
test $# -eq 0 && { echo "${usage}" 1>&2; exit 1; }
|
||||
dirmode="${1}"
|
||||
shift ;;
|
||||
-- ) shift; break ;; # stop option processing
|
||||
-* ) echo "${usage}" 1>&2; exit 1 ;; # unknown option
|
||||
* ) break ;; # first non-opt arg
|
||||
esac
|
||||
done
|
||||
|
||||
for file
|
||||
do
|
||||
if test -d "$file"; then
|
||||
shift
|
||||
else
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
case $# in
|
||||
0) exit 0 ;;
|
||||
esac
|
||||
|
||||
case $dirmode in
|
||||
'')
|
||||
if mkdir -p -- . 2>/dev/null; then
|
||||
echo "mkdir -p -- $*"
|
||||
exec mkdir -p -- "$@"
|
||||
fi ;;
|
||||
*)
|
||||
if mkdir -m "$dirmode" -p -- . 2>/dev/null; then
|
||||
echo "mkdir -m $dirmode -p -- $*"
|
||||
exec mkdir -m "$dirmode" -p -- "$@"
|
||||
fi ;;
|
||||
esac
|
||||
|
||||
for file
|
||||
do
|
||||
set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
|
||||
shift
|
||||
|
||||
pathcomp=
|
||||
for d
|
||||
do
|
||||
pathcomp="$pathcomp$d"
|
||||
case "$pathcomp" in
|
||||
-* ) pathcomp=./$pathcomp ;;
|
||||
esac
|
||||
|
||||
if test ! -d "$pathcomp"; then
|
||||
echo "mkdir $pathcomp"
|
||||
|
||||
mkdir "$pathcomp" || lasterr=$?
|
||||
|
||||
if test ! -d "$pathcomp"; then
|
||||
errstatus=$lasterr
|
||||
else
|
||||
if test ! -z "$dirmode"; then
|
||||
echo "chmod $dirmode $pathcomp"
|
||||
|
||||
lasterr=""
|
||||
chmod "$dirmode" "$pathcomp" || lasterr=$?
|
||||
|
||||
if test ! -z "$lasterr"; then
|
||||
errstatus=$lasterr
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
pathcomp="$pathcomp/"
|
||||
done
|
||||
done
|
||||
|
||||
exit $errstatus
|
||||
|
||||
# Local Variables:
|
||||
# mode: shell-script
|
||||
# sh-indentation: 3
|
||||
# End:
|
||||
# mkinstalldirs ends here
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,41 @@
|
|||
# -*- Autoconf -*-
|
||||
# Process this file with autoconf to produce a configure script.
|
||||
|
||||
AC_PREREQ(2.59)
|
||||
AC_INIT(sfftobmp, 2.3, peter.schaefer@gmx.de)
|
||||
AC_CONFIG_AUX_DIR(config)
|
||||
|
||||
AM_INIT_AUTOMAKE(sff, 2.3,peter.schaefer@gmx.de)
|
||||
|
||||
AC_CONFIG_SRCDIR([src/main.cpp])
|
||||
AM_CONFIG_HEADER([src/config.h])
|
||||
|
||||
# Checks for programs.
|
||||
AC_PROG_CXX
|
||||
AC_PROG_CC
|
||||
|
||||
AC_CHECK_HEADER(tiffio.h,AC_DEFINE( HAVE_LIBTIFF,1, LibTIFF),AC_MSG_ERROR(tiffio.h not found))
|
||||
AC_CHECK_LIB(tiff,TIFFOpen,[ TIFF_LIB="-ltiff" ],AC_MSG_ERROR(You need libtiff))
|
||||
AC_SUBST(TIFF_LIB)
|
||||
|
||||
AC_CHECK_HEADER(jpeglib.h,AC_DEFINE(HAVE_LIBJPEG,1, LibJPEG),AC_MSG_ERROR(jpeglib.h not found))
|
||||
AC_CHECK_LIB(jpeg, jpeg_destroy_decompress,[ JPEG_LIB="-ljpeg" ],AC_MSG_ERROR(You need libjpeg))
|
||||
AC_SUBST(JPEG_LIB)
|
||||
|
||||
# Checks for header files.
|
||||
AC_HEADER_STDC
|
||||
AC_CHECK_HEADERS([stdlib.h string.h utime.h])
|
||||
|
||||
# Checks for typedefs, structures, and compiler characteristics.
|
||||
AC_HEADER_STDBOOL
|
||||
AC_C_CONST
|
||||
AC_TYPE_OFF_T
|
||||
AC_TYPE_SIZE_T
|
||||
|
||||
# Checks for library functions.
|
||||
AC_FUNC_MALLOC
|
||||
AC_FUNC_MEMCMP
|
||||
AC_FUNC_UTIME_NULL
|
||||
AC_CHECK_FUNCS([memset strdup strrchr utime])
|
||||
AC_OUTPUT(Makefile src/Makefile)
|
||||
|
|
@ -0,0 +1,64 @@
|
|||
CHANGES
|
||||
-------
|
||||
|
||||
V0.1 : crude start
|
||||
V0.2 : code cleanup, added support for multiple pages, robust
|
||||
file handling.
|
||||
V0.3 : added support for PBM output.
|
||||
V1.0 : finally fixed mirroring bug (after recognizing that as
|
||||
a bug). Page orientation should be correct now.
|
||||
V1.1 : changed license to BSD-style with advertising clause removed.
|
||||
V1.2 : added -bmpx and -pbmx switches to add file extensions,
|
||||
changed mode of output file to binary (caused problems
|
||||
with MS Windows), fixed bug with bmp output (wrote one
|
||||
additional line).
|
||||
V2.0 : added jpeg and tiff output, sfftobmp now honours the vertical
|
||||
resolution (lpi) field in the sff header and doubles
|
||||
the scanlines accordingly.
|
||||
V2.1 : added single-page tiff output on request (sic!),
|
||||
added adjustable jpeg quality,
|
||||
omitted exception in the no-black-after-white-code case -
|
||||
this seems to be a common error therefore continuing decoding
|
||||
here seems reasonable. There maybe also an error in the code
|
||||
table but omitting the exception fixed the problem faster ;),
|
||||
changed the wording of the license for clarity.
|
||||
V2.2 : contributions by Ulf Zibis (thanks a lot!):
|
||||
restructured and cleaned up code, preserve resolution information
|
||||
in output files (JPG/BMP and TIFF), made line-doubling optional,
|
||||
handle 300 and 400 dpi information (for SFF files created by
|
||||
RVS COM)
|
||||
*
|
||||
contribution by Gernot Hillier (thanks a lot, too!):
|
||||
output on stdout possible for multipage TIFF output
|
||||
*
|
||||
me:
|
||||
changed the wording of the license to include contributors
|
||||
created CREDITS file
|
||||
restructured the code even more
|
||||
added new commandline option parser my_getopt ((C) by Benjamin Sittler)
|
||||
adapted stdout patch for Windows
|
||||
tuned decoder to handle extended codes and EOLs
|
||||
V3.0 : me:
|
||||
shuffled the code quite a bit
|
||||
changed commandline options, now includes multi-file processing
|
||||
made keeping the date possible for linux, too
|
||||
fixed decoder bug which did not decode a full line (Kudos to Eckhard Rueggeberg)
|
||||
fixed extended MH codes (wrong bitorder; silly me)
|
||||
V3.1 : me:
|
||||
changed message output from stderr to stdout except errors (duh!)
|
||||
added -quiet switch
|
||||
some fixes from debian package
|
||||
some big endian fixes
|
||||
allowed up to 2048 bytes "fuzz" at the beginning of the file
|
||||
V3.1.1 me:
|
||||
set the "DateTime" field within TIFF files with the UTC value of the
|
||||
input file's mtime (suggestion by asterisk@puzzled.xs4all.nl).
|
||||
V3.1.2 me:
|
||||
treat files with empty pages correctly (thanks to dirk.fellenberg@interdata.de).
|
||||
V3.1.3 me:
|
||||
corrected path handling under Windows, no features added or changed.
|
||||
Sfftobmp -v now also prints the library versions involved.
|
||||
The source tree now also contains makefile and 3rd-party libs for
|
||||
compilation with Microsoft Visual C.
|
||||
--
|
||||
$Id: changes,v 1.6 2009/08/23 13:21:34 pschaefer Exp $
|
|
@ -0,0 +1,26 @@
|
|||
This is sff2bmp, a program to convert structured fax files
|
||||
(sff) to windows bitmap files (bmp), portable bitmap graphics (pbm),
|
||||
tagged image file format (tiff) or JPEG (jpg).
|
||||
|
||||
Copyright (c) 1998-2008 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
|
||||
Permission to use, copy, modify, distribute, and sell this software and
|
||||
its documentation for any purpose is hereby granted without fee.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
|
||||
IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
|
||||
INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
|
||||
RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
|
||||
THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT
|
||||
OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
|
||||
You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
|
||||
Contributor(s):
|
||||
Gernot Hillier <ghillie@suse.de>
|
||||
Ulf Zibis <ulf.zibis@gmx.de>
|
||||
|
||||
$Id: copying,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
|
@ -0,0 +1,11 @@
|
|||
---
|
||||
Gernot Hillier <ghillie@suse.de>
|
||||
Added support for output on stdout in TIFF output class
|
||||
---
|
||||
Ulf Zibis <ulf.zibis@gmx.de>
|
||||
General code cleanup, changes to the output classes to
|
||||
preserve the resolution information of the input file.
|
||||
---
|
||||
(in alphabetic order)
|
||||
|
||||
$Id: credits,v 1.1.1.1 2005/05/20 21:24:16 pschaefer Exp $
|
|
@ -0,0 +1,16 @@
|
|||
2002-07-26 Benjamin C. W. Sittler <bsittler@knownow.com>
|
||||
|
||||
* README: updated for version 1.4
|
||||
|
||||
* my_getopt.c: now we include <sys/types.h> explicitly for those
|
||||
systems that narrowly (mis-)interpret ANSI C and POSIX
|
||||
(_my_getopt_internal): added an explicit cast to size_t to make
|
||||
g++ happy
|
||||
|
||||
* getopt.h, my_getopt.h: added extern "C" { ... } for C++
|
||||
compilation (thanks to Jeff Lawson <bovine@ud.com> and others)
|
||||
|
||||
2001-08-20 Benjamin C. W. Sittler <bsittler@knownow.com>
|
||||
|
||||
* getopt.h (getopt_long_only): fixed typo (thanks to Justin Lee
|
||||
<justin_lee@ud.com>)
|
|
@ -0,0 +1,22 @@
|
|||
my_getopt - a command-line argument parser
|
||||
Copyright 1997-2001, Benjamin Sittler
|
||||
|
||||
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, sublicense, and/or sell copies
|
||||
of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
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. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
DEALINGS IN THE SOFTWARE.
|
|
@ -0,0 +1,140 @@
|
|||
my_getopt - a command-line argument parser
|
||||
Copyright 1997-2002, Benjamin Sittler
|
||||
|
||||
The author can be reached by sending email to <bsittler@iname.com>.
|
||||
|
||||
The version of my_getopt in this package (1.4) has a BSD-like license;
|
||||
see the file LICENSE for details. Version 1.0 of my_getopt was similar
|
||||
to the GPL'ed version of my_getopt included with SMOKE-16 Version 1,
|
||||
Release 19990717. SMOKE-16 packages are available from:
|
||||
|
||||
http://geocities.com/bsittler/#smoke16
|
||||
|
||||
OVERVIEW OF THE ARGUMENT PARSER
|
||||
===============================
|
||||
|
||||
The getopt(), getopt_long() and getopt_long_only() functions parse
|
||||
command line arguments. The argc and argv parameters passed to these
|
||||
functions correspond to the argument count and argument list passed to
|
||||
your program's main() function at program start-up. Element 0 of the
|
||||
argument list conventionally contains the name of your program. Any
|
||||
remaining arguments starting with "-" (except for "-" or "--" by
|
||||
themselves) are option arguments, some of include option values. This
|
||||
family of getopt() functions allows intermixed option and non-option
|
||||
arguments anywhere in the argument list, except that "--" by itself
|
||||
causes the remaining elements of the argument list to be treated as
|
||||
non-option arguments.
|
||||
|
||||
[ See the parts of this document labeled "DOCUMENTATION" and
|
||||
"WHY RE-INVENT THE WHEEL?" for a more information. ]
|
||||
|
||||
FILES
|
||||
=====
|
||||
|
||||
The following four files constitute the my_getopt package:
|
||||
|
||||
LICENSE - license and warranty information for my_getopt
|
||||
my_getopt.c - implementation of my getopt replacement
|
||||
my_getopt.h - interface for my getopt replacement
|
||||
getopt.h - a header file to make my getopt look like GNU getopt
|
||||
|
||||
USAGE
|
||||
=====
|
||||
|
||||
To use my_getopt in your application, include the following line to
|
||||
your main program source:
|
||||
|
||||
#include "getopt.h"
|
||||
|
||||
This line should appear after your standard system header files to
|
||||
avoid conflicting with your system's built-in getopt.
|
||||
|
||||
Then compile my_getopt.c into my_getopt.o, and link my_getopt.o into
|
||||
your application:
|
||||
|
||||
$ cc -c my_getopt.c
|
||||
$ ld -o app app.o ... my_getopt.o
|
||||
|
||||
To avoid conflicting with standard library functions, the function
|
||||
names and global variables used by my_getopt all begin with `my_'. To
|
||||
ensure compatibility with existing C programs, the `getopt.h' header
|
||||
file uses the C preprocessor to redefine names like getopt, optarg,
|
||||
optind, and so forth to my_getopt, my_optarg, my_optind, etc.
|
||||
|
||||
SAMPLE PROGRAM
|
||||
==============
|
||||
|
||||
There is also a public-domain sample program:
|
||||
|
||||
main.c - main() for a sample program using my_getopt
|
||||
Makefile - build script for the sample program (called `copy')
|
||||
|
||||
To build and test the sample program:
|
||||
|
||||
$ make
|
||||
$ ./copy -help
|
||||
$ ./copy -version
|
||||
|
||||
The sample program bears a slight resemblance to the UNIX `cat'
|
||||
utility, but can be used rot13-encode streams, and can redirect output
|
||||
to a file.
|
||||
|
||||
DOCUMENTATION
|
||||
=============
|
||||
|
||||
There is not yet any real documentation for my_getopt. For the moment,
|
||||
use the Linux manual page for getopt. It has its own copyright and
|
||||
license; view the file `getopt.3' in a text editor for more details.
|
||||
|
||||
getopt.3 - the manual page for GNU getopt
|
||||
getopt.txt - preformatted copy of the manual page for GNU getopt,
|
||||
for your convenience
|
||||
|
||||
WHY RE-INVENT THE WHEEL?
|
||||
========================
|
||||
|
||||
I re-implemented getopt, getopt_long, and getopt_long_only because
|
||||
there were noticable bugs in several versions of the GNU
|
||||
implementations, and because the GNU versions aren't always available
|
||||
on some systems (*BSD, for example.) Other systems don't include any
|
||||
sort of standard argument parser (Win32 with Microsoft tools, for
|
||||
example, has no getopt.)
|
||||
|
||||
These should do all the expected Unix- and GNU-style argument
|
||||
parsing, including permution, bunching, long options with single or
|
||||
double dashes (double dashes are required if you use
|
||||
my_getopt_long,) and optional arguments for both long and short
|
||||
options. A word with double dashes all by themselves halts argument
|
||||
parsing. A required long option argument can be in the same word as
|
||||
the option name, separated by '=', or in the next word. An optional
|
||||
long option argument must be in the same word as the option name,
|
||||
separated by '='.
|
||||
|
||||
As with the GNU versions, a '+' prefix to the short option
|
||||
specification (or the POSIXLY_CORRECT environment variable) disables
|
||||
permution, a '-' prefix to the short option specification returns 1
|
||||
for non-options, ':' after a short option indicates a required
|
||||
argument, and '::' after a short option specification indicates an
|
||||
optional argument (which must appear in the same word.) If you'd like
|
||||
to recieve ':' instead of '?' for missing option arguments, prefix the
|
||||
short option specification with ':'.
|
||||
|
||||
The original intent was to re-implement the documented behavior of
|
||||
the GNU versions, but I have found it necessary to emulate some of
|
||||
the undocumented behavior as well. Some programs depend on it.
|
||||
|
||||
KNOWN BUGS
|
||||
==========
|
||||
|
||||
The GNU versions support POSIX-style -W "name=value" long
|
||||
options. Currently, my_getopt does not support these, because I
|
||||
don't have any documentation on them (other than the fact that they
|
||||
are enabled by "W;" in the short option specification.) As a
|
||||
temporary workaround, my_getopt treats "W;" in the short option
|
||||
string identically to "W:".
|
||||
|
||||
The GNU versions support internationalized/localized
|
||||
messages. Currently, my_getopt does not.
|
||||
|
||||
There should be re-entrant versions of all these functions so that
|
||||
multiple threads can parse arguments simultaneously.
|
|
@ -0,0 +1,233 @@
|
|||
---------------
|
||||
SFFTOBMP V3.1.3
|
||||
---------------
|
||||
|
||||
Tool to convert "Structured Fax Files" into Windows bitmaps (BMP),
|
||||
Portable Bitmaps (PBM), JPEG Pictures (JPG) and single or multi-
|
||||
paged TIFF Images.
|
||||
|
||||
|
||||
SFF - Wotsit ?
|
||||
--------------
|
||||
|
||||
SFF means 'Structured Fax File', intended by the CAPI interface to be
|
||||
used to save incoming faxes. Within Linux it's e.g. the AVM-B1 card
|
||||
which creates such files.
|
||||
|
||||
See http://www.capi.org for specs of the CAPI interface.
|
||||
|
||||
This is where sfftobmp comes in.
|
||||
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
Conversion of SFF files in Modified Huffman (MH) coding to Windows
|
||||
BMP (monochrome, uncompressed), PBM (Portable Bitmap with RAWBITS
|
||||
P4-Header), JPEG or TIFF files.
|
||||
|
||||
SFF files containing more than one page will be split into one
|
||||
output file per page, except for TIFF output which will be one multi-
|
||||
paged file (however, even for TIFF there's an option to create
|
||||
singlepaged files).
|
||||
|
||||
Written in C++
|
||||
|
||||
|
||||
Compilation
|
||||
-----------
|
||||
|
||||
Only tested under Ubuntu Linux ('Gutsy') and Windows2000 SP4.
|
||||
|
||||
Used compilers:
|
||||
|
||||
gcc 4.1.3
|
||||
Visual Studio Express
|
||||
|
||||
Under Linux, a simple call to './configure && make' will be sufficient
|
||||
most of the time if using GNU make and provided all needed libraries
|
||||
are installed (see below).
|
||||
|
||||
Under Windows, a Visual Studio workspace file is no longer supplied.
|
||||
Please see the folder "win32" for a Makefile for Microsoft NMAKE to
|
||||
compile sfftobmp on the command line. Use
|
||||
|
||||
nmake nodebug=1 /f makefile.vc
|
||||
|
||||
to build (run the VCVARSALL.BAT before to set all environment variables).
|
||||
|
||||
Alternatively, you can use the free MinGW C++ Compiler.
|
||||
A good (and also free) IDE is Dev-C++ from Bloodshed Software - you'll
|
||||
find a workspace file for this IDE in the distribution ("sfftobmp.dev").
|
||||
See http://www.bloodshed.net/dev/devcpp.html. However, you will have to
|
||||
update the paths to external libraries contained in this workspace.
|
||||
|
||||
To compile sfftobmp you need the following 3rd party libraries:
|
||||
|
||||
- jpeglib
|
||||
- tifflib
|
||||
- libboost-filesystem (available since Boost 1.31.0).
|
||||
|
||||
On a Linux system these libraries can usually be installed via the package
|
||||
manager. On a Debian system you need
|
||||
|
||||
libjpeg62 and libjpeg62-dev
|
||||
libtiff4 and libtiff4-dev
|
||||
libboost-filesystem-dev
|
||||
|
||||
That's all.
|
||||
|
||||
On Windows, the sources are supplied in the "win32" folder, the makefiles
|
||||
are already preconfigured for statically linkage with sfftobmp.
|
||||
|
||||
For Dev-C++ pre-packaged versions of Tfflib and Jpeglib are available.
|
||||
See http://www.bloodshed.net/dev/packages/imagelib.html. Boost libraries
|
||||
have to be compiled by yourself, tough (they do provide MinGW support).
|
||||
|
||||
The 3rd party libraries can be downloaded at this locations:
|
||||
|
||||
Boost libraries: http://www.boost.org/
|
||||
Tifflib : http://www.remotesensing.org/libtiff/
|
||||
Jpeglib : http://www.ijg.org/
|
||||
|
||||
|
||||
Usage
|
||||
-----
|
||||
|
||||
sfftobmp [options] INFILE1 [INFILE2 ..] [-o OUTSPEC]
|
||||
|
||||
Options:
|
||||
-h or -help Show help message and exit
|
||||
-v or -version Show version and exit
|
||||
-b or -bmp Output is one monochrome BMP file for each fax page
|
||||
-p or -pbm Output is one Portable Bitmap file for each fax page
|
||||
-j or -jpg Output is one JPEG file for each fax page
|
||||
-jNUM or -jpg=NUM Use jpeg quality of NUM percent (1..99)
|
||||
-T or -tifs Output is one single-page TIFF file for each fax page
|
||||
-t or -tif Output is one multi-paged TIFF file containing all pages
|
||||
-r or -keepres Inhibit line doubling for low-res faxes
|
||||
-d or -keepdate Keep date and time of input file for the output file(s)
|
||||
-q or -quiet Don't display messages (except errors)
|
||||
|
||||
OUTSPEC is interpreted as:
|
||||
|
||||
- a filename if only one input file is given.
|
||||
- a directory name if more than one input file is given.
|
||||
|
||||
If OUTSPEC is ommitted, the name of the output files will be
|
||||
derived from the input files and created in the same directory.
|
||||
|
||||
In case of TIFF output, you can specify the compression by using
|
||||
additional specifiers:
|
||||
|
||||
-tr resp. -Tr : CCITT modified Huffman RLE
|
||||
-t4 resp. -T4 : CCITT Fax Class 4 compression
|
||||
|
||||
The default is CCITT Fax Class 3 compression.
|
||||
|
||||
For JPEG output you can optionally set the JPEG quality used by
|
||||
adding a two-digit number between 1 and 99 to the option.
|
||||
|
||||
I.e.
|
||||
|
||||
-j35 or
|
||||
-jpg=35
|
||||
|
||||
means JPEG output with 35% quality. If you don't give a quality,
|
||||
a default of 40% is used (mostly sufficient for b&w faxes).
|
||||
|
||||
|
||||
OUTPUT ON STDOUT
|
||||
----------------
|
||||
|
||||
Output on stdout is available for multipaged TIFF output
|
||||
only (option "-t"). Use "-" as output filename in this
|
||||
case:
|
||||
|
||||
sfftobmp -t infile.sff -o - > out.tif
|
||||
|
||||
NOTE: Reading from stdin is not supported.
|
||||
|
||||
|
||||
OUTPUT FILENAMES
|
||||
----------------
|
||||
|
||||
The output filenames will be created by replacing the
|
||||
extension of the input file (if it exists) by the extension
|
||||
of the target format. If the input file contains more than
|
||||
one page a three-digit number is added.
|
||||
|
||||
So, if the input is called "foo.sff" and has 3 pages,
|
||||
the output files are named "foo_001.bmp", "foo_002.bmp"
|
||||
and "foo_003.bmp" if you don't specify an OUTSPEC.
|
||||
|
||||
If you specify an OUTSPEC with an extension, say
|
||||
"sfftobmp -b foo.sff -o bar.out" the output filenames are
|
||||
called "bar_001.out", "bar_002.out" and "bar_003.out" -
|
||||
that is the given extension ".out" is preserved in this
|
||||
case.
|
||||
|
||||
If you specify an OUTSPEC with no extension, the output
|
||||
files will also carry no extension.
|
||||
|
||||
|
||||
RESOLUTION HANDLING
|
||||
-------------------
|
||||
|
||||
SffToBmp keeps resolution information intact. This means, if
|
||||
you convert a fax with 203x98 dpi this resolution information is
|
||||
written in the output file if it is supported by the output
|
||||
format. This is JPEG, TIFF and BMP.
|
||||
|
||||
However, as many bitmap viewer applications are not considering
|
||||
this information while displaying the bitmap, SffToBmp defaults
|
||||
to double scanlines if a low-res fax (i.e. 203x98 dpi) is
|
||||
converted.
|
||||
|
||||
In case your image viewer does actually treat resolution information
|
||||
correctly (your image will look stretched vertically in this case),
|
||||
you can suppress this scanline-doubling by specifying the "-r" option.
|
||||
|
||||
|
||||
TODO
|
||||
----
|
||||
|
||||
- speed up decoder with better table lookups
|
||||
(looking at GHz CPUs noadays, i doubt that this happes...)
|
||||
- support other non-intel architectures (64 Bits, different
|
||||
byte order). Sfftobmp will most likely fail on these.
|
||||
(well, no one complained till now)
|
||||
- BMP format stores the scan lines bottom-up, that means
|
||||
the first line in the file is the last on the screen...
|
||||
Therefore the BMP target file will be filled from the end to
|
||||
the beginning. To do that, a seek beyond the end of file
|
||||
is necessary at creation of the file. This may lead to problems
|
||||
on some platforms.
|
||||
|
||||
|
||||
Last but not least...
|
||||
---------------------
|
||||
|
||||
Should decoding of a SFF file fail:
|
||||
Please send the SFF file uuencoded to me - if it isn't about
|
||||
500 MB and/or contains top secret information ;).
|
||||
|
||||
Suggestions, extensions and patches welcome, flames will go
|
||||
to /dev/null.
|
||||
|
||||
I'm always pleased to hear that somebody is actually using my
|
||||
software. If you can manage it, e-mail me a quick notice.
|
||||
|
||||
If you *really* like sfftobmp or depend on it, please look
|
||||
into my wishlist:
|
||||
|
||||
http://www.amazon.de/gp/registry/wishlist/OVQ6LSYS4E4D/028-1843567-9543743
|
||||
|
||||
Thanks!
|
||||
|
||||
Contact:
|
||||
--------
|
||||
peter.schaefer@gmx.net
|
||||
http://sfftools.sourceforge.net
|
||||
|
||||
$Id: readme,v 1.6 2009/08/23 13:21:34 pschaefer Exp $
|
|
@ -0,0 +1,237 @@
|
|||
[Project]
|
||||
FileName=sfftobmp.dev
|
||||
Name=sfftobmp
|
||||
UnitCount=19
|
||||
Type=1
|
||||
Ver=1
|
||||
ObjFiles=
|
||||
Includes=C:\Boost\include\boost-1_31;E:\Dev-Cpp\include
|
||||
Libs=
|
||||
PrivateResource=
|
||||
ResourceIncludes=
|
||||
MakeIncludes=
|
||||
Compiler=
|
||||
CppCompiler=-Os_@@_
|
||||
Linker=../Dev-Cpp/lib/libtiff.a_@@_../Dev-Cpp/lib/libjpeg.a_@@_C:/Boost/lib/libboost_filesystem-mgw-s-1_31.lib_@@_
|
||||
IsCpp=1
|
||||
Icon=
|
||||
ExeOutput=
|
||||
ObjectOutput=
|
||||
OverrideOutput=0
|
||||
OverrideOutputName=sfftobmp.exe
|
||||
HostApplication=
|
||||
Folders=
|
||||
CommandLine=
|
||||
IncludeVersionInfo=0
|
||||
SupportXPThemes=0
|
||||
CompilerSet=1
|
||||
CompilerSettings=000000100000000000
|
||||
|
||||
[Unit1]
|
||||
FileName=src\input.cpp
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit2]
|
||||
FileName=src\cmdline.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit3]
|
||||
FileName=src\codes.cpp
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit4]
|
||||
FileName=src\codes.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit5]
|
||||
FileName=src\common.cpp
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit6]
|
||||
FileName=src\common.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit7]
|
||||
FileName=src\config.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit8]
|
||||
FileName=src\decoder.cpp
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit9]
|
||||
FileName=src\decoder.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit10]
|
||||
FileName=src\getopt.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit11]
|
||||
FileName=src\cmdline.cpp
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit12]
|
||||
FileName=src\input.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit13]
|
||||
FileName=src\main.cpp
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit14]
|
||||
FileName=src\main.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit15]
|
||||
FileName=src\my_getopt.c
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit16]
|
||||
FileName=src\my_getopt.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit17]
|
||||
FileName=src\output.cpp
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit18]
|
||||
FileName=src\output.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit19]
|
||||
FileName=src\sfftypes.h
|
||||
CompileCpp=1
|
||||
Folder=sfftobmp
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[VersionInfo]
|
||||
Major=0
|
||||
Minor=1
|
||||
Release=1
|
||||
Build=1
|
||||
LanguageID=1033
|
||||
CharsetID=1252
|
||||
CompanyName=
|
||||
FileVersion=
|
||||
FileDescription=Developed using the Dev-C++ IDE
|
||||
InternalName=
|
||||
LegalCopyright=
|
||||
LegalTrademarks=
|
||||
OriginalFilename=
|
||||
ProductName=
|
||||
ProductVersion=
|
||||
AutoIncBuildNr=0
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
stamp-h1
|
||||
config.h
|
||||
.deps
|
||||
sfftobmp
|
||||
Makefile
|
|
@ -0,0 +1,6 @@
|
|||
## Makefile.am -- Process this file with automake to produce Makefile.in
|
||||
|
||||
INCLUDES = -I$(top_builddir) -I$(top_srcdir)
|
||||
bin_PROGRAMS = sfftobmp
|
||||
sfftobmp_SOURCES = my_getopt.c cmdline.cpp codes.cpp common.cpp decoder.cpp input.cpp main.cpp output.cpp
|
||||
sfftobmp_LDADD = @TIFF_LIB@ @JPEG_LIB@ -lboost_filesystem-mt -lboost_system
|
|
@ -0,0 +1,504 @@
|
|||
# Makefile.in generated by automake 1.11.1 from Makefile.am.
|
||||
# @configure_input@
|
||||
|
||||
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
|
||||
# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
|
||||
# Inc.
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy and/or distribute it,
|
||||
# with or without modifications, as long as this notice is preserved.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE.
|
||||
|
||||
@SET_MAKE@
|
||||
|
||||
VPATH = @srcdir@
|
||||
pkgdatadir = $(datadir)/@PACKAGE@
|
||||
pkgincludedir = $(includedir)/@PACKAGE@
|
||||
pkglibdir = $(libdir)/@PACKAGE@
|
||||
pkglibexecdir = $(libexecdir)/@PACKAGE@
|
||||
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
|
||||
install_sh_DATA = $(install_sh) -c -m 644
|
||||
install_sh_PROGRAM = $(install_sh) -c
|
||||
install_sh_SCRIPT = $(install_sh) -c
|
||||
INSTALL_HEADER = $(INSTALL_DATA)
|
||||
transform = $(program_transform_name)
|
||||
NORMAL_INSTALL = :
|
||||
PRE_INSTALL = :
|
||||
POST_INSTALL = :
|
||||
NORMAL_UNINSTALL = :
|
||||
PRE_UNINSTALL = :
|
||||
POST_UNINSTALL = :
|
||||
bin_PROGRAMS = sfftobmp$(EXEEXT)
|
||||
subdir = src
|
||||
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
|
||||
$(srcdir)/config.h.in
|
||||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||
am__aclocal_m4_deps = $(top_srcdir)/configure.ac
|
||||
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||
$(ACLOCAL_M4)
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/config/mkinstalldirs
|
||||
CONFIG_HEADER = config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
CONFIG_CLEAN_VPATH_FILES =
|
||||
am__installdirs = "$(DESTDIR)$(bindir)"
|
||||
PROGRAMS = $(bin_PROGRAMS)
|
||||
am_sfftobmp_OBJECTS = my_getopt.$(OBJEXT) cmdline.$(OBJEXT) \
|
||||
codes.$(OBJEXT) common.$(OBJEXT) decoder.$(OBJEXT) \
|
||||
input.$(OBJEXT) main.$(OBJEXT) output.$(OBJEXT)
|
||||
sfftobmp_OBJECTS = $(am_sfftobmp_OBJECTS)
|
||||
sfftobmp_DEPENDENCIES =
|
||||
DEFAULT_INCLUDES = -I.@am__isrc@
|
||||
depcomp = $(SHELL) $(top_srcdir)/config/depcomp
|
||||
am__depfiles_maybe = depfiles
|
||||
am__mv = mv -f
|
||||
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
|
||||
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||
CCLD = $(CC)
|
||||
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
|
||||
CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
|
||||
CXXLD = $(CXX)
|
||||
CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
|
||||
-o $@
|
||||
SOURCES = $(sfftobmp_SOURCES)
|
||||
DIST_SOURCES = $(sfftobmp_SOURCES)
|
||||
ETAGS = etags
|
||||
CTAGS = ctags
|
||||
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||
ACLOCAL = @ACLOCAL@
|
||||
AMTAR = @AMTAR@
|
||||
AUTOCONF = @AUTOCONF@
|
||||
AUTOHEADER = @AUTOHEADER@
|
||||
AUTOMAKE = @AUTOMAKE@
|
||||
AWK = @AWK@
|
||||
CC = @CC@
|
||||
CCDEPMODE = @CCDEPMODE@
|
||||
CFLAGS = @CFLAGS@
|
||||
CPP = @CPP@
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
CXX = @CXX@
|
||||
CXXDEPMODE = @CXXDEPMODE@
|
||||
CXXFLAGS = @CXXFLAGS@
|
||||
CYGPATH_W = @CYGPATH_W@
|
||||
DEFS = @DEFS@
|
||||
DEPDIR = @DEPDIR@
|
||||
ECHO_C = @ECHO_C@
|
||||
ECHO_N = @ECHO_N@
|
||||
ECHO_T = @ECHO_T@
|
||||
EGREP = @EGREP@
|
||||
EXEEXT = @EXEEXT@
|
||||
GREP = @GREP@
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
|
||||
JPEG_LIB = @JPEG_LIB@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
LIBOBJS = @LIBOBJS@
|
||||
LIBS = @LIBS@
|
||||
LTLIBOBJS = @LTLIBOBJS@
|
||||
MAKEINFO = @MAKEINFO@
|
||||
MKDIR_P = @MKDIR_P@
|
||||
OBJEXT = @OBJEXT@
|
||||
PACKAGE = @PACKAGE@
|
||||
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
|
||||
PACKAGE_NAME = @PACKAGE_NAME@
|
||||
PACKAGE_STRING = @PACKAGE_STRING@
|
||||
PACKAGE_TARNAME = @PACKAGE_TARNAME@
|
||||
PACKAGE_URL = @PACKAGE_URL@
|
||||
PACKAGE_VERSION = @PACKAGE_VERSION@
|
||||
PATH_SEPARATOR = @PATH_SEPARATOR@
|
||||
SET_MAKE = @SET_MAKE@
|
||||
SHELL = @SHELL@
|
||||
STRIP = @STRIP@
|
||||
TIFF_LIB = @TIFF_LIB@
|
||||
VERSION = @VERSION@
|
||||
abs_builddir = @abs_builddir@
|
||||
abs_srcdir = @abs_srcdir@
|
||||
abs_top_builddir = @abs_top_builddir@
|
||||
abs_top_srcdir = @abs_top_srcdir@
|
||||
ac_ct_CC = @ac_ct_CC@
|
||||
ac_ct_CXX = @ac_ct_CXX@
|
||||
am__include = @am__include@
|
||||
am__leading_dot = @am__leading_dot@
|
||||
am__quote = @am__quote@
|
||||
am__tar = @am__tar@
|
||||
am__untar = @am__untar@
|
||||
bindir = @bindir@
|
||||
build_alias = @build_alias@
|
||||
builddir = @builddir@
|
||||
datadir = @datadir@
|
||||
datarootdir = @datarootdir@
|
||||
docdir = @docdir@
|
||||
dvidir = @dvidir@
|
||||
exec_prefix = @exec_prefix@
|
||||
host_alias = @host_alias@
|
||||
htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
localstatedir = @localstatedir@
|
||||
mandir = @mandir@
|
||||
mkdir_p = @mkdir_p@
|
||||
oldincludedir = @oldincludedir@
|
||||
pdfdir = @pdfdir@
|
||||
prefix = @prefix@
|
||||
program_transform_name = @program_transform_name@
|
||||
psdir = @psdir@
|
||||
sbindir = @sbindir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
srcdir = @srcdir@
|
||||
sysconfdir = @sysconfdir@
|
||||
target_alias = @target_alias@
|
||||
top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
INCLUDES = -I$(top_builddir) -I$(top_srcdir)
|
||||
sfftobmp_SOURCES = my_getopt.c cmdline.cpp codes.cpp common.cpp decoder.cpp input.cpp main.cpp output.cpp
|
||||
sfftobmp_LDADD = @TIFF_LIB@ @JPEG_LIB@ -lboost_filesystem-mt -lboost_system
|
||||
all: config.h
|
||||
$(MAKE) $(AM_MAKEFLAGS) all-am
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .c .cpp .o .obj
|
||||
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
|
||||
@for dep in $?; do \
|
||||
case '$(am__configure_deps)' in \
|
||||
*$$dep*) \
|
||||
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
|
||||
&& { if test -f $@; then exit 0; else break; fi; }; \
|
||||
exit 1;; \
|
||||
esac; \
|
||||
done; \
|
||||
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \
|
||||
$(am__cd) $(top_srcdir) && \
|
||||
$(AUTOMAKE) --foreign src/Makefile
|
||||
.PRECIOUS: Makefile
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||
@case '$?' in \
|
||||
*config.status*) \
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
|
||||
*) \
|
||||
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
|
||||
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
|
||||
esac;
|
||||
|
||||
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
|
||||
$(top_srcdir)/configure: $(am__configure_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
|
||||
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||
$(am__aclocal_m4_deps):
|
||||
|
||||
config.h: stamp-h1
|
||||
@if test ! -f $@; then \
|
||||
rm -f stamp-h1; \
|
||||
$(MAKE) $(AM_MAKEFLAGS) stamp-h1; \
|
||||
else :; fi
|
||||
|
||||
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
|
||||
@rm -f stamp-h1
|
||||
cd $(top_builddir) && $(SHELL) ./config.status src/config.h
|
||||
$(srcdir)/config.h.in: $(am__configure_deps)
|
||||
($(am__cd) $(top_srcdir) && $(AUTOHEADER))
|
||||
rm -f stamp-h1
|
||||
touch $@
|
||||
|
||||
distclean-hdr:
|
||||
-rm -f config.h stamp-h1
|
||||
install-binPROGRAMS: $(bin_PROGRAMS)
|
||||
@$(NORMAL_INSTALL)
|
||||
test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)"
|
||||
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
|
||||
for p in $$list; do echo "$$p $$p"; done | \
|
||||
sed 's/$(EXEEXT)$$//' | \
|
||||
while read p p1; do if test -f $$p; \
|
||||
then echo "$$p"; echo "$$p"; else :; fi; \
|
||||
done | \
|
||||
sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
|
||||
-e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
|
||||
sed 'N;N;N;s,\n, ,g' | \
|
||||
$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
|
||||
{ d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
|
||||
if ($$2 == $$4) files[d] = files[d] " " $$1; \
|
||||
else { print "f", $$3 "/" $$4, $$1; } } \
|
||||
END { for (d in files) print "f", d, files[d] }' | \
|
||||
while read type dir files; do \
|
||||
if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
|
||||
test -z "$$files" || { \
|
||||
echo " $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \
|
||||
$(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
|
||||
} \
|
||||
; done
|
||||
|
||||
uninstall-binPROGRAMS:
|
||||
@$(NORMAL_UNINSTALL)
|
||||
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
|
||||
files=`for p in $$list; do echo "$$p"; done | \
|
||||
sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
|
||||
-e 's/$$/$(EXEEXT)/' `; \
|
||||
test -n "$$list" || exit 0; \
|
||||
echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
|
||||
cd "$(DESTDIR)$(bindir)" && rm -f $$files
|
||||
|
||||
clean-binPROGRAMS:
|
||||
-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
|
||||
sfftobmp$(EXEEXT): $(sfftobmp_OBJECTS) $(sfftobmp_DEPENDENCIES)
|
||||
@rm -f sfftobmp$(EXEEXT)
|
||||
$(CXXLINK) $(sfftobmp_OBJECTS) $(sfftobmp_LDADD) $(LIBS)
|
||||
|
||||
mostlyclean-compile:
|
||||
-rm -f *.$(OBJEXT)
|
||||
|
||||
distclean-compile:
|
||||
-rm -f *.tab.c
|
||||
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmdline.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/codes.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/common.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decoder.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/input.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/my_getopt.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/output.Po@am__quote@
|
||||
|
||||
.c.o:
|
||||
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
|
||||
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||
@am__fastdepCC_FALSE@ $(COMPILE) -c $<
|
||||
|
||||
.c.obj:
|
||||
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
|
||||
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||
@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'`
|
||||
|
||||
.cpp.o:
|
||||
@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
|
||||
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||
@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ $<
|
||||
|
||||
.cpp.obj:
|
||||
@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
|
||||
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||
@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
|
||||
|
||||
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
|
||||
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
mkid -fID $$unique
|
||||
tags: TAGS
|
||||
|
||||
TAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
|
||||
$(TAGS_FILES) $(LISP)
|
||||
set x; \
|
||||
here=`pwd`; \
|
||||
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
shift; \
|
||||
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
|
||||
test -n "$$unique" || unique=$$empty_fix; \
|
||||
if test $$# -gt 0; then \
|
||||
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||
"$$@" $$unique; \
|
||||
else \
|
||||
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||
$$unique; \
|
||||
fi; \
|
||||
fi
|
||||
ctags: CTAGS
|
||||
CTAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
|
||||
$(TAGS_FILES) $(LISP)
|
||||
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
|
||||
unique=`for i in $$list; do \
|
||||
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||
done | \
|
||||
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||
test -z "$(CTAGS_ARGS)$$unique" \
|
||||
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
|
||||
$$unique
|
||||
|
||||
GTAGS:
|
||||
here=`$(am__cd) $(top_builddir) && pwd` \
|
||||
&& $(am__cd) $(top_srcdir) \
|
||||
&& gtags -i $(GTAGS_ARGS) "$$here"
|
||||
|
||||
distclean-tags:
|
||||
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
|
||||
|
||||
distdir: $(DISTFILES)
|
||||
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||
list='$(DISTFILES)'; \
|
||||
dist_files=`for file in $$list; do echo $$file; done | \
|
||||
sed -e "s|^$$srcdirstrip/||;t" \
|
||||
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
|
||||
case $$dist_files in \
|
||||
*/*) $(MKDIR_P) `echo "$$dist_files" | \
|
||||
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
|
||||
sort -u` ;; \
|
||||
esac; \
|
||||
for file in $$dist_files; do \
|
||||
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
|
||||
if test -d $$d/$$file; then \
|
||||
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
|
||||
if test -d "$(distdir)/$$file"; then \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
|
||||
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
|
||||
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||
fi; \
|
||||
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
|
||||
else \
|
||||
test -f "$(distdir)/$$file" \
|
||||
|| cp -p $$d/$$file "$(distdir)/$$file" \
|
||||
|| exit 1; \
|
||||
fi; \
|
||||
done
|
||||
check-am: all-am
|
||||
check: check-am
|
||||
all-am: Makefile $(PROGRAMS) config.h
|
||||
installdirs:
|
||||
for dir in "$(DESTDIR)$(bindir)"; do \
|
||||
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
|
||||
done
|
||||
install: install-am
|
||||
install-exec: install-exec-am
|
||||
install-data: install-data-am
|
||||
uninstall: uninstall-am
|
||||
|
||||
install-am: all-am
|
||||
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
|
||||
|
||||
installcheck: installcheck-am
|
||||
install-strip:
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||
`test -z '$(STRIP)' || \
|
||||
echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
|
||||
mostlyclean-generic:
|
||||
|
||||
clean-generic:
|
||||
|
||||
distclean-generic:
|
||||
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
|
||||
|
||||
maintainer-clean-generic:
|
||||
@echo "This command is intended for maintainers to use"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
clean: clean-am
|
||||
|
||||
clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
|
||||
|
||||
distclean: distclean-am
|
||||
-rm -rf ./$(DEPDIR)
|
||||
-rm -f Makefile
|
||||
distclean-am: clean-am distclean-compile distclean-generic \
|
||||
distclean-hdr distclean-tags
|
||||
|
||||
dvi: dvi-am
|
||||
|
||||
dvi-am:
|
||||
|
||||
html: html-am
|
||||
|
||||
html-am:
|
||||
|
||||
info: info-am
|
||||
|
||||
info-am:
|
||||
|
||||
install-data-am:
|
||||
|
||||
install-dvi: install-dvi-am
|
||||
|
||||
install-dvi-am:
|
||||
|
||||
install-exec-am: install-binPROGRAMS
|
||||
|
||||
install-html: install-html-am
|
||||
|
||||
install-html-am:
|
||||
|
||||
install-info: install-info-am
|
||||
|
||||
install-info-am:
|
||||
|
||||
install-man:
|
||||
|
||||
install-pdf: install-pdf-am
|
||||
|
||||
install-pdf-am:
|
||||
|
||||
install-ps: install-ps-am
|
||||
|
||||
install-ps-am:
|
||||
|
||||
installcheck-am:
|
||||
|
||||
maintainer-clean: maintainer-clean-am
|
||||
-rm -rf ./$(DEPDIR)
|
||||
-rm -f Makefile
|
||||
maintainer-clean-am: distclean-am maintainer-clean-generic
|
||||
|
||||
mostlyclean: mostlyclean-am
|
||||
|
||||
mostlyclean-am: mostlyclean-compile mostlyclean-generic
|
||||
|
||||
pdf: pdf-am
|
||||
|
||||
pdf-am:
|
||||
|
||||
ps: ps-am
|
||||
|
||||
ps-am:
|
||||
|
||||
uninstall-am: uninstall-binPROGRAMS
|
||||
|
||||
.MAKE: all install-am install-strip
|
||||
|
||||
.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \
|
||||
clean-generic ctags distclean distclean-compile \
|
||||
distclean-generic distclean-hdr distclean-tags distdir dvi \
|
||||
dvi-am html html-am info info-am install install-am \
|
||||
install-binPROGRAMS install-data install-data-am install-dvi \
|
||||
install-dvi-am install-exec install-exec-am install-html \
|
||||
install-html-am install-info install-info-am install-man \
|
||||
install-pdf install-pdf-am install-ps install-ps-am \
|
||||
install-strip installcheck installcheck-am installdirs \
|
||||
maintainer-clean maintainer-clean-generic mostlyclean \
|
||||
mostlyclean-compile mostlyclean-generic pdf pdf-am ps ps-am \
|
||||
tags uninstall uninstall-am uninstall-binPROGRAMS
|
||||
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
|
@ -0,0 +1,325 @@
|
|||
// Command line processor
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: cmdline.cpp,v 1.11 2011/11/11 19:41:49 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include <vector>
|
||||
#include <cassert>
|
||||
#include <cstdio>
|
||||
#include <iostream>
|
||||
|
||||
#include <boost/filesystem/operations.hpp>
|
||||
#include <boost/filesystem/convenience.hpp>
|
||||
#include <boost/version.hpp>
|
||||
|
||||
#include <tiff.h>
|
||||
|
||||
#include "sfftypes.h"
|
||||
#include "common.h"
|
||||
#include "getopt.h"
|
||||
|
||||
#include "cmdline.h"
|
||||
|
||||
extern "C"
|
||||
{
|
||||
#define XMD_H
|
||||
#include <jpeglib.h>
|
||||
#include <tiffio.h>
|
||||
}
|
||||
|
||||
using namespace std;
|
||||
namespace fs = boost::filesystem;
|
||||
|
||||
//-------------------------------------------------------------
|
||||
|
||||
#define VERSION "3.1.3"
|
||||
#define COPYRIGHT "1998-2009 Peter Schaefer-Hutter and contributors"
|
||||
|
||||
//-------------------------------------------------------------
|
||||
|
||||
CCmdLineProcessor::CCmdLineProcessor(char **argv, int argc)
|
||||
{
|
||||
m_argv = argv;
|
||||
m_argc = argc;
|
||||
m_pszProgName = argv[0];
|
||||
m_nOutputFormat = fmt_unknown;
|
||||
m_nTiffCompression = COMPRESSION_CCITTFAX3;
|
||||
m_nJpegQuality = 40;
|
||||
m_nFileIdx = 0;
|
||||
m_bKeepDate = m_bKeepVRes = m_bOverwrite = m_bQuiet = false;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------
|
||||
|
||||
CCmdLineProcessor::~CCmdLineProcessor()
|
||||
{
|
||||
FILEVECTOR::iterator it;
|
||||
m_vFiles.clear();
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------
|
||||
|
||||
void CCmdLineProcessor::printHelp()
|
||||
{
|
||||
cout << endl << "Usage: " << m_pszProgName << " [options] INFILE1 [INFILE2 ..] [-o OUTSPEC]" << endl << endl;
|
||||
cout << "Options:" << endl;
|
||||
cout << "-h or -help Show this message and exit" << endl;
|
||||
cout << "-v or -version Show version and exit" << endl;
|
||||
cout << "-b or -bmp Output is one monochrome BMP file for each fax page" << endl;
|
||||
cout << "-p or -pbm Output is one Portable Bitmap file for each fax page" << endl;
|
||||
cout << "-j or -jpg Output is one JPEG file for each fax page" << endl;
|
||||
cout << "-jNUM or -jpg=NUM Use jpeg quality of NUM percent (1..99)" << endl;
|
||||
cout << "-T or -tifs Output is one single-page TIFF file for each fax page" << endl;
|
||||
cout << "-t or -tif Output is one multi-paged TIFF file containing all pages" << endl;
|
||||
cout << "-r or -keepres Inhibit line doubling for low-res faxes" << endl;
|
||||
cout << "-d or -keepdate Keep date and time of input file for the output file(s)" << endl;
|
||||
cout << "-q or -quiet No messages except errors" << endl << endl;
|
||||
cout << "The OUTSPEC is interpreted as:" << endl;
|
||||
cout << " - a filename if only one input file is given." << endl;
|
||||
cout << " - a directory name if more than one input file is given." << endl << endl;
|
||||
cout << "If OUTSPEC is ommitted, the name of the output files will be derived from the input" << endl;
|
||||
cout << "files and created in the same directory." << endl << endl;
|
||||
cout << "Output on stdout is available for multipaged TIFF output only (option \"-t\")." << endl;
|
||||
cout << "Use \"-\" as output filename in this case." << endl << endl;
|
||||
cout << "In case of TIFF output, you can specify the compression by using additional" << endl;
|
||||
cout << "specifiers: " << endl;
|
||||
cout << " -tr resp. -Tr : CCITT modified Huffman RLE" << endl;
|
||||
cout << " -t4 resp. -T4 : CCITT Fax Class 4 compression" << endl << endl;
|
||||
cout << "The default is CCITT Fax Class 3 compression." << endl << endl;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------
|
||||
|
||||
void CCmdLineProcessor::printUsage()
|
||||
{
|
||||
cout << "Summary: " << m_pszProgName
|
||||
<< " [-help] [-version] [options] INFILE OUTSPEC"
|
||||
<< endl;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------
|
||||
|
||||
void CCmdLineProcessor::printVersion()
|
||||
{
|
||||
cout << endl << "SffToBmp Version " << VERSION << endl;
|
||||
cout << "Copyright (C) " << COPYRIGHT << endl;
|
||||
cout << "This is free software, and you are welcome to redistribute it under" << endl;
|
||||
cout << "the terms of the enclosed license. See the file COPYING for details." << endl;
|
||||
cout << "If you haven't got this file, please contact peter.schaefer@gmx.de." << endl;
|
||||
cout << "This program comes with ABSOLUTELY NO WARRANTY without even the implied" << endl;
|
||||
cout << "warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." << endl << endl;
|
||||
cout << "Contributors:" << endl;
|
||||
cout << "Ulf Zibis <ulf.zibis@gmx.de>" << endl;
|
||||
cout << "Gernot Hillier <ghillie@suse.de>" << endl << endl;
|
||||
cout << "Library versions:" << endl << endl;
|
||||
cout << TIFFGetVersion() << endl << endl;
|
||||
cout << "Independent JPEG Group's CJPEG, version "
|
||||
<< JPEG_LIB_VERSION / 10 << "." << JPEG_LIB_VERSION % 10 << endl << endl;
|
||||
cout << "Boost libraries, version: "
|
||||
<< BOOST_VERSION / 100000 << "."
|
||||
<< BOOST_VERSION / 100 % 1000 << "."
|
||||
<< BOOST_VERSION % 100 << endl;
|
||||
}
|
||||
|
||||
void CCmdLineProcessor::parseCmdLine()
|
||||
{
|
||||
// short options string (one colon: req arg, two colon: opt arg)
|
||||
const char *shortopts = "vhbpT::t::frdj::o:q";
|
||||
// long options list
|
||||
struct option longopts[] =
|
||||
{
|
||||
// name, has_arg, flag, val longind
|
||||
{ "version", no_argument, 0, 'v' }, // 0
|
||||
{ "help", no_argument, 0, 'h' }, // 1
|
||||
{ "bmp", no_argument, 0, 'b' }, // 2
|
||||
{ "pbm", no_argument, 0, 'p' }, // 3
|
||||
{ "jpg", optional_argument, 0, 'j' }, // 4
|
||||
{ "tifs", optional_argument, 0, 'T' }, // 5
|
||||
{ "tif", optional_argument, 0, 't' }, // 6
|
||||
{ "force-overwrite", no_argument, 0, 'f' }, // 7
|
||||
{ "keepres", no_argument, 0, 'r' }, // 8
|
||||
{ "keepdate", no_argument, 0, 'd' }, // 9
|
||||
{ "out", required_argument, 0, 'o' }, // 10
|
||||
{ "quiet", no_argument, 0, 'q' }, // 11
|
||||
// end-of-list marker
|
||||
{ 0, 0, 0, 0 }
|
||||
};
|
||||
// long option list index
|
||||
int longind = 0;
|
||||
int opt;
|
||||
|
||||
m_strOutSpec = "";
|
||||
|
||||
// parse all options from the command line
|
||||
while ((opt = getopt_long_only(m_argc, m_argv, shortopts, longopts, &longind)) != -1)
|
||||
{
|
||||
switch (opt)
|
||||
{
|
||||
case 'v': // -version
|
||||
printVersion();
|
||||
return;
|
||||
case 'h': // -help
|
||||
printHelp();
|
||||
return;
|
||||
case 'j': // -jpg[=NUM]
|
||||
if (m_nOutputFormat != fmt_unknown) {
|
||||
throw CSimpleException(CSimpleException::err_toomuchformats);
|
||||
}
|
||||
if (optarg) {
|
||||
// we use this while trying to parse a numeric argument
|
||||
char ignored;
|
||||
int val;
|
||||
if (sscanf(optarg, "%d%c", &val, &ignored) != 1) {
|
||||
cerr << m_pszProgName << ": jpeg quality is not a number" << endl;
|
||||
throw CSimpleException(CSimpleException::err_cmdline);
|
||||
}
|
||||
if ((val <= 0) || (val >= 100)) {
|
||||
cerr << m_pszProgName << ": jpeg quality out of range (1..99)" << endl;
|
||||
throw CSimpleException(CSimpleException::err_cmdline);
|
||||
}
|
||||
m_nJpegQuality = val;
|
||||
}
|
||||
m_nOutputFormat = fmt_jpeg;
|
||||
break;
|
||||
case 'b':
|
||||
if (m_nOutputFormat != fmt_unknown) {
|
||||
throw CSimpleException(CSimpleException::err_toomuchformats);
|
||||
}
|
||||
m_nOutputFormat = fmt_bmp;
|
||||
break;
|
||||
case 'p':
|
||||
if (m_nOutputFormat != fmt_unknown) {
|
||||
throw CSimpleException(CSimpleException::err_toomuchformats);
|
||||
}
|
||||
m_nOutputFormat = fmt_pbm;
|
||||
break;
|
||||
case 't': // -tif[=r|4]
|
||||
case 'T': // -tifs[=r|4]
|
||||
if (m_nOutputFormat != fmt_unknown) {
|
||||
throw CSimpleException(CSimpleException::err_toomuchformats);
|
||||
}
|
||||
m_nOutputFormat = (opt == 't') ? fmt_tiff : fmt_tiff_single_pages;
|
||||
if (optarg) {
|
||||
// we use this while trying to parse the compression
|
||||
switch (optarg[0]) {
|
||||
case 'r': // CCITT modified Huffman RLE
|
||||
m_nTiffCompression = COMPRESSION_CCITTRLE;
|
||||
break;
|
||||
case '4': // CCITT Fax 4
|
||||
m_nTiffCompression = COMPRESSION_CCITTFAX4;
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'f':
|
||||
m_bOverwrite = true;
|
||||
break;
|
||||
case 'r':
|
||||
m_bKeepVRes = true;
|
||||
break;
|
||||
case 'd':
|
||||
m_bKeepDate = true;
|
||||
break;
|
||||
case 'o':
|
||||
m_strOutSpec = optarg;
|
||||
break;
|
||||
case 'q':
|
||||
m_bQuiet = true;
|
||||
break;
|
||||
case '?': // getopt_long_only noticed an error
|
||||
printUsage();
|
||||
throw CSimpleException(CSimpleException::err_cmdline);
|
||||
default: // something unexpected has happened
|
||||
printUsage();
|
||||
throw CSimpleException(CSimpleException::err_cmdline);
|
||||
}
|
||||
}
|
||||
if (m_nOutputFormat == fmt_unknown) {
|
||||
throw CSimpleException(CSimpleException::err_noformat);
|
||||
}
|
||||
if ((m_strOutSpec == "-") && (m_nOutputFormat != fmt_tiff)) {
|
||||
throw CSimpleException(CSimpleException::err_stdoutnotallowed);
|
||||
}
|
||||
|
||||
#ifdef WIN32
|
||||
WIN32_FIND_DATA fd;
|
||||
fs::path fp = fs::path(m_argv[optind], fs::native);
|
||||
fp.remove_filename();
|
||||
HANDLE hFind = ::FindFirstFile(m_argv[optind], &fd);
|
||||
if (hFind == INVALID_HANDLE_VALUE) {
|
||||
throw CSimpleException( CSimpleException::err_openfile);
|
||||
}
|
||||
do {
|
||||
if (!(fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
|
||||
fs::path fp1 = fp;
|
||||
fp1 /= fs::path(fd.cFileName, fs::native);
|
||||
m_vFiles.push_back( fp1 );
|
||||
}
|
||||
} while (::FindNextFile(hFind, &fd));
|
||||
::FindClose(hFind);
|
||||
#else
|
||||
int n = optind;
|
||||
while (n < m_argc) {
|
||||
#if !defined(BOOST_FILESYSTEM_VERSION) || BOOST_FILESYSTEM_VERSION == 2
|
||||
m_vFiles.push_back( fs::path(m_argv[n], fs::native) );
|
||||
#else
|
||||
m_vFiles.push_back( fs::path(m_argv[n]) );
|
||||
#endif
|
||||
++n;
|
||||
}
|
||||
#endif
|
||||
|
||||
if ((m_strOutSpec == "-") && (getFileCount() > 1)) {
|
||||
throw CSimpleException(CSimpleException::err_stdoutonlyonefile);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
bool CCmdLineProcessor::getNextFile(fs::path& strFile)
|
||||
{
|
||||
bool rc = false;
|
||||
fs::path fname;
|
||||
if (m_nFileIdx < getFileCount()) {
|
||||
strFile = m_vFiles[m_nFileIdx];
|
||||
++m_nFileIdx;
|
||||
rc = true;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
const std::string& CCmdLineProcessor::getOutSpec()
|
||||
{
|
||||
return m_strOutSpec;
|
||||
}
|
|
@ -0,0 +1,98 @@
|
|||
#ifndef __CMDLINE_H__
|
||||
#define __CMDLINE_H__
|
||||
//
|
||||
// Headerfile for command line processor
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: cmdline.h,v 1.4 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include <boost/filesystem/path.hpp>
|
||||
|
||||
typedef std::vector<boost::filesystem::path> FILEVECTOR;
|
||||
|
||||
class CCmdLineProcessor
|
||||
{
|
||||
protected:
|
||||
const char *m_pszProgName;
|
||||
int m_nOutputFormat;
|
||||
int m_nTiffCompression;
|
||||
int m_nJpegQuality;
|
||||
bool m_bKeepDate;
|
||||
bool m_bKeepVRes;
|
||||
bool m_bOverwrite;
|
||||
bool m_bQuiet;
|
||||
std::string m_strOutSpec;
|
||||
|
||||
char **m_argv;
|
||||
int m_argc;
|
||||
|
||||
int m_nFileIdx;
|
||||
FILEVECTOR m_vFiles;
|
||||
|
||||
public:
|
||||
enum {
|
||||
fmt_jpeg,
|
||||
fmt_pbm,
|
||||
fmt_bmp,
|
||||
fmt_tiff,
|
||||
fmt_tiff_single_pages,
|
||||
// -- add here
|
||||
fmt_unknown
|
||||
};
|
||||
|
||||
CCmdLineProcessor(char **argv, int argc);
|
||||
~CCmdLineProcessor();
|
||||
|
||||
void printHelp();
|
||||
void printUsage();
|
||||
void printVersion();
|
||||
|
||||
void parseCmdLine(); // throw
|
||||
|
||||
int getFileCount() { return m_vFiles.size(); };
|
||||
bool getNextFile(boost::filesystem::path& strFile);
|
||||
const std::string& getOutSpec();
|
||||
|
||||
bool keepDate() { return m_bKeepDate; };
|
||||
bool keepVRes() { return m_bKeepVRes; };
|
||||
bool doOverwrite() { return m_bOverwrite; };
|
||||
bool beQuiet() { return m_bQuiet; };
|
||||
int getJpegQuality() { return m_nJpegQuality; };
|
||||
int getTiffCompression() { return m_nTiffCompression; };
|
||||
int getOutputFormat() { return m_nOutputFormat; };
|
||||
|
||||
};
|
||||
|
||||
#endif // __CMDLINE_H__
|
|
@ -0,0 +1,274 @@
|
|||
// MH markup codes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: codes.cpp,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include "sfftypes.h"
|
||||
#include "codes.h"
|
||||
|
||||
#define EXT_CODES
|
||||
|
||||
TABENTRY aMarkUpWhite[] = {
|
||||
{ 0x0080,RL_EOL, 8 },
|
||||
{ 0x0800,RL_EOL,12 },
|
||||
{ 0x001b, 64, 5 },
|
||||
{ 0x0009, 128, 5 },
|
||||
{ 0x003a, 192, 6 },
|
||||
{ 0x0076, 256, 7 },
|
||||
{ 0x006c, 320, 8 },
|
||||
{ 0x00ec, 384, 8 },
|
||||
{ 0x0026, 448, 8 },
|
||||
{ 0x00a6, 512, 8 },
|
||||
{ 0x0016, 576, 8 },
|
||||
{ 0x00e6, 640, 8 },
|
||||
{ 0x0066, 704, 9 },
|
||||
{ 0x0166, 768, 9 },
|
||||
{ 0x0096, 832, 9 },
|
||||
{ 0x0196, 896, 9 },
|
||||
{ 0x0056, 960, 9 },
|
||||
{ 0x0156, 1024, 9 },
|
||||
{ 0x00d6, 1088, 9 },
|
||||
{ 0x01d6, 1152, 9 },
|
||||
{ 0x0036, 1216, 9 },
|
||||
{ 0x0136, 1280, 9 },
|
||||
{ 0x00b6, 1344, 9 },
|
||||
{ 0x01b6, 1408, 9 },
|
||||
{ 0x0032, 1472, 9 },
|
||||
{ 0x0132, 1536, 9 },
|
||||
{ 0x00b2, 1600, 9 },
|
||||
{ 0x0006, 1664, 6 },
|
||||
{ 0x01b2, 1728, 9 },
|
||||
#ifdef EXT_CODES
|
||||
{ 0x0080, 1792, 11 },
|
||||
{ 0x0180, 1856, 11 },
|
||||
{ 0x0580, 1920, 11 },
|
||||
{ 0x0480, 1984, 12 },
|
||||
{ 0x0c80, 2048, 12 },
|
||||
{ 0x0280, 2112, 12 },
|
||||
{ 0x0a80, 2176, 12 },
|
||||
{ 0x0680, 2240, 12 },
|
||||
{ 0x0e80, 2304, 12 },
|
||||
{ 0x0380, 2368, 12 },
|
||||
{ 0x0b80, 2432, 12 },
|
||||
{ 0x0780, 2496, 12 },
|
||||
{ 0x0f80, 2560, 12 },
|
||||
#endif
|
||||
{ 0, 0, 0 }
|
||||
};
|
||||
TABENTRY aTermWhite[] = {
|
||||
{ 0x0080,RL_EOL, 8 },
|
||||
{ 0x0800,RL_EOL,12 },
|
||||
{ 0x00ac, 0, 8 },
|
||||
{ 0x0038, 1, 6 },
|
||||
{ 0x000e, 2, 4 },
|
||||
{ 0x0001, 3, 4 },
|
||||
{ 0x000d, 4, 4 },
|
||||
{ 0x0003, 5, 4 },
|
||||
{ 0x0007, 6, 4 },
|
||||
{ 0x000f, 7, 4 },
|
||||
{ 0x0019, 8, 5 },
|
||||
{ 0x0005, 9, 5 },
|
||||
{ 0x001c, 10, 5 },
|
||||
{ 0x0002, 11, 5 },
|
||||
{ 0x0004, 12, 6 },
|
||||
{ 0x0030, 13, 6 },
|
||||
{ 0x000b, 14, 6 },
|
||||
{ 0x002b, 15, 6 },
|
||||
{ 0x0015, 16, 6 },
|
||||
{ 0x0035, 17, 6 },
|
||||
{ 0x0072, 18, 7 },
|
||||
{ 0x0018, 19, 7 },
|
||||
{ 0x0008, 20, 7 },
|
||||
{ 0x0074, 21, 7 },
|
||||
{ 0x0060, 22, 7 },
|
||||
{ 0x0010, 23, 7 },
|
||||
{ 0x000a, 24, 7 },
|
||||
{ 0x006a, 25, 7 },
|
||||
{ 0x0064, 26, 7 },
|
||||
{ 0x0012, 27, 7 },
|
||||
{ 0x000c, 28, 7 },
|
||||
{ 0x0040, 29, 8 },
|
||||
{ 0x00c0, 30, 8 },
|
||||
{ 0x0058, 31, 8 },
|
||||
{ 0x00d8, 32, 8 },
|
||||
{ 0x0048, 33, 8 },
|
||||
{ 0x00c8, 34, 8 },
|
||||
{ 0x0028, 35, 8 },
|
||||
{ 0x00a8, 36, 8 },
|
||||
{ 0x0068, 37, 8 },
|
||||
{ 0x00e8, 38, 8 },
|
||||
{ 0x0014, 39, 8 },
|
||||
{ 0x0094, 40, 8 },
|
||||
{ 0x0054, 41, 8 },
|
||||
{ 0x00d4, 42, 8 },
|
||||
{ 0x0034, 43, 8 },
|
||||
{ 0x00b4, 44, 8 },
|
||||
{ 0x0020, 45, 8 },
|
||||
{ 0x00a0, 46, 8 },
|
||||
{ 0x0050, 47, 8 },
|
||||
{ 0x00d0, 48, 8 },
|
||||
{ 0x004a, 49, 8 },
|
||||
{ 0x00ca, 50, 8 },
|
||||
{ 0x002a, 51, 8 },
|
||||
{ 0x00aa, 52, 8 },
|
||||
{ 0x0024, 53, 8 },
|
||||
{ 0x00a4, 54, 8 },
|
||||
{ 0x001a, 55, 8 },
|
||||
{ 0x009a, 56, 8 },
|
||||
{ 0x005a, 57, 8 },
|
||||
{ 0x00da, 58, 8 },
|
||||
{ 0x0052, 59, 8 },
|
||||
{ 0x00d2, 60, 8 },
|
||||
{ 0x004c, 61, 8 },
|
||||
{ 0x00cc, 62, 8 },
|
||||
{ 0x002c, 63, 8 },
|
||||
{ 0, 0, 0 }
|
||||
};
|
||||
TABENTRY aMarkUpBlack[] = {
|
||||
{ 0x0080,RL_EOL, 8 },
|
||||
{ 0x0800,RL_EOL,12 },
|
||||
{ 0x03c0, 64, 10 },
|
||||
{ 0x0130, 128, 12 },
|
||||
{ 0x0930, 192, 12 },
|
||||
{ 0x0da0, 256, 12 },
|
||||
{ 0x0cc0, 320, 12 },
|
||||
{ 0x02c0, 384, 12 },
|
||||
{ 0x0ac0, 448, 12 },
|
||||
{ 0x06c0, 512, 13 },
|
||||
{ 0x16c0, 576, 13 },
|
||||
{ 0x0a40, 640, 13 },
|
||||
{ 0x1a40, 704, 13 },
|
||||
{ 0x0640, 768, 13 },
|
||||
{ 0x1640, 832, 13 },
|
||||
{ 0x09c0, 896, 13 },
|
||||
{ 0x19c0, 960, 13 },
|
||||
{ 0x05c0, 1024, 13 },
|
||||
{ 0x15c0, 1088, 13 },
|
||||
{ 0x0dc0, 1152, 13 },
|
||||
{ 0x1dc0, 1216, 13 },
|
||||
{ 0x0940, 1280, 13 },
|
||||
{ 0x1940, 1344, 13 },
|
||||
{ 0x0540, 1408, 13 },
|
||||
{ 0x1540, 1472, 13 },
|
||||
{ 0x0b40, 1536, 13 },
|
||||
{ 0x1b40, 1600, 13 },
|
||||
{ 0x04c0, 1664, 13 },
|
||||
{ 0x14c0, 1728, 13 },
|
||||
#ifdef EXT_CODES
|
||||
{ 0x0080, 1792, 11 },
|
||||
{ 0x0180, 1856, 11 },
|
||||
{ 0x0580, 1920, 11 },
|
||||
{ 0x0480, 1984, 12 },
|
||||
{ 0x0c80, 2048, 12 },
|
||||
{ 0x0280, 2112, 12 },
|
||||
{ 0x0a80, 2176, 12 },
|
||||
{ 0x0680, 2240, 12 },
|
||||
{ 0x0e80, 2304, 12 },
|
||||
{ 0x0380, 2368, 12 },
|
||||
{ 0x0b80, 2432, 12 },
|
||||
{ 0x0780, 2496, 12 },
|
||||
{ 0x0f80, 2560, 12 },
|
||||
#endif
|
||||
{ 0, 0, 0 }
|
||||
};
|
||||
TABENTRY aTermBlack[] = {
|
||||
{ 0x0080,RL_EOL, 8 },
|
||||
{ 0x0800,RL_EOL,12 },
|
||||
{ 0x03b0, 0, 10 },
|
||||
{ 0x0002, 1, 3 },
|
||||
{ 0x0003, 2, 2 },
|
||||
{ 0x0001, 3, 2 },
|
||||
{ 0x0006, 4, 3 },
|
||||
{ 0x000c, 5, 4 },
|
||||
{ 0x0004, 6, 4 },
|
||||
{ 0x0018, 7, 5 },
|
||||
{ 0x0028, 8, 6 },
|
||||
{ 0x0008, 9, 6 },
|
||||
{ 0x0010, 10, 7 },
|
||||
{ 0x0050, 11, 7 },
|
||||
{ 0x0070, 12, 7 },
|
||||
{ 0x0020, 13, 8 },
|
||||
{ 0x00e0, 14, 8 },
|
||||
{ 0x0030, 15, 9 },
|
||||
{ 0x03a0, 16, 10 },
|
||||
{ 0x0060, 17, 10 },
|
||||
{ 0x0040, 18, 10 },
|
||||
{ 0x0730, 19, 11 },
|
||||
{ 0x00b0, 20, 11 },
|
||||
{ 0x01b0, 21, 11 },
|
||||
{ 0x0760, 22, 11 },
|
||||
{ 0x00a0, 23, 11 },
|
||||
{ 0x0740, 24, 11 },
|
||||
{ 0x00c0, 25, 11 },
|
||||
{ 0x0530, 26, 12 },
|
||||
{ 0x0d30, 27, 12 },
|
||||
{ 0x0330, 28, 12 },
|
||||
{ 0x0b30, 29, 12 },
|
||||
{ 0x0160, 30, 12 },
|
||||
{ 0x0960, 31, 12 },
|
||||
{ 0x0560, 32, 12 },
|
||||
{ 0x0d60, 33, 12 },
|
||||
{ 0x04b0, 34, 12 },
|
||||
{ 0x0cb0, 35, 12 },
|
||||
{ 0x02b0, 36, 12 },
|
||||
{ 0x0ab0, 37, 12 },
|
||||
{ 0x06b0, 38, 12 },
|
||||
{ 0x0eb0, 39, 12 },
|
||||
{ 0x0360, 40, 12 },
|
||||
{ 0x0b60, 41, 12 },
|
||||
{ 0x05b0, 42, 12 },
|
||||
{ 0x0db0, 43, 12 },
|
||||
{ 0x02a0, 44, 12 },
|
||||
{ 0x0aa0, 45, 12 },
|
||||
{ 0x06a0, 46, 12 },
|
||||
{ 0x0ea0, 47, 12 },
|
||||
{ 0x0260, 48, 12 },
|
||||
{ 0x0a60, 49, 12 },
|
||||
{ 0x04a0, 50, 12 },
|
||||
{ 0x0ca0, 51, 12 },
|
||||
{ 0x0240, 52, 12 },
|
||||
{ 0x0ec0, 53, 12 },
|
||||
{ 0x01c0, 54, 12 },
|
||||
{ 0x0e40, 55, 12 },
|
||||
{ 0x0140, 56, 12 },
|
||||
{ 0x01a0, 57, 12 },
|
||||
{ 0x09a0, 58, 12 },
|
||||
{ 0x0d40, 59, 12 },
|
||||
{ 0x0340, 60, 12 },
|
||||
{ 0x05a0, 61, 12 },
|
||||
{ 0x0660, 62, 12 },
|
||||
{ 0x0e60, 63, 12 },
|
||||
{ 0, 0, 0 }
|
||||
};
|
|
@ -0,0 +1,54 @@
|
|||
#ifndef __CODES_H__
|
||||
#define __CODES_H__
|
||||
//
|
||||
// Headerfile for mh markup codes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: codes.h,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
typedef struct {
|
||||
sff_word code; /* code, right justified, lsb-first, zero filled */
|
||||
int run; /* runlength */
|
||||
sff_byte bits; /* codewidth in bits */
|
||||
} TABENTRY, *LPTABENTRY;
|
||||
|
||||
#define RL_EOL -2
|
||||
|
||||
extern TABENTRY aMarkUpWhite[];
|
||||
extern TABENTRY aTermWhite[];
|
||||
extern TABENTRY aMarkUpBlack[];
|
||||
extern TABENTRY aTermBlack[];
|
||||
|
||||
#endif // __CODES_H__
|
|
@ -0,0 +1,283 @@
|
|||
// Utility classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// Ulf Zibis <ulf.zibis@gmx.de> (Prepared for inheritance,
|
||||
// destructor handling, preserving filetime)
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: common.cpp,v 1.5 2009/04/28 19:02:08 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include "sfftypes.h"
|
||||
#include "common.h"
|
||||
|
||||
#include <time.h>
|
||||
#include <errno.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#ifndef WIN32
|
||||
#include <utime.h>
|
||||
#else
|
||||
#include <sys/utime.h>
|
||||
#endif
|
||||
|
||||
#include <cassert>
|
||||
#include <cstdio>
|
||||
#include <iostream>
|
||||
|
||||
#ifdef WIN32
|
||||
#include <io.h> // _mktemp
|
||||
#endif
|
||||
|
||||
using namespace std;
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
const std::string CSimpleException::m_aReasons[err_count+1] =
|
||||
{
|
||||
// err_invalidfile
|
||||
"Not a valid sff file.",
|
||||
// err_corruptfile,
|
||||
"File seems corrupt. Reading abandoned.",
|
||||
// err_lastpageread,
|
||||
"Last page read.",
|
||||
// err_notsupported,
|
||||
"Operation not supported.",
|
||||
// err_openfile,
|
||||
"Can't open file.",
|
||||
// err_closedfile,
|
||||
"Operation on closed file.",
|
||||
// err_findPath,
|
||||
"Path not found.",
|
||||
// err_nowhitestart,
|
||||
"Line doesn't begin with white code.",
|
||||
// err_noblackcode,
|
||||
"White code not followed by black code.",
|
||||
// err_noblackterm,
|
||||
"Black MUC not followed by black TERM.",
|
||||
// err_nowhiteterm,
|
||||
"White MUC not followed by white TERM.",
|
||||
// err_invalidversion,
|
||||
"OOps. Don't know how to handle this Fileversion.",
|
||||
// err_unknowncoding,
|
||||
"Oh my dear. Don't know how to handle this encoding.",
|
||||
// err_toomuchformats,
|
||||
"Please specify only one output format.",
|
||||
// err_cmdline,
|
||||
"Error in commandline.",
|
||||
// err_noformat,
|
||||
"No output format specified.",
|
||||
// err_outfileexists,
|
||||
"Output file already exists, use -f to force overwrite.",
|
||||
// err_outfileisdir,
|
||||
"Given output file is directory.",
|
||||
// err_outdir,
|
||||
"Cannot create output directory.",
|
||||
// err_stdoutnotallowed
|
||||
"Output on stdout is not available with this output format.",
|
||||
// err_stdoutonlyonefile
|
||||
"Output on stdout is not available with more than one input file.",
|
||||
//
|
||||
// ------------------- INSERT HERE
|
||||
//
|
||||
// err_count
|
||||
"Unknown error."
|
||||
};
|
||||
|
||||
const string& CSimpleException::what()
|
||||
{
|
||||
if (m_nError < err_count) {
|
||||
return m_aReasons[m_nError];
|
||||
}
|
||||
return m_aReasons[err_count];
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
CFile::CFile(const std::string& strPath) :
|
||||
m_hFile(NULL)
|
||||
{
|
||||
Open( strPath, "rb");
|
||||
}
|
||||
|
||||
CFile::~CFile()
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
void CFile::Open(const std::string& strPath, const char *pszMode)
|
||||
{
|
||||
m_strPath = strPath;
|
||||
if (( m_hFile ) || !( m_hFile = fopen(strPath.c_str(), pszMode))) {
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
m_nFileNo = fileno( m_hFile);
|
||||
}
|
||||
|
||||
void CFile::OpenTemp()
|
||||
{
|
||||
char tmp_name[] = "sfftobmp-tmpXXXXXX";
|
||||
#ifndef WIN32
|
||||
if (( m_nFileNo ) || !(( m_nFileNo = mkstemp(tmp_name)) > 0)) {
|
||||
m_nFileNo = 0;
|
||||
cerr << "temp file couldn't be created: error " << errno << endl;
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
unlink(tmp_name);
|
||||
#else
|
||||
_mktemp(tmp_name);
|
||||
if (( m_nFileNo ) ||
|
||||
(( m_nFileNo = (int)::CreateFile(tmp_name,
|
||||
GENERIC_READ|GENERIC_WRITE, 0, NULL,
|
||||
CREATE_NEW,FILE_ATTRIBUTE_TEMPORARY|
|
||||
FILE_FLAG_DELETE_ON_CLOSE, NULL)) == 0))
|
||||
{
|
||||
cerr << "temp file couldn't be created: error " << errno << endl;
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
#endif
|
||||
m_strPath = tmp_name;
|
||||
}
|
||||
|
||||
void CFile::Close()
|
||||
{
|
||||
if (m_hFile) {
|
||||
fclose(m_hFile);
|
||||
} else if (m_nFileNo) {
|
||||
#ifndef WIN32
|
||||
close(m_nFileNo);
|
||||
#else
|
||||
::CloseHandle((HANDLE)m_nFileNo);
|
||||
#endif
|
||||
}
|
||||
m_nFileNo = 0;
|
||||
m_hFile = NULL;
|
||||
}
|
||||
|
||||
time_t CFile::GetModificationTime()
|
||||
{
|
||||
struct stat buf;
|
||||
if (::fstat( m_nFileNo, &buf ) == 0)
|
||||
return buf.st_mtime ;
|
||||
else
|
||||
throw CSimpleException(CSimpleException::err_notsupported);
|
||||
}
|
||||
|
||||
void CFile::SetModificationTime(const time_t &modtime)
|
||||
{
|
||||
time_t ltime;
|
||||
time( <ime);
|
||||
utimbuf filetime;
|
||||
filetime.actime = ltime;
|
||||
filetime.modtime = modtime;
|
||||
if (::utime( m_strPath.string().c_str(), &filetime) != 0) {
|
||||
cerr << "CFile::SetModificationTime(): ErrorNr.: " << errno << endl;
|
||||
}
|
||||
}
|
||||
|
||||
sff_byte CFile::GetC()
|
||||
{
|
||||
return ::fgetc(m_hFile);
|
||||
}
|
||||
|
||||
void CFile::Read(void *pTarget, int nLen)
|
||||
{
|
||||
size_t rc = ::fread(pTarget, 1, nLen, m_hFile);
|
||||
}
|
||||
|
||||
void CFile::Write(void *pSource, int nLen)
|
||||
{
|
||||
::fwrite(pSource, nLen, 1, m_hFile);
|
||||
}
|
||||
|
||||
sff_dword CFile::Tell()
|
||||
{
|
||||
return ::ftell(m_hFile);
|
||||
}
|
||||
|
||||
void CFile::Seek(int pos, CFile::seek_offset dir)
|
||||
{
|
||||
int whence;
|
||||
if (dir == sk_from_start) {
|
||||
whence = SEEK_SET;
|
||||
} else if (dir == sk_current) {
|
||||
whence = SEEK_CUR;
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
::fseek(m_hFile, pos, whence);
|
||||
}
|
||||
|
||||
bool CFile::Eof()
|
||||
{
|
||||
return (feof(m_hFile) != 0);
|
||||
}
|
||||
|
||||
void CFile::DumpToStdOut()
|
||||
{
|
||||
char buf[1024];
|
||||
sff_dword count;
|
||||
|
||||
#ifndef WIN32
|
||||
int result=lseek(m_nFileNo,0,SEEK_SET);
|
||||
if (result!=0) {
|
||||
cerr << "seeking to temp file start failed " << endl;
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
while ( (count = read(m_nFileNo, buf, 1024)) > 0) {
|
||||
result=write(STDOUT_FILENO, buf, count);
|
||||
if (result<0) {
|
||||
cerr << "writing to stdout failed with error " << errno << endl;
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
}
|
||||
if (count<0) {
|
||||
cerr << "reading from temp file failed with error " << errno << endl;
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
#else
|
||||
SetFilePointer((HANDLE)m_nFileNo,0,0,FILE_BEGIN);
|
||||
HANDLE hStdOut = ::GetStdHandle(STD_OUTPUT_HANDLE);
|
||||
sff_dword written;
|
||||
for (;;) {
|
||||
::ReadFile((HANDLE)m_nFileNo, buf, 1024, (DWORD*)&count, NULL);
|
||||
if (count <= 0) break;
|
||||
if (!::WriteFile(hStdOut, buf, count, (DWORD *)&written, NULL)) {
|
||||
cerr << "writing to stdout failed with error " << errno << endl;
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
}
|
||||
if (count<0) {
|
||||
cerr << "reading from temp file failed with error " << errno << endl;
|
||||
throw CSimpleException(CSimpleException::err_openfile);
|
||||
}
|
||||
#endif
|
||||
}
|
|
@ -0,0 +1,128 @@
|
|||
#ifndef __COMMON_H__
|
||||
#define __COMMON_H__
|
||||
//
|
||||
// Headerfile for support classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// Ulf Zibis <ulf.zibis@gmx.de> (Prepared for inheritance,
|
||||
// destructor handling, preserving filetime, CWildcardTranslator)
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: common.h,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include <boost/filesystem/path.hpp>
|
||||
|
||||
class CSimpleException
|
||||
{
|
||||
public:
|
||||
enum {
|
||||
err_invalidfile = 0,
|
||||
err_corruptfile,
|
||||
err_lastpageread,
|
||||
err_notsupported,
|
||||
err_openfile,
|
||||
err_closedfile,
|
||||
err_findPath,
|
||||
err_nowhitestart,
|
||||
err_noblackcode,
|
||||
err_noblackterm,
|
||||
err_nowhiteterm,
|
||||
err_invalidversion,
|
||||
err_unknowncoding,
|
||||
err_toomuchformats,
|
||||
err_cmdline,
|
||||
err_noformat,
|
||||
err_outfileexists,
|
||||
err_outfileisdir,
|
||||
err_outdir,
|
||||
err_stdoutnotallowed,
|
||||
err_stdoutonlyonefile,
|
||||
// insert here
|
||||
err_count
|
||||
};
|
||||
|
||||
unsigned m_nError;
|
||||
|
||||
CSimpleException(const int nError) :
|
||||
m_nError(nError) { };
|
||||
|
||||
const std::string& what();
|
||||
|
||||
protected:
|
||||
static const std::string m_aReasons[err_count+1];
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CFile
|
||||
{
|
||||
protected:
|
||||
FILE *m_hFile;
|
||||
int m_nFileNo;
|
||||
boost::filesystem::path m_strPath;
|
||||
|
||||
public:
|
||||
enum seek_offset {
|
||||
sk_from_start,
|
||||
sk_current
|
||||
};
|
||||
|
||||
CFile() : m_hFile(NULL), m_nFileNo(0) { /* sonst nix */ };
|
||||
CFile(const std::string& strPath);
|
||||
// throw CSimpleException
|
||||
|
||||
virtual ~CFile();
|
||||
|
||||
FILE *GetFP() { return m_hFile; };
|
||||
int GetFN() { return m_nFileNo; };
|
||||
const char *GetFileName() { return m_strPath.string().c_str(); };
|
||||
sff_byte GetC();
|
||||
sff_dword Tell();
|
||||
bool Eof();
|
||||
void Seek(int pos, CFile::seek_offset dir);
|
||||
void Read(void *pTarget, int nLen);
|
||||
void Write(void *pSource, int nLen);
|
||||
|
||||
void DumpToStdOut(); // throw CSimpleException
|
||||
|
||||
virtual void Open(const std::string& strPath, const char *pszMode);
|
||||
// throw CSimpleException
|
||||
virtual void OpenTemp();
|
||||
// throw CSimpleException
|
||||
virtual void Close();
|
||||
// throw CSimpleException
|
||||
|
||||
time_t GetModificationTime();
|
||||
virtual void SetModificationTime(const time_t &modtime);
|
||||
};
|
||||
|
||||
#endif // __COMMON_H__
|
|
@ -0,0 +1,95 @@
|
|||
/* src/config.h.in. Generated from configure.ac by autoheader. */
|
||||
|
||||
/* Define to 1 if you have the <inttypes.h> header file. */
|
||||
#undef HAVE_INTTYPES_H
|
||||
|
||||
/* LibJPEG */
|
||||
#undef HAVE_LIBJPEG
|
||||
|
||||
/* LibTIFF */
|
||||
#undef HAVE_LIBTIFF
|
||||
|
||||
/* Define to 1 if your system has a GNU libc compatible `malloc' function, and
|
||||
to 0 otherwise. */
|
||||
#undef HAVE_MALLOC
|
||||
|
||||
/* Define to 1 if you have the <memory.h> header file. */
|
||||
#undef HAVE_MEMORY_H
|
||||
|
||||
/* Define to 1 if you have the `memset' function. */
|
||||
#undef HAVE_MEMSET
|
||||
|
||||
/* Define to 1 if stdbool.h conforms to C99. */
|
||||
#undef HAVE_STDBOOL_H
|
||||
|
||||
/* Define to 1 if you have the <stdint.h> header file. */
|
||||
#undef HAVE_STDINT_H
|
||||
|
||||
/* Define to 1 if you have the <stdlib.h> header file. */
|
||||
#undef HAVE_STDLIB_H
|
||||
|
||||
/* Define to 1 if you have the `strdup' function. */
|
||||
#undef HAVE_STRDUP
|
||||
|
||||
/* Define to 1 if you have the <strings.h> header file. */
|
||||
#undef HAVE_STRINGS_H
|
||||
|
||||
/* Define to 1 if you have the <string.h> header file. */
|
||||
#undef HAVE_STRING_H
|
||||
|
||||
/* Define to 1 if you have the `strrchr' function. */
|
||||
#undef HAVE_STRRCHR
|
||||
|
||||
/* Define to 1 if you have the <sys/stat.h> header file. */
|
||||
#undef HAVE_SYS_STAT_H
|
||||
|
||||
/* Define to 1 if you have the <sys/types.h> header file. */
|
||||
#undef HAVE_SYS_TYPES_H
|
||||
|
||||
/* Define to 1 if you have the <unistd.h> header file. */
|
||||
#undef HAVE_UNISTD_H
|
||||
|
||||
/* Define to 1 if you have the `utime' function. */
|
||||
#undef HAVE_UTIME
|
||||
|
||||
/* Define to 1 if you have the <utime.h> header file. */
|
||||
#undef HAVE_UTIME_H
|
||||
|
||||
/* Define to 1 if `utime(file, NULL)' sets file's timestamp to the present. */
|
||||
#undef HAVE_UTIME_NULL
|
||||
|
||||
/* Define to 1 if the system has the type `_Bool'. */
|
||||
#undef HAVE__BOOL
|
||||
|
||||
/* Define to the address where bug reports for this package should be sent. */
|
||||
#undef PACKAGE_BUGREPORT
|
||||
|
||||
/* Define to the full name of this package. */
|
||||
#undef PACKAGE_NAME
|
||||
|
||||
/* Define to the full name and version of this package. */
|
||||
#undef PACKAGE_STRING
|
||||
|
||||
/* Define to the one symbol short name of this package. */
|
||||
#undef PACKAGE_TARNAME
|
||||
|
||||
/* Define to the home page for this package. */
|
||||
#undef PACKAGE_URL
|
||||
|
||||
/* Define to the version of this package. */
|
||||
#undef PACKAGE_VERSION
|
||||
|
||||
/* Define to 1 if you have the ANSI C header files. */
|
||||
#undef STDC_HEADERS
|
||||
|
||||
/* Define to empty if `const' does not conform to ANSI C. */
|
||||
#undef const
|
||||
|
||||
/* Define to rpl_malloc if the replacement function should be used. */
|
||||
#undef malloc
|
||||
|
||||
/* Define to `long int' if <sys/types.h> does not define. */
|
||||
#undef off_t
|
||||
|
||||
/* Define to `unsigned int' if <sys/types.h> does not define. */
|
||||
#undef size_t
|
|
@ -0,0 +1,278 @@
|
|||
// Decoder classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: decoder.cpp,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include "sfftypes.h"
|
||||
#include "common.h"
|
||||
|
||||
#include "codes.h"
|
||||
#include "decoder.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
//-Types-----------------------------------------------------------
|
||||
|
||||
typedef enum {
|
||||
NEED_WHITE,
|
||||
NEED_BLACK,
|
||||
NEED_WHITETERM,
|
||||
NEED_BLACKTERM
|
||||
} TDecoderState;
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
void CBitSource::NeedBits(int nCount)
|
||||
{
|
||||
while ((m_dwByteCount > 0) && (m_wBitsAvail < nCount)) {
|
||||
m_dwAccu |= ((*m_pBuffer) << m_wBitsAvail);
|
||||
m_wBitsAvail += 8;
|
||||
--m_dwByteCount;
|
||||
++m_pBuffer;
|
||||
}
|
||||
}
|
||||
|
||||
void CBitSource::ClrBits(int nCount)
|
||||
{
|
||||
m_wBitsAvail -= nCount;
|
||||
m_dwAccu = (m_dwAccu >> nCount);
|
||||
}
|
||||
|
||||
sff_word CBitSource::GetBits(int nCount)
|
||||
{
|
||||
return (sff_word)(m_dwAccu & ((1<<(nCount))-1)); // mask lower x bits out
|
||||
}
|
||||
|
||||
bool CBitSource::NoMoreBits()
|
||||
{
|
||||
return ((m_dwByteCount <= 0) && (m_dwAccu == 0));
|
||||
}
|
||||
|
||||
CBitSource::CBitSource(void *pBuffer, sff_dword nByteCount) :
|
||||
m_pBuffer((sff_byte *)pBuffer),
|
||||
m_wBitsAvail(0),
|
||||
m_dwAccu(0),
|
||||
m_dwByteCount(nByteCount)
|
||||
{
|
||||
/* sonst nix */
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
void CBitSink::SetBits(int nCount)
|
||||
{
|
||||
sff_byte *p;
|
||||
|
||||
p = m_pBuffer + (m_dwBitPos >> 3);
|
||||
sff_byte mask = 0x80 >> (m_dwBitPos % 8);
|
||||
m_dwBitPos += nCount;
|
||||
while (mask && nCount) {
|
||||
*p |= mask;
|
||||
mask >>= 1;
|
||||
nCount--;
|
||||
}
|
||||
p++;
|
||||
while (nCount >= 8) {
|
||||
*p++ = 0xff;
|
||||
nCount -= 8;
|
||||
}
|
||||
mask = 0x80;
|
||||
while (nCount) {
|
||||
*p |= mask;
|
||||
mask >>= 1;
|
||||
nCount--;
|
||||
}
|
||||
}
|
||||
|
||||
void CBitSink::ClearBits(int nCount)
|
||||
{
|
||||
m_dwBitPos += nCount;
|
||||
}
|
||||
|
||||
CBitSink::CBitSink(void *pBuffer, sff_dword nByteCount) :
|
||||
m_pBuffer((sff_byte *)pBuffer),
|
||||
m_dwBitPos(0),
|
||||
m_dwByteCount(nByteCount),
|
||||
m_dwBitCount(nByteCount * 8)
|
||||
{
|
||||
}
|
||||
|
||||
void CBitSink::Reset()
|
||||
{
|
||||
m_dwBitPos = 0;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
void CByteSink::SetBits(int nCount)
|
||||
{
|
||||
sff_byte *p;
|
||||
|
||||
p = m_pBuffer;
|
||||
p += m_dwBitPos;
|
||||
for (int i=0; i<nCount; i++)
|
||||
*p++ = 0;
|
||||
m_dwBitPos += nCount;
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
int CHuffDecoder::FindToken(LPTABENTRY pTable)
|
||||
{
|
||||
sff_word bits;
|
||||
while (pTable->code) {
|
||||
bits = GetBits(pTable->bits);
|
||||
if (bits == pTable->code) {
|
||||
ClrBits(pTable->bits);
|
||||
return pTable->run;
|
||||
}
|
||||
pTable++;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
int CHuffDecoder::DecodeLine(CBitSink& aBitSink)
|
||||
{
|
||||
int iRunlength;
|
||||
m_dwRunlength = 0;
|
||||
TDecoderState state = NEED_WHITE;
|
||||
|
||||
for (;;)
|
||||
{
|
||||
switch (state) {
|
||||
case NEED_WHITE :
|
||||
// we expect white_term or white_markup
|
||||
NeedBits(12);
|
||||
iRunlength = FindToken(aTermWhite);
|
||||
if ( iRunlength == RL_EOL) {
|
||||
goto exit; // EOL
|
||||
}
|
||||
if ( iRunlength >= 0 ) {
|
||||
if ( iRunlength > 0 ) {
|
||||
m_dwRunlength += iRunlength;
|
||||
aBitSink.ClearBits(iRunlength);
|
||||
}
|
||||
state = NEED_BLACK;
|
||||
} else {
|
||||
iRunlength = FindToken(aMarkUpWhite);
|
||||
if ( iRunlength == RL_EOL) {
|
||||
goto exit; // EOL
|
||||
}
|
||||
if (iRunlength >= 0) {
|
||||
if ( iRunlength > 0 ) {
|
||||
m_dwRunlength += iRunlength;
|
||||
aBitSink.ClearBits(iRunlength);
|
||||
}
|
||||
state = NEED_WHITETERM;
|
||||
} else {
|
||||
throw CSimpleException(CSimpleException::err_nowhitestart);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case NEED_BLACK :
|
||||
// we expect black_term or black_markup
|
||||
NeedBits(13);
|
||||
iRunlength = FindToken(aTermBlack);
|
||||
if ( iRunlength == RL_EOL) {
|
||||
goto exit; // EOL
|
||||
}
|
||||
if (iRunlength >= 0) {
|
||||
if (iRunlength > 0 ) {
|
||||
m_dwRunlength += iRunlength;
|
||||
aBitSink.SetBits(iRunlength);
|
||||
}
|
||||
state = NEED_WHITE;
|
||||
} else {
|
||||
iRunlength = FindToken(aMarkUpBlack);
|
||||
if (iRunlength == RL_EOL) {
|
||||
goto exit; // EOL
|
||||
}
|
||||
if (iRunlength >= 0) {
|
||||
if (iRunlength > 0) {
|
||||
m_dwRunlength += iRunlength;
|
||||
aBitSink.SetBits(iRunlength);
|
||||
}
|
||||
state = NEED_BLACKTERM;
|
||||
} else {
|
||||
state = NEED_WHITE;
|
||||
// throw CSimpleException(CSimpleException::err_noblackcode);
|
||||
// [PS] changed to allow further decoding...
|
||||
// currently no problems known, but we'll see...
|
||||
}
|
||||
}
|
||||
break;
|
||||
case NEED_WHITETERM :
|
||||
// expect White_Term only
|
||||
NeedBits(8);
|
||||
iRunlength = FindToken(aTermWhite);
|
||||
if (iRunlength == RL_EOL) {
|
||||
goto exit; // EOL
|
||||
}
|
||||
if (iRunlength >= 0) {
|
||||
if ( iRunlength > 0 ) {
|
||||
aBitSink.ClearBits(iRunlength);
|
||||
m_dwRunlength += iRunlength;
|
||||
}
|
||||
state = NEED_BLACK;
|
||||
} else {
|
||||
throw CSimpleException(CSimpleException::err_nowhiteterm);
|
||||
}
|
||||
break;
|
||||
case NEED_BLACKTERM :
|
||||
// expect Black_Term only
|
||||
NeedBits(12);
|
||||
iRunlength = FindToken(aTermBlack);
|
||||
if (iRunlength == RL_EOL) {
|
||||
goto exit; // EOL
|
||||
}
|
||||
if (iRunlength >= 0) {
|
||||
if ( iRunlength > 0 ) {
|
||||
m_dwRunlength += iRunlength;
|
||||
aBitSink.SetBits(iRunlength);
|
||||
}
|
||||
state = NEED_WHITE;
|
||||
} else {
|
||||
throw CSimpleException(CSimpleException::err_noblackterm);
|
||||
}
|
||||
break;
|
||||
}
|
||||
if (NoMoreBits())
|
||||
break;
|
||||
}
|
||||
exit:
|
||||
return m_dwRunlength;
|
||||
}
|
|
@ -0,0 +1,104 @@
|
|||
#ifndef __DECODER_H__
|
||||
#define __DECODER_H__
|
||||
//
|
||||
// Headerfile for decoder classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: decoder.h,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
class CBitSource
|
||||
{
|
||||
private:
|
||||
sff_byte *m_pBuffer;
|
||||
sff_word m_wBitsAvail;
|
||||
sff_dword m_dwAccu;
|
||||
sff_dword m_dwByteCount;
|
||||
|
||||
public:
|
||||
void NeedBits(int nCount);
|
||||
void ClrBits(int nCount);
|
||||
sff_word GetBits(int nCount);
|
||||
bool NoMoreBits();
|
||||
|
||||
CBitSource(void *pBuffer, sff_dword nByteCount);
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CBitSink
|
||||
{
|
||||
protected:
|
||||
sff_byte *m_pBuffer;
|
||||
|
||||
sff_dword m_dwBitPos;
|
||||
sff_dword m_dwByteCount;
|
||||
sff_dword m_dwBitCount;
|
||||
|
||||
public:
|
||||
void Reset();
|
||||
|
||||
virtual void SetBits(int nCount);
|
||||
virtual void ClearBits(int nCount);
|
||||
|
||||
CBitSink(void *pBuffer, sff_dword nByteCount);
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CByteSink : public CBitSink
|
||||
{
|
||||
public:
|
||||
CByteSink(void *pBuffer, sff_dword nByteCount) :
|
||||
CBitSink(pBuffer, nByteCount) { /* nth. else */ };
|
||||
|
||||
void SetBits(int nCount);
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CHuffDecoder : public CBitSource
|
||||
{
|
||||
protected:
|
||||
sff_dword m_dwRunlength;
|
||||
|
||||
public:
|
||||
CHuffDecoder(sff_byte *pBuffer, sff_dword nByteCount) :
|
||||
CBitSource(pBuffer, nByteCount) { /* nth. else */ };
|
||||
|
||||
int FindToken(LPTABENTRY pTable);
|
||||
int DecodeLine(CBitSink& aBitSink);
|
||||
};
|
||||
|
||||
#endif // __DECODER_H__
|
|
@ -0,0 +1,56 @@
|
|||
/*
|
||||
* getopt.h - cpp wrapper for my_getopt to make it look like getopt.
|
||||
* Copyright 1997, 2000, 2001, 2002, Benjamin Sittler
|
||||
*
|
||||
* 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, sublicense, and/or sell copies
|
||||
* of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* 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. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
* DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef MY_WRAPPER_GETOPT_H_INCLUDED
|
||||
#define MY_WRAPPER_GETOPT_H_INCLUDED
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include "my_getopt.h"
|
||||
|
||||
#undef getopt
|
||||
#define getopt my_getopt
|
||||
#undef getopt_long
|
||||
#define getopt_long my_getopt_long
|
||||
#undef getopt_long_only
|
||||
#define getopt_long_only my_getopt_long_only
|
||||
#undef _getopt_internal
|
||||
#define _getopt_internal _my_getopt_internal
|
||||
#undef opterr
|
||||
#define opterr my_opterr
|
||||
#undef optind
|
||||
#define optind my_optind
|
||||
#undef optopt
|
||||
#define optopt my_optopt
|
||||
#undef optarg
|
||||
#define optarg my_optarg
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* MY_WRAPPER_GETOPT_H_INCLUDED */
|
|
@ -0,0 +1,341 @@
|
|||
// Input classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// Ulf Zibis <ulf.zibis@gmx.de> (resolution preserving, RVS COM resolutions,
|
||||
// inheritance from CFile)
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: input.cpp,v 1.6 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include <cstring>
|
||||
#include <vector>
|
||||
#include <iostream>
|
||||
|
||||
#include "sfftypes.h"
|
||||
#include "common.h"
|
||||
|
||||
extern "C"
|
||||
{
|
||||
#define XMD_H
|
||||
#include <jpeglib.h>
|
||||
#include <tiffio.h>
|
||||
}
|
||||
|
||||
#include "codes.h"
|
||||
#include "output.h"
|
||||
#include "decoder.h"
|
||||
#include "input.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
//-Constants-------------------------------------------------------
|
||||
|
||||
sff_byte CSffFile::m_SFFID[4] = { 0x53, 0x66, 0x66, 0x66 };
|
||||
|
||||
//-Types-----------------------------------------------------------
|
||||
|
||||
typedef enum {
|
||||
NEED_MAGIC,
|
||||
NEED_PAGESTART,
|
||||
NEED_PAGEHEADER,
|
||||
NEED_RECORD,
|
||||
LAST_PAGE
|
||||
} TScannerState;
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
CSffFile::CSffFile(const std::string& strFileName) :
|
||||
CFile(strFileName)
|
||||
{
|
||||
ScanFile();
|
||||
}
|
||||
|
||||
CSffFile::~CSffFile()
|
||||
{
|
||||
PAGEVECTOR::iterator it = m_acPages.begin();
|
||||
for (; it != m_acPages.end(); it++) {
|
||||
delete (*it);
|
||||
}
|
||||
}
|
||||
|
||||
void CSffFile::ScanFile()
|
||||
{
|
||||
TSFFFileHeader dh;
|
||||
TSFFPageHeader ph;
|
||||
sff_byte b1 = 0, b2 = 0;
|
||||
sff_word w;
|
||||
int nLineCount = 0;
|
||||
int fuzz = 0;
|
||||
TSFFPage *pPage;
|
||||
|
||||
if (Eof())
|
||||
return;
|
||||
|
||||
TScannerState state = NEED_MAGIC;
|
||||
do {
|
||||
switch (state) {
|
||||
case NEED_MAGIC :
|
||||
for (fuzz = 0; fuzz < 2048; ++fuzz) {
|
||||
Seek(fuzz, CFile::sk_from_start);
|
||||
Read(&dh, sizeof(dh));
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_invalidfile);
|
||||
if (::memcmp(&dh.sff_id, &m_SFFID, sizeof(m_SFFID)) == 0)
|
||||
break;
|
||||
}
|
||||
if (::memcmp(&dh.sff_id, &m_SFFID, sizeof(m_SFFID)) != 0)
|
||||
throw CSimpleException(CSimpleException::err_invalidfile);
|
||||
if (dh.version > 1)
|
||||
throw CSimpleException(CSimpleException::err_invalidversion);
|
||||
if (fuzz>0) {
|
||||
cerr << "NOTE: File starts with " << fuzz << " bytes of garbage." << endl;
|
||||
dh.first_page += fuzz;
|
||||
}
|
||||
Seek(dh.first_page, CFile::sk_from_start);
|
||||
state = NEED_PAGESTART;
|
||||
break;
|
||||
case NEED_PAGESTART :
|
||||
b1 = GetC(); // record header (0xFE fuer beginning of page)
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
if (b1 != 0xFE)
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
b1 = GetC(); // record length (usually 0x10)
|
||||
if (b1 == 0)
|
||||
state = LAST_PAGE;
|
||||
else
|
||||
state = NEED_PAGEHEADER;
|
||||
break;
|
||||
case NEED_PAGEHEADER :
|
||||
Read(&ph, sizeof(TSFFPageHeader));
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
if (ph.coding > 0)
|
||||
throw CSimpleException(CSimpleException::err_unknowncoding);
|
||||
Seek(b1 - sizeof(TSFFPageHeader), CFile::sk_current); // skip user data
|
||||
pPage = new TSFFPage;
|
||||
pPage->filepos = Tell();
|
||||
pPage->width = ph.linelen;
|
||||
pPage->height = ph.pagelen;
|
||||
// Values 254/255 are known for RVS COM
|
||||
pPage->dpi = (ph.horiz_res == 0) ? 203 :
|
||||
(ph.horiz_res == 255) ? 300 :
|
||||
(ph.horiz_res == 254) ? 400 : 0;
|
||||
pPage->lpi = (ph.vert_res == 0) ? 98 :
|
||||
(ph.vert_res == 1) ? 196 :
|
||||
(ph.vert_res == 255) ? 300 :
|
||||
(ph.vert_res == 254) ? 400 : 0;
|
||||
m_acPages.push_back(pPage);
|
||||
state = NEED_RECORD;
|
||||
nLineCount = 0;
|
||||
break;
|
||||
case NEED_RECORD :
|
||||
b1 = GetC(); // read record type
|
||||
if (Eof()) {
|
||||
m_acPages[GetPageCount()-1]->height = nLineCount;
|
||||
state = LAST_PAGE;
|
||||
} else if (b1 == 0) {
|
||||
// variable amount of bytes following
|
||||
b1 = GetC(); // LSB
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
b2 = GetC(); // MSB
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
w = ((b2 << 8) | b1);
|
||||
Seek(w, CFile::sk_current); // skip data
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
++nLineCount;
|
||||
} else if (b1 < 217) {
|
||||
// normal amount of bytes following
|
||||
Seek((long)b1, CFile::sk_current); // skip data
|
||||
if (Eof()) {
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
}
|
||||
++nLineCount;
|
||||
} else if (b1 < 254) {
|
||||
// white skip
|
||||
nLineCount+=(b1 - 216);
|
||||
} else if (b1 < 255) {
|
||||
// 254 -> page header
|
||||
m_acPages[GetPageCount()-1]->height = nLineCount;
|
||||
nLineCount = 0;
|
||||
b1 = GetC(); // record length (usually 0x10)
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
if (b1 == 0) {
|
||||
state = LAST_PAGE;
|
||||
} else {
|
||||
state = NEED_PAGEHEADER;
|
||||
}
|
||||
} else {
|
||||
// bad line or user info
|
||||
b1 = GetC(); // LSB
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
if (b1 == 0) {
|
||||
++nLineCount;
|
||||
} else {
|
||||
Seek(b1, CFile::sk_current); // skip user info
|
||||
if (Eof())
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case LAST_PAGE :
|
||||
break;
|
||||
}
|
||||
} while(state != LAST_PAGE);
|
||||
return;
|
||||
}
|
||||
|
||||
bool CSffFile::PageIsValid(int nPage)
|
||||
{
|
||||
return ((nPage >= 0) && (nPage < GetPageCount()));
|
||||
}
|
||||
|
||||
bool CSffFile::SeekPage(int nPage)
|
||||
{
|
||||
if (!PageIsValid(nPage))
|
||||
return false;
|
||||
Seek(m_acPages[nPage]->filepos, CFile::sk_from_start);
|
||||
return true;
|
||||
}
|
||||
|
||||
TSFFPage *CSffFile::GetPage(int nPage)
|
||||
{
|
||||
return PageIsValid(nPage) ? m_acPages[nPage] : (TSFFPage *)NULL;
|
||||
}
|
||||
|
||||
bool CSffFile::IsLowRes(int nPage)
|
||||
{
|
||||
return PageIsValid(nPage) && (m_acPages[nPage]->lpi == 98);
|
||||
}
|
||||
|
||||
sff_word CSffFile::GetHorizontalResolution(int nPage)
|
||||
{
|
||||
return PageIsValid(nPage) ? m_acPages[nPage]->dpi :0;
|
||||
}
|
||||
|
||||
sff_word CSffFile::GetVerticalResolution(int nPage)
|
||||
{
|
||||
return PageIsValid(nPage) ? m_acPages[nPage]->lpi :0;
|
||||
}
|
||||
|
||||
sff_dword CSffFile::GetPageWidth(int nPage)
|
||||
{
|
||||
return PageIsValid(nPage) ? m_acPages[nPage]->width :0;
|
||||
}
|
||||
|
||||
sff_dword CSffFile::GetPageHeight(int nPage)
|
||||
{
|
||||
return PageIsValid(nPage) ? m_acPages[nPage]->height :0;
|
||||
}
|
||||
|
||||
bool CSffFile::GetRecord(TSFFRecord& rec)
|
||||
{
|
||||
sff_byte b1, b2;
|
||||
sff_word w;
|
||||
bool result;
|
||||
|
||||
if (Eof()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
b1 = GetC(); // read record type
|
||||
if (Eof()) {
|
||||
result = FALSE;
|
||||
} else if (b1 == 0) {
|
||||
// variable amount of bytes following
|
||||
b1 = GetC(); // LSB
|
||||
b2 = GetC(); // MSB
|
||||
w = ((b2 << 8) | b1);
|
||||
rec.type = NORMAL;
|
||||
rec.cb = w;
|
||||
rec.pData = (sff_byte *)malloc(w);
|
||||
Read(rec.pData, w);
|
||||
result = TRUE;
|
||||
} else if (b1 < 217) {
|
||||
// normal amount of bytes following
|
||||
rec.type = NORMAL;
|
||||
rec.cb = b1;
|
||||
rec.pData = (sff_byte *)malloc(b1);
|
||||
Read(rec.pData, b1);
|
||||
result = TRUE;
|
||||
} else if (b1 < 254) {
|
||||
// white skip
|
||||
rec.type = WHITESKIP;
|
||||
rec.cb = (b1 - 216);
|
||||
rec.pData = 0;
|
||||
result = TRUE;
|
||||
} else if (b1 < 255) {
|
||||
// 254 -> page header
|
||||
result = FALSE;
|
||||
} else {
|
||||
// bad line or user info
|
||||
b1 = GetC(); // LSB
|
||||
if (b1 == 0) {
|
||||
rec.type = BADLINE;
|
||||
rec.cb = 1;
|
||||
rec.pData = 0;
|
||||
} else {
|
||||
rec.type = USERINFO;
|
||||
rec.cb = b1;
|
||||
rec.pData = (sff_byte *)malloc(b1);
|
||||
Read(rec.pData, b1);
|
||||
}
|
||||
result = TRUE;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
bool CSffFile::DecodeRecord(TSFFRecord& rec, CBitSink& bitsink)
|
||||
{
|
||||
bool rc;
|
||||
|
||||
if (rec.type != NORMAL)
|
||||
return FALSE;
|
||||
|
||||
CHuffDecoder source(rec.pData, rec.cb);
|
||||
|
||||
try {
|
||||
rec.runlength = source.DecodeLine(bitsink);
|
||||
rc = TRUE;
|
||||
}
|
||||
catch(CSimpleException e)
|
||||
{
|
||||
cerr << "ERROR: " << e.what() << endl;
|
||||
rc = FALSE;
|
||||
}
|
||||
return rc;
|
||||
}
|
|
@ -0,0 +1,123 @@
|
|||
#ifndef __INPUT_H__
|
||||
#define __INPUT_H__
|
||||
//
|
||||
// Headerfile for input classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// Ulf Zibis <ulf.zibis@gmx.de> (resolution preserving, RVS COM resolutions,
|
||||
// inheritance from CFile)
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: input.h,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
typedef enum {
|
||||
NORMAL,
|
||||
WHITESKIP,
|
||||
BADLINE,
|
||||
USERINFO
|
||||
} TSFFRecordType;
|
||||
|
||||
typedef struct{
|
||||
sff_dword sff_id;
|
||||
sff_byte version;
|
||||
sff_byte reserved;
|
||||
sff_word user_info;
|
||||
sff_word num_pages;
|
||||
sff_word first_page;
|
||||
sff_dword last_page;
|
||||
sff_dword file_size;
|
||||
} TSFFFileHeader;
|
||||
|
||||
typedef struct{
|
||||
sff_byte vert_res;
|
||||
sff_byte horiz_res;
|
||||
sff_byte coding;
|
||||
sff_byte specials;
|
||||
sff_word linelen;
|
||||
sff_word pagelen;
|
||||
sff_dword prev_page;
|
||||
sff_dword next_page;
|
||||
} TSFFPageHeader;
|
||||
|
||||
typedef struct{
|
||||
TSFFRecordType type;
|
||||
sff_word cb;
|
||||
sff_dword runlength;
|
||||
sff_byte *pData;
|
||||
} TSFFRecord;
|
||||
|
||||
typedef struct{
|
||||
sff_dword width;
|
||||
sff_dword height;
|
||||
sff_word dpi;
|
||||
sff_word lpi;
|
||||
off_t filepos;
|
||||
} TSFFPage;
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
typedef std::vector<TSFFPage *> PAGEVECTOR;
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CSffFile : public CFile
|
||||
{
|
||||
protected:
|
||||
static sff_byte m_SFFID[4];
|
||||
PAGEVECTOR m_acPages;
|
||||
|
||||
void ScanFile();
|
||||
// throw CSimpleException
|
||||
|
||||
public:
|
||||
CSffFile(const std::string& strFileName);
|
||||
~CSffFile();
|
||||
|
||||
int GetPageCount() { return m_acPages.size(); };
|
||||
|
||||
bool PageIsValid(int nPage);
|
||||
bool SeekPage(int nPage);
|
||||
TSFFPage *GetPage(int nPage);
|
||||
|
||||
bool IsLowRes(int nPage);
|
||||
|
||||
sff_word GetHorizontalResolution(int nPage);
|
||||
sff_word GetVerticalResolution(int nPage);
|
||||
|
||||
sff_dword GetPageWidth(int nPage);
|
||||
sff_dword GetPageHeight(int nPage);
|
||||
|
||||
bool GetRecord(TSFFRecord& rec);
|
||||
bool DecodeRecord(TSFFRecord& rec, CBitSink& bitsink);
|
||||
};
|
||||
|
||||
#endif // __INPUT_H__
|
|
@ -0,0 +1,321 @@
|
|||
// Main program file
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: main.cpp,v 1.7 2009/08/23 12:39:08 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include <cassert>
|
||||
#include <vector>
|
||||
#include <iostream>
|
||||
|
||||
#include <boost/filesystem/path.hpp>
|
||||
#include <boost/filesystem/operations.hpp>
|
||||
#include <boost/filesystem/convenience.hpp>
|
||||
|
||||
extern "C"
|
||||
{
|
||||
#define XMD_H
|
||||
#include <jpeglib.h>
|
||||
#include <tiffio.h>
|
||||
}
|
||||
|
||||
#include "sfftypes.h"
|
||||
#include "common.h"
|
||||
|
||||
#include "codes.h"
|
||||
#include "output.h"
|
||||
#include "decoder.h"
|
||||
#include "input.h"
|
||||
#include "cmdline.h"
|
||||
|
||||
#include "main.h"
|
||||
|
||||
using namespace std;
|
||||
namespace fs = boost::filesystem;
|
||||
|
||||
int main( int argc, char *argv[] )
|
||||
{
|
||||
int rc = 0;
|
||||
|
||||
fs::path pathInFileName;
|
||||
fs::path pathOutFileName;
|
||||
fs::path pathOutDirectory;
|
||||
|
||||
CCmdLineProcessor proc(argv, argc);
|
||||
|
||||
int nIdx = 0;
|
||||
try
|
||||
{
|
||||
proc.parseCmdLine();
|
||||
|
||||
if (!proc.getFileCount())
|
||||
return 0;
|
||||
|
||||
const string& strOutSpec = proc.getOutSpec();
|
||||
|
||||
bool bStdOut = (strOutSpec == "-");
|
||||
bool bQuiet = proc.beQuiet() || bStdOut;
|
||||
|
||||
if (strOutSpec.length() && (strOutSpec != "-")) {
|
||||
if (proc.getFileCount() > 1) {
|
||||
// More than one input file -> interpret OutSpec as a directory
|
||||
if (!fs::exists(strOutSpec)) { // Create directory, if necessary
|
||||
if (!bQuiet) cout << endl << "Creating directory " << strOutSpec.c_str() << "." << endl;
|
||||
try {
|
||||
fs::create_directories(strOutSpec);
|
||||
}
|
||||
catch (const std::exception & e) {
|
||||
}
|
||||
}
|
||||
// Check that dir exists
|
||||
if (!(fs::exists(strOutSpec) && fs::is_directory(strOutSpec))) {
|
||||
throw CSimpleException(CSimpleException::err_outdir);
|
||||
}
|
||||
pathOutDirectory = strOutSpec;
|
||||
} else {
|
||||
// Exact one input file -> interpret OutSpec as one file
|
||||
if (fs::exists(strOutSpec) && fs::is_directory(strOutSpec)) {
|
||||
throw CSimpleException(CSimpleException::err_outfileisdir);
|
||||
}
|
||||
pathOutFileName = strOutSpec;
|
||||
}
|
||||
}
|
||||
|
||||
while (proc.getNextFile(pathInFileName))
|
||||
{
|
||||
COutputFilter *pOut = NULL;
|
||||
CSffFile *pInfile = NULL;
|
||||
char acNumber[10];
|
||||
|
||||
try
|
||||
{
|
||||
fs::path outPath;
|
||||
|
||||
CSffFile *pInfile = new CSffFile(pathInFileName.string());
|
||||
int nPageCount = pInfile->GetPageCount();
|
||||
if (!bQuiet)
|
||||
cout << "File " << pathInFileName.string()
|
||||
<< " seems to have " << nPageCount << " page(s)." << endl;
|
||||
int nFileCountOut = nPageCount;
|
||||
time_t modTime = pInfile->GetModificationTime();
|
||||
|
||||
switch (proc.getOutputFormat())
|
||||
{
|
||||
case CCmdLineProcessor::fmt_bmp:
|
||||
pOut = new CBMPFilter(nPageCount);
|
||||
break;
|
||||
case CCmdLineProcessor::fmt_pbm:
|
||||
pOut = new CPBMFilter(nPageCount);
|
||||
break;
|
||||
case CCmdLineProcessor::fmt_jpeg:
|
||||
pOut = new CJPEGFilter(nPageCount, proc.getJpegQuality());
|
||||
break;
|
||||
case CCmdLineProcessor::fmt_tiff:
|
||||
nFileCountOut = 1; // all pages in one file
|
||||
pOut = new CTIFFFilter(nPageCount,
|
||||
proc.getTiffCompression(), modTime);
|
||||
break;
|
||||
case CCmdLineProcessor::fmt_tiff_single_pages:
|
||||
pOut = new CTIFFFilter(nPageCount,
|
||||
proc.getTiffCompression(), modTime);
|
||||
break;
|
||||
}
|
||||
|
||||
CFile fileOut;
|
||||
if (bStdOut) {
|
||||
fileOut.OpenTemp();
|
||||
pOut->Init(&fileOut);
|
||||
}
|
||||
|
||||
for (int nPage = 0; nPage < nPageCount; nPage++)
|
||||
{
|
||||
TSFFPage* pPage = pInfile->GetPage(nPage);
|
||||
if (pPage->height <= 0) {
|
||||
if (!bQuiet) {
|
||||
cout << "Skipping page (no lines)." << endl;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
if (!bStdOut)
|
||||
{
|
||||
if (pathOutFileName.string().length()) {
|
||||
// A fixed name was given, so use it as a base name
|
||||
outPath = pathOutFileName;
|
||||
std::string orgExt = fs::extension(outPath);
|
||||
if (nFileCountOut > 1) {
|
||||
sprintf(acNumber, "_%03d", nPage+1);
|
||||
outPath = fs::change_extension(outPath, acNumber);
|
||||
if (orgExt.length()) {
|
||||
std::string strTemp = outPath.string();
|
||||
strTemp += orgExt;
|
||||
outPath = fs::path(strTemp);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// Otherwise construct output filename from input filename
|
||||
outPath = pathOutDirectory / pathInFileName.leaf();
|
||||
if (nFileCountOut > 1) {
|
||||
sprintf(acNumber, "_%03d", nPage+1);
|
||||
outPath = fs::change_extension(outPath, acNumber);
|
||||
std::string strTemp = outPath.string();
|
||||
strTemp += pOut->GetExtension();
|
||||
outPath = fs::path(strTemp);
|
||||
} else {
|
||||
outPath = fs::change_extension(outPath, pOut->GetExtension());
|
||||
}
|
||||
}
|
||||
if (!proc.doOverwrite() && !((nPage > 0) && (nFileCountOut == 1)) && fs::exists(outPath)) {
|
||||
throw CSimpleException(CSimpleException::err_outfileexists);
|
||||
}
|
||||
}
|
||||
|
||||
bool bIsLowRes = pInfile->IsLowRes(nPage);
|
||||
bool bDoubleLines = !proc.keepVRes() && bIsLowRes;
|
||||
|
||||
if (!bQuiet) {
|
||||
if (!((nPage > 0) && (nFileCountOut == 1))) {
|
||||
cout << "- Destination File " << outPath.string() << " : " << endl;
|
||||
}
|
||||
cout << " Converting page " << nPage+1
|
||||
<< " (" << pPage->width << "x" << pPage->height << "px / ";
|
||||
cout << pPage->dpi << "x" << pPage->lpi << "dpi), ";
|
||||
cout << (bIsLowRes ? "LowRes" : "HiRes") << " ..." << endl;
|
||||
}
|
||||
|
||||
if (!pInfile->SeekPage(nPage)) {
|
||||
throw CSimpleException(CSimpleException::err_corruptfile);
|
||||
}
|
||||
|
||||
if (!bStdOut && !((nPage > 0) && (nFileCountOut == 1))) {
|
||||
fileOut.Open(outPath.string(), "wb+");
|
||||
pOut->Init(&fileOut);
|
||||
}
|
||||
|
||||
if (bDoubleLines) {
|
||||
pOut->BeginPage(nPage, pPage->width,
|
||||
pPage->height*2, pPage->dpi, pPage->lpi*2);
|
||||
} else {
|
||||
pOut->BeginPage(nPage, pPage->width,
|
||||
pPage->height, pPage->dpi, pPage->lpi);
|
||||
}
|
||||
|
||||
pOut->BlankLine();
|
||||
|
||||
TSFFRecord rec;
|
||||
|
||||
while (pInfile->GetRecord(rec))
|
||||
{
|
||||
switch(rec.type)
|
||||
{
|
||||
case NORMAL :
|
||||
pOut->BlankLine();
|
||||
if (pInfile->DecodeRecord(rec, pOut->GetBitSink())) {
|
||||
pOut->WriteLine();
|
||||
if (bDoubleLines) {
|
||||
pOut->WriteLine();
|
||||
}
|
||||
}
|
||||
if (rec.pData != 0) free(rec.pData);
|
||||
break;
|
||||
case USERINFO :
|
||||
// not yet considered
|
||||
if (rec.pData != 0) free(rec.pData);
|
||||
break;
|
||||
case BADLINE :
|
||||
pOut->WriteLine();
|
||||
if (bDoubleLines) {
|
||||
pOut->WriteLine();
|
||||
}
|
||||
break;
|
||||
case WHITESKIP :
|
||||
pOut->BlankLine();
|
||||
for (int j=0; j < rec.cb; ++j) {
|
||||
pOut->WriteLine();
|
||||
if (bDoubleLines) {
|
||||
pOut->WriteLine();
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
pOut->EndPage();
|
||||
|
||||
if (!bStdOut) {
|
||||
if ((nFileCountOut > 1) || ((nFileCountOut == 1) && (nPage == nPageCount-1))) {
|
||||
pOut->Finalize();
|
||||
fileOut.Close();
|
||||
if (proc.keepDate()) {
|
||||
fileOut.SetModificationTime(modTime);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (bStdOut) {
|
||||
fileOut.DumpToStdOut();
|
||||
fileOut.Close();
|
||||
if (pOut) {
|
||||
pOut->Finalize();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
catch (const std::exception & e) {
|
||||
cerr << "ERROR: " << pathInFileName.string() << ": " << e.what() << endl;
|
||||
rc = 2;
|
||||
}
|
||||
catch (CSimpleException e) {
|
||||
cerr << "ERROR: " << pathInFileName.string() << ": " << e.what() << endl;
|
||||
rc = 2;
|
||||
}
|
||||
if (pOut) {
|
||||
delete pOut;
|
||||
}
|
||||
if (pInfile) {
|
||||
delete pInfile;
|
||||
}
|
||||
if (!bQuiet) cout << endl;
|
||||
}
|
||||
if (!bQuiet) cout << "Finished. " << endl << endl;
|
||||
}
|
||||
catch (const std::exception & e) {
|
||||
cerr << "ERROR: " << e.what() << endl;
|
||||
rc = 2;
|
||||
}
|
||||
catch (CSimpleException e) {
|
||||
cerr << "ERROR: " << e.what() << endl;
|
||||
rc = 2;
|
||||
}
|
||||
return rc;
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
#ifndef __MAIN_H__
|
||||
#define __MAIN_H__
|
||||
//
|
||||
// Main header file
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: main.h,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#endif // __MAIN_H__
|
|
@ -0,0 +1,271 @@
|
|||
/*
|
||||
* my_getopt.c - my re-implementation of getopt.
|
||||
* Copyright 1997, 2000, 2001, 2002, Benjamin Sittler
|
||||
*
|
||||
* 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, sublicense, and/or sell copies
|
||||
* of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* 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. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
* DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include "my_getopt.h"
|
||||
|
||||
int my_optind=1, my_opterr=1, my_optopt=0;
|
||||
char *my_optarg=0;
|
||||
|
||||
/* this is the plain old UNIX getopt, with GNU-style extensions. */
|
||||
/* if you're porting some piece of UNIX software, this is all you need. */
|
||||
/* this supports GNU-style permution and optional arguments */
|
||||
|
||||
int my_getopt(int argc, char * argv[], const char *opts)
|
||||
{
|
||||
static int charind=0;
|
||||
const char *s;
|
||||
char mode, colon_mode;
|
||||
int off = 0, opt = -1;
|
||||
|
||||
if(getenv("POSIXLY_CORRECT")) colon_mode = mode = '+';
|
||||
else {
|
||||
if((colon_mode = *opts) == ':') off ++;
|
||||
if(((mode = opts[off]) == '+') || (mode == '-')) {
|
||||
off++;
|
||||
if((colon_mode != ':') && ((colon_mode = opts[off]) == ':'))
|
||||
off ++;
|
||||
}
|
||||
}
|
||||
my_optarg = 0;
|
||||
if(charind) {
|
||||
my_optopt = argv[my_optind][charind];
|
||||
for(s=opts+off; *s; s++) if(my_optopt == *s) {
|
||||
charind++;
|
||||
if((*(++s) == ':') || ((my_optopt == 'W') && (*s == ';'))) {
|
||||
if(argv[my_optind][charind]) {
|
||||
my_optarg = &(argv[my_optind++][charind]);
|
||||
charind = 0;
|
||||
} else if(*(++s) != ':') {
|
||||
charind = 0;
|
||||
if(++my_optind >= argc) {
|
||||
if(my_opterr) fprintf(stderr,
|
||||
"%s: option requires an argument -- %c\n",
|
||||
argv[0], my_optopt);
|
||||
opt = (colon_mode == ':') ? ':' : '?';
|
||||
goto my_getopt_ok;
|
||||
}
|
||||
my_optarg = argv[my_optind++];
|
||||
}
|
||||
}
|
||||
opt = my_optopt;
|
||||
goto my_getopt_ok;
|
||||
}
|
||||
if(my_opterr) fprintf(stderr,
|
||||
"%s: illegal option -- %c\n",
|
||||
argv[0], my_optopt);
|
||||
opt = '?';
|
||||
if(argv[my_optind][++charind] == '\0') {
|
||||
my_optind++;
|
||||
charind = 0;
|
||||
}
|
||||
my_getopt_ok:
|
||||
if(charind && ! argv[my_optind][charind]) {
|
||||
my_optind++;
|
||||
charind = 0;
|
||||
}
|
||||
} else if((my_optind >= argc) ||
|
||||
((argv[my_optind][0] == '-') &&
|
||||
(argv[my_optind][1] == '-') &&
|
||||
(argv[my_optind][2] == '\0'))) {
|
||||
my_optind++;
|
||||
opt = -1;
|
||||
} else if((argv[my_optind][0] != '-') ||
|
||||
(argv[my_optind][1] == '\0')) {
|
||||
char *tmp;
|
||||
int i, j, k;
|
||||
|
||||
if(mode == '+') opt = -1;
|
||||
else if(mode == '-') {
|
||||
my_optarg = argv[my_optind++];
|
||||
charind = 0;
|
||||
opt = 1;
|
||||
} else {
|
||||
for(i=j=my_optind; i<argc; i++) if((argv[i][0] == '-') &&
|
||||
(argv[i][1] != '\0')) {
|
||||
my_optind=i;
|
||||
opt=my_getopt(argc, argv, opts);
|
||||
while(i > j) {
|
||||
tmp=argv[--i];
|
||||
for(k=i; k+1<my_optind; k++) argv[k]=argv[k+1];
|
||||
argv[--my_optind]=tmp;
|
||||
}
|
||||
break;
|
||||
}
|
||||
if(i == argc) opt = -1;
|
||||
}
|
||||
} else {
|
||||
charind++;
|
||||
opt = my_getopt(argc, argv, opts);
|
||||
}
|
||||
if (my_optind > argc) my_optind = argc;
|
||||
return opt;
|
||||
}
|
||||
|
||||
/* this is the extended getopt_long{,_only}, with some GNU-like
|
||||
* extensions. Implements _getopt_internal in case any programs
|
||||
* expecting GNU libc getopt call it.
|
||||
*/
|
||||
|
||||
int _my_getopt_internal(int argc, char * argv[], const char *shortopts,
|
||||
const struct option *longopts, int *longind,
|
||||
int long_only)
|
||||
{
|
||||
char mode, colon_mode = *shortopts;
|
||||
int shortoff = 0, opt = -1;
|
||||
|
||||
if(getenv("POSIXLY_CORRECT")) colon_mode = mode = '+';
|
||||
else {
|
||||
if((colon_mode = *shortopts) == ':') shortoff ++;
|
||||
if(((mode = shortopts[shortoff]) == '+') || (mode == '-')) {
|
||||
shortoff++;
|
||||
if((colon_mode != ':') && ((colon_mode = shortopts[shortoff]) == ':'))
|
||||
shortoff ++;
|
||||
}
|
||||
}
|
||||
my_optarg = 0;
|
||||
if((my_optind >= argc) ||
|
||||
((argv[my_optind][0] == '-') &&
|
||||
(argv[my_optind][1] == '-') &&
|
||||
(argv[my_optind][2] == '\0'))) {
|
||||
my_optind++;
|
||||
opt = -1;
|
||||
} else if((argv[my_optind][0] != '-') ||
|
||||
(argv[my_optind][1] == '\0')) {
|
||||
char *tmp;
|
||||
int i, j, k;
|
||||
|
||||
opt = -1;
|
||||
if(mode == '+') return -1;
|
||||
else if(mode == '-') {
|
||||
my_optarg = argv[my_optind++];
|
||||
return 1;
|
||||
}
|
||||
for(i=j=my_optind; i<argc; i++) if((argv[i][0] == '-') &&
|
||||
(argv[i][1] != '\0')) {
|
||||
my_optind=i;
|
||||
opt=_my_getopt_internal(argc, argv, shortopts,
|
||||
longopts, longind,
|
||||
long_only);
|
||||
while(i > j) {
|
||||
tmp=argv[--i];
|
||||
for(k=i; k+1<my_optind; k++)
|
||||
argv[k]=argv[k+1];
|
||||
argv[--my_optind]=tmp;
|
||||
}
|
||||
break;
|
||||
}
|
||||
} else if((!long_only) && (argv[my_optind][1] != '-'))
|
||||
opt = my_getopt(argc, argv, shortopts);
|
||||
else {
|
||||
int charind, offset;
|
||||
int found = 0, ind, hits = 0;
|
||||
|
||||
if(((my_optopt = argv[my_optind][1]) != '-') && ! argv[my_optind][2]) {
|
||||
int c;
|
||||
|
||||
ind = shortoff;
|
||||
while((c = shortopts[ind++])) {
|
||||
if(((shortopts[ind] == ':') ||
|
||||
((c == 'W') && (shortopts[ind] == ';'))) &&
|
||||
(shortopts[++ind] == ':'))
|
||||
ind ++;
|
||||
if(my_optopt == c) return my_getopt(argc, argv, shortopts);
|
||||
}
|
||||
}
|
||||
offset = 2 - (argv[my_optind][1] != '-');
|
||||
for(charind = offset;
|
||||
(argv[my_optind][charind] != '\0') &&
|
||||
(argv[my_optind][charind] != '=');
|
||||
charind++);
|
||||
for(ind = 0; longopts[ind].name && !hits; ind++)
|
||||
if((strlen(longopts[ind].name) == (size_t) (charind - offset)) &&
|
||||
(strncmp(longopts[ind].name,
|
||||
argv[my_optind] + offset, charind - offset) == 0))
|
||||
found = ind, hits++;
|
||||
if(!hits) for(ind = 0; longopts[ind].name; ind++)
|
||||
if(strncmp(longopts[ind].name,
|
||||
argv[my_optind] + offset, charind - offset) == 0)
|
||||
found = ind, hits++;
|
||||
if(hits == 1) {
|
||||
opt = 0;
|
||||
|
||||
if(argv[my_optind][charind] == '=') {
|
||||
if(longopts[found].has_arg == 0) {
|
||||
opt = '?';
|
||||
if(my_opterr) fprintf(stderr,
|
||||
"%s: option `--%s' doesn't allow an argument\n",
|
||||
argv[0], longopts[found].name);
|
||||
} else {
|
||||
my_optarg = argv[my_optind] + ++charind;
|
||||
charind = 0;
|
||||
}
|
||||
} else if(longopts[found].has_arg == 1) {
|
||||
if(++my_optind >= argc) {
|
||||
opt = (colon_mode == ':') ? ':' : '?';
|
||||
if(my_opterr) fprintf(stderr,
|
||||
"%s: option `--%s' requires an argument\n",
|
||||
argv[0], longopts[found].name);
|
||||
} else my_optarg = argv[my_optind];
|
||||
}
|
||||
if(!opt) {
|
||||
if (longind) *longind = found;
|
||||
if(!longopts[found].flag) opt = longopts[found].val;
|
||||
else *(longopts[found].flag) = longopts[found].val;
|
||||
}
|
||||
my_optind++;
|
||||
} else if(!hits) {
|
||||
if(offset == 1) opt = my_getopt(argc, argv, shortopts);
|
||||
else {
|
||||
opt = '?';
|
||||
if(my_opterr) fprintf(stderr,
|
||||
"%s: unrecognized option `%s'\n",
|
||||
argv[0], argv[my_optind++]);
|
||||
}
|
||||
} else {
|
||||
opt = '?';
|
||||
if(my_opterr) fprintf(stderr,
|
||||
"%s: option `%s' is ambiguous\n",
|
||||
argv[0], argv[my_optind++]);
|
||||
}
|
||||
}
|
||||
if (my_optind > argc) my_optind = argc;
|
||||
return opt;
|
||||
}
|
||||
|
||||
int my_getopt_long(int argc, char * argv[], const char *shortopts,
|
||||
const struct option *longopts, int *longind)
|
||||
{
|
||||
return _my_getopt_internal(argc, argv, shortopts, longopts, longind, 0);
|
||||
}
|
||||
|
||||
int my_getopt_long_only(int argc, char * argv[], const char *shortopts,
|
||||
const struct option *longopts, int *longind)
|
||||
{
|
||||
return _my_getopt_internal(argc, argv, shortopts, longopts, longind, 1);
|
||||
}
|
|
@ -0,0 +1,69 @@
|
|||
/*
|
||||
* my_getopt.h - interface to my re-implementation of getopt.
|
||||
* Copyright 1997, 2000, 2001, 2002, Benjamin Sittler
|
||||
*
|
||||
* 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, sublicense, and/or sell copies
|
||||
* of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* 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. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
* DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef MY_GETOPT_H_INCLUDED
|
||||
#define MY_GETOPT_H_INCLUDED
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* UNIX-style short-argument parser */
|
||||
extern int my_getopt(int argc, char * argv[], const char *opts);
|
||||
|
||||
extern int my_optind, my_opterr, my_optopt;
|
||||
extern char *my_optarg;
|
||||
|
||||
struct option {
|
||||
const char *name;
|
||||
int has_arg;
|
||||
int *flag;
|
||||
int val;
|
||||
};
|
||||
|
||||
/* human-readable values for has_arg */
|
||||
#undef no_argument
|
||||
#define no_argument 0
|
||||
#undef required_argument
|
||||
#define required_argument 1
|
||||
#undef optional_argument
|
||||
#define optional_argument 2
|
||||
|
||||
/* GNU-style long-argument parsers */
|
||||
extern int my_getopt_long(int argc, char * argv[], const char *shortopts,
|
||||
const struct option *longopts, int *longind);
|
||||
|
||||
extern int my_getopt_long_only(int argc, char * argv[], const char *shortopts,
|
||||
const struct option *longopts, int *longind);
|
||||
|
||||
extern int _my_getopt_internal(int argc, char * argv[], const char *shortopts,
|
||||
const struct option *longopts, int *longind,
|
||||
int long_only);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* MY_GETOPT_H_INCLUDED */
|
|
@ -0,0 +1,306 @@
|
|||
// Output classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// Gernot Hillier <ghillie@suse.de> (StdOut output support)
|
||||
// Ulf Zibis <ulf.zibis@gmx.de> (Resolution preserving output, Cleanups,
|
||||
// inheritance from CFile, destructor handling, preserving filetime)
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: output.cpp,v 1.5 2009/04/28 19:02:08 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include <cstring>
|
||||
#include <cassert>
|
||||
#include <iostream>
|
||||
|
||||
#include <boost/filesystem/path.hpp>
|
||||
#include <boost/filesystem/convenience.hpp>
|
||||
|
||||
#ifdef WIN32
|
||||
#include <io.h>
|
||||
#endif
|
||||
|
||||
#include "sfftypes.h"
|
||||
#include "common.h"
|
||||
|
||||
extern "C"
|
||||
{
|
||||
#define XMD_H
|
||||
#include <jpeglib.h>
|
||||
#include <tiffio.h>
|
||||
}
|
||||
|
||||
#include "codes.h"
|
||||
#include "decoder.h"
|
||||
#include "output.h"
|
||||
|
||||
using namespace std;
|
||||
namespace fs = boost::filesystem;
|
||||
|
||||
//-Constants-------------------------------------------------------
|
||||
|
||||
TBitMapFileHeader CBMPFilter::m_bmpHeader =
|
||||
{
|
||||
0x4d42, /* magic 'BM' */
|
||||
0, /* filesize */
|
||||
0, /* reserved */
|
||||
0, /* reserved */
|
||||
sizeof(TBitMapFileHeader), /* offset to bitmap data */
|
||||
0x28, /* length of bitmap info header 0x28 -> Windows BMP */
|
||||
0, /* width in pixels */
|
||||
0, /* height in pixels */
|
||||
1, /* no. of planes */
|
||||
1, /* bpp -> monochrome */
|
||||
0, /* compression -> none */
|
||||
0, /* size of bitmap data in bytes rounded to 4 byte boundary */
|
||||
0, /* horz. resolution in pixels/meter */
|
||||
0, /* vert. resolution in pixels/meter */
|
||||
2, /* no. of colours */
|
||||
2, /* no. of important colours */
|
||||
{ 255,255,255, 0 }, /* palette */
|
||||
{ 0, 0, 0, 0 }
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
CBitSink& COutputFilter::GetBitSink()
|
||||
{
|
||||
m_sink.Reset();
|
||||
return m_sink;
|
||||
}
|
||||
|
||||
void COutputFilter::BlankLine()
|
||||
{
|
||||
::memset(m_abBuffer, 0x00, sizeof(m_abBuffer));
|
||||
}
|
||||
|
||||
void COutputFilter::Init(CFile *pFile)
|
||||
{
|
||||
m_pFile = pFile;
|
||||
}
|
||||
|
||||
void COutputFilter::EndPage()
|
||||
{
|
||||
}
|
||||
|
||||
void COutputFilter::Finalize()
|
||||
{
|
||||
// base class does nothing
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
void CBMPFilter::BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi)
|
||||
{
|
||||
assert(m_pFile);
|
||||
|
||||
m_bmpHeader.dwPixelWidth = aWidth;
|
||||
m_bmpHeader.dwPixelHeight = aHeight;
|
||||
m_bmpHeader.dwPixelWidthPerMeter = (aDpi*10000+127)/254;
|
||||
m_bmpHeader.dwPixelHeightPerMeter = (aLpi*10000+127)/254;
|
||||
m_bmpHeader.dwSizeImage = (m_bmpHeader.dwPixelWidth >> 3) * m_bmpHeader.dwPixelHeight;
|
||||
m_nLineToWrite = aHeight;
|
||||
|
||||
m_pFile->Seek(0, CFile::sk_from_start);
|
||||
m_pFile->Write(&m_bmpHeader, sizeof(m_bmpHeader));
|
||||
}
|
||||
|
||||
void CBMPFilter::WriteLine()
|
||||
{
|
||||
assert(m_pFile);
|
||||
|
||||
sff_dword dwBytesPerLine = (m_bmpHeader.dwPixelWidth >> 3);
|
||||
/* we write lines from the end to the top of the file */
|
||||
if (m_nLineToWrite-- > 0) {
|
||||
m_pFile->Seek(dwBytesPerLine * m_nLineToWrite + sizeof(m_bmpHeader), CFile::sk_from_start);
|
||||
m_pFile->Write(m_abBuffer, dwBytesPerLine);
|
||||
}
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
void CPBMFilter::BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi)
|
||||
{
|
||||
char acBuf[50];
|
||||
|
||||
assert(m_pFile);
|
||||
|
||||
m_Width = aWidth;
|
||||
m_pFile->Seek(0, CFile::sk_from_start);
|
||||
sprintf(acBuf, "%s", "P4\n");
|
||||
m_pFile->Write(acBuf, strlen(acBuf));
|
||||
sprintf(acBuf, "%s", "# generated with SffToBmp\n");
|
||||
m_pFile->Write(acBuf, strlen(acBuf));
|
||||
sprintf(acBuf, "%ld %ld\n", (long int) aWidth, (long int) aHeight);
|
||||
m_pFile->Write(acBuf, strlen(acBuf));
|
||||
}
|
||||
|
||||
void CPBMFilter::WriteLine()
|
||||
{
|
||||
assert(m_pFile);
|
||||
m_pFile->Write(m_abBuffer, m_Width >> 3);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
void CJPEGFilter::BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi)
|
||||
{
|
||||
assert(m_pFile);
|
||||
memset(&m_cinfo, 0, sizeof(m_cinfo));
|
||||
m_cinfo.err = jpeg_std_error(&m_jerr);
|
||||
jpeg_create_compress(&m_cinfo);
|
||||
m_cinfo.in_color_space = JCS_GRAYSCALE;
|
||||
jpeg_set_defaults(&m_cinfo);
|
||||
m_cinfo.image_width = aWidth;
|
||||
m_cinfo.image_height = aHeight;
|
||||
m_cinfo.input_components = 1;
|
||||
m_cinfo.dct_method = JDCT_FLOAT;
|
||||
m_cinfo.density_unit = 1;
|
||||
m_cinfo.X_density = aDpi;
|
||||
m_cinfo.Y_density = aLpi;
|
||||
jpeg_stdio_dest(&m_cinfo, m_pFile->GetFP());
|
||||
jpeg_set_quality(&m_cinfo, m_quality, FALSE);
|
||||
jpeg_set_colorspace(&m_cinfo, JCS_GRAYSCALE);
|
||||
jpeg_start_compress(&m_cinfo, TRUE);
|
||||
}
|
||||
|
||||
void CJPEGFilter::WriteLine()
|
||||
{
|
||||
m_row_pointer[0] = m_abBuffer;
|
||||
jpeg_write_scanlines(&m_cinfo, m_row_pointer, 1);
|
||||
}
|
||||
|
||||
void CJPEGFilter::EndPage()
|
||||
{
|
||||
assert(m_pFile);
|
||||
jpeg_finish_compress(&m_cinfo);
|
||||
jpeg_destroy_compress(&m_cinfo);
|
||||
}
|
||||
|
||||
CBitSink& CJPEGFilter::GetBitSink()
|
||||
{
|
||||
m_bytesink.Reset();
|
||||
return m_bytesink;
|
||||
}
|
||||
|
||||
void CJPEGFilter::BlankLine()
|
||||
{
|
||||
::memset(m_abBuffer, 0xFF, sizeof(m_abBuffer));
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
void CTIFFFilter::Init(CFile *pFile)
|
||||
{
|
||||
COutputFilter::Init(pFile);
|
||||
}
|
||||
|
||||
void CTIFFFilter::BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi)
|
||||
{
|
||||
tm *pTime;
|
||||
char acTime[25];
|
||||
|
||||
if (!m_tiffFile) {
|
||||
#ifndef WIN32
|
||||
m_tiffFile = TIFFFdOpen(m_pFile->GetFN(), m_pFile->GetFileName(), "w");
|
||||
#else
|
||||
m_tiffFile = TIFFFdOpen(_get_osfhandle(m_pFile->GetFN()),
|
||||
m_pFile->GetFileName(), "w");
|
||||
#endif
|
||||
}
|
||||
m_nRow = 0;
|
||||
// --- TIFF required:
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_SUBFILETYPE, FILETYPE_PAGE);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_IMAGEWIDTH, aWidth);
|
||||
// TIFFTAG_IMAGELENGTH ...automaticaly set by TIFFWriteScanline()
|
||||
// TIFFTAG_STRIPOFFSETS ...automaticaly set by TIFFWriteScanline()
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_ROWSPERSTRIP, aHeight);
|
||||
// TIFFTAG_STRIPBYTECOUNTS ...automaticaly set by TIFFWriteScanline()
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_XRESOLUTION, (float)aDpi);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_YRESOLUTION, (float)aLpi);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_RESOLUTIONUNIT, RESUNIT_INCH);
|
||||
// --- Class B required:
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_BITSPERSAMPLE, 1);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_COMPRESSION, m_wCompression);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_PHOTOMETRIC, PHOTOMETRIC_MINISWHITE);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_SAMPLESPERPIXEL, 1);
|
||||
// --- Class F required:
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_FAXMODE, FAXMODE_CLASSF);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_FILLORDER, FILLORDER_MSB2LSB);
|
||||
if (m_wCompression == COMPRESSION_CCITTFAX3) {
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_GROUP3OPTIONS, GROUP3OPT_FILLBITS|GROUP3OPT_2DENCODING);
|
||||
}
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_PAGENUMBER, aPage, m_nPageCount);
|
||||
// --- Class F recommended:
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_ORIENTATION, ORIENTATION_TOPLEFT);
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_SOFTWARE, "SffToBmp");
|
||||
// - Some viewers interpret this as fax sender
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_IMAGEDESCRIPTION, "");
|
||||
// - Some viewers interpret this as receive time
|
||||
// - Has to be exactly 19 chars: 2007-01-01 24:00:00
|
||||
if ((pTime = ::gmtime(&m_nModTime))) {
|
||||
strftime(acTime, 20, "%Y-%m-%d %H:%M:%S", pTime);
|
||||
}
|
||||
acTime[19]='\0';
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_DATETIME, acTime);
|
||||
// - not recommended, but required by TIFFWriteScanline(); why ?:
|
||||
TIFFSetField(m_tiffFile, TIFFTAG_PLANARCONFIG, PLANARCONFIG_CONTIG);
|
||||
//TIFFSetWarningHandler(NULL);
|
||||
}
|
||||
|
||||
void CTIFFFilter::WriteLine()
|
||||
{
|
||||
if (m_tiffFile) {
|
||||
TIFFWriteScanline(m_tiffFile, m_abBuffer, m_nRow++,0);
|
||||
}
|
||||
}
|
||||
|
||||
void CTIFFFilter::EndPage()
|
||||
{
|
||||
TIFFWriteDirectory(m_tiffFile);
|
||||
}
|
||||
|
||||
void CTIFFFilter::Finalize()
|
||||
{
|
||||
if (m_tiffFile) {
|
||||
TIFFClose(m_tiffFile);
|
||||
}
|
||||
m_tiffFile = NULL;
|
||||
}
|
||||
|
|
@ -0,0 +1,203 @@
|
|||
#ifndef __OUTPUT_H__
|
||||
#define __OUTPUT_H__
|
||||
//
|
||||
// Headerfile for output classes
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// Gernot Hillier <ghillie@suse.de> (StdOut output support)
|
||||
// Ulf Zibis <ulf.zibis@gmx.de> (Resolution preserving output, Cleanups,
|
||||
// inheritance from CFile, destructor handling, preserving filetime)
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: output.h,v 1.4 2009/08/23 12:58:37 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#include "decoder.h"
|
||||
|
||||
#pragma pack(1)
|
||||
|
||||
typedef struct {
|
||||
sff_byte bBlue;
|
||||
sff_byte bGreen;
|
||||
sff_byte bRed;
|
||||
sff_byte bNOP;
|
||||
} TBmpRGB;
|
||||
|
||||
typedef struct {
|
||||
sff_word wType;
|
||||
sff_dword dwFileSize;
|
||||
sff_word wNOP1;
|
||||
sff_word wNOP2;
|
||||
sff_dword dwOffset;
|
||||
sff_dword dwBitmapSize;
|
||||
sff_dword dwPixelWidth;
|
||||
sff_dword dwPixelHeight;
|
||||
sff_word wPlanes;
|
||||
sff_word wCountBits;
|
||||
sff_dword dwCompression;
|
||||
sff_dword dwSizeImage;
|
||||
sff_dword dwPixelWidthPerMeter;
|
||||
sff_dword dwPixelHeightPerMeter;
|
||||
sff_dword dwUsedColors;
|
||||
sff_dword dwImportantColors;
|
||||
TBmpRGB sCol1;
|
||||
TBmpRGB sCol2;
|
||||
} TBitMapFileHeader;
|
||||
|
||||
#pragma pack()
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class COutputFilter
|
||||
{
|
||||
protected:
|
||||
CBitSink m_sink;
|
||||
sff_byte m_abBuffer[5120];
|
||||
sff_word m_nPageCount;
|
||||
std::string m_strExtension;
|
||||
CFile *m_pFile;
|
||||
|
||||
public:
|
||||
COutputFilter(const std::string& strExt, sff_word nPagecount) :
|
||||
m_strExtension(strExt),
|
||||
m_nPageCount(nPagecount),
|
||||
m_sink(m_abBuffer, sizeof(m_abBuffer))
|
||||
{ /* nth. else */ }
|
||||
|
||||
virtual void Init(CFile *pFile);
|
||||
virtual void BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi) = 0;
|
||||
virtual void EndPage();
|
||||
virtual void Finalize();
|
||||
|
||||
virtual CBitSink& GetBitSink();
|
||||
virtual void BlankLine();
|
||||
virtual void WriteLine() = 0;
|
||||
|
||||
const std::string& GetExtension() { return m_strExtension; };
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CBMPFilter : public COutputFilter
|
||||
{
|
||||
protected:
|
||||
static TBitMapFileHeader m_bmpHeader;
|
||||
int m_nLineToWrite;
|
||||
|
||||
public:
|
||||
CBMPFilter(sff_word nPagecount) :
|
||||
COutputFilter(".bmp", nPagecount)
|
||||
{ /* nth. else */ };
|
||||
|
||||
void BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi);
|
||||
void WriteLine();
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CPBMFilter : public COutputFilter
|
||||
{
|
||||
protected:
|
||||
sff_dword m_Width;
|
||||
|
||||
public:
|
||||
CPBMFilter(sff_word nPagecount) :
|
||||
COutputFilter(".pbm", nPagecount)
|
||||
{ /* nth. else */ };
|
||||
|
||||
void BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi);
|
||||
void WriteLine();
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CJPEGFilter : public COutputFilter
|
||||
{
|
||||
protected:
|
||||
CByteSink m_bytesink;
|
||||
jpeg_compress_struct m_cinfo;
|
||||
jpeg_error_mgr m_jerr;
|
||||
JSAMPROW m_row_pointer[1];
|
||||
int m_quality;
|
||||
|
||||
public:
|
||||
CJPEGFilter(sff_word nPagecount, int nQuality = 40) :
|
||||
COutputFilter(".jpg", nPagecount),
|
||||
m_quality(nQuality),
|
||||
m_bytesink(m_abBuffer, sizeof(m_abBuffer))
|
||||
{ /* nth. else */ };
|
||||
|
||||
CBitSink& GetBitSink();
|
||||
void BlankLine();
|
||||
|
||||
void BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi);
|
||||
void WriteLine();
|
||||
void EndPage();
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
|
||||
class CTIFFFilter : public COutputFilter
|
||||
{
|
||||
protected:
|
||||
TIFF * m_tiffFile;
|
||||
TIFFErrorHandler m_terr;
|
||||
unsigned m_nRow;
|
||||
sff_dword m_wCompression;
|
||||
time_t m_nModTime;
|
||||
|
||||
public:
|
||||
CTIFFFilter(sff_word nPagecount, sff_word nCompression, time_t nModTime) :
|
||||
COutputFilter(".tif", nPagecount),
|
||||
m_wCompression(nCompression),
|
||||
m_tiffFile(NULL),
|
||||
m_nModTime(nModTime)
|
||||
{ /* nth. else */ };
|
||||
|
||||
void Init(CFile *pFile);
|
||||
|
||||
void BeginPage(sff_dword aPage, sff_dword aWidth,
|
||||
sff_dword aHeight, sff_word aDpi,
|
||||
sff_word aLpi);
|
||||
void WriteLine();
|
||||
void EndPage();
|
||||
void Finalize();
|
||||
};
|
||||
|
||||
#endif // __OUTPUT_H__
|
|
@ -0,0 +1,66 @@
|
|||
#ifndef __SFFTYPES_H__
|
||||
#define __SFFTYPES_H__
|
||||
//
|
||||
// Headerfile for general types for sfftobmp
|
||||
//
|
||||
// This file is part of sfftobmp, a program to convert
|
||||
// structured fax files (sff) to windows bitmap files (bmp),
|
||||
// portable bitmap graphics (pbm), tagged image file format (tiff)
|
||||
// or JPEG (jpg).
|
||||
//
|
||||
// Copyright (C) 1998-2012 Peter Schaefer-Hutter and contributors ("THE AUTHORS")
|
||||
//
|
||||
// Permission to use, copy, modify, distribute, and sell this software and
|
||||
// its documentation for any purpose is hereby granted without fee.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
||||
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
//
|
||||
// IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL,
|
||||
// INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
|
||||
// DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
||||
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY
|
||||
// THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
|
||||
// OR PERFORMANCE OF THIS SOFTWARE.
|
||||
//
|
||||
// Contributor(s):
|
||||
// None
|
||||
//
|
||||
// You can contact the original author by email at peter.schaefer@gmx.de.
|
||||
//
|
||||
// I'm always pleased to hear that somebody is actually using my software.
|
||||
// If you can manage it, e-mail me a quick notice. Thanks!
|
||||
//
|
||||
/*-RCS-Info----------------------------------------------------
|
||||
|
||||
$Id: sfftypes.h,v 1.3 2008/09/13 13:06:26 pschaefer Exp $
|
||||
|
||||
---RCS-Info--------------------------------------------------*/
|
||||
|
||||
#if !defined(__WINDOWS__) && (defined(_WINDOWS) || defined(_Windows))
|
||||
#define __WINDOWS__
|
||||
#endif
|
||||
#if !defined(__WIN32__) && (defined(_WIN32) || defined(WIN32))
|
||||
#define __WIN32__
|
||||
#endif
|
||||
#if defined(__WIN32__) || defined(__WINDOWS__)
|
||||
#include <windows.h>
|
||||
#ifdef __WIN32__
|
||||
DECLARE_HANDLE(uhandle_t); /* Win32 file handle */
|
||||
#else
|
||||
typedef HFILE uhandle_t; /* Windows file handle */
|
||||
#endif
|
||||
#else
|
||||
typedef void* uhandle_t; /* client data handle */
|
||||
#endif
|
||||
|
||||
typedef unsigned char sff_byte;
|
||||
typedef unsigned short sff_word;
|
||||
typedef unsigned int sff_dword;
|
||||
|
||||
#ifndef _MAX_PATH
|
||||
#define _MAX_PATH 256
|
||||
#endif
|
||||
|
||||
#endif // __SFFTYPES_H__
|
|
@ -0,0 +1 @@
|
|||
*.exe
|
|
@ -0,0 +1,75 @@
|
|||
#
|
||||
# Makefile for MS Visual C (nmake)
|
||||
#
|
||||
# Build command:
|
||||
# nmake /f makefile.vc
|
||||
#
|
||||
# Without debug info:
|
||||
# nmake nodebug=1 /f makefile.vc
|
||||
|
||||
!include <win32.mak>
|
||||
|
||||
INCL = -I. -Ilibjpeg -Ilibtiff/libtiff -Iboost
|
||||
|
||||
LIBTIFF=libtiff\libtiff\libtiff.lib
|
||||
LIBJPEG=libjpeg\libjpeg.lib
|
||||
|
||||
EXE=sfftobmp.exe
|
||||
|
||||
CFLAGS= /D_CRT_SECURE_NO_DEPRECATE $(cflags) $(cdebug) $(cvars)
|
||||
CPPFLAGS= /EHsc /D_CRT_SECURE_NO_DEPRECATE /DBOOST_ALL_NO_LIB $(INCL) $(cppflags) $(cflags) $(cdebug) $(cvars)
|
||||
LDFLAGS= $(ldebug) $(conlflags)
|
||||
LDLIBS= $(conlibs) $(LIBJPEG) $(LIBTIFF)
|
||||
|
||||
OBJ = \
|
||||
..\src\cmdline.obj \
|
||||
..\src\codes.obj \
|
||||
..\src\common.obj \
|
||||
..\src\decoder.obj \
|
||||
..\src\input.obj \
|
||||
..\src\main.obj \
|
||||
..\src\my_getopt.obj \
|
||||
..\src\output.obj \
|
||||
boost\libs\system\src\error_code.obj \
|
||||
boost\libs\filesystem\src\operations.obj \
|
||||
boost\libs\filesystem\src\path.obj \
|
||||
boost\libs\filesystem\src\portability.obj \
|
||||
boost\libs\filesystem\src\utf8_codecvt_facet.obj
|
||||
|
||||
# Template command for compiling .c to .obj
|
||||
.c.obj:
|
||||
$(cc) $(CFLAGS) $*.c /Fo$@
|
||||
|
||||
# Template command for compiling .c to .obj
|
||||
.cpp.obj:
|
||||
$(CPP) $(CPPFLAGS) $*.cpp /Fo$@
|
||||
|
||||
all: $(LIBJPEG) $(LIBTIFF) $(EXE)
|
||||
|
||||
$(LIBJPEG):
|
||||
cd libjpeg
|
||||
$(MAKE) /f Makefile.vc
|
||||
cd..
|
||||
|
||||
$(LIBTIFF):
|
||||
cd libtiff
|
||||
$(MAKE) /f Makefile.vc
|
||||
cd..
|
||||
|
||||
$(EXE): $(LIBTIFF) $(LIBJPEG) $(OBJ)
|
||||
$(link) $(LDFLAGS) $(LDLIBS) $(OBJ) -out:$(EXE)
|
||||
|
||||
clean:
|
||||
cd libtiff
|
||||
$(MAKE) /f Makefile.vc clean
|
||||
cd..
|
||||
cd libjpeg
|
||||
$(MAKE) /f Makefile.vc clean
|
||||
cd..
|
||||
-del *.exe
|
||||
-del *.ilk
|
||||
-del *.dll.manifest
|
||||
-del *.exe.manifest
|
||||
-del *.exp
|
||||
-del *.pdb
|
||||
-del $(OBJ)
|
|
@ -0,0 +1,23 @@
|
|||
Boost Software License - Version 1.0 - August 17th, 2003
|
||||
|
||||
Permission is hereby granted, free of charge, to any person or organization
|
||||
obtaining a copy of the software and accompanying documentation covered by
|
||||
this license (the "Software") to use, reproduce, display, distribute,
|
||||
execute, and transmit the Software, and to prepare derivative works of the
|
||||
Software, and to permit third-parties to whom the Software is furnished to
|
||||
do so, all subject to the following:
|
||||
|
||||
The copyright notices in the Software and this entire statement, including
|
||||
the above license grant, this restriction and the following disclaimer,
|
||||
must be included in all copies of the Software, in whole or in part, and
|
||||
all derivative works of the Software, unless such copies or derivative
|
||||
works are solely in the form of machine-executable object code generated by
|
||||
a source language processor.
|
||||
|
||||
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, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
DEALINGS IN THE SOFTWARE.
|
|
@ -0,0 +1,5 @@
|
|||
Boost libraries version 1.39.0
|
||||
|
||||
NOTE: This is a subset of the boost libraries, sufficient to compile sfftobmp.
|
||||
|
||||
See http://www.boost.org for more!
|
|
@ -0,0 +1,50 @@
|
|||
//
|
||||
// boost/assert.hpp - BOOST_ASSERT(expr)
|
||||
//
|
||||
// Copyright (c) 2001, 2002 Peter Dimov and Multi Media Ltd.
|
||||
// Copyright (c) 2007 Peter Dimov
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// Note: There are no include guards. This is intentional.
|
||||
//
|
||||
// See http://www.boost.org/libs/utility/assert.html for documentation.
|
||||
//
|
||||
|
||||
#undef BOOST_ASSERT
|
||||
|
||||
#if defined(BOOST_DISABLE_ASSERTS)
|
||||
|
||||
# define BOOST_ASSERT(expr) ((void)0)
|
||||
|
||||
#elif defined(BOOST_ENABLE_ASSERT_HANDLER)
|
||||
|
||||
#include <boost/current_function.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
|
||||
void assertion_failed(char const * expr, char const * function, char const * file, long line); // user defined
|
||||
|
||||
} // namespace boost
|
||||
|
||||
#define BOOST_ASSERT(expr) ((expr)? ((void)0): ::boost::assertion_failed(#expr, BOOST_CURRENT_FUNCTION, __FILE__, __LINE__))
|
||||
|
||||
#else
|
||||
# include <assert.h> // .h to support old libraries w/o <cassert> - effect is the same
|
||||
# define BOOST_ASSERT(expr) assert(expr)
|
||||
#endif
|
||||
|
||||
#undef BOOST_VERIFY
|
||||
|
||||
#if defined(BOOST_DISABLE_ASSERTS) || ( !defined(BOOST_ENABLE_ASSERT_HANDLER) && defined(NDEBUG) )
|
||||
|
||||
# define BOOST_VERIFY(expr) ((void)(expr))
|
||||
|
||||
#else
|
||||
|
||||
# define BOOST_VERIFY(expr) BOOST_ASSERT(expr)
|
||||
|
||||
#endif
|
|
@ -0,0 +1,331 @@
|
|||
// Boost cerrno.hpp header -------------------------------------------------//
|
||||
|
||||
// Copyright Beman Dawes 2005.
|
||||
// Use, modification, and distribution is subject to the Boost Software
|
||||
// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See library home page at http://www.boost.org/libs/system
|
||||
|
||||
#ifndef BOOST_CERRNO_HPP
|
||||
#define BOOST_CERRNO_HPP
|
||||
|
||||
#include <cerrno>
|
||||
|
||||
// supply errno values likely to be missing, particularly on Windows
|
||||
|
||||
#ifndef EAFNOSUPPORT
|
||||
#define EAFNOSUPPORT 9901
|
||||
#endif
|
||||
|
||||
#ifndef EADDRINUSE
|
||||
#define EADDRINUSE 9902
|
||||
#endif
|
||||
|
||||
#ifndef EADDRNOTAVAIL
|
||||
#define EADDRNOTAVAIL 9903
|
||||
#endif
|
||||
|
||||
#ifndef EISCONN
|
||||
#define EISCONN 9904
|
||||
#endif
|
||||
|
||||
#ifndef EBADMSG
|
||||
#define EBADMSG 9905
|
||||
#endif
|
||||
|
||||
#ifndef ECONNABORTED
|
||||
#define ECONNABORTED 9906
|
||||
#endif
|
||||
|
||||
#ifndef EALREADY
|
||||
#define EALREADY 9907
|
||||
#endif
|
||||
|
||||
#ifndef ECONNREFUSED
|
||||
#define ECONNREFUSED 9908
|
||||
#endif
|
||||
|
||||
#ifndef ECONNRESET
|
||||
#define ECONNRESET 9909
|
||||
#endif
|
||||
|
||||
#ifndef EDESTADDRREQ
|
||||
#define EDESTADDRREQ 9910
|
||||
#endif
|
||||
|
||||
#ifndef EHOSTUNREACH
|
||||
#define EHOSTUNREACH 9911
|
||||
#endif
|
||||
|
||||
#ifndef EIDRM
|
||||
#define EIDRM 9912
|
||||
#endif
|
||||
|
||||
#ifndef EMSGSIZE
|
||||
#define EMSGSIZE 9913
|
||||
#endif
|
||||
|
||||
#ifndef ENETDOWN
|
||||
#define ENETDOWN 9914
|
||||
#endif
|
||||
|
||||
#ifndef ENETRESET
|
||||
#define ENETRESET 9915
|
||||
#endif
|
||||
|
||||
#ifndef ENETUNREACH
|
||||
#define ENETUNREACH 9916
|
||||
#endif
|
||||
|
||||
#ifndef ENOBUFS
|
||||
#define ENOBUFS 9917
|
||||
#endif
|
||||
|
||||
#ifndef ENOLINK
|
||||
#define ENOLINK 9918
|
||||
#endif
|
||||
|
||||
#ifndef ENODATA
|
||||
#define ENODATA 9919
|
||||
#endif
|
||||
|
||||
#ifndef ENOMSG
|
||||
#define ENOMSG 9920
|
||||
#endif
|
||||
|
||||
#ifndef ENOPROTOOPT
|
||||
#define ENOPROTOOPT 9921
|
||||
#endif
|
||||
|
||||
#ifndef ENOSR
|
||||
#define ENOSR 9922
|
||||
#endif
|
||||
|
||||
#ifndef ENOTSOCK
|
||||
#define ENOTSOCK 9923
|
||||
#endif
|
||||
|
||||
#ifndef ENOSTR
|
||||
#define ENOSTR 9924
|
||||
#endif
|
||||
|
||||
#ifndef ENOTCONN
|
||||
#define ENOTCONN 9925
|
||||
#endif
|
||||
|
||||
#ifndef ENOTSUP
|
||||
#define ENOTSUP 9926
|
||||
#endif
|
||||
|
||||
#ifndef ECANCELED
|
||||
#define ECANCELED 9927
|
||||
#endif
|
||||
|
||||
#ifndef EINPROGRESS
|
||||
#define EINPROGRESS 9928
|
||||
#endif
|
||||
|
||||
#ifndef EOPNOTSUPP
|
||||
#define EOPNOTSUPP 9929
|
||||
#endif
|
||||
|
||||
#ifndef EWOULDBLOCK
|
||||
#define EWOULDBLOCK 9930
|
||||
#endif
|
||||
|
||||
#ifndef EOWNERDEAD
|
||||
#define EOWNERDEAD 9931
|
||||
#endif
|
||||
|
||||
#ifndef EPROTO
|
||||
#define EPROTO 9932
|
||||
#endif
|
||||
|
||||
#ifndef EPROTONOSUPPORT
|
||||
#define EPROTONOSUPPORT 9933
|
||||
#endif
|
||||
|
||||
#ifndef ENOTRECOVERABLE
|
||||
#define ENOTRECOVERABLE 9934
|
||||
#endif
|
||||
|
||||
#ifndef ETIME
|
||||
#define ETIME 9935
|
||||
#endif
|
||||
|
||||
#ifndef ETXTBSY
|
||||
#define ETXTBSY 9936
|
||||
#endif
|
||||
|
||||
#ifndef ETIMEDOUT
|
||||
#define ETIMEDOUT 9938
|
||||
#endif
|
||||
|
||||
#ifndef ELOOP
|
||||
#define ELOOP 9939
|
||||
#endif
|
||||
|
||||
#ifndef EOVERFLOW
|
||||
#define EOVERFLOW 9940
|
||||
#endif
|
||||
|
||||
#ifndef EPROTOTYPE
|
||||
#define EPROTOTYPE 9941
|
||||
#endif
|
||||
|
||||
#ifndef ENOSYS
|
||||
#define ENOSYS 9942
|
||||
#endif
|
||||
|
||||
#ifndef EINVAL
|
||||
#define EINVAL 9943
|
||||
#endif
|
||||
|
||||
#ifndef ERANGE
|
||||
#define ERANGE 9944
|
||||
#endif
|
||||
|
||||
#ifndef EILSEQ
|
||||
#define EILSEQ 9945
|
||||
#endif
|
||||
|
||||
// Windows Mobile doesn't appear to define these:
|
||||
|
||||
#ifndef E2BIG
|
||||
#define E2BIG 9946
|
||||
#endif
|
||||
|
||||
#ifndef EDOM
|
||||
#define EDOM 9947
|
||||
#endif
|
||||
|
||||
#ifndef EFAULT
|
||||
#define EFAULT 9948
|
||||
#endif
|
||||
|
||||
#ifndef EBADF
|
||||
#define EBADF 9949
|
||||
#endif
|
||||
|
||||
#ifndef EPIPE
|
||||
#define EPIPE 9950
|
||||
#endif
|
||||
|
||||
#ifndef EXDEV
|
||||
#define EXDEV 9951
|
||||
#endif
|
||||
|
||||
#ifndef EBUSY
|
||||
#define EBUSY 9952
|
||||
#endif
|
||||
|
||||
#ifndef ENOTEMPTY
|
||||
#define ENOTEMPTY 9953
|
||||
#endif
|
||||
|
||||
#ifndef ENOEXEC
|
||||
#define ENOEXEC 9954
|
||||
#endif
|
||||
|
||||
#ifndef EEXIST
|
||||
#define EEXIST 9955
|
||||
#endif
|
||||
|
||||
#ifndef EFBIG
|
||||
#define EFBIG 9956
|
||||
#endif
|
||||
|
||||
#ifndef ENAMETOOLONG
|
||||
#define ENAMETOOLONG 9957
|
||||
#endif
|
||||
|
||||
#ifndef ENOTTY
|
||||
#define ENOTTY 9958
|
||||
#endif
|
||||
|
||||
#ifndef EINTR
|
||||
#define EINTR 9959
|
||||
#endif
|
||||
|
||||
#ifndef ESPIPE
|
||||
#define ESPIPE 9960
|
||||
#endif
|
||||
|
||||
#ifndef EIO
|
||||
#define EIO 9961
|
||||
#endif
|
||||
|
||||
#ifndef EISDIR
|
||||
#define EISDIR 9962
|
||||
#endif
|
||||
|
||||
#ifndef ECHILD
|
||||
#define ECHILD 9963
|
||||
#endif
|
||||
|
||||
#ifndef ENOLCK
|
||||
#define ENOLCK 9964
|
||||
#endif
|
||||
|
||||
#ifndef ENOSPC
|
||||
#define ENOSPC 9965
|
||||
#endif
|
||||
|
||||
#ifndef ENXIO
|
||||
#define ENXIO 9966
|
||||
#endif
|
||||
|
||||
#ifndef ENODEV
|
||||
#define ENODEV 9967
|
||||
#endif
|
||||
|
||||
#ifndef ENOENT
|
||||
#define ENOENT 9968
|
||||
#endif
|
||||
|
||||
#ifndef ESRCH
|
||||
#define ESRCH 9969
|
||||
#endif
|
||||
|
||||
#ifndef ENOTDIR
|
||||
#define ENOTDIR 9970
|
||||
#endif
|
||||
|
||||
#ifndef ENOMEM
|
||||
#define ENOMEM 9971
|
||||
#endif
|
||||
|
||||
#ifndef EPERM
|
||||
#define EPERM 9972
|
||||
#endif
|
||||
|
||||
#ifndef EACCES
|
||||
#define EACCES 9973
|
||||
#endif
|
||||
|
||||
#ifndef EROFS
|
||||
#define EROFS 9974
|
||||
#endif
|
||||
|
||||
#ifndef EDEADLK
|
||||
#define EDEADLK 9975
|
||||
#endif
|
||||
|
||||
#ifndef EAGAIN
|
||||
#define EAGAIN 9976
|
||||
#endif
|
||||
|
||||
#ifndef ENFILE
|
||||
#define ENFILE 9977
|
||||
#endif
|
||||
|
||||
#ifndef EMFILE
|
||||
#define EMFILE 9978
|
||||
#endif
|
||||
|
||||
#ifndef EMLINK
|
||||
#define EMLINK 9979
|
||||
#endif
|
||||
|
||||
#endif // include guard
|
|
@ -0,0 +1,69 @@
|
|||
#ifndef BOOST_CHECKED_DELETE_HPP_INCLUDED
|
||||
#define BOOST_CHECKED_DELETE_HPP_INCLUDED
|
||||
|
||||
// MS compatible compilers support #pragma once
|
||||
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||
# pragma once
|
||||
#endif
|
||||
|
||||
//
|
||||
// boost/checked_delete.hpp
|
||||
//
|
||||
// Copyright (c) 2002, 2003 Peter Dimov
|
||||
// Copyright (c) 2003 Daniel Frey
|
||||
// Copyright (c) 2003 Howard Hinnant
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/utility/checked_delete.html for documentation.
|
||||
//
|
||||
|
||||
namespace boost
|
||||
{
|
||||
|
||||
// verify that types are complete for increased safety
|
||||
|
||||
template<class T> inline void checked_delete(T * x)
|
||||
{
|
||||
// intentionally complex - simplification causes regressions
|
||||
typedef char type_must_be_complete[ sizeof(T)? 1: -1 ];
|
||||
(void) sizeof(type_must_be_complete);
|
||||
delete x;
|
||||
}
|
||||
|
||||
template<class T> inline void checked_array_delete(T * x)
|
||||
{
|
||||
typedef char type_must_be_complete[ sizeof(T)? 1: -1 ];
|
||||
(void) sizeof(type_must_be_complete);
|
||||
delete [] x;
|
||||
}
|
||||
|
||||
template<class T> struct checked_deleter
|
||||
{
|
||||
typedef void result_type;
|
||||
typedef T * argument_type;
|
||||
|
||||
void operator()(T * x) const
|
||||
{
|
||||
// boost:: disables ADL
|
||||
boost::checked_delete(x);
|
||||
}
|
||||
};
|
||||
|
||||
template<class T> struct checked_array_deleter
|
||||
{
|
||||
typedef void result_type;
|
||||
typedef T * argument_type;
|
||||
|
||||
void operator()(T * x) const
|
||||
{
|
||||
boost::checked_array_delete(x);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace boost
|
||||
|
||||
#endif // #ifndef BOOST_CHECKED_DELETE_HPP_INCLUDED
|
|
@ -0,0 +1,70 @@
|
|||
// Boost config.hpp configuration header file ------------------------------//
|
||||
|
||||
// (C) Copyright John Maddock 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org/libs/config for most recent version.
|
||||
|
||||
// Boost config.hpp policy and rationale documentation has been moved to
|
||||
// http://www.boost.org/libs/config
|
||||
//
|
||||
// CAUTION: This file is intended to be completely stable -
|
||||
// DO NOT MODIFY THIS FILE!
|
||||
//
|
||||
|
||||
#ifndef BOOST_CONFIG_HPP
|
||||
#define BOOST_CONFIG_HPP
|
||||
|
||||
// if we don't have a user config, then use the default location:
|
||||
#if !defined(BOOST_USER_CONFIG) && !defined(BOOST_NO_USER_CONFIG)
|
||||
# define BOOST_USER_CONFIG <boost/config/user.hpp>
|
||||
#endif
|
||||
// include it first:
|
||||
#ifdef BOOST_USER_CONFIG
|
||||
# include BOOST_USER_CONFIG
|
||||
#endif
|
||||
|
||||
// if we don't have a compiler config set, try and find one:
|
||||
#if !defined(BOOST_COMPILER_CONFIG) && !defined(BOOST_NO_COMPILER_CONFIG) && !defined(BOOST_NO_CONFIG)
|
||||
# include <boost/config/select_compiler_config.hpp>
|
||||
#endif
|
||||
// if we have a compiler config, include it now:
|
||||
#ifdef BOOST_COMPILER_CONFIG
|
||||
# include BOOST_COMPILER_CONFIG
|
||||
#endif
|
||||
|
||||
// if we don't have a std library config set, try and find one:
|
||||
#if !defined(BOOST_STDLIB_CONFIG) && !defined(BOOST_NO_STDLIB_CONFIG) && !defined(BOOST_NO_CONFIG)
|
||||
# include <boost/config/select_stdlib_config.hpp>
|
||||
#endif
|
||||
// if we have a std library config, include it now:
|
||||
#ifdef BOOST_STDLIB_CONFIG
|
||||
# include BOOST_STDLIB_CONFIG
|
||||
#endif
|
||||
|
||||
// if we don't have a platform config set, try and find one:
|
||||
#if !defined(BOOST_PLATFORM_CONFIG) && !defined(BOOST_NO_PLATFORM_CONFIG) && !defined(BOOST_NO_CONFIG)
|
||||
# include <boost/config/select_platform_config.hpp>
|
||||
#endif
|
||||
// if we have a platform config, include it now:
|
||||
#ifdef BOOST_PLATFORM_CONFIG
|
||||
# include BOOST_PLATFORM_CONFIG
|
||||
#endif
|
||||
|
||||
// get config suffix code:
|
||||
#include <boost/config/suffix.hpp>
|
||||
|
||||
#endif // BOOST_CONFIG_HPP
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
// (C) Copyright John Maddock 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// for C++ Builder the following options effect the ABI:
|
||||
//
|
||||
// -b (on or off - effect emum sizes)
|
||||
// -Vx (on or off - empty members)
|
||||
// -Ve (on or off - empty base classes)
|
||||
// -aX (alignment - 5 options).
|
||||
// -pX (Calling convention - 4 options)
|
||||
// -VmX (member pointer size and layout - 5 options)
|
||||
// -VC (on or off, changes name mangling)
|
||||
// -Vl (on or off, changes struct layout).
|
||||
|
||||
// In addition the following warnings are sufficiently annoying (and
|
||||
// unfixable) to have them turned off by default:
|
||||
//
|
||||
// 8027 - functions containing [for|while] loops are not expanded inline
|
||||
// 8026 - functions taking class by value arguments are not expanded inline
|
||||
|
||||
#pragma nopushoptwarn
|
||||
# pragma option push -Vx -Ve -a8 -b -pc -Vmv -VC- -Vl- -w-8027 -w-8026
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
// (C) Copyright John Maddock 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
# pragma option pop
|
||||
#pragma nopushoptwarn
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
// (C) Copyright John Maddock 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
//
|
||||
// Boost binaries are built with the compiler's default ABI settings,
|
||||
// if the user changes their default alignment in the VS IDE then their
|
||||
// code will no longer be binary compatible with the bjam built binaries
|
||||
// unless this header is included to force Boost code into a consistent ABI.
|
||||
//
|
||||
// Note that inclusion of this header is only necessary for libraries with
|
||||
// separate source, header only libraries DO NOT need this as long as all
|
||||
// translation units are built with the same options.
|
||||
//
|
||||
#if defined(_M_X64)
|
||||
# pragma pack(push,16)
|
||||
#else
|
||||
# pragma pack(push,8)
|
||||
#endif
|
||||
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
// (C) Copyright John Maddock 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#pragma pack(pop)
|
||||
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
// abi_prefix header -------------------------------------------------------//
|
||||
|
||||
// (c) Copyright John Maddock 2003
|
||||
|
||||
// Use, modification and distribution are subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt).
|
||||
|
||||
#ifndef BOOST_CONFIG_ABI_PREFIX_HPP
|
||||
# define BOOST_CONFIG_ABI_PREFIX_HPP
|
||||
#else
|
||||
# error double inclusion of header boost/config/abi_prefix.hpp is an error
|
||||
#endif
|
||||
|
||||
#include <boost/config.hpp>
|
||||
|
||||
// this must occur after all other includes and before any code appears:
|
||||
#ifdef BOOST_HAS_ABI_HEADERS
|
||||
# include BOOST_ABI_PREFIX
|
||||
#endif
|
||||
|
||||
#if defined( __BORLANDC__ )
|
||||
#pragma nopushoptwarn
|
||||
#endif
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
// abi_sufffix header -------------------------------------------------------//
|
||||
|
||||
// (c) Copyright John Maddock 2003
|
||||
|
||||
// Use, modification and distribution are subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt).
|
||||
|
||||
// This header should be #included AFTER code that was preceded by a #include
|
||||
// <boost/config/abi_prefix.hpp>.
|
||||
|
||||
#ifndef BOOST_CONFIG_ABI_PREFIX_HPP
|
||||
# error Header boost/config/abi_suffix.hpp must only be used after boost/config/abi_prefix.hpp
|
||||
#else
|
||||
# undef BOOST_CONFIG_ABI_PREFIX_HPP
|
||||
#endif
|
||||
|
||||
// the suffix header occurs after all of our code:
|
||||
#ifdef BOOST_HAS_ABI_HEADERS
|
||||
# include BOOST_ABI_SUFFIX
|
||||
#endif
|
||||
|
||||
#if defined( __BORLANDC__ )
|
||||
#pragma nopushoptwarn
|
||||
#endif
|
||||
|
||||
|
|
@ -0,0 +1,373 @@
|
|||
// (C) Copyright John Maddock 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
/*
|
||||
* LOCATION: see http://www.boost.org for most recent version.
|
||||
* FILE auto_link.hpp
|
||||
* VERSION see <boost/version.hpp>
|
||||
* DESCRIPTION: Automatic library inclusion for Borland/Microsoft compilers.
|
||||
*/
|
||||
|
||||
/*************************************************************************
|
||||
|
||||
USAGE:
|
||||
~~~~~~
|
||||
|
||||
Before including this header you must define one or more of define the following macros:
|
||||
|
||||
BOOST_LIB_NAME: Required: A string containing the basename of the library,
|
||||
for example boost_regex.
|
||||
BOOST_LIB_TOOLSET: Optional: the base name of the toolset.
|
||||
BOOST_DYN_LINK: Optional: when set link to dll rather than static library.
|
||||
BOOST_LIB_DIAGNOSTIC: Optional: when set the header will print out the name
|
||||
of the library selected (useful for debugging).
|
||||
BOOST_AUTO_LINK_NOMANGLE: Specifies that we should link to BOOST_LIB_NAME.lib,
|
||||
rather than a mangled-name version.
|
||||
|
||||
These macros will be undef'ed at the end of the header, further this header
|
||||
has no include guards - so be sure to include it only once from your library!
|
||||
|
||||
Algorithm:
|
||||
~~~~~~~~~~
|
||||
|
||||
Libraries for Borland and Microsoft compilers are automatically
|
||||
selected here, the name of the lib is selected according to the following
|
||||
formula:
|
||||
|
||||
BOOST_LIB_PREFIX
|
||||
+ BOOST_LIB_NAME
|
||||
+ "_"
|
||||
+ BOOST_LIB_TOOLSET
|
||||
+ BOOST_LIB_THREAD_OPT
|
||||
+ BOOST_LIB_RT_OPT
|
||||
"-"
|
||||
+ BOOST_LIB_VERSION
|
||||
|
||||
These are defined as:
|
||||
|
||||
BOOST_LIB_PREFIX: "lib" for static libraries otherwise "".
|
||||
|
||||
BOOST_LIB_NAME: The base name of the lib ( for example boost_regex).
|
||||
|
||||
BOOST_LIB_TOOLSET: The compiler toolset name (vc6, vc7, bcb5 etc).
|
||||
|
||||
BOOST_LIB_THREAD_OPT: "-mt" for multithread builds, otherwise nothing.
|
||||
|
||||
BOOST_LIB_RT_OPT: A suffix that indicates the runtime library used,
|
||||
contains one or more of the following letters after
|
||||
a hiphen:
|
||||
|
||||
s static runtime (dynamic if not present).
|
||||
d debug build (release if not present).
|
||||
g debug/diagnostic runtime (release if not present).
|
||||
p STLPort Build.
|
||||
|
||||
BOOST_LIB_VERSION: The Boost version, in the form x_y, for Boost version x.y.
|
||||
|
||||
|
||||
***************************************************************************/
|
||||
|
||||
#ifdef __cplusplus
|
||||
# ifndef BOOST_CONFIG_HPP
|
||||
# include <boost/config.hpp>
|
||||
# endif
|
||||
#elif defined(_MSC_VER) && !defined(__MWERKS__) && !defined(__EDG_VERSION__)
|
||||
//
|
||||
// C language compatability (no, honestly)
|
||||
//
|
||||
# define BOOST_MSVC _MSC_VER
|
||||
# define BOOST_STRINGIZE(X) BOOST_DO_STRINGIZE(X)
|
||||
# define BOOST_DO_STRINGIZE(X) #X
|
||||
#endif
|
||||
//
|
||||
// Only include what follows for known and supported compilers:
|
||||
//
|
||||
#if defined(BOOST_MSVC) \
|
||||
|| defined(__BORLANDC__) \
|
||||
|| (defined(__MWERKS__) && defined(_WIN32) && (__MWERKS__ >= 0x3000)) \
|
||||
|| (defined(__ICL) && defined(_MSC_EXTENSIONS) && (_MSC_VER >= 1200))
|
||||
|
||||
#ifndef BOOST_VERSION_HPP
|
||||
# include <boost/version.hpp>
|
||||
#endif
|
||||
|
||||
#ifndef BOOST_LIB_NAME
|
||||
# error "Macro BOOST_LIB_NAME not set (internal error)"
|
||||
#endif
|
||||
|
||||
//
|
||||
// error check:
|
||||
//
|
||||
#if defined(__MSVC_RUNTIME_CHECKS) && !defined(_DEBUG)
|
||||
# pragma message("Using the /RTC option without specifying a debug runtime will lead to linker errors")
|
||||
# pragma message("Hint: go to the code generation options and switch to one of the debugging runtimes")
|
||||
# error "Incompatible build options"
|
||||
#endif
|
||||
//
|
||||
// select toolset if not defined already:
|
||||
//
|
||||
#ifndef BOOST_LIB_TOOLSET
|
||||
// Note: no compilers before 1200 are supported
|
||||
#if defined(BOOST_MSVC) && (BOOST_MSVC < 1300)
|
||||
|
||||
# ifdef UNDER_CE
|
||||
// vc6:
|
||||
# define BOOST_LIB_TOOLSET "evc4"
|
||||
# else
|
||||
// vc6:
|
||||
# define BOOST_LIB_TOOLSET "vc6"
|
||||
# endif
|
||||
|
||||
#elif defined(BOOST_MSVC) && (BOOST_MSVC == 1300)
|
||||
|
||||
// vc7:
|
||||
# define BOOST_LIB_TOOLSET "vc7"
|
||||
|
||||
#elif defined(BOOST_MSVC) && (BOOST_MSVC == 1310)
|
||||
|
||||
// vc71:
|
||||
# define BOOST_LIB_TOOLSET "vc71"
|
||||
|
||||
#elif defined(BOOST_MSVC) && (BOOST_MSVC == 1400)
|
||||
|
||||
// vc80:
|
||||
# define BOOST_LIB_TOOLSET "vc80"
|
||||
|
||||
#elif defined(BOOST_MSVC) && (BOOST_MSVC == 1500)
|
||||
|
||||
// vc90:
|
||||
# define BOOST_LIB_TOOLSET "vc90"
|
||||
|
||||
#elif defined(BOOST_MSVC) && (BOOST_MSVC >= 1600)
|
||||
|
||||
// vc10:
|
||||
# define BOOST_LIB_TOOLSET "vc100"
|
||||
|
||||
#elif defined(__BORLANDC__)
|
||||
|
||||
// CBuilder 6:
|
||||
# define BOOST_LIB_TOOLSET "bcb"
|
||||
|
||||
#elif defined(__ICL)
|
||||
|
||||
// Intel C++, no version number:
|
||||
# define BOOST_LIB_TOOLSET "iw"
|
||||
|
||||
#elif defined(__MWERKS__) && (__MWERKS__ <= 0x31FF )
|
||||
|
||||
// Metrowerks CodeWarrior 8.x
|
||||
# define BOOST_LIB_TOOLSET "cw8"
|
||||
|
||||
#elif defined(__MWERKS__) && (__MWERKS__ <= 0x32FF )
|
||||
|
||||
// Metrowerks CodeWarrior 9.x
|
||||
# define BOOST_LIB_TOOLSET "cw9"
|
||||
|
||||
#endif
|
||||
#endif // BOOST_LIB_TOOLSET
|
||||
|
||||
//
|
||||
// select thread opt:
|
||||
//
|
||||
#if defined(_MT) || defined(__MT__)
|
||||
# define BOOST_LIB_THREAD_OPT "-mt"
|
||||
#else
|
||||
# define BOOST_LIB_THREAD_OPT
|
||||
#endif
|
||||
|
||||
#if defined(_MSC_VER) || defined(__MWERKS__)
|
||||
|
||||
# ifdef _DLL
|
||||
|
||||
# if (defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)) && (defined(_STLP_OWN_IOSTREAMS) || defined(__STL_OWN_IOSTREAMS))
|
||||
|
||||
# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))
|
||||
# define BOOST_LIB_RT_OPT "-gdp"
|
||||
# elif defined(_DEBUG)
|
||||
# define BOOST_LIB_RT_OPT "-gdp"
|
||||
# pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
|
||||
# error "Build options aren't compatible with pre-built libraries"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT "-p"
|
||||
# endif
|
||||
|
||||
# elif defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)
|
||||
|
||||
# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))
|
||||
# define BOOST_LIB_RT_OPT "-gdpn"
|
||||
# elif defined(_DEBUG)
|
||||
# define BOOST_LIB_RT_OPT "-gdpn"
|
||||
# pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
|
||||
# error "Build options aren't compatible with pre-built libraries"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT "-pn"
|
||||
# endif
|
||||
|
||||
# else
|
||||
|
||||
# if defined(_DEBUG)
|
||||
# define BOOST_LIB_RT_OPT "-gd"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT
|
||||
# endif
|
||||
|
||||
# endif
|
||||
|
||||
# else
|
||||
|
||||
# if (defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)) && (defined(_STLP_OWN_IOSTREAMS) || defined(__STL_OWN_IOSTREAMS))
|
||||
|
||||
# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))
|
||||
# define BOOST_LIB_RT_OPT "-sgdp"
|
||||
# elif defined(_DEBUG)
|
||||
# define BOOST_LIB_RT_OPT "-sgdp"
|
||||
# pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
|
||||
# error "Build options aren't compatible with pre-built libraries"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT "-sp"
|
||||
# endif
|
||||
|
||||
# elif defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)
|
||||
|
||||
# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))
|
||||
# define BOOST_LIB_RT_OPT "-sgdpn"
|
||||
# elif defined(_DEBUG)
|
||||
# define BOOST_LIB_RT_OPT "-sgdpn"
|
||||
# pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
|
||||
# error "Build options aren't compatible with pre-built libraries"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT "-spn"
|
||||
# endif
|
||||
|
||||
# else
|
||||
|
||||
# if defined(_DEBUG)
|
||||
# define BOOST_LIB_RT_OPT "-sgd"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT "-s"
|
||||
# endif
|
||||
|
||||
# endif
|
||||
|
||||
# endif
|
||||
|
||||
#elif defined(__BORLANDC__)
|
||||
|
||||
//
|
||||
// figure out whether we want the debug builds or not:
|
||||
//
|
||||
#if __BORLANDC__ > 0x561
|
||||
#pragma defineonoption BOOST_BORLAND_DEBUG -v
|
||||
#endif
|
||||
//
|
||||
// sanity check:
|
||||
//
|
||||
#if defined(__STL_DEBUG) || defined(_STLP_DEBUG)
|
||||
#error "Pre-built versions of the Boost libraries are not provided in STLPort-debug form"
|
||||
#endif
|
||||
|
||||
# ifdef _RTLDLL
|
||||
|
||||
# ifdef BOOST_BORLAND_DEBUG
|
||||
# define BOOST_LIB_RT_OPT "-d"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT
|
||||
# endif
|
||||
|
||||
# else
|
||||
|
||||
# ifdef BOOST_BORLAND_DEBUG
|
||||
# define BOOST_LIB_RT_OPT "-sd"
|
||||
# else
|
||||
# define BOOST_LIB_RT_OPT "-s"
|
||||
# endif
|
||||
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
//
|
||||
// select linkage opt:
|
||||
//
|
||||
#if (defined(_DLL) || defined(_RTLDLL)) && defined(BOOST_DYN_LINK)
|
||||
# define BOOST_LIB_PREFIX
|
||||
#elif defined(BOOST_DYN_LINK)
|
||||
# error "Mixing a dll boost library with a static runtime is a really bad idea..."
|
||||
#else
|
||||
# define BOOST_LIB_PREFIX "lib"
|
||||
#endif
|
||||
|
||||
//
|
||||
// now include the lib:
|
||||
//
|
||||
#if defined(BOOST_LIB_NAME) \
|
||||
&& defined(BOOST_LIB_PREFIX) \
|
||||
&& defined(BOOST_LIB_TOOLSET) \
|
||||
&& defined(BOOST_LIB_THREAD_OPT) \
|
||||
&& defined(BOOST_LIB_RT_OPT) \
|
||||
&& defined(BOOST_LIB_VERSION)
|
||||
|
||||
#ifndef BOOST_AUTO_LINK_NOMANGLE
|
||||
# pragma comment(lib, BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT "-" BOOST_LIB_VERSION ".lib")
|
||||
# ifdef BOOST_LIB_DIAGNOSTIC
|
||||
# pragma message ("Linking to lib file: " BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT "-" BOOST_LIB_VERSION ".lib")
|
||||
# endif
|
||||
#else
|
||||
# pragma comment(lib, BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib")
|
||||
# ifdef BOOST_LIB_DIAGNOSTIC
|
||||
# pragma message ("Linking to lib file: " BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib")
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#else
|
||||
# error "some required macros where not defined (internal logic error)."
|
||||
#endif
|
||||
|
||||
|
||||
#endif // _MSC_VER || __BORLANDC__
|
||||
|
||||
//
|
||||
// finally undef any macros we may have set:
|
||||
//
|
||||
#ifdef BOOST_LIB_PREFIX
|
||||
# undef BOOST_LIB_PREFIX
|
||||
#endif
|
||||
#if defined(BOOST_LIB_NAME)
|
||||
# undef BOOST_LIB_NAME
|
||||
#endif
|
||||
// Don't undef this one: it can be set by the user and should be the
|
||||
// same for all libraries:
|
||||
//#if defined(BOOST_LIB_TOOLSET)
|
||||
//# undef BOOST_LIB_TOOLSET
|
||||
//#endif
|
||||
#if defined(BOOST_LIB_THREAD_OPT)
|
||||
# undef BOOST_LIB_THREAD_OPT
|
||||
#endif
|
||||
#if defined(BOOST_LIB_RT_OPT)
|
||||
# undef BOOST_LIB_RT_OPT
|
||||
#endif
|
||||
#if defined(BOOST_LIB_LINK_OPT)
|
||||
# undef BOOST_LIB_LINK_OPT
|
||||
#endif
|
||||
#if defined(BOOST_LIB_DEBUG_OPT)
|
||||
# undef BOOST_LIB_DEBUG_OPT
|
||||
#endif
|
||||
#if defined(BOOST_DYN_LINK)
|
||||
# undef BOOST_DYN_LINK
|
||||
#endif
|
||||
#if defined(BOOST_AUTO_LINK_NOMANGLE)
|
||||
# undef BOOST_AUTO_LINK_NOMANGLE
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,267 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright David Abrahams 2002 - 2003.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Borland C++ compiler setup:
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support Borland prior to version 5.4:
|
||||
#if __BORLANDC__ < 0x540
|
||||
# error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
|
||||
// last known compiler version:
|
||||
#if (__BORLANDC__ > 0x610)
|
||||
//# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
//# else
|
||||
//# pragma message( "Unknown compiler version - please run the configure tests and report the results")
|
||||
//# endif
|
||||
#elif (__BORLANDC__ == 0x600)
|
||||
# error "CBuilderX preview compiler is no longer supported"
|
||||
#endif
|
||||
|
||||
//
|
||||
// Support macros to help with standard library detection
|
||||
#if (__BORLANDC__ < 0x560) || defined(_USE_OLD_RW_STL)
|
||||
# define BOOST_BCB_WITH_ROGUE_WAVE
|
||||
#elif __BORLANDC__ < 0x570
|
||||
# define BOOST_BCB_WITH_STLPORT
|
||||
#else
|
||||
# define BOOST_BCB_WITH_DINKUMWARE
|
||||
#endif
|
||||
|
||||
//
|
||||
// Version 5.0 and below:
|
||||
# if __BORLANDC__ <= 0x0550
|
||||
// Borland C++Builder 4 and 5:
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# if __BORLANDC__ == 0x0550
|
||||
// Borland C++Builder 5, command-line compiler 5.5:
|
||||
# define BOOST_NO_OPERATORS_IN_NAMESPACE
|
||||
# endif
|
||||
# endif
|
||||
|
||||
// Version 5.51 and below:
|
||||
#if (__BORLANDC__ <= 0x551)
|
||||
# define BOOST_NO_CV_SPECIALIZATIONS
|
||||
# define BOOST_NO_CV_VOID_SPECIALIZATIONS
|
||||
# define BOOST_NO_DEDUCED_TYPENAME
|
||||
// workaround for missing WCHAR_MAX/WCHAR_MIN:
|
||||
#include <climits>
|
||||
#include <cwchar>
|
||||
#ifndef WCHAR_MAX
|
||||
# define WCHAR_MAX 0xffff
|
||||
#endif
|
||||
#ifndef WCHAR_MIN
|
||||
# define WCHAR_MIN 0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// Borland C++ Builder 6 and below:
|
||||
#if (__BORLANDC__ <= 0x564)
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
|
||||
# ifdef NDEBUG
|
||||
// fix broken <cstring> so that Boost.test works:
|
||||
# include <cstring>
|
||||
# undef strcmp
|
||||
# endif
|
||||
// fix broken errno declaration:
|
||||
# include <errno.h>
|
||||
# ifndef errno
|
||||
# define errno errno
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
//
|
||||
// new bug in 5.61:
|
||||
#if (__BORLANDC__ >= 0x561) && (__BORLANDC__ <= 0x580)
|
||||
// this seems to be needed by the command line compiler, but not the IDE:
|
||||
# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS
|
||||
#endif
|
||||
|
||||
// Borland C++ Builder 2006 Update 2 and below:
|
||||
#if (__BORLANDC__ <= 0x582)
|
||||
# define BOOST_NO_SFINAE
|
||||
# define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG
|
||||
# define BOOST_NO_TEMPLATE_TEMPLATES
|
||||
|
||||
# define BOOST_NO_PRIVATE_IN_AGGREGATE
|
||||
|
||||
# ifdef _WIN32
|
||||
# define BOOST_NO_SWPRINTF
|
||||
# elif defined(linux) || defined(__linux__) || defined(__linux)
|
||||
// we should really be able to do without this
|
||||
// but the wcs* functions aren't imported into std::
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
// _CPPUNWIND doesn't get automatically set for some reason:
|
||||
# pragma defineonoption BOOST_CPPUNWIND -x
|
||||
# endif
|
||||
#endif
|
||||
|
||||
// Borland C++ Builder 2007 December 2007 Update and below:
|
||||
//#if (__BORLANDC__ <= 0x593)
|
||||
#if (__BORLANDC__ <= 0x610) // Beman has asked Alisdair for more info
|
||||
// we shouldn't really need this - but too many things choke
|
||||
// without it, this needs more investigation:
|
||||
# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# define BOOST_NO_FUNCTION_TYPE_SPECIALIZATIONS
|
||||
|
||||
// Temporary workaround
|
||||
#define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
|
||||
#endif
|
||||
|
||||
// Borland C++ Builder 2008 and below:
|
||||
#if (__BORLANDC__ <= 0x601)
|
||||
# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
# define BOOST_ILLEGAL_CV_REFERENCES
|
||||
# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
# define BOOST_NO_USING_TEMPLATE
|
||||
# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
|
||||
#endif
|
||||
|
||||
//
|
||||
// Positive Feature detection
|
||||
//
|
||||
// Borland C++ Builder 2008 and below:
|
||||
#if (__BORLANDC__ >= 0x599)
|
||||
# pragma defineonoption BOOST_CODEGEAR_0X_SUPPORT -Ax
|
||||
#endif
|
||||
//
|
||||
// C++0x Macros:
|
||||
//
|
||||
#if defined( BOOST_CODEGEAR_0X_SUPPORT ) && (__BORLANDC__ >= 0x610)
|
||||
# define BOOST_HAS_ALIGNOF
|
||||
# define BOOST_HAS_CHAR16_T
|
||||
# define BOOST_HAS_CHAR32_T
|
||||
# define BOOST_HAS_DECLTYPE
|
||||
# define BOOST_HAS_EXPLICIT_CONVERSION_OPS
|
||||
# define BOOST_HAS_REF_QUALIFIER
|
||||
# define BOOST_HAS_RVALUE_REFS
|
||||
# define BOOST_HAS_STATIC_ASSERT
|
||||
|
||||
# define BOOST_NO_EXTERN_TEMPLATE
|
||||
# define BOOST_NO_SCOPED_ENUMS
|
||||
# define BOOST_NO_VARIADIC_TEMPLATES
|
||||
# define BOOST_NO_CONSTEXPR
|
||||
# define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
# define BOOST_NO_DELETED_FUNCTIONS
|
||||
# define BOOST_NO_RAW_LITERALS
|
||||
# define BOOST_NO_UNICODE_LITERALS // UTF-8 still not supported
|
||||
#else
|
||||
# define BOOST_NO_CHAR16_T
|
||||
# define BOOST_NO_CHAR32_T
|
||||
# define BOOST_NO_DECLTYPE
|
||||
# define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
# define BOOST_NO_EXTERN_TEMPLATE
|
||||
# define BOOST_NO_SCOPED_ENUMS
|
||||
# define BOOST_NO_STATIC_ASSERT
|
||||
# define BOOST_NO_RVALUE_REFERENCES
|
||||
# define BOOST_NO_VARIADIC_TEMPLATES
|
||||
# define BOOST_NO_CONSTEXPR
|
||||
# define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
# define BOOST_NO_DELETED_FUNCTIONS
|
||||
# define BOOST_NO_RAW_LITERALS
|
||||
# define BOOST_NO_UNICODE_LITERALS
|
||||
#endif
|
||||
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
#define BOOST_NO_INITIALIZER_LISTS
|
||||
|
||||
#if __BORLANDC__ >= 0x590
|
||||
# define BOOST_HAS_TR1_HASH
|
||||
|
||||
# define BOOST_HAS_MACRO_USE_FACET
|
||||
#endif
|
||||
|
||||
//
|
||||
// Post 0x561 we have long long and stdint.h:
|
||||
#if __BORLANDC__ >= 0x561
|
||||
# ifndef __NO_LONG_LONG
|
||||
# define BOOST_HAS_LONG_LONG
|
||||
# else
|
||||
# define BOOST_NO_LONG_LONG
|
||||
# endif
|
||||
// On non-Win32 platforms let the platform config figure this out:
|
||||
# ifdef _WIN32
|
||||
# define BOOST_HAS_STDINT_H
|
||||
# endif
|
||||
#endif
|
||||
|
||||
// Borland C++Builder 6 defaults to using STLPort. If _USE_OLD_RW_STL is
|
||||
// defined, then we have 0x560 or greater with the Rogue Wave implementation
|
||||
// which presumably has the std::DBL_MAX bug.
|
||||
#if defined( BOOST_BCB_WITH_ROGUE_WAVE )
|
||||
// <climits> is partly broken, some macros define symbols that are really in
|
||||
// namespace std, so you end up having to use illegal constructs like
|
||||
// std::DBL_MAX, as a fix we'll just include float.h and have done with:
|
||||
#include <float.h>
|
||||
#endif
|
||||
//
|
||||
// __int64:
|
||||
//
|
||||
#if (__BORLANDC__ >= 0x530) && !defined(__STRICT_ANSI__)
|
||||
# define BOOST_HAS_MS_INT64
|
||||
#endif
|
||||
//
|
||||
// check for exception handling support:
|
||||
//
|
||||
#if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS)
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
#endif
|
||||
//
|
||||
// all versions have a <dirent.h>:
|
||||
//
|
||||
#ifndef __STRICT_ANSI__
|
||||
# define BOOST_HAS_DIRENT_H
|
||||
#endif
|
||||
//
|
||||
// all versions support __declspec:
|
||||
//
|
||||
#ifndef __STRICT_ANSI__
|
||||
# define BOOST_HAS_DECLSPEC
|
||||
#endif
|
||||
//
|
||||
// ABI fixing headers:
|
||||
//
|
||||
#if __BORLANDC__ < 0x600 // not implemented for version 6 compiler yet
|
||||
#ifndef BOOST_ABI_PREFIX
|
||||
# define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp"
|
||||
#endif
|
||||
#ifndef BOOST_ABI_SUFFIX
|
||||
# define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp"
|
||||
#endif
|
||||
#endif
|
||||
//
|
||||
// Disable Win32 support in ANSI mode:
|
||||
//
|
||||
#if __BORLANDC__ < 0x600
|
||||
# pragma defineonoption BOOST_DISABLE_WIN32 -A
|
||||
#elif defined(__STRICT_ANSI__)
|
||||
# define BOOST_DISABLE_WIN32
|
||||
#endif
|
||||
//
|
||||
// MSVC compatibility mode does some nasty things:
|
||||
// TODO: look up if this doesn't apply to the whole 12xx range
|
||||
//
|
||||
#if defined(_MSC_VER) && (_MSC_VER <= 1200)
|
||||
# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
|
||||
# define BOOST_NO_VOID_RETURNS
|
||||
#endif
|
||||
|
||||
#define BOOST_COMPILER "Borland C++ version " BOOST_STRINGIZE(__BORLANDC__)
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,153 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright David Abrahams 2002 - 2003.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// CodeGear C++ compiler setup:
|
||||
|
||||
#if !defined( BOOST_WITH_CODEGEAR_WARNINGS )
|
||||
// these warnings occur frequently in optimized template code
|
||||
# pragma warn -8004 // var assigned value, but never used
|
||||
# pragma warn -8008 // condition always true/false
|
||||
# pragma warn -8066 // dead code can never execute
|
||||
# pragma warn -8104 // static members with ctors not threadsafe
|
||||
# pragma warn -8105 // reference member in class without ctors
|
||||
#endif
|
||||
//
|
||||
// versions check:
|
||||
// last known and checked version is 0x610
|
||||
#if (__CODEGEARC__ > 0x610)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# else
|
||||
# pragma message( "Unknown compiler version - please run the configure tests and report the results")
|
||||
# endif
|
||||
#endif
|
||||
|
||||
// CodeGear C++ Builder 2009
|
||||
#if (__CODEGEARC__ <= 0x610)
|
||||
# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# define BOOST_NO_PRIVATE_IN_AGGREGATE
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
|
||||
# define BOOST_NO_USING_TEMPLATE
|
||||
// we shouldn't really need this - but too many things choke
|
||||
// without it, this needs more investigation:
|
||||
# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
|
||||
# define BOOST_NO_TYPENAME_WITH_CTOR // Cannot use typename keyword when making temporaries of a dependant type
|
||||
# define BOOST_NO_NESTED_FRIENDSHIP // TC1 gives nested classes access rights as any other member
|
||||
|
||||
// Temporary hack, until specific MPL preprocessed headers are generated
|
||||
# define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
|
||||
|
||||
# ifdef NDEBUG
|
||||
// fix broken <cstring> so that Boost.test works:
|
||||
# include <cstring>
|
||||
# undef strcmp
|
||||
# endif
|
||||
// fix broken errno declaration:
|
||||
# include <errno.h>
|
||||
# ifndef errno
|
||||
# define errno errno
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x macros:
|
||||
//
|
||||
#define BOOST_HAS_CHAR16_T
|
||||
#define BOOST_HAS_CHAR32_T
|
||||
#define BOOST_HAS_LONG_LONG
|
||||
// #define BOOST_HAS_ALIGNOF
|
||||
#define BOOST_HAS_DECLTYPE
|
||||
#define BOOST_HAS_EXPLICIT_CONVERSION_OPS
|
||||
// #define BOOST_HAS_RVALUE_REFS
|
||||
#define BOOST_HAS_SCOPED_ENUM
|
||||
// #define BOOST_HAS_STATIC_ASSERT
|
||||
#define BOOST_HAS_STD_TYPE_TRAITS
|
||||
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
//
|
||||
// TR1 macros:
|
||||
//
|
||||
#define BOOST_HAS_TR1_HASH
|
||||
#define BOOST_HAS_TR1_TYPE_TRAITS
|
||||
#define BOOST_HAS_TR1_UNORDERED_MAP
|
||||
#define BOOST_HAS_TR1_UNORDERED_SET
|
||||
|
||||
#define BOOST_HAS_MACRO_USE_FACET
|
||||
|
||||
#define BOOST_NO_INITIALIZER_LISTS
|
||||
|
||||
// On non-Win32 platforms let the platform config figure this out:
|
||||
#ifdef _WIN32
|
||||
# define BOOST_HAS_STDINT_H
|
||||
#endif
|
||||
|
||||
//
|
||||
// __int64:
|
||||
//
|
||||
#if !defined(__STRICT_ANSI__)
|
||||
# define BOOST_HAS_MS_INT64
|
||||
#endif
|
||||
//
|
||||
// check for exception handling support:
|
||||
//
|
||||
#if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS)
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
#endif
|
||||
//
|
||||
// all versions have a <dirent.h>:
|
||||
//
|
||||
#if !defined(__STRICT_ANSI__)
|
||||
# define BOOST_HAS_DIRENT_H
|
||||
#endif
|
||||
//
|
||||
// all versions support __declspec:
|
||||
//
|
||||
#if !defined(__STRICT_ANSI__)
|
||||
# define BOOST_HAS_DECLSPEC
|
||||
#endif
|
||||
//
|
||||
// ABI fixing headers:
|
||||
//
|
||||
#ifndef BOOST_ABI_PREFIX
|
||||
# define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp"
|
||||
#endif
|
||||
#ifndef BOOST_ABI_SUFFIX
|
||||
# define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp"
|
||||
#endif
|
||||
//
|
||||
// Disable Win32 support in ANSI mode:
|
||||
//
|
||||
# pragma defineonoption BOOST_DISABLE_WIN32 -A
|
||||
//
|
||||
// MSVC compatibility mode does some nasty things:
|
||||
// TODO: look up if this doesn't apply to the whole 12xx range
|
||||
//
|
||||
#if defined(_MSC_VER) && (_MSC_VER <= 1200)
|
||||
# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
|
||||
# define BOOST_NO_VOID_RETURNS
|
||||
#endif
|
||||
|
||||
#define BOOST_COMPILER "CodeGear C++ version " BOOST_STRINGIZE(__CODEGEARC__)
|
||||
|
|
@ -0,0 +1,59 @@
|
|||
// (C) Copyright John Maddock 2001.
|
||||
// (C) Copyright Douglas Gregor 2001.
|
||||
// (C) Copyright Peter Dimov 2001.
|
||||
// (C) Copyright Aleksey Gurtovoy 2003.
|
||||
// (C) Copyright Beman Dawes 2003.
|
||||
// (C) Copyright Jens Maurer 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Comeau C++ compiler setup:
|
||||
|
||||
#include "boost/config/compiler/common_edg.hpp"
|
||||
|
||||
#if (__COMO_VERSION__ <= 4245)
|
||||
|
||||
# if defined(_MSC_VER) && _MSC_VER <= 1300
|
||||
# if _MSC_VER > 100
|
||||
// only set this in non-strict mode:
|
||||
# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
|
||||
# endif
|
||||
# endif
|
||||
|
||||
// Void returns don't work when emulating VC 6 (Peter Dimov)
|
||||
// TODO: look up if this doesn't apply to the whole 12xx range
|
||||
# if defined(_MSC_VER) && (_MSC_VER < 1300)
|
||||
# define BOOST_NO_VOID_RETURNS
|
||||
# endif
|
||||
|
||||
#endif // version 4245
|
||||
|
||||
//
|
||||
// enable __int64 support in VC emulation mode
|
||||
//
|
||||
# if defined(_MSC_VER) && (_MSC_VER >= 1200)
|
||||
# define BOOST_HAS_MS_INT64
|
||||
# endif
|
||||
|
||||
#define BOOST_COMPILER "Comeau compiler version " BOOST_STRINGIZE(__COMO_VERSION__)
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't know Comeau prior to version 4245:
|
||||
#if __COMO_VERSION__ < 4245
|
||||
# error "Compiler not configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is 4245:
|
||||
#if (__COMO_VERSION__ > 4245)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,90 @@
|
|||
// (C) Copyright John Maddock 2001 - 2002.
|
||||
// (C) Copyright Jens Maurer 2001.
|
||||
// (C) Copyright David Abrahams 2002.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// (C) Copyright Markus Schoepflin 2005.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
//
|
||||
// Options common to all edg based compilers.
|
||||
//
|
||||
// This is included from within the individual compiler mini-configs.
|
||||
|
||||
#ifndef __EDG_VERSION__
|
||||
# error This file requires that __EDG_VERSION__ be defined.
|
||||
#endif
|
||||
|
||||
#if (__EDG_VERSION__ <= 238)
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
# define BOOST_NO_SFINAE
|
||||
#endif
|
||||
|
||||
#if (__EDG_VERSION__ <= 240)
|
||||
# define BOOST_NO_VOID_RETURNS
|
||||
#endif
|
||||
|
||||
#if (__EDG_VERSION__ <= 241) && !defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP)
|
||||
# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
|
||||
#endif
|
||||
|
||||
#if (__EDG_VERSION__ <= 244) && !defined(BOOST_NO_TEMPLATE_TEMPLATES)
|
||||
# define BOOST_NO_TEMPLATE_TEMPLATES
|
||||
#endif
|
||||
|
||||
#if (__EDG_VERSION__ < 300) && !defined(BOOST_NO_IS_ABSTRACT)
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
#endif
|
||||
|
||||
#if (__EDG_VERSION__ <= 303) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL)
|
||||
# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
#endif
|
||||
|
||||
#if (__EDG_VERSION__ <= 310) || !defined(BOOST_STRICT_CONFIG)
|
||||
// No support for initializer lists
|
||||
# define BOOST_NO_INITIALIZER_LISTS
|
||||
#endif
|
||||
|
||||
// See also kai.hpp which checks a Kai-specific symbol for EH
|
||||
# if !defined(__KCC) && !defined(__EXCEPTIONS)
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
# endif
|
||||
|
||||
# if !defined(__NO_LONG_LONG)
|
||||
# define BOOST_HAS_LONG_LONG
|
||||
# else
|
||||
# define BOOST_NO_LONG_LONG
|
||||
# endif
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See above for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
#ifdef c_plusplus
|
||||
// EDG has "long long" in non-strict mode
|
||||
// However, some libraries have insufficient "long long" support
|
||||
// #define BOOST_HAS_LONG_LONG
|
||||
#endif
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,19 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Tru64 C++ compiler setup (now HP):
|
||||
|
||||
#define BOOST_COMPILER "HP Tru64 C++ " BOOST_STRINGIZE(__DECCXX_VER)
|
||||
|
||||
#include "boost/config/compiler/common_edg.hpp"
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// Nothing to do here?
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,87 @@
|
|||
// Copyright (C) Christof Meerwald 2003
|
||||
// Copyright (C) Dan Watkins 2003
|
||||
//
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// Digital Mars C++ compiler setup:
|
||||
#define BOOST_COMPILER __DMC_VERSION_STRING__
|
||||
|
||||
#define BOOST_HAS_LONG_LONG
|
||||
#define BOOST_HAS_PRAGMA_ONCE
|
||||
|
||||
#if (__DMC__ <= 0x833)
|
||||
#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
#define BOOST_NO_TEMPLATE_TEMPLATES
|
||||
#define BOOST_NEEDS_TOKEN_PASTING_OP_FOR_TOKENS_JUXTAPOSING
|
||||
#define BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS
|
||||
#define BOOST_NO_EXPLICIT_FUNCTION_TEMPLATE_ARGUMENTS
|
||||
#endif
|
||||
#if (__DMC__ <= 0x840) || !defined(BOOST_STRICT_CONFIG)
|
||||
#define BOOST_NO_EXPLICIT_FUNCTION_TEMPLATE_ARGUMENTS
|
||||
#define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
#define BOOST_NO_OPERATORS_IN_NAMESPACE
|
||||
#define BOOST_NO_UNREACHABLE_RETURN_DETECTION
|
||||
#define BOOST_NO_SFINAE
|
||||
#define BOOST_NO_USING_TEMPLATE
|
||||
#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
#define BOOST_NO_INITIALIZER_LISTS
|
||||
#endif
|
||||
|
||||
//
|
||||
// has macros:
|
||||
#if (__DMC__ >= 0x840)
|
||||
#define BOOST_HAS_DIRENT_H
|
||||
#define BOOST_HAS_STDINT_H
|
||||
#define BOOST_HAS_WINTHREADS
|
||||
#endif
|
||||
|
||||
#if (__DMC__ >= 0x847)
|
||||
#define BOOST_HAS_EXPM1
|
||||
#define BOOST_HAS_LOG1P
|
||||
#endif
|
||||
|
||||
//
|
||||
// Is this really the best way to detect whether the std lib is in namespace std?
|
||||
//
|
||||
#include <cstddef>
|
||||
#if !defined(__STL_IMPORT_VENDOR_CSTD) && !defined(_STLP_IMPORT_VENDOR_CSTD)
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
#endif
|
||||
|
||||
|
||||
// check for exception handling support:
|
||||
#ifndef _CPPUNWIND
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
#if __DMC__ < 0x800
|
||||
#error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is ...:
|
||||
#if (__DMC__ > 0x848)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
|
@ -0,0 +1,177 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Darin Adler 2001 - 2002.
|
||||
// (C) Copyright Jens Maurer 2001 - 2002.
|
||||
// (C) Copyright Beman Dawes 2001 - 2003.
|
||||
// (C) Copyright Douglas Gregor 2002.
|
||||
// (C) Copyright David Abrahams 2002 - 2003.
|
||||
// (C) Copyright Synge Todo 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// GNU C++ compiler setup:
|
||||
|
||||
#if __GNUC__ < 3
|
||||
# if __GNUC_MINOR__ == 91
|
||||
// egcs 1.1 won't parse shared_ptr.hpp without this:
|
||||
# define BOOST_NO_AUTO_PTR
|
||||
# endif
|
||||
# if __GNUC_MINOR__ < 95
|
||||
//
|
||||
// Prior to gcc 2.95 member templates only partly
|
||||
// work - define BOOST_MSVC6_MEMBER_TEMPLATES
|
||||
// instead since inline member templates mostly work.
|
||||
//
|
||||
# define BOOST_NO_MEMBER_TEMPLATES
|
||||
# if __GNUC_MINOR__ >= 9
|
||||
# define BOOST_MSVC6_MEMBER_TEMPLATES
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# if __GNUC_MINOR__ < 96
|
||||
# define BOOST_NO_SFINAE
|
||||
# endif
|
||||
|
||||
# if __GNUC_MINOR__ <= 97
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# define BOOST_NO_OPERATORS_IN_NAMESPACE
|
||||
# endif
|
||||
|
||||
# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
|
||||
# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
#elif __GNUC__ == 3
|
||||
# if defined (__PATHSCALE__)
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# endif
|
||||
//
|
||||
// gcc-3.x problems:
|
||||
//
|
||||
// Bug specific to gcc 3.1 and 3.2:
|
||||
//
|
||||
# if ((__GNUC_MINOR__ == 1) || (__GNUC_MINOR__ == 2))
|
||||
# define BOOST_NO_EXPLICIT_FUNCTION_TEMPLATE_ARGUMENTS
|
||||
# endif
|
||||
# if __GNUC_MINOR__ < 4
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# endif
|
||||
#endif
|
||||
#if __GNUC__ < 4
|
||||
//
|
||||
// All problems to gcc-3.x and earlier here:
|
||||
//
|
||||
#define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#endif
|
||||
|
||||
#ifndef __EXCEPTIONS
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
#endif
|
||||
|
||||
|
||||
//
|
||||
// Threading support: Turn this on unconditionally here (except for
|
||||
// those platforms where we can know for sure). It will get turned off again
|
||||
// later if no threading API is detected.
|
||||
//
|
||||
#if !defined(__MINGW32__) && !defined(linux) && !defined(__linux) && !defined(__linux__)
|
||||
# define BOOST_HAS_THREADS
|
||||
#endif
|
||||
|
||||
//
|
||||
// gcc has "long long"
|
||||
//
|
||||
#define BOOST_HAS_LONG_LONG
|
||||
|
||||
//
|
||||
// gcc implements the named return value optimization since version 3.1
|
||||
//
|
||||
#if __GNUC__ > 3 || ( __GNUC__ == 3 && __GNUC_MINOR__ >= 1 )
|
||||
#define BOOST_HAS_NRVO
|
||||
#endif
|
||||
//
|
||||
// RTTI and typeinfo detection is possible post gcc-4.3:
|
||||
//
|
||||
#if __GNUC__ * 100 + __GNUC_MINOR__ >= 403
|
||||
# ifndef __GXX_RTTI
|
||||
# define BOOST_NO_TYPEID
|
||||
# define BOOST_NO_RTTI
|
||||
# endif
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
// See below for BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
#if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 2)) && defined(__GXX_EXPERIMENTAL_CXX0X__)
|
||||
// C++0x features are only enabled when -std=c++0x or -std=gnu++0x are
|
||||
// passed on the command line, which in turn defines
|
||||
// __GXX_EXPERIMENTAL_CXX0X__.
|
||||
# define BOOST_HAS_DECLTYPE
|
||||
# define BOOST_HAS_RVALUE_REFS
|
||||
# define BOOST_HAS_STATIC_ASSERT
|
||||
# define BOOST_HAS_VARIADIC_TMPL
|
||||
#else
|
||||
# define BOOST_NO_DECLTYPE
|
||||
# define BOOST_NO_RVALUE_REFERENCES
|
||||
# define BOOST_NO_STATIC_ASSERT
|
||||
|
||||
// Variadic templates compiler:
|
||||
// http://www.generic-programming.org/~dgregor/cpp/variadic-templates.html
|
||||
# ifdef __VARIADIC_TEMPLATES
|
||||
# define BOOST_HAS_VARIADIC_TMPL
|
||||
# else
|
||||
# define BOOST_NO_VARIADIC_TEMPLATES
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if !defined(__GXX_EXPERIMENTAL_CXX0X__) || __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 4)
|
||||
# define BOOST_NO_INITIALIZER_LISTS
|
||||
# define BOOST_NO_AUTO_DECLARATIONS
|
||||
#endif
|
||||
|
||||
// ConceptGCC compiler:
|
||||
// http://www.generic-programming.org/software/ConceptGCC/
|
||||
#ifdef __GXX_CONCEPTS__
|
||||
# define BOOST_HAS_CONCEPTS
|
||||
# define BOOST_COMPILER "ConceptGCC version " __VERSION__
|
||||
#endif
|
||||
|
||||
#ifndef BOOST_COMPILER
|
||||
# define BOOST_COMPILER "GNU C++ version " __VERSION__
|
||||
#endif
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't know gcc prior to version 2.90:
|
||||
#if (__GNUC__ == 2) && (__GNUC_MINOR__ < 90)
|
||||
# error "Compiler not configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is 4.3 (Pre-release):
|
||||
#if (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ > 3))
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# else
|
||||
// we don't emit warnings here anymore since there are no defect macros defined for
|
||||
// gcc post 3.4, so any failures are gcc regressions...
|
||||
//# warning "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
// (C) Copyright John Maddock 2006.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// GCC-XML C++ compiler setup:
|
||||
|
||||
# if !defined(__GCCXML_GNUC__) || ((__GCCXML_GNUC__ <= 3) && (__GCCXML_GNUC_MINOR__ <= 3))
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# endif
|
||||
|
||||
//
|
||||
// Threading support: Turn this on unconditionally here (except for
|
||||
// those platforms where we can know for sure). It will get turned off again
|
||||
// later if no threading API is detected.
|
||||
//
|
||||
#if !defined(__MINGW32__) && !defined(_MSC_VER) && !defined(linux) && !defined(__linux) && !defined(__linux__)
|
||||
# define BOOST_HAS_THREADS
|
||||
#endif
|
||||
|
||||
//
|
||||
// gcc has "long long"
|
||||
//
|
||||
#define BOOST_HAS_LONG_LONG
|
||||
|
||||
#define BOOST_COMPILER "GCC-XML C++ version " __GCCXML__
|
||||
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
// (C) Copyright John Maddock 2001.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Greenhills C++ compiler setup:
|
||||
|
||||
#define BOOST_COMPILER "Greenhills C++ version " BOOST_STRINGIZE(__ghs)
|
||||
|
||||
#include "boost/config/compiler/common_edg.hpp"
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support Greenhills prior to version 0:
|
||||
#if __ghs < 0
|
||||
# error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is 0:
|
||||
#if (__ghs > 0)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
|
@ -0,0 +1,117 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2001 - 2003.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// (C) Copyright David Abrahams 2002 - 2003.
|
||||
// (C) Copyright Toon Knapen 2003.
|
||||
// (C) Copyright Boris Gubenko 2006 - 2007.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// HP aCC C++ compiler setup:
|
||||
|
||||
#if defined(__EDG__)
|
||||
#include "boost/config/compiler/common_edg.hpp"
|
||||
#endif
|
||||
|
||||
#if (__HP_aCC <= 33100)
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
# define BOOST_NO_OPERATORS_IN_NAMESPACE
|
||||
# if !defined(_NAMESPACE_STD)
|
||||
# define BOOST_NO_STD_LOCALE
|
||||
# define BOOST_NO_STRINGSTREAM
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if (__HP_aCC <= 33300)
|
||||
// member templates are sufficiently broken that we disable them for now
|
||||
# define BOOST_NO_MEMBER_TEMPLATES
|
||||
# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
|
||||
# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
|
||||
#endif
|
||||
|
||||
#if (__HP_aCC <= 38000)
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#endif
|
||||
|
||||
#if (__HP_aCC > 50000) && (__HP_aCC < 60000)
|
||||
# define BOOST_NO_UNREACHABLE_RETURN_DETECTION
|
||||
# define BOOST_NO_TEMPLATE_TEMPLATES
|
||||
# define BOOST_NO_SWPRINTF
|
||||
# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
#endif
|
||||
|
||||
// optional features rather than defects:
|
||||
#if (__HP_aCC >= 33900)
|
||||
# define BOOST_HAS_LONG_LONG
|
||||
# define BOOST_HAS_PARTIAL_STD_ALLOCATOR
|
||||
#endif
|
||||
|
||||
#if (__HP_aCC >= 50000 ) && (__HP_aCC <= 53800 ) || (__HP_aCC < 31300 )
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD
|
||||
#endif
|
||||
|
||||
// This macro should not be defined when compiling in strict ansi
|
||||
// mode, but, currently, we don't have the ability to determine
|
||||
// what standard mode we are compiling with. Some future version
|
||||
// of aCC6 compiler will provide predefined macros reflecting the
|
||||
// compilation options, including the standard mode.
|
||||
#if (__HP_aCC >= 60000) || ((__HP_aCC > 38000) && defined(__hpxstd98))
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#endif
|
||||
|
||||
#define BOOST_COMPILER "HP aCC version " BOOST_STRINGIZE(__HP_aCC)
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support HP aCC prior to version 33000:
|
||||
#if __HP_aCC < 33000
|
||||
# error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
|
||||
//
|
||||
// Extended checks for supporting aCC on PA-RISC
|
||||
#if __HP_aCC > 30000 && __HP_aCC < 50000
|
||||
# if __HP_aCC < 38000
|
||||
// versions prior to version A.03.80 not supported
|
||||
# error "Compiler version not supported - version A.03.80 or higher is required"
|
||||
# elif !defined(__hpxstd98)
|
||||
// must compile using the option +hpxstd98 with version A.03.80 and above
|
||||
# error "Compiler option '+hpxstd98' is required for proper support"
|
||||
# endif //PA-RISC
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
//
|
||||
// last known and checked version for HP-UX/ia64 is 61300
|
||||
// last known and checked version for PA-RISC is 38000
|
||||
#if ((__HP_aCC > 61300) || ((__HP_aCC > 38000) && defined(__hpxstd98)))
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
|
@ -0,0 +1,195 @@
|
|||
// (C) Copyright John Maddock 2001-8.
|
||||
// (C) Copyright Peter Dimov 2001.
|
||||
// (C) Copyright Jens Maurer 2001.
|
||||
// (C) Copyright David Abrahams 2002 - 2003.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002 - 2003.
|
||||
// (C) Copyright Guillaume Melquiond 2002 - 2003.
|
||||
// (C) Copyright Beman Dawes 2003.
|
||||
// (C) Copyright Martin Wille 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Intel compiler setup:
|
||||
|
||||
#include "boost/config/compiler/common_edg.hpp"
|
||||
|
||||
#if defined(__INTEL_COMPILER)
|
||||
# define BOOST_INTEL_CXX_VERSION __INTEL_COMPILER
|
||||
#elif defined(__ICL)
|
||||
# define BOOST_INTEL_CXX_VERSION __ICL
|
||||
#elif defined(__ICC)
|
||||
# define BOOST_INTEL_CXX_VERSION __ICC
|
||||
#elif defined(__ECC)
|
||||
# define BOOST_INTEL_CXX_VERSION __ECC
|
||||
#endif
|
||||
|
||||
#define BOOST_COMPILER "Intel C++ version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION)
|
||||
#define BOOST_INTEL BOOST_INTEL_CXX_VERSION
|
||||
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
# define BOOST_INTEL_WIN BOOST_INTEL
|
||||
#else
|
||||
# define BOOST_INTEL_LINUX BOOST_INTEL
|
||||
#endif
|
||||
|
||||
#if (BOOST_INTEL_CXX_VERSION <= 500) && defined(_MSC_VER)
|
||||
# define BOOST_NO_EXPLICIT_FUNCTION_TEMPLATE_ARGUMENTS
|
||||
# define BOOST_NO_TEMPLATE_TEMPLATES
|
||||
#endif
|
||||
|
||||
#if (BOOST_INTEL_CXX_VERSION <= 600)
|
||||
|
||||
# if defined(_MSC_VER) && (_MSC_VER <= 1300) // added check for <= VC 7 (Peter Dimov)
|
||||
|
||||
// Boost libraries assume strong standard conformance unless otherwise
|
||||
// indicated by a config macro. As configured by Intel, the EDG front-end
|
||||
// requires certain compiler options be set to achieve that strong conformance.
|
||||
// Particularly /Qoption,c,--arg_dep_lookup (reported by Kirk Klobe & Thomas Witt)
|
||||
// and /Zc:wchar_t,forScope. See boost-root/tools/build/intel-win32-tools.jam for
|
||||
// details as they apply to particular versions of the compiler. When the
|
||||
// compiler does not predefine a macro indicating if an option has been set,
|
||||
// this config file simply assumes the option has been set.
|
||||
// Thus BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP will not be defined, even if
|
||||
// the compiler option is not enabled.
|
||||
|
||||
# define BOOST_NO_SWPRINTF
|
||||
# endif
|
||||
|
||||
// Void returns, 64 bit integrals don't work when emulating VC 6 (Peter Dimov)
|
||||
|
||||
# if defined(_MSC_VER) && (_MSC_VER <= 1200)
|
||||
# define BOOST_NO_VOID_RETURNS
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
#if (BOOST_INTEL_CXX_VERSION <= 710) && defined(_WIN32)
|
||||
# define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS
|
||||
#endif
|
||||
|
||||
// See http://aspn.activestate.com/ASPN/Mail/Message/boost/1614864
|
||||
#if BOOST_INTEL_CXX_VERSION < 600
|
||||
# define BOOST_NO_INTRINSIC_WCHAR_T
|
||||
#else
|
||||
// We should test the macro _WCHAR_T_DEFINED to check if the compiler
|
||||
// supports wchar_t natively. *BUT* there is a problem here: the standard
|
||||
// headers define this macro if they typedef wchar_t. Anyway, we're lucky
|
||||
// because they define it without a value, while Intel C++ defines it
|
||||
// to 1. So we can check its value to see if the macro was defined natively
|
||||
// or not.
|
||||
// Under UNIX, the situation is exactly the same, but the macro _WCHAR_T
|
||||
// is used instead.
|
||||
# if ((_WCHAR_T_DEFINED + 0) == 0) && ((_WCHAR_T + 0) == 0)
|
||||
# define BOOST_NO_INTRINSIC_WCHAR_T
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if defined(__GNUC__) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL)
|
||||
//
|
||||
// Figure out when Intel is emulating this gcc bug
|
||||
// (All Intel versions prior to 9.0.26, and versions
|
||||
// later than that if they are set up to emulate gcc 3.2
|
||||
// or earlier):
|
||||
//
|
||||
# if ((__GNUC__ == 3) && (__GNUC_MINOR__ <= 2)) || (BOOST_INTEL < 900) || (__INTEL_COMPILER_BUILD_DATE < 20050912)
|
||||
# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
# endif
|
||||
#endif
|
||||
#if (defined(__GNUC__) && (__GNUC__ < 4)) || defined(_WIN32) || (BOOST_INTEL_CXX_VERSION <= 1100)
|
||||
// GCC or VC emulation:
|
||||
#define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#endif
|
||||
//
|
||||
// Verify that we have actually got BOOST_NO_INTRINSIC_WCHAR_T
|
||||
// set correctly, if we don't do this now, we will get errors later
|
||||
// in type_traits code among other things, getting this correct
|
||||
// for the Intel compiler is actually remarkably fragile and tricky:
|
||||
//
|
||||
#if defined(BOOST_NO_INTRINSIC_WCHAR_T)
|
||||
#include <cwchar>
|
||||
template< typename T > struct assert_no_intrinsic_wchar_t;
|
||||
template<> struct assert_no_intrinsic_wchar_t<wchar_t> { typedef void type; };
|
||||
// if you see an error here then you need to unset BOOST_NO_INTRINSIC_WCHAR_T
|
||||
// where it is defined above:
|
||||
typedef assert_no_intrinsic_wchar_t<unsigned short>::type assert_no_intrinsic_wchar_t_;
|
||||
#else
|
||||
template< typename T > struct assert_intrinsic_wchar_t;
|
||||
template<> struct assert_intrinsic_wchar_t<wchar_t> {};
|
||||
// if you see an error here then define BOOST_NO_INTRINSIC_WCHAR_T on the command line:
|
||||
template<> struct assert_intrinsic_wchar_t<unsigned short> {};
|
||||
#endif
|
||||
|
||||
#if _MSC_VER+0 >= 1000
|
||||
# if _MSC_VER >= 1200
|
||||
# define BOOST_HAS_MS_INT64
|
||||
# endif
|
||||
# define BOOST_NO_SWPRINTF
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#elif defined(_WIN32)
|
||||
# define BOOST_DISABLE_WIN32
|
||||
#endif
|
||||
|
||||
// I checked version 6.0 build 020312Z, it implements the NRVO.
|
||||
// Correct this as you find out which version of the compiler
|
||||
// implemented the NRVO first. (Daniel Frey)
|
||||
#if (BOOST_INTEL_CXX_VERSION >= 600)
|
||||
# define BOOST_HAS_NRVO
|
||||
#endif
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support Intel prior to version 5.0:
|
||||
#if BOOST_INTEL_CXX_VERSION < 500
|
||||
# error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
|
||||
// Intel on MacOS requires
|
||||
#if defined(__APPLE__) && defined(__INTEL_COMPILER)
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#endif
|
||||
|
||||
// Intel on Altix Itanium
|
||||
#if defined(__itanium__) && defined(__INTEL_COMPILER)
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
//
|
||||
// last known and checked version:
|
||||
#if (BOOST_INTEL_CXX_VERSION > 1100)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# elif defined(_MSC_VER)
|
||||
//
|
||||
// We don't emit this warning any more, since we have so few
|
||||
// defect macros set anyway (just the one).
|
||||
//
|
||||
//# pragma message("Unknown compiler version - please run the configure tests and report the results")
|
||||
# endif
|
||||
#endif
|
||||
|
|
@ -0,0 +1,35 @@
|
|||
// (C) Copyright John Maddock 2001.
|
||||
// (C) Copyright David Abrahams 2002.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Kai C++ compiler setup:
|
||||
|
||||
#include "boost/config/compiler/common_edg.hpp"
|
||||
|
||||
# if (__KCC_VERSION <= 4001) || !defined(BOOST_STRICT_CONFIG)
|
||||
// at least on Sun, the contents of <cwchar> is not in namespace std
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
# endif
|
||||
|
||||
// see also common_edg.hpp which needs a special check for __KCC
|
||||
# if !defined(_EXCEPTIONS)
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
# endif
|
||||
|
||||
#define BOOST_COMPILER "Kai C++ version " BOOST_STRINGIZE(__KCC_VERSION)
|
||||
|
||||
//
|
||||
// last known and checked version is 4001:
|
||||
#if (__KCC_VERSION > 4001)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,131 @@
|
|||
// (C) Copyright John Maddock 2001.
|
||||
// (C) Copyright Darin Adler 2001.
|
||||
// (C) Copyright Peter Dimov 2001.
|
||||
// (C) Copyright David Abrahams 2001 - 2002.
|
||||
// (C) Copyright Beman Dawes 2001 - 2003.
|
||||
// (C) Copyright Stefan Slapeta 2004.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Metrowerks C++ compiler setup:
|
||||
|
||||
// locale support is disabled when linking with the dynamic runtime
|
||||
# ifdef _MSL_NO_LOCALE
|
||||
# define BOOST_NO_STD_LOCALE
|
||||
# endif
|
||||
|
||||
# if __MWERKS__ <= 0x2301 // 5.3
|
||||
# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING
|
||||
# define BOOST_NO_POINTER_TO_MEMBER_CONST
|
||||
# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD
|
||||
# endif
|
||||
|
||||
# if __MWERKS__ <= 0x2401 // 6.2
|
||||
//# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING
|
||||
# endif
|
||||
|
||||
# if(__MWERKS__ <= 0x2407) // 7.x
|
||||
# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS
|
||||
# define BOOST_NO_UNREACHABLE_RETURN_DETECTION
|
||||
# endif
|
||||
|
||||
# if(__MWERKS__ <= 0x3003) // 8.x
|
||||
# define BOOST_NO_SFINAE
|
||||
# endif
|
||||
|
||||
// the "|| !defined(BOOST_STRICT_CONFIG)" part should apply to the last
|
||||
// tested version *only*:
|
||||
# if(__MWERKS__ <= 0x3206) || !defined(BOOST_STRICT_CONFIG) // 9.5
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# define BOOST_NO_INITIALIZER_LISTS
|
||||
# endif
|
||||
|
||||
#if !__option(wchar_type)
|
||||
# define BOOST_NO_INTRINSIC_WCHAR_T
|
||||
#endif
|
||||
|
||||
#if !__option(exceptions)
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
#endif
|
||||
|
||||
#if (__INTEL__ && _WIN32) || (__POWERPC__ && macintosh)
|
||||
# if __MWERKS__ == 0x3000
|
||||
# define BOOST_COMPILER_VERSION 8.0
|
||||
# elif __MWERKS__ == 0x3001
|
||||
# define BOOST_COMPILER_VERSION 8.1
|
||||
# elif __MWERKS__ == 0x3002
|
||||
# define BOOST_COMPILER_VERSION 8.2
|
||||
# elif __MWERKS__ == 0x3003
|
||||
# define BOOST_COMPILER_VERSION 8.3
|
||||
# elif __MWERKS__ == 0x3200
|
||||
# define BOOST_COMPILER_VERSION 9.0
|
||||
# elif __MWERKS__ == 0x3201
|
||||
# define BOOST_COMPILER_VERSION 9.1
|
||||
# elif __MWERKS__ == 0x3202
|
||||
# define BOOST_COMPILER_VERSION 9.2
|
||||
# elif __MWERKS__ == 0x3204
|
||||
# define BOOST_COMPILER_VERSION 9.3
|
||||
# elif __MWERKS__ == 0x3205
|
||||
# define BOOST_COMPILER_VERSION 9.4
|
||||
# elif __MWERKS__ == 0x3206
|
||||
# define BOOST_COMPILER_VERSION 9.5
|
||||
# else
|
||||
# define BOOST_COMPILER_VERSION __MWERKS__
|
||||
# endif
|
||||
#else
|
||||
# define BOOST_COMPILER_VERSION __MWERKS__
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#if __MWERKS__ > 0x3206 && __option(rvalue_refs)
|
||||
# define BOOST_HAS_RVALUE_REFS
|
||||
#else
|
||||
# define BOOST_NO_RVALUE_REFERENCES
|
||||
#endif
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
#define BOOST_COMPILER "Metrowerks CodeWarrior C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION)
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support Metrowerks prior to version 5.3:
|
||||
#if __MWERKS__ < 0x2301
|
||||
# error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version:
|
||||
#if (__MWERKS__ > 0x3205)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,75 @@
|
|||
// (C) Copyright John Maddock 2001 - 2002.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// MPW C++ compilers setup:
|
||||
|
||||
# if defined(__SC__)
|
||||
# define BOOST_COMPILER "MPW SCpp version " BOOST_STRINGIZE(__SC__)
|
||||
# elif defined(__MRC__)
|
||||
# define BOOST_COMPILER "MPW MrCpp version " BOOST_STRINGIZE(__MRC__)
|
||||
# else
|
||||
# error "Using MPW compiler configuration by mistake. Please update."
|
||||
# endif
|
||||
|
||||
//
|
||||
// MPW 8.90:
|
||||
//
|
||||
#if (MPW_CPLUS <= 0x890) || !defined(BOOST_STRICT_CONFIG)
|
||||
# define BOOST_NO_CV_SPECIALIZATIONS
|
||||
# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
|
||||
# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS
|
||||
# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION
|
||||
# define BOOST_NO_INTRINSIC_WCHAR_T
|
||||
# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
|
||||
# define BOOST_NO_USING_TEMPLATE
|
||||
|
||||
# define BOOST_NO_CWCHAR
|
||||
# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
|
||||
|
||||
# define BOOST_NO_STD_ALLOCATOR /* actually a bug with const reference overloading */
|
||||
|
||||
# define BOOST_NO_INITIALIZER_LISTS
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support MPW prior to version 8.9:
|
||||
#if MPW_CPLUS < 0x890
|
||||
# error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is 0x890:
|
||||
#if (MPW_CPLUS > 0x890)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
// (C) Copyright Noel Belcourt 2007.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// PGI C++ compiler setup:
|
||||
|
||||
#define BOOST_COMPILER_VERSION __PGIC__##__PGIC_MINOR__
|
||||
#define BOOST_COMPILER "PGI compiler version " BOOST_STRINGIZE(_COMPILER_VERSION)
|
||||
|
||||
//
|
||||
// Threading support:
|
||||
// Turn this on unconditionally here, it will get turned off again later
|
||||
// if no threading API is detected.
|
||||
//
|
||||
|
||||
#if (__PGIC__ >= 7)
|
||||
|
||||
#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
#define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#define BOOST_NO_SWPRINTF
|
||||
#define BOOST_NO_INITIALIZER_LISTS
|
||||
|
||||
#else
|
||||
|
||||
# error "Pgi compiler not configured - please reconfigure"
|
||||
|
||||
#endif
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
//
|
||||
// version check:
|
||||
// probably nothing to do here?
|
||||
|
|
@ -0,0 +1,52 @@
|
|||
// (C) Copyright John Maddock 2001 - 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// SGI C++ compiler setup:
|
||||
|
||||
#define BOOST_COMPILER "SGI Irix compiler version " BOOST_STRINGIZE(_COMPILER_VERSION)
|
||||
|
||||
#include "boost/config/compiler/common_edg.hpp"
|
||||
|
||||
//
|
||||
// Threading support:
|
||||
// Turn this on unconditionally here, it will get turned off again later
|
||||
// if no threading API is detected.
|
||||
//
|
||||
#define BOOST_HAS_THREADS
|
||||
#define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
|
||||
#undef BOOST_NO_SWPRINTF
|
||||
#undef BOOST_DEDUCED_TYPENAME
|
||||
|
||||
#define BOOST_NO_INITIALIZER_LISTS
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
//
|
||||
// version check:
|
||||
// probably nothing to do here?
|
||||
|
||||
|
|
@ -0,0 +1,124 @@
|
|||
// (C) Copyright John Maddock 2001.
|
||||
// (C) Copyright Jens Maurer 2001 - 2003.
|
||||
// (C) Copyright Peter Dimov 2002.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002 - 2003.
|
||||
// (C) Copyright David Abrahams 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Sun C++ compiler setup:
|
||||
|
||||
# if __SUNPRO_CC <= 0x500
|
||||
# define BOOST_NO_MEMBER_TEMPLATES
|
||||
# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING
|
||||
# endif
|
||||
|
||||
# if (__SUNPRO_CC <= 0x520)
|
||||
//
|
||||
// Sunpro 5.2 and earler:
|
||||
//
|
||||
// although sunpro 5.2 supports the syntax for
|
||||
// inline initialization it often gets the value
|
||||
// wrong, especially where the value is computed
|
||||
// from other constants (J Maddock 6th May 2001)
|
||||
# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION
|
||||
|
||||
// Although sunpro 5.2 supports the syntax for
|
||||
// partial specialization, it often seems to
|
||||
// bind to the wrong specialization. Better
|
||||
// to disable it until suppport becomes more stable
|
||||
// (J Maddock 6th May 2001).
|
||||
# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
|
||||
# endif
|
||||
|
||||
# if (__SUNPRO_CC <= 0x530)
|
||||
// Requesting debug info (-g) with Boost.Python results
|
||||
// in an internal compiler error for "static const"
|
||||
// initialized in-class.
|
||||
// >> Assertion: (../links/dbg_cstabs.cc, line 611)
|
||||
// while processing ../test.cpp at line 0.
|
||||
// (Jens Maurer according to Gottfried Ganssauge 04 Mar 2002)
|
||||
# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION
|
||||
|
||||
// SunPro 5.3 has better support for partial specialization,
|
||||
// but breaks when compiling std::less<shared_ptr<T> >
|
||||
// (Jens Maurer 4 Nov 2001).
|
||||
|
||||
// std::less specialization fixed as reported by George
|
||||
// Heintzelman; partial specialization re-enabled
|
||||
// (Peter Dimov 17 Jan 2002)
|
||||
|
||||
//# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
|
||||
|
||||
// integral constant expressions with 64 bit numbers fail
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
# endif
|
||||
|
||||
# if (__SUNPRO_CC < 0x570)
|
||||
# define BOOST_NO_TEMPLATE_TEMPLATES
|
||||
// see http://lists.boost.org/MailArchives/boost/msg47184.php
|
||||
// and http://lists.boost.org/MailArchives/boost/msg47220.php
|
||||
# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION
|
||||
# define BOOST_NO_SFINAE
|
||||
# define BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS
|
||||
# endif
|
||||
# if (__SUNPRO_CC <= 0x580)
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# endif
|
||||
|
||||
//
|
||||
// Issues that effect all known versions:
|
||||
//
|
||||
#define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#define BOOST_NO_ADL_BARRIER
|
||||
#define BOOST_NO_INITIALIZER_LISTS
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
|
||||
#if(__SUNPRO_CC >= 0x590)
|
||||
# define BOOST_HAS_LONG_LONG
|
||||
#else
|
||||
# define BOOST_NO_LONG_LONG
|
||||
#endif
|
||||
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
//
|
||||
// Version
|
||||
//
|
||||
|
||||
#define BOOST_COMPILER "Sun compiler version " BOOST_STRINGIZE(__SUNPRO_CC)
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support sunpro prior to version 4:
|
||||
#if __SUNPRO_CC < 0x400
|
||||
#error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is 0x590:
|
||||
#if (__SUNPRO_CC > 0x590)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
|
@ -0,0 +1,82 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Toon Knapen 2001 - 2003.
|
||||
// (C) Copyright Lie-Quan Lee 2001.
|
||||
// (C) Copyright Markus Schoepflin 2002 - 2003.
|
||||
// (C) Copyright Beman Dawes 2002 - 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Visual Age (IBM) C++ compiler setup:
|
||||
|
||||
#if __IBMCPP__ <= 501
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS
|
||||
#endif
|
||||
|
||||
#if (__IBMCPP__ <= 502)
|
||||
// Actually the compiler supports inclass member initialization but it
|
||||
// requires a definition for the class member and it doesn't recognize
|
||||
// it as an integral constant expression when used as a template argument.
|
||||
# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD
|
||||
#endif
|
||||
|
||||
#if (__IBMCPP__ <= 600) || !defined(BOOST_STRICT_CONFIG)
|
||||
# define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS
|
||||
# define BOOST_NO_INITIALIZER_LISTS
|
||||
#endif
|
||||
|
||||
//
|
||||
// On AIX thread support seems to be indicated by _THREAD_SAFE:
|
||||
//
|
||||
#ifdef _THREAD_SAFE
|
||||
# define BOOST_HAS_THREADS
|
||||
#endif
|
||||
|
||||
#define BOOST_COMPILER "IBM Visual Age version " BOOST_STRINGIZE(__IBMCPP__)
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support Visual age prior to version 5:
|
||||
#if __IBMCPP__ < 500
|
||||
#error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is 600:
|
||||
#if (__IBMCPP__ > 600)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
// Some versions of the compiler have issues with default arguments on partial specializations
|
||||
#define BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS
|
||||
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG
|
||||
//
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,241 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Darin Adler 2001 - 2002.
|
||||
// (C) Copyright Peter Dimov 2001.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// (C) Copyright David Abrahams 2002 - 2003.
|
||||
// (C) Copyright Beman Dawes 2002 - 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Microsoft Visual C++ compiler setup:
|
||||
|
||||
#define BOOST_MSVC _MSC_VER
|
||||
|
||||
// turn off the warnings before we #include anything
|
||||
#pragma warning( disable : 4503 ) // warning: decorated name length exceeded
|
||||
|
||||
#if _MSC_VER < 1300 // 1200 == VC++ 6.0, 1200-1202 == eVC++4
|
||||
# pragma warning( disable : 4786 ) // ident trunc to '255' chars in debug info
|
||||
# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS
|
||||
# define BOOST_NO_VOID_RETURNS
|
||||
# define BOOST_NO_EXCEPTION_STD_NAMESPACE
|
||||
|
||||
# if BOOST_MSVC == 1202
|
||||
# define BOOST_NO_STD_TYPEINFO
|
||||
# endif
|
||||
|
||||
// disable min/max macro defines on vc6:
|
||||
//
|
||||
#endif
|
||||
|
||||
#if (_MSC_VER <= 1300) // 1300 == VC++ 7.0
|
||||
|
||||
# if !defined(_MSC_EXTENSIONS) && !defined(BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS) // VC7 bug with /Za
|
||||
# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS
|
||||
# endif
|
||||
|
||||
# define BOOST_NO_EXPLICIT_FUNCTION_TEMPLATE_ARGUMENTS
|
||||
# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION
|
||||
# define BOOST_NO_PRIVATE_IN_AGGREGATE
|
||||
# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
# define BOOST_NO_DEDUCED_TYPENAME
|
||||
# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
|
||||
|
||||
// VC++ 6/7 has member templates but they have numerous problems including
|
||||
// cases of silent failure, so for safety we define:
|
||||
# define BOOST_NO_MEMBER_TEMPLATES
|
||||
// For VC++ experts wishing to attempt workarounds, we define:
|
||||
# define BOOST_MSVC6_MEMBER_TEMPLATES
|
||||
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
|
||||
# define BOOST_NO_CV_VOID_SPECIALIZATIONS
|
||||
# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING
|
||||
# define BOOST_NO_USING_TEMPLATE
|
||||
# define BOOST_NO_SWPRINTF
|
||||
# define BOOST_NO_TEMPLATE_TEMPLATES
|
||||
# define BOOST_NO_SFINAE
|
||||
# define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS
|
||||
# define BOOST_NO_IS_ABSTRACT
|
||||
# define BOOST_NO_FUNCTION_TYPE_SPECIALIZATIONS
|
||||
// TODO: what version is meant here? Have there really been any fixes in cl 12.01 (as e.g. shipped with eVC4)?
|
||||
# if (_MSC_VER > 1200)
|
||||
# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
#if _MSC_VER < 1400
|
||||
// although a conforming signature for swprint exists in VC7.1
|
||||
// it appears not to actually work:
|
||||
# define BOOST_NO_SWPRINTF
|
||||
#endif
|
||||
|
||||
#if defined(UNDER_CE)
|
||||
// Windows CE does not have a conforming signature for swprintf
|
||||
# define BOOST_NO_SWPRINTF
|
||||
#endif
|
||||
|
||||
#if _MSC_VER <= 1400 // 1400 == VC++ 8.0
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
#endif
|
||||
|
||||
#if _MSC_VER <= 1600 // 1600 == VC++ 10.0
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
#endif
|
||||
|
||||
#if _MSC_VER == 1500 // 1500 == VC++ 9.0
|
||||
// A bug in VC9:
|
||||
# define BOOST_NO_ADL_BARRIER
|
||||
#endif
|
||||
|
||||
#if _MSC_VER <= 1500 || !defined(BOOST_STRICT_CONFIG) // 1500 == VC++ 9.0
|
||||
# define BOOST_NO_INITIALIZER_LISTS
|
||||
#endif
|
||||
|
||||
#ifndef _NATIVE_WCHAR_T_DEFINED
|
||||
# define BOOST_NO_INTRINSIC_WCHAR_T
|
||||
#endif
|
||||
|
||||
#if defined(_WIN32_WCE) || defined(UNDER_CE)
|
||||
# define BOOST_NO_THREADEX
|
||||
# define BOOST_NO_GETSYSTEMTIMEASFILETIME
|
||||
# define BOOST_NO_SWPRINTF
|
||||
#endif
|
||||
|
||||
//
|
||||
// check for exception handling support:
|
||||
#ifndef _CPPUNWIND
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
#endif
|
||||
|
||||
//
|
||||
// __int64 support:
|
||||
//
|
||||
#if (_MSC_VER >= 1200)
|
||||
# define BOOST_HAS_MS_INT64
|
||||
#endif
|
||||
#if (_MSC_VER >= 1310) && defined(_MSC_EXTENSIONS)
|
||||
# define BOOST_HAS_LONG_LONG
|
||||
#else
|
||||
# define BOOST_NO_LONG_LONG
|
||||
#endif
|
||||
#if (_MSC_VER >= 1400) && !defined(_DEBUG)
|
||||
# define BOOST_HAS_NRVO
|
||||
#endif
|
||||
//
|
||||
// disable Win32 API's if compiler extentions are
|
||||
// turned off:
|
||||
//
|
||||
#ifndef _MSC_EXTENSIONS
|
||||
# define BOOST_DISABLE_WIN32
|
||||
#endif
|
||||
#ifndef _CPPRTTI
|
||||
# define BOOST_NO_RTTI
|
||||
#endif
|
||||
|
||||
//
|
||||
// all versions support __declspec:
|
||||
//
|
||||
#define BOOST_HAS_DECLSPEC
|
||||
//
|
||||
// C++0x features
|
||||
//
|
||||
// See above for BOOST_NO_LONG_LONG
|
||||
#define BOOST_NO_CHAR16_T
|
||||
#define BOOST_NO_CHAR32_T
|
||||
#define BOOST_NO_CONSTEXPR
|
||||
#define BOOST_NO_DECLTYPE
|
||||
#define BOOST_NO_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
|
||||
#define BOOST_NO_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_RAW_LITERALS
|
||||
#define BOOST_NO_SCOPED_ENUMS
|
||||
#define BOOST_NO_UNICODE_LITERALS
|
||||
#define BOOST_NO_VARIADIC_TEMPLATES
|
||||
|
||||
// MSVC 2010 CTP has some support for C++0x, but we still disable it until the compiler release
|
||||
// #if _MSC_VER < 1600
|
||||
#define BOOST_NO_RVALUE_REFERENCES
|
||||
#define BOOST_NO_STATIC_ASSERT
|
||||
#define BOOST_NO_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_AUTO_MULTIDECLARATIONS
|
||||
// #endif // _MSC_VER < 1600
|
||||
|
||||
//
|
||||
// prefix and suffix headers:
|
||||
//
|
||||
#ifndef BOOST_ABI_PREFIX
|
||||
# define BOOST_ABI_PREFIX "boost/config/abi/msvc_prefix.hpp"
|
||||
#endif
|
||||
#ifndef BOOST_ABI_SUFFIX
|
||||
# define BOOST_ABI_SUFFIX "boost/config/abi/msvc_suffix.hpp"
|
||||
#endif
|
||||
|
||||
// TODO:
|
||||
// these things are mostly bogus. 1200 means version 12.0 of the compiler. The
|
||||
// artificial versions assigned to them only refer to the versions of some IDE
|
||||
// these compilers have been shipped with, and even that is not all of it. Some
|
||||
// were shipped with freely downloadable SDKs, others as crosscompilers in eVC.
|
||||
// IOW, you can't use these 'versions' in any sensible way. Sorry.
|
||||
# if defined(UNDER_CE)
|
||||
# if _MSC_VER < 1200
|
||||
// Note: these are so far off, they are not really supported
|
||||
# elif _MSC_VER < 1300 // eVC++ 4 comes with 1200-1202
|
||||
# define BOOST_COMPILER_VERSION evc4.0
|
||||
# elif _MSC_VER == 1400
|
||||
# define BOOST_COMPILER_VERSION evc8
|
||||
# elif _MSC_VER == 1500
|
||||
# define BOOST_COMPILER_VERSION evc9
|
||||
# elif _MSC_VER == 1600
|
||||
# define BOOST_COMPILER_VERSION evc10
|
||||
# else
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown EVC++ compiler version - please run the configure tests and report the results"
|
||||
# else
|
||||
# pragma message("Unknown EVC++ compiler version - please run the configure tests and report the results")
|
||||
# endif
|
||||
# endif
|
||||
# else
|
||||
# if _MSC_VER < 1200
|
||||
// Note: these are so far off, they are not really supported
|
||||
# define BOOST_COMPILER_VERSION 5.0
|
||||
# elif _MSC_VER < 1300
|
||||
# define BOOST_COMPILER_VERSION 6.0
|
||||
# elif _MSC_VER == 1300
|
||||
# define BOOST_COMPILER_VERSION 7.0
|
||||
# elif _MSC_VER == 1310
|
||||
# define BOOST_COMPILER_VERSION 7.1
|
||||
# elif _MSC_VER == 1400
|
||||
# define BOOST_COMPILER_VERSION 8.0
|
||||
# elif _MSC_VER == 1500
|
||||
# define BOOST_COMPILER_VERSION 9.0
|
||||
# elif _MSC_VER == 1600
|
||||
# define BOOST_COMPILER_VERSION 10.0
|
||||
# else
|
||||
# define BOOST_COMPILER_VERSION _MSC_VER
|
||||
# endif
|
||||
# endif
|
||||
|
||||
#define BOOST_COMPILER "Microsoft Visual C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION)
|
||||
|
||||
//
|
||||
// versions check:
|
||||
// we don't support Visual C++ prior to version 6:
|
||||
#if _MSC_VER < 1200
|
||||
#error "Compiler not supported or configured - please reconfigure"
|
||||
#endif
|
||||
//
|
||||
// last known and checked version is 1500 (VC9):
|
||||
#if (_MSC_VER > 1600)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# else
|
||||
# pragma message("Unknown compiler version - please run the configure tests and report the results")
|
||||
# endif
|
||||
#endif
|
|
@ -0,0 +1,28 @@
|
|||
// (C) Copyright John Maddock 2008.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// The aim of this header is just to include <cmath> but to do
|
||||
// so in a way that does not result in recursive inclusion of
|
||||
// the Boost TR1 components if boost/tr1/tr1/cmath is in the
|
||||
// include search path. We have to do this to avoid circular
|
||||
// dependencies:
|
||||
//
|
||||
|
||||
#ifndef BOOST_CONFIG_CMATH
|
||||
# define BOOST_CONFIG_CMATH
|
||||
|
||||
# ifndef BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_CONFIG_NO_CMATH_RECURSION
|
||||
# endif
|
||||
|
||||
# include <cmath>
|
||||
|
||||
# ifdef BOOST_CONFIG_NO_CMATH_RECURSION
|
||||
# undef BOOST_TR1_NO_RECURSION
|
||||
# undef BOOST_CONFIG_NO_CMATH_RECURSION
|
||||
# endif
|
||||
|
||||
#endif
|
|
@ -0,0 +1,28 @@
|
|||
// (C) Copyright John Maddock 2005.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// The aim of this header is just to include <complex> but to do
|
||||
// so in a way that does not result in recursive inclusion of
|
||||
// the Boost TR1 components if boost/tr1/tr1/complex is in the
|
||||
// include search path. We have to do this to avoid circular
|
||||
// dependencies:
|
||||
//
|
||||
|
||||
#ifndef BOOST_CONFIG_COMPLEX
|
||||
# define BOOST_CONFIG_COMPLEX
|
||||
|
||||
# ifndef BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_CONFIG_NO_COMPLEX_RECURSION
|
||||
# endif
|
||||
|
||||
# include <complex>
|
||||
|
||||
# ifdef BOOST_CONFIG_NO_COMPLEX_RECURSION
|
||||
# undef BOOST_TR1_NO_RECURSION
|
||||
# undef BOOST_CONFIG_NO_COMPLEX_RECURSION
|
||||
# endif
|
||||
|
||||
#endif
|
|
@ -0,0 +1,28 @@
|
|||
// (C) Copyright John Maddock 2005.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// The aim of this header is just to include <functional> but to do
|
||||
// so in a way that does not result in recursive inclusion of
|
||||
// the Boost TR1 components if boost/tr1/tr1/functional is in the
|
||||
// include search path. We have to do this to avoid circular
|
||||
// dependencies:
|
||||
//
|
||||
|
||||
#ifndef BOOST_CONFIG_FUNCTIONAL
|
||||
# define BOOST_CONFIG_FUNCTIONAL
|
||||
|
||||
# ifndef BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_CONFIG_NO_FUNCTIONAL_RECURSION
|
||||
# endif
|
||||
|
||||
# include <functional>
|
||||
|
||||
# ifdef BOOST_CONFIG_NO_FUNCTIONAL_RECURSION
|
||||
# undef BOOST_TR1_NO_RECURSION
|
||||
# undef BOOST_CONFIG_NO_FUNCTIONAL_RECURSION
|
||||
# endif
|
||||
|
||||
#endif
|
|
@ -0,0 +1,28 @@
|
|||
// (C) Copyright John Maddock 2005.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// The aim of this header is just to include <memory> but to do
|
||||
// so in a way that does not result in recursive inclusion of
|
||||
// the Boost TR1 components if boost/tr1/tr1/memory is in the
|
||||
// include search path. We have to do this to avoid circular
|
||||
// dependencies:
|
||||
//
|
||||
|
||||
#ifndef BOOST_CONFIG_MEMORY
|
||||
# define BOOST_CONFIG_MEMORY
|
||||
|
||||
# ifndef BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_CONFIG_NO_MEMORY_RECURSION
|
||||
# endif
|
||||
|
||||
# include <memory>
|
||||
|
||||
# ifdef BOOST_CONFIG_NO_MEMORY_RECURSION
|
||||
# undef BOOST_TR1_NO_RECURSION
|
||||
# undef BOOST_CONFIG_NO_MEMORY_RECURSION
|
||||
# endif
|
||||
|
||||
#endif
|
|
@ -0,0 +1,28 @@
|
|||
// (C) Copyright John Maddock 2005.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// The aim of this header is just to include <utility> but to do
|
||||
// so in a way that does not result in recursive inclusion of
|
||||
// the Boost TR1 components if boost/tr1/tr1/utility is in the
|
||||
// include search path. We have to do this to avoid circular
|
||||
// dependencies:
|
||||
//
|
||||
|
||||
#ifndef BOOST_CONFIG_UTILITY
|
||||
# define BOOST_CONFIG_UTILITY
|
||||
|
||||
# ifndef BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_TR1_NO_RECURSION
|
||||
# define BOOST_CONFIG_NO_UTILITY_RECURSION
|
||||
# endif
|
||||
|
||||
# include <utility>
|
||||
|
||||
# ifdef BOOST_CONFIG_NO_UTILITY_RECURSION
|
||||
# undef BOOST_TR1_NO_RECURSION
|
||||
# undef BOOST_CONFIG_NO_UTILITY_RECURSION
|
||||
# endif
|
||||
|
||||
#endif
|
|
@ -0,0 +1,33 @@
|
|||
// (C) Copyright John Maddock 2001 - 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// IBM/Aix specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "IBM Aix"
|
||||
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#define BOOST_HAS_NL_TYPES_H
|
||||
#define BOOST_HAS_NANOSLEEP
|
||||
#define BOOST_HAS_CLOCK_GETTIME
|
||||
|
||||
// This needs support in "boost/cstdint.hpp" exactly like FreeBSD.
|
||||
// This platform has header named <inttypes.h> which includes all
|
||||
// the things needed.
|
||||
#define BOOST_HAS_STDINT_H
|
||||
|
||||
// Threading API's:
|
||||
#define BOOST_HAS_PTHREADS
|
||||
#define BOOST_HAS_PTHREAD_DELAY_NP
|
||||
#define BOOST_HAS_SCHED_YIELD
|
||||
//#define BOOST_HAS_PTHREAD_YIELD
|
||||
|
||||
// boilerplate code:
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
// (C) Copyright John Maddock 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
#define BOOST_PLATFORM "AmigaOS"
|
||||
|
||||
#define BOOST_DISABLE_THREADS
|
||||
#define BOOST_NO_CWCHAR
|
||||
#define BOOST_NO_STD_WSTRING
|
||||
#define BOOST_NO_INTRINSIC_WCHAR_T
|
||||
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
// (C) Copyright John Maddock 2001.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// BeOS specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "BeOS"
|
||||
|
||||
#define BOOST_NO_CWCHAR
|
||||
#define BOOST_NO_CWCTYPE
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
|
||||
#define BOOST_HAS_BETHREADS
|
||||
|
||||
#ifndef BOOST_DISABLE_THREADS
|
||||
# define BOOST_HAS_THREADS
|
||||
#endif
|
||||
|
||||
// boilerplate code:
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Darin Adler 2001.
|
||||
// (C) Copyright Douglas Gregor 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// generic BSD config options:
|
||||
|
||||
#if !defined(__FreeBSD__) && !defined(__NetBSD__) && !defined(__OpenBSD__) && !defined(__DragonFly__)
|
||||
#error "This platform is not BSD"
|
||||
#endif
|
||||
|
||||
#ifdef __FreeBSD__
|
||||
#define BOOST_PLATFORM "FreeBSD " BOOST_STRINGIZE(__FreeBSD__)
|
||||
#elif defined(__NetBSD__)
|
||||
#define BOOST_PLATFORM "NetBSD " BOOST_STRINGIZE(__NetBSD__)
|
||||
#elif defined(__OpenBSD__)
|
||||
#define BOOST_PLATFORM "OpenBSD " BOOST_STRINGIZE(__OpenBSD__)
|
||||
#elif defined(__DragonFly__)
|
||||
#define BOOST_PLATFORM "DragonFly " BOOST_STRINGIZE(__DragonFly__)
|
||||
#endif
|
||||
|
||||
//
|
||||
// is this the correct version check?
|
||||
// FreeBSD has <nl_types.h> but does not
|
||||
// advertise the fact in <unistd.h>:
|
||||
//
|
||||
#if (defined(__FreeBSD__) && (__FreeBSD__ >= 3)) || defined(__DragonFly__)
|
||||
# define BOOST_HAS_NL_TYPES_H
|
||||
#endif
|
||||
|
||||
//
|
||||
// FreeBSD 3.x has pthreads support, but defines _POSIX_THREADS in <pthread.h>
|
||||
// and not in <unistd.h>
|
||||
//
|
||||
#if (defined(__FreeBSD__) && (__FreeBSD__ <= 3))\
|
||||
|| defined(__OpenBSD__) || defined(__DragonFly__)
|
||||
# define BOOST_HAS_PTHREADS
|
||||
#endif
|
||||
|
||||
//
|
||||
// No wide character support in the BSD header files:
|
||||
//
|
||||
#if defined(__NetBSD__)
|
||||
#define __NetBSD_GCC__ (__GNUC__ * 1000000 \
|
||||
+ __GNUC_MINOR__ * 1000 \
|
||||
+ __GNUC_PATCHLEVEL__)
|
||||
// XXX - the following is required until c++config.h
|
||||
// defines _GLIBCXX_HAVE_SWPRINTF and friends
|
||||
// or the preprocessor conditionals are removed
|
||||
// from the cwchar header.
|
||||
#define _GLIBCXX_HAVE_SWPRINTF 1
|
||||
#endif
|
||||
|
||||
#if !((defined(__FreeBSD__) && (__FreeBSD__ >= 5)) \
|
||||
|| (__NetBSD_GCC__ >= 2095003) || defined(__DragonFly__))
|
||||
# define BOOST_NO_CWCHAR
|
||||
#endif
|
||||
//
|
||||
// The BSD <ctype.h> has macros only, no functions:
|
||||
//
|
||||
#if !defined(__OpenBSD__) || defined(__DragonFly__)
|
||||
# define BOOST_NO_CTYPE_FUNCTIONS
|
||||
#endif
|
||||
|
||||
//
|
||||
// thread API's not auto detected:
|
||||
//
|
||||
#define BOOST_HAS_SCHED_YIELD
|
||||
#define BOOST_HAS_NANOSLEEP
|
||||
#define BOOST_HAS_GETTIMEOFDAY
|
||||
#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
#define BOOST_HAS_SIGACTION
|
||||
|
||||
// boilerplate code:
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// cygwin specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "Cygwin"
|
||||
#define BOOST_NO_CWCTYPE
|
||||
#define BOOST_NO_CWCHAR
|
||||
#define BOOST_NO_SWPRINTF
|
||||
#define BOOST_HAS_DIRENT_H
|
||||
#define BOOST_HAS_LOG1P
|
||||
#define BOOST_HAS_EXPM1
|
||||
|
||||
//
|
||||
// Threading API:
|
||||
// See if we have POSIX threads, if we do use them, otherwise
|
||||
// revert to native Win threads.
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#if defined(_POSIX_THREADS) && (_POSIX_THREADS+0 >= 0) && !defined(BOOST_HAS_WINTHREADS)
|
||||
# define BOOST_HAS_PTHREADS
|
||||
# define BOOST_HAS_SCHED_YIELD
|
||||
# define BOOST_HAS_GETTIMEOFDAY
|
||||
# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
# define BOOST_HAS_SIGACTION
|
||||
#else
|
||||
# if !defined(BOOST_HAS_WINTHREADS)
|
||||
# define BOOST_HAS_WINTHREADS
|
||||
# endif
|
||||
# define BOOST_HAS_FTIME
|
||||
#endif
|
||||
|
||||
//
|
||||
// find out if we have a stdint.h, there should be a better way to do this:
|
||||
//
|
||||
#include <sys/types.h>
|
||||
#ifdef _STDINT_H
|
||||
#define BOOST_HAS_STDINT_H
|
||||
#endif
|
||||
|
||||
// boilerplate code:
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,87 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2001 - 2003.
|
||||
// (C) Copyright David Abrahams 2002.
|
||||
// (C) Copyright Toon Knapen 2003.
|
||||
// (C) Copyright Boris Gubenko 2006 - 2007.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// hpux specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "HP-UX"
|
||||
|
||||
// In principle, HP-UX has a nice <stdint.h> under the name <inttypes.h>
|
||||
// However, it has the following problem:
|
||||
// Use of UINT32_C(0) results in "0u l" for the preprocessed source
|
||||
// (verifyable with gcc 2.95.3)
|
||||
#if (defined(__GNUC__) && (__GNUC__ >= 3)) || defined(__HP_aCC)
|
||||
# define BOOST_HAS_STDINT_H
|
||||
#endif
|
||||
|
||||
#if !(defined(__HP_aCC) || !defined(_INCLUDE__STDC_A1_SOURCE))
|
||||
# define BOOST_NO_SWPRINTF
|
||||
#endif
|
||||
#if defined(__HP_aCC) && !defined(_INCLUDE__STDC_A1_SOURCE)
|
||||
# define BOOST_NO_CWCTYPE
|
||||
#endif
|
||||
|
||||
#if defined(__GNUC__)
|
||||
# if (__GNUC__ < 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ < 3))
|
||||
// GNU C on HP-UX does not support threads (checked up to gcc 3.3)
|
||||
# define BOOST_DISABLE_THREADS
|
||||
# elif !defined(BOOST_DISABLE_THREADS)
|
||||
// threads supported from gcc-3.3 onwards:
|
||||
# define BOOST_HAS_THREADS
|
||||
# define BOOST_HAS_PTHREADS
|
||||
# endif
|
||||
#elif defined(__HP_aCC) && !defined(BOOST_DISABLE_THREADS)
|
||||
# define BOOST_HAS_PTHREADS
|
||||
#endif
|
||||
|
||||
// boilerplate code:
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
// the following are always available:
|
||||
#ifndef BOOST_HAS_GETTIMEOFDAY
|
||||
# define BOOST_HAS_GETTIMEOFDAY
|
||||
#endif
|
||||
#ifndef BOOST_HAS_SCHED_YIELD
|
||||
# define BOOST_HAS_SCHED_YIELD
|
||||
#endif
|
||||
#ifndef BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
#endif
|
||||
#ifndef BOOST_HAS_NL_TYPES_H
|
||||
# define BOOST_HAS_NL_TYPES_H
|
||||
#endif
|
||||
#ifndef BOOST_HAS_NANOSLEEP
|
||||
# define BOOST_HAS_NANOSLEEP
|
||||
#endif
|
||||
#ifndef BOOST_HAS_GETTIMEOFDAY
|
||||
# define BOOST_HAS_GETTIMEOFDAY
|
||||
#endif
|
||||
#ifndef BOOST_HAS_DIRENT_H
|
||||
# define BOOST_HAS_DIRENT_H
|
||||
#endif
|
||||
#ifndef BOOST_HAS_CLOCK_GETTIME
|
||||
# define BOOST_HAS_CLOCK_GETTIME
|
||||
#endif
|
||||
#ifndef BOOST_HAS_SIGACTION
|
||||
# define BOOST_HAS_SIGACTION
|
||||
#endif
|
||||
#ifndef BOOST_HAS_NRVO
|
||||
# ifndef __parisc
|
||||
# define BOOST_HAS_NRVO
|
||||
# endif
|
||||
#endif
|
||||
#ifndef BOOST_HAS_LOG1P
|
||||
# define BOOST_HAS_LOG1P
|
||||
#endif
|
||||
#ifndef BOOST_HAS_EXPM1
|
||||
# define BOOST_HAS_EXPM1
|
||||
#endif
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// SGI Irix specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "SGI Irix"
|
||||
|
||||
#define BOOST_NO_SWPRINTF
|
||||
//
|
||||
// these are not auto detected by POSIX feature tests:
|
||||
//
|
||||
#define BOOST_HAS_GETTIMEOFDAY
|
||||
#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
|
||||
#ifdef __GNUC__
|
||||
// GNU C on IRIX does not support threads (checked up to gcc 3.3)
|
||||
# define BOOST_DISABLE_THREADS
|
||||
#endif
|
||||
|
||||
// boilerplate code:
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,98 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2001 - 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// linux specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "linux"
|
||||
|
||||
// make sure we have __GLIBC_PREREQ if available at all
|
||||
#include <cstdlib>
|
||||
|
||||
//
|
||||
// <stdint.h> added to glibc 2.1.1
|
||||
// We can only test for 2.1 though:
|
||||
//
|
||||
#if defined(__GLIBC__) && ((__GLIBC__ > 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ >= 1)))
|
||||
// <stdint.h> defines int64_t unconditionally, but <sys/types.h> defines
|
||||
// int64_t only if __GNUC__. Thus, assume a fully usable <stdint.h>
|
||||
// only when using GCC.
|
||||
# if defined __GNUC__
|
||||
# define BOOST_HAS_STDINT_H
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if defined(__LIBCOMO__)
|
||||
//
|
||||
// como on linux doesn't have std:: c functions:
|
||||
// NOTE: versions of libcomo prior to beta28 have octal version numbering,
|
||||
// e.g. version 25 is 21 (dec)
|
||||
//
|
||||
# if __LIBCOMO_VERSION__ <= 20
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
# endif
|
||||
|
||||
# if __LIBCOMO_VERSION__ <= 21
|
||||
# define BOOST_NO_SWPRINTF
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
//
|
||||
// If glibc is past version 2 then we definitely have
|
||||
// gettimeofday, earlier versions may or may not have it:
|
||||
//
|
||||
#if defined(__GLIBC__) && (__GLIBC__ >= 2)
|
||||
# define BOOST_HAS_GETTIMEOFDAY
|
||||
#endif
|
||||
|
||||
#ifdef __USE_POSIX199309
|
||||
# define BOOST_HAS_NANOSLEEP
|
||||
#endif
|
||||
|
||||
#if defined(__GLIBC__) && defined(__GLIBC_PREREQ)
|
||||
// __GLIBC_PREREQ is available since 2.1.2
|
||||
|
||||
// swprintf is available since glibc 2.2.0
|
||||
# if !__GLIBC_PREREQ(2,2) || (!defined(__USE_ISOC99) && !defined(__USE_UNIX98))
|
||||
# define BOOST_NO_SWPRINTF
|
||||
# endif
|
||||
#else
|
||||
# define BOOST_NO_SWPRINTF
|
||||
#endif
|
||||
|
||||
// boilerplate code:
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
#ifndef __GNUC__
|
||||
//
|
||||
// if the compiler is not gcc we still need to be able to parse
|
||||
// the GNU system headers, some of which (mainly <stdint.h>)
|
||||
// use GNU specific extensions:
|
||||
//
|
||||
# ifndef __extension__
|
||||
# define __extension__
|
||||
# endif
|
||||
# ifndef __const__
|
||||
# define __const__ const
|
||||
# endif
|
||||
# ifndef __volatile__
|
||||
# define __volatile__ volatile
|
||||
# endif
|
||||
# ifndef __signed__
|
||||
# define __signed__ signed
|
||||
# endif
|
||||
# ifndef __typeof__
|
||||
# define __typeof__ typeof
|
||||
# endif
|
||||
# ifndef __inline__
|
||||
# define __inline__ inline
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Darin Adler 2001 - 2002.
|
||||
// (C) Copyright Bill Kempf 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Mac OS specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "Mac OS"
|
||||
|
||||
#if __MACH__ && !defined(_MSL_USING_MSL_C)
|
||||
|
||||
// Using the Mac OS X system BSD-style C library.
|
||||
|
||||
# ifndef BOOST_HAS_UNISTD_H
|
||||
# define BOOST_HAS_UNISTD_H
|
||||
# endif
|
||||
//
|
||||
// Begin by including our boilerplate code for POSIX
|
||||
// feature detection, this is safe even when using
|
||||
// the MSL as Metrowerks supply their own <unistd.h>
|
||||
// to replace the platform-native BSD one. G++ users
|
||||
// should also always be able to do this on MaxOS X.
|
||||
//
|
||||
# include <boost/config/posix_features.hpp>
|
||||
# ifndef BOOST_HAS_STDINT_H
|
||||
# define BOOST_HAS_STDINT_H
|
||||
# endif
|
||||
|
||||
//
|
||||
// BSD runtime has pthreads, sigaction, sched_yield and gettimeofday,
|
||||
// of these only pthreads are advertised in <unistd.h>, so set the
|
||||
// other options explicitly:
|
||||
//
|
||||
# define BOOST_HAS_SCHED_YIELD
|
||||
# define BOOST_HAS_GETTIMEOFDAY
|
||||
# define BOOST_HAS_SIGACTION
|
||||
|
||||
# if (__GNUC__ < 3) && !defined( __APPLE_CC__)
|
||||
|
||||
// GCC strange "ignore std" mode works better if you pretend everything
|
||||
// is in the std namespace, for the most part.
|
||||
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
# endif
|
||||
|
||||
# if (__GNUC__ == 4)
|
||||
|
||||
// Both gcc and intel require these.
|
||||
# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
# define BOOST_HAS_NANOSLEEP
|
||||
|
||||
# endif
|
||||
|
||||
#else
|
||||
|
||||
// Using the MSL C library.
|
||||
|
||||
// We will eventually support threads in non-Carbon builds, but we do
|
||||
// not support this yet.
|
||||
# if ( defined(TARGET_API_MAC_CARBON) && TARGET_API_MAC_CARBON ) || ( defined(TARGET_CARBON) && TARGET_CARBON )
|
||||
|
||||
# if !defined(BOOST_HAS_PTHREADS)
|
||||
# define BOOST_HAS_MPTASKS
|
||||
# elif ( __dest_os == __mac_os_x )
|
||||
// We are doing a Carbon/Mach-O/MSL build which has pthreads, but only the
|
||||
// gettimeofday and no posix.
|
||||
# define BOOST_HAS_GETTIMEOFDAY
|
||||
# endif
|
||||
|
||||
// The MP task implementation of Boost Threads aims to replace MP-unsafe
|
||||
// parts of the MSL, so we turn on threads unconditionally.
|
||||
# define BOOST_HAS_THREADS
|
||||
|
||||
// The remote call manager depends on this.
|
||||
# define BOOST_BIND_ENABLE_PASCAL
|
||||
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
// (C) Copyright Jim Douglas 2005.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// QNX specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "QNX"
|
||||
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
// QNX claims XOpen version 5 compatibility, but doesn't have an nl_types.h
|
||||
// or log1p and expm1:
|
||||
#undef BOOST_HAS_NL_TYPES_H
|
||||
#undef BOOST_HAS_LOG1P
|
||||
#undef BOOST_HAS_EXPM1
|
||||
|
||||
#define BOOST_HAS_PTHREADS
|
||||
#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
|
||||
#define BOOST_HAS_GETTIMEOFDAY
|
||||
#define BOOST_HAS_CLOCK_GETTIME
|
||||
#define BOOST_HAS_NANOSLEEP
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// sun specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "Sun Solaris"
|
||||
|
||||
#define BOOST_HAS_GETTIMEOFDAY
|
||||
|
||||
// boilerplate code:
|
||||
#define BOOST_HAS_UNISTD_H
|
||||
#include <boost/config/posix_features.hpp>
|
||||
|
||||
//
|
||||
// pthreads don't actually work with gcc unless _PTHREADS is defined:
|
||||
//
|
||||
#if defined(__GNUC__) && defined(_POSIX_THREADS) && !defined(_PTHREADS)
|
||||
# undef BOOST_HAS_PTHREADS
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,58 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Bill Kempf 2001.
|
||||
// (C) Copyright Aleksey Gurtovoy 2003.
|
||||
// (C) Copyright Rene Rivera 2005.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Win32 specific config options:
|
||||
|
||||
#define BOOST_PLATFORM "Win32"
|
||||
|
||||
// Get the information about the MinGW runtime, i.e. __MINGW32_*VERSION.
|
||||
#if defined(__MINGW32__)
|
||||
# include <_mingw.h>
|
||||
#endif
|
||||
|
||||
#if defined(__GNUC__) && !defined(BOOST_NO_SWPRINTF)
|
||||
# define BOOST_NO_SWPRINTF
|
||||
#endif
|
||||
|
||||
#if !defined(__GNUC__) && !defined(BOOST_HAS_DECLSPEC)
|
||||
# define BOOST_HAS_DECLSPEC
|
||||
#endif
|
||||
|
||||
#if defined(__MINGW32__) && ((__MINGW32_MAJOR_VERSION > 2) || ((__MINGW32_MAJOR_VERSION == 2) && (__MINGW32_MINOR_VERSION >= 0)))
|
||||
# define BOOST_HAS_STDINT_H
|
||||
# define __STDC_LIMIT_MACROS
|
||||
# define BOOST_HAS_DIRENT_H
|
||||
# define BOOST_HAS_UNISTD_H
|
||||
#endif
|
||||
|
||||
//
|
||||
// Win32 will normally be using native Win32 threads,
|
||||
// but there is a pthread library avaliable as an option,
|
||||
// we used to disable this when BOOST_DISABLE_WIN32 was
|
||||
// defined but no longer - this should allow some
|
||||
// files to be compiled in strict mode - while maintaining
|
||||
// a consistent setting of BOOST_HAS_THREADS across
|
||||
// all translation units (needed for shared_ptr etc).
|
||||
//
|
||||
|
||||
#ifdef _WIN32_WCE
|
||||
# define BOOST_NO_ANSI_APIS
|
||||
#endif
|
||||
|
||||
#ifndef BOOST_HAS_PTHREADS
|
||||
# define BOOST_HAS_WINTHREADS
|
||||
#endif
|
||||
|
||||
#ifndef BOOST_DISABLE_WIN32
|
||||
// WEK: Added
|
||||
#define BOOST_HAS_FTIME
|
||||
#define BOOST_WINDOWS 1
|
||||
|
||||
#endif
|
|
@ -0,0 +1,95 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// All POSIX feature tests go in this file,
|
||||
// Note that we test _POSIX_C_SOURCE and _XOPEN_SOURCE as well
|
||||
// _POSIX_VERSION and _XOPEN_VERSION: on some systems POSIX API's
|
||||
// may be present but none-functional unless _POSIX_C_SOURCE and
|
||||
// _XOPEN_SOURCE have been defined to the right value (it's up
|
||||
// to the user to do this *before* including any header, although
|
||||
// in most cases the compiler will do this for you).
|
||||
|
||||
# if defined(BOOST_HAS_UNISTD_H)
|
||||
# include <unistd.h>
|
||||
|
||||
// XOpen has <nl_types.h>, but is this the correct version check?
|
||||
# if defined(_XOPEN_VERSION) && (_XOPEN_VERSION >= 3)
|
||||
# define BOOST_HAS_NL_TYPES_H
|
||||
# endif
|
||||
|
||||
// POSIX version 6 requires <stdint.h>
|
||||
# if defined(_POSIX_VERSION) && (_POSIX_VERSION >= 200100)
|
||||
# define BOOST_HAS_STDINT_H
|
||||
# endif
|
||||
|
||||
// POSIX version 2 requires <dirent.h>
|
||||
# if defined(_POSIX_VERSION) && (_POSIX_VERSION >= 199009L)
|
||||
# define BOOST_HAS_DIRENT_H
|
||||
# endif
|
||||
|
||||
// POSIX version 3 requires <signal.h> to have sigaction:
|
||||
# if defined(_POSIX_VERSION) && (_POSIX_VERSION >= 199506L)
|
||||
# define BOOST_HAS_SIGACTION
|
||||
# endif
|
||||
// POSIX defines _POSIX_THREADS > 0 for pthread support,
|
||||
// however some platforms define _POSIX_THREADS without
|
||||
// a value, hence the (_POSIX_THREADS+0 >= 0) check.
|
||||
// Strictly speaking this may catch platforms with a
|
||||
// non-functioning stub <pthreads.h>, but such occurrences should
|
||||
// occur very rarely if at all.
|
||||
# if defined(_POSIX_THREADS) && (_POSIX_THREADS+0 >= 0) && !defined(BOOST_HAS_WINTHREADS) && !defined(BOOST_HAS_MPTASKS)
|
||||
# define BOOST_HAS_PTHREADS
|
||||
# endif
|
||||
|
||||
// BOOST_HAS_NANOSLEEP:
|
||||
// This is predicated on _POSIX_TIMERS or _XOPEN_REALTIME:
|
||||
# if (defined(_POSIX_TIMERS) && (_POSIX_TIMERS+0 >= 0)) \
|
||||
|| (defined(_XOPEN_REALTIME) && (_XOPEN_REALTIME+0 >= 0))
|
||||
# define BOOST_HAS_NANOSLEEP
|
||||
# endif
|
||||
|
||||
// BOOST_HAS_CLOCK_GETTIME:
|
||||
// This is predicated on _POSIX_TIMERS (also on _XOPEN_REALTIME
|
||||
// but at least one platform - linux - defines that flag without
|
||||
// defining clock_gettime):
|
||||
# if (defined(_POSIX_TIMERS) && (_POSIX_TIMERS+0 >= 0))
|
||||
# define BOOST_HAS_CLOCK_GETTIME
|
||||
# endif
|
||||
|
||||
// BOOST_HAS_SCHED_YIELD:
|
||||
// This is predicated on _POSIX_PRIORITY_SCHEDULING or
|
||||
// on _POSIX_THREAD_PRIORITY_SCHEDULING or on _XOPEN_REALTIME.
|
||||
# if defined(_POSIX_PRIORITY_SCHEDULING) && (_POSIX_PRIORITY_SCHEDULING+0 > 0)\
|
||||
|| (defined(_POSIX_THREAD_PRIORITY_SCHEDULING) && (_POSIX_THREAD_PRIORITY_SCHEDULING+0 > 0))\
|
||||
|| (defined(_XOPEN_REALTIME) && (_XOPEN_REALTIME+0 >= 0))
|
||||
# define BOOST_HAS_SCHED_YIELD
|
||||
# endif
|
||||
|
||||
// BOOST_HAS_GETTIMEOFDAY:
|
||||
// BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE:
|
||||
// These are predicated on _XOPEN_VERSION, and appears to be first released
|
||||
// in issue 4, version 2 (_XOPEN_VERSION > 500).
|
||||
// Likewise for the functions log1p and expm1.
|
||||
# if defined(_XOPEN_VERSION) && (_XOPEN_VERSION+0 >= 500)
|
||||
# define BOOST_HAS_GETTIMEOFDAY
|
||||
# if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE+0 >= 500)
|
||||
# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
|
||||
# endif
|
||||
# ifndef BOOST_HAS_LOG1P
|
||||
# define BOOST_HAS_LOG1P
|
||||
# endif
|
||||
# ifndef BOOST_HAS_EXPM1
|
||||
# define BOOST_HAS_EXPM1
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# endif
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,92 @@
|
|||
// (C) Copyright John Maddock 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
|
||||
#ifndef BOOST_CONFIG_REQUIRES_THREADS_HPP
|
||||
#define BOOST_CONFIG_REQUIRES_THREADS_HPP
|
||||
|
||||
#ifndef BOOST_CONFIG_HPP
|
||||
# include <boost/config.hpp>
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_DISABLE_THREADS)
|
||||
|
||||
//
|
||||
// special case to handle versions of gcc which don't currently support threads:
|
||||
//
|
||||
#if defined(__GNUC__) && ((__GNUC__ < 3) || (__GNUC_MINOR__ <= 3) || !defined(BOOST_STRICT_CONFIG))
|
||||
//
|
||||
// this is checked up to gcc 3.3:
|
||||
//
|
||||
#if defined(__sgi) || defined(__hpux)
|
||||
# error "Multi-threaded programs are not supported by gcc on HPUX or Irix (last checked with gcc 3.3)"
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
# error "Threading support unavaliable: it has been explicitly disabled with BOOST_DISABLE_THREADS"
|
||||
|
||||
#elif !defined(BOOST_HAS_THREADS)
|
||||
|
||||
# if defined __COMO__
|
||||
// Comeau C++
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -D_MT (Windows) or -D_REENTRANT (Unix)"
|
||||
|
||||
#elif defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)
|
||||
// Intel
|
||||
#ifdef _WIN32
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: either /MT /MTd /MD or /MDd"
|
||||
#else
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -openmp"
|
||||
#endif
|
||||
|
||||
# elif defined __GNUC__
|
||||
// GNU C++:
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -pthread (Linux), -pthreads (Solaris) or -mthreads (Mingw32)"
|
||||
|
||||
#elif defined __sgi
|
||||
// SGI MIPSpro C++
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -D_SGI_MP_SOURCE"
|
||||
|
||||
#elif defined __DECCXX
|
||||
// Compaq Tru64 Unix cxx
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -pthread"
|
||||
|
||||
#elif defined __BORLANDC__
|
||||
// Borland
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -tWM"
|
||||
|
||||
#elif defined __MWERKS__
|
||||
// Metrowerks CodeWarrior
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: either -runtime sm, -runtime smd, -runtime dm, or -runtime dmd"
|
||||
|
||||
#elif defined __SUNPRO_CC
|
||||
// Sun Workshop Compiler C++
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -mt"
|
||||
|
||||
#elif defined __HP_aCC
|
||||
// HP aCC
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -mt"
|
||||
|
||||
#elif defined(__IBMCPP__)
|
||||
// IBM Visual Age
|
||||
# error "Compiler threading support is not turned on. Please compile the code with the xlC_r compiler"
|
||||
|
||||
#elif defined _MSC_VER
|
||||
// Microsoft Visual C++
|
||||
//
|
||||
// Must remain the last #elif since some other vendors (Metrowerks, for
|
||||
// example) also #define _MSC_VER
|
||||
# error "Compiler threading support is not turned on. Please set the correct command line options for threading: either /MT /MTd /MD or /MDd"
|
||||
|
||||
#else
|
||||
|
||||
# error "Compiler threading support is not turned on. Please consult your compiler's documentation for the appropriate options to use"
|
||||
|
||||
#endif // compilers
|
||||
|
||||
#endif // BOOST_HAS_THREADS
|
||||
|
||||
#endif // BOOST_CONFIG_REQUIRES_THREADS_HPP
|
|
@ -0,0 +1,119 @@
|
|||
// Boost compiler configuration selection header file
|
||||
|
||||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Martin Wille 2003.
|
||||
// (C) Copyright Guillaume Melquiond 2003.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org/ for most recent version.
|
||||
|
||||
|
||||
// one identification macro for each of the
|
||||
// compilers we support:
|
||||
|
||||
# define BOOST_CXX_GCCXML 0
|
||||
# define BOOST_CXX_COMO 0
|
||||
# define BOOST_CXX_DMC 0
|
||||
# define BOOST_CXX_INTEL 0
|
||||
# define BOOST_CXX_GNUC 0
|
||||
# define BOOST_CXX_KCC 0
|
||||
# define BOOST_CXX_SGI 0
|
||||
# define BOOST_CXX_TRU64 0
|
||||
# define BOOST_CXX_GHS 0
|
||||
# define BOOST_CXX_BORLAND 0
|
||||
# define BOOST_CXX_CW 0
|
||||
# define BOOST_CXX_SUNPRO 0
|
||||
# define BOOST_CXX_HPACC 0
|
||||
# define BOOST_CXX_MPW 0
|
||||
# define BOOST_CXX_IBMCPP 0
|
||||
# define BOOST_CXX_MSVC 0
|
||||
# define BOOST_CXX_PGI 0
|
||||
|
||||
|
||||
// locate which compiler we are using and define
|
||||
// BOOST_COMPILER_CONFIG as needed:
|
||||
|
||||
#if defined(__GCCXML__)
|
||||
// GCC-XML emulates other compilers, it has to appear first here!
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/gcc_xml.hpp"
|
||||
|
||||
#elif defined __COMO__
|
||||
// Comeau C++
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/comeau.hpp"
|
||||
|
||||
#elif defined __DMC__
|
||||
// Digital Mars C++
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/digitalmars.hpp"
|
||||
|
||||
#elif defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)
|
||||
// Intel
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/intel.hpp"
|
||||
|
||||
# elif defined __GNUC__
|
||||
// GNU C++:
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/gcc.hpp"
|
||||
|
||||
#elif defined __KCC
|
||||
// Kai C++
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/kai.hpp"
|
||||
|
||||
#elif defined __sgi
|
||||
// SGI MIPSpro C++
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/sgi_mipspro.hpp"
|
||||
|
||||
#elif defined __DECCXX
|
||||
// Compaq Tru64 Unix cxx
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/compaq_cxx.hpp"
|
||||
|
||||
#elif defined __ghs
|
||||
// Greenhills C++
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/greenhills.hpp"
|
||||
|
||||
#elif defined __CODEGEARC__
|
||||
// CodeGear - must be checked for before Borland
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/codegear.hpp"
|
||||
|
||||
#elif defined __BORLANDC__
|
||||
// Borland
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/borland.hpp"
|
||||
|
||||
#elif defined __MWERKS__
|
||||
// Metrowerks CodeWarrior
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/metrowerks.hpp"
|
||||
|
||||
#elif defined __SUNPRO_CC
|
||||
// Sun Workshop Compiler C++
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/sunpro_cc.hpp"
|
||||
|
||||
#elif defined __HP_aCC
|
||||
// HP aCC
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/hp_acc.hpp"
|
||||
|
||||
#elif defined(__MRC__) || defined(__SC__)
|
||||
// MPW MrCpp or SCpp
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/mpw.hpp"
|
||||
|
||||
#elif defined(__IBMCPP__)
|
||||
// IBM Visual Age
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/vacpp.hpp"
|
||||
|
||||
#elif defined(__PGI)
|
||||
// Portland Group Inc.
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/pgi.hpp"
|
||||
|
||||
#elif defined _MSC_VER
|
||||
// Microsoft Visual C++
|
||||
//
|
||||
// Must remain the last #elif since some other vendors (Metrowerks, for
|
||||
// example) also #define _MSC_VER
|
||||
# define BOOST_COMPILER_CONFIG "boost/config/compiler/visualc.hpp"
|
||||
|
||||
#elif defined (BOOST_ASSERT_CONFIG)
|
||||
// this must come last - generate an error if we don't
|
||||
// recognise the compiler:
|
||||
# error "Unknown compiler - please configure (http://www.boost.org/libs/config/config.htm#configuring) and report the results to the main boost mailing list (http://www.boost.org/more/mailing_lists.htm#main)"
|
||||
|
||||
#endif
|
|
@ -0,0 +1,90 @@
|
|||
// Boost compiler configuration selection header file
|
||||
|
||||
// (C) Copyright John Maddock 2001 - 2002.
|
||||
// (C) Copyright Jens Maurer 2001.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// locate which platform we are on and define BOOST_PLATFORM_CONFIG as needed.
|
||||
// Note that we define the headers to include using "header_name" not
|
||||
// <header_name> in order to prevent macro expansion within the header
|
||||
// name (for example "linux" is a macro on linux systems).
|
||||
|
||||
#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)
|
||||
// linux, also other platforms (Hurd etc) that use GLIBC, should these really have their own config headers though?
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/linux.hpp"
|
||||
|
||||
#elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
|
||||
// BSD:
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/bsd.hpp"
|
||||
|
||||
#elif defined(sun) || defined(__sun)
|
||||
// solaris:
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/solaris.hpp"
|
||||
|
||||
#elif defined(__sgi)
|
||||
// SGI Irix:
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/irix.hpp"
|
||||
|
||||
#elif defined(__hpux)
|
||||
// hp unix:
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/hpux.hpp"
|
||||
|
||||
#elif defined(__CYGWIN__)
|
||||
// cygwin is not win32:
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/cygwin.hpp"
|
||||
|
||||
#elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
|
||||
// win32:
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/win32.hpp"
|
||||
|
||||
#elif defined(__BEOS__)
|
||||
// BeOS
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/beos.hpp"
|
||||
|
||||
#elif defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)
|
||||
// MacOS
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/macos.hpp"
|
||||
|
||||
#elif defined(__IBMCPP__) || defined(_AIX)
|
||||
// IBM
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/aix.hpp"
|
||||
|
||||
#elif defined(__amigaos__)
|
||||
// AmigaOS
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/amigaos.hpp"
|
||||
|
||||
#elif defined(__QNXNTO__)
|
||||
// QNX:
|
||||
# define BOOST_PLATFORM_CONFIG "boost/config/platform/qnxnto.hpp"
|
||||
|
||||
#else
|
||||
|
||||
# if defined(unix) \
|
||||
|| defined(__unix) \
|
||||
|| defined(_XOPEN_SOURCE) \
|
||||
|| defined(_POSIX_SOURCE)
|
||||
|
||||
// generic unix platform:
|
||||
|
||||
# ifndef BOOST_HAS_UNISTD_H
|
||||
# define BOOST_HAS_UNISTD_H
|
||||
# endif
|
||||
|
||||
# include <boost/config/posix_features.hpp>
|
||||
|
||||
# endif
|
||||
|
||||
# if defined (BOOST_ASSERT_CONFIG)
|
||||
// this must come last - generate an error if we don't
|
||||
// recognise the platform:
|
||||
# error "Unknown platform - please configure and report the results to boost.org"
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,68 @@
|
|||
// Boost compiler configuration selection header file
|
||||
|
||||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2001 - 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// locate which std lib we are using and define BOOST_STDLIB_CONFIG as needed:
|
||||
|
||||
// we need to include a std lib header here in order to detect which
|
||||
// library is in use, use <utility> as it's about the smallest
|
||||
// of the std lib headers - do not rely on this header being included -
|
||||
// users can short-circuit this header if they know whose std lib
|
||||
// they are using.
|
||||
|
||||
#include <boost/config/no_tr1/utility.hpp>
|
||||
|
||||
#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)
|
||||
// STLPort library; this _must_ come first, otherwise since
|
||||
// STLport typically sits on top of some other library, we
|
||||
// can end up detecting that first rather than STLport:
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/stlport.hpp"
|
||||
|
||||
#elif defined(__LIBCOMO__)
|
||||
// Comeau STL:
|
||||
#define BOOST_STDLIB_CONFIG "boost/config/stdlib/libcomo.hpp"
|
||||
|
||||
#elif defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER)
|
||||
// Rogue Wave library:
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/roguewave.hpp"
|
||||
|
||||
#elif defined(__GLIBCPP__) || defined(__GLIBCXX__)
|
||||
// GNU libstdc++ 3
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/libstdcpp3.hpp"
|
||||
|
||||
#elif defined(__STL_CONFIG_H)
|
||||
// generic SGI STL
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/sgi.hpp"
|
||||
|
||||
#elif defined(__MSL_CPP__)
|
||||
// MSL standard lib:
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/msl.hpp"
|
||||
|
||||
#elif defined(__IBMCPP__)
|
||||
// take the default VACPP std lib
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/vacpp.hpp"
|
||||
|
||||
#elif defined(MSIPL_COMPILE_H)
|
||||
// Modena C++ standard library
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/modena.hpp"
|
||||
|
||||
#elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER)
|
||||
// Dinkumware Library (this has to appear after any possible replacement libraries):
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/dinkumware.hpp"
|
||||
|
||||
#elif defined (BOOST_ASSERT_CONFIG)
|
||||
// this must come last - generate an error if we don't
|
||||
// recognise the library:
|
||||
# error "Unknown standard library - please configure and report the results to boost.org"
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,111 @@
|
|||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2001.
|
||||
// (C) Copyright Peter Dimov 2001.
|
||||
// (C) Copyright David Abrahams 2002.
|
||||
// (C) Copyright Guillaume Melquiond 2003.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Dinkumware standard library config:
|
||||
|
||||
#if !defined(_YVALS) && !defined(_CPPLIB_VER)
|
||||
#include <boost/config/no_tr1/utility.hpp>
|
||||
#if !defined(_YVALS) && !defined(_CPPLIB_VER)
|
||||
#error This is not the Dinkumware lib!
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#if defined(_CPPLIB_VER) && (_CPPLIB_VER >= 306)
|
||||
// full dinkumware 3.06 and above
|
||||
// fully conforming provided the compiler supports it:
|
||||
# if !(defined(_GLOBAL_USING) && (_GLOBAL_USING+0 > 0)) && !defined(__BORLANDC__) && !defined(_STD) && !(defined(__ICC) && (__ICC >= 700)) // can be defined in yvals.h
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
# endif
|
||||
# if !(defined(_HAS_MEMBER_TEMPLATES_REBIND) && (_HAS_MEMBER_TEMPLATES_REBIND+0 > 0)) && !(defined(_MSC_VER) && (_MSC_VER > 1300)) && defined(BOOST_MSVC)
|
||||
# define BOOST_NO_STD_ALLOCATOR
|
||||
# endif
|
||||
# define BOOST_HAS_PARTIAL_STD_ALLOCATOR
|
||||
# if defined(BOOST_MSVC) && (BOOST_MSVC < 1300)
|
||||
// if this lib version is set up for vc6 then there is no std::use_facet:
|
||||
# define BOOST_NO_STD_USE_FACET
|
||||
# define BOOST_HAS_TWO_ARG_USE_FACET
|
||||
// C lib functions aren't in namespace std either:
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
// and nor is <exception>
|
||||
# define BOOST_NO_EXCEPTION_STD_NAMESPACE
|
||||
# endif
|
||||
// There's no numeric_limits<long long> support unless _LONGLONG is defined:
|
||||
# if !defined(_LONGLONG) && (_CPPLIB_VER <= 310)
|
||||
# define BOOST_NO_MS_INT64_NUMERIC_LIMITS
|
||||
# endif
|
||||
// 3.06 appears to have (non-sgi versions of) <hash_set> & <hash_map>,
|
||||
// and no <slist> at all
|
||||
#else
|
||||
# define BOOST_MSVC_STD_ITERATOR 1
|
||||
# define BOOST_NO_STD_ITERATOR
|
||||
# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS
|
||||
# define BOOST_NO_STD_ALLOCATOR
|
||||
# define BOOST_NO_STDC_NAMESPACE
|
||||
# define BOOST_NO_STD_USE_FACET
|
||||
# define BOOST_NO_STD_OUTPUT_ITERATOR_ASSIGN
|
||||
# define BOOST_HAS_MACRO_USE_FACET
|
||||
# ifndef _CPPLIB_VER
|
||||
// Updated Dinkum library defines this, and provides
|
||||
// its own min and max definitions.
|
||||
# define BOOST_NO_STD_MIN_MAX
|
||||
# define BOOST_NO_MS_INT64_NUMERIC_LIMITS
|
||||
# endif
|
||||
#endif
|
||||
|
||||
//
|
||||
// std extension namespace is stdext for vc7.1 and later,
|
||||
// the same applies to other compilers that sit on top
|
||||
// of vc7.1 (Intel and Comeau):
|
||||
//
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1310) && !defined(__BORLANDC__)
|
||||
# define BOOST_STD_EXTENSION_NAMESPACE stdext
|
||||
#endif
|
||||
|
||||
|
||||
#if (defined(_MSC_VER) && (_MSC_VER <= 1300) && !defined(__BORLANDC__)) || !defined(_CPPLIB_VER) || (_CPPLIB_VER < 306)
|
||||
// if we're using a dinkum lib that's
|
||||
// been configured for VC6/7 then there is
|
||||
// no iterator traits (true even for icl)
|
||||
# define BOOST_NO_STD_ITERATOR_TRAITS
|
||||
#endif
|
||||
|
||||
//
|
||||
// No std::unordered_* containers yet:
|
||||
//
|
||||
#define BOOST_NO_STD_UNORDERED
|
||||
|
||||
#if defined(__ICL) && (__ICL < 800) && defined(_CPPLIB_VER) && (_CPPLIB_VER <= 310)
|
||||
// Intel C++ chokes over any non-trivial use of <locale>
|
||||
// this may be an overly restrictive define, but regex fails without it:
|
||||
# define BOOST_NO_STD_LOCALE
|
||||
#endif
|
||||
|
||||
#ifdef _CPPLIB_VER
|
||||
# define BOOST_DINKUMWARE_STDLIB _CPPLIB_VER
|
||||
#else
|
||||
# define BOOST_DINKUMWARE_STDLIB 1
|
||||
#endif
|
||||
|
||||
#ifdef _CPPLIB_VER
|
||||
# define BOOST_STDLIB "Dinkumware standard library version " BOOST_STRINGIZE(_CPPLIB_VER)
|
||||
#else
|
||||
# define BOOST_STDLIB "Dinkumware standard library version 1.x"
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue