fi
if ! [ -e src/expr/node.h -a -e .svn ]; then
- echo "$(basename "$0"): ERROR: you should run this from the top-level of a CVC4 subversion working directory" >&2
+ echo "$(basename "$0"): ERROR: You should run this from the top-level of a CVC4 subversion working directory" >&2
exit 1
fi
shift
if echo "$version" | grep '[^a-zA-Z0-9_.+(){}^%#-]' &>/dev/null; then
- echo "$(basename "$0"): ERROR: version designation \`$version' contains illegal characters" >&2
+ echo "$(basename "$0"): ERROR: Version designation \`$version' contains illegal characters" >&2
exit 1
fi
echo
isthatright
+echo "Checking whether release \`$version' already exists..."
if ! svn ls "https://subversive.cims.nyu.edu/cvc4/cvc4/tags/releases/$version" 2>&1 >/dev/null | grep non-existent >/dev/null; then
- echo "$(basename "$0"): ERROR: subversion repo already contains a release \`$version'" >&2
+ echo "$(basename "$0"): ERROR: Subversion repo already contains a release \`$version'" >&2
$dryrun || exit 1
fi
+echo "Checking working directory for local modifications..."
if $dryrun; then
if [ -n "$(svn status -q configure.ac)" ]; then
- echo "$(basename "$0"): ERROR: in dry-run mode, cannot operate properly with local modifications to \"configure.ac\", sorry" >&2
+ echo "$(basename "$0"): ERROR: In dry-run mode, cannot operate properly with local modifications to \"configure.ac\", sorry" >&2
exit 1
fi
elif [ -n "$(svn status -q)" ]; then
root="$(svn info | grep "^Repository Root: https://subversive.cims.nyu.edu/.*" | cut -f3 -d' ')"
if [ -z "$root" ]; then
- echo "$(basename "$0"): ERROR: can't get repository root URL" 2>&1
+ echo "$(basename "$0"): ERROR: Can't get repository root URL" 2>&1
$dryrun || exit 1
fi
+echo "Checking repo for unmerged updates..."
if [ `svn -uq status | wc -l` -ne 1 ]; then
- echo "$(basename "$0"): ERROR: this working directory isn't up to date" 2>&1
+ echo "$(basename "$0"): ERROR: This working directory isn't up to date" 2>&1
$dryrun || exit 1
fi
+echo "Checking sources for broken public headers..."
+suspect_files="\
+$(grep -r --exclude-dir=.svn '^[ \t]*#[ \t]*include[ \t]*"[^/]*"' src |
+ grep -v '"cvc4parser_public\.h"' |
+ grep -v '"cvc4_public\.h"' |
+ grep -v '"cvc4_private\.h"' |
+ grep -v '"cvc4autoconfig\.h"' |
+ grep -v '"cvc4parser_private\.h"' |
+ cut -f1 -d: |
+ sort -u |
+ xargs grep -l '^[ \t]*#[ \t]*include[ \t]*"cvc4.*public\.h"' |
+ xargs echo)"
+if [ -n "$suspect_files" ]; then
+ echo "$(basename "$0"): ERROR: The following publicly-installed headers appear" 2>&1
+ echo "$(basename "$0"): ERROR: to have relative #includes and may be broken up" 2>&1
+ echo "$(basename "$0"): ERROR: on install: $suspect_files" 2>&1
+ $dryrun || exit 1
+fi
+
+echo "Adjusting version info lines in configure.ac..."
if ! grep '^m4_define(_CVC4_MAJOR, *[0-9][0-9]* *)' configure.ac &>/dev/null ||
! grep '^m4_define(_CVC4_MINOR, *[0-9][0-9]* *)' configure.ac &>/dev/null ||
! grep '^m4_define(_CVC4_RELEASE, *[0-9][0-9]* *)' configure.ac &>/dev/null ||
! grep '^m4_define(_CVC4_EXTRAVERSION, *\[.*\] *)' configure.ac &>/dev/null; then
- echo "$(basename "$0"): ERROR: cannot locate the version info lines of configure.ac" >&2
+ echo "$(basename "$0"): ERROR: Cannot locate the version info lines of configure.ac" >&2
$dryrun || exit 1
fi
perl -pi -e 's/^m4_define\(_CVC4_MAJOR, ( *)[0-9]+( *)\)/m4_define(_CVC4_MAJOR, ${1}'"$major"'$2)/;
! grep '^m4_define(_CVC4_MINOR, *'"$minor"' *)' configure.ac &>/dev/null ||
! grep '^m4_define(_CVC4_RELEASE, *'"$release"' *)' configure.ac &>/dev/null ||
! grep '^m4_define(_CVC4_EXTRAVERSION, *\['"$extra"'\] *)' configure.ac &>/dev/null; then
- echo "$(basename "$0"): INTERNAL ERROR: cannot find the modified version info lines in configure.ac, bailing..." >&2
+ echo "$(basename "$0"): INTERNAL ERROR: Cannot find the modified version info lines in configure.ac, bailing..." >&2
exit 1
fi
if [ -z "$(svn status -q configure.ac)" ]; then
exit 1
fi
+echo "Building and checking distribution \`cvc4-$version'..."
if ! $SHELL -c '\
version="'$version'"; \
set -ex; \
fi
if ! [ -e release-$version/cvc4-$version.tar.gz ]; then
- echo "$(basename "$0"): INTERNAL ERROR: cannot find the distribution tarball I just built" >&2
+ echo "$(basename "$0"): INTERNAL ERROR: Cannot find the distribution tarball I just built" >&2
exit 1
fi
if ! [ -e release-$version/src/main/cvc4 ]; then
- echo "$(basename "$0"): INTERNAL ERROR: cannot find the binary I just built" >&2
+ echo "$(basename "$0"): INTERNAL ERROR: Cannot find the binary I just built" >&2
exit 1
fi
install-data-local:
(echo include/cvc4.h; \
echo include/cvc4_public.h; \
+ echo include/cvc4parser_public.h; \
find * -name '*.h' | \
xargs grep -l '^# *include *"cvc4.*_public\.h"'; \
(cd "$(srcdir)" && find * -name '*.h' | \
$(mkinstalldirs) "$$(dirname "$(DESTDIR)$(includedir)/cvc4/$$d")"; \
if [ -e "$$f" ]; then \
path="$$f"; \
+ fixpath="$$f.fix"; \
else \
path="$(srcdir)/$$f"; \
+ fixpath="$(builddir)/$$f.fix"; \
+ $(MKDIR_P) "`dirname "$$fixpath"`"; \
fi; \
- echo $(INSTALL_DATA) "$$path" "$(DESTDIR)$(includedir)/cvc4/$$d"; \
- $(INSTALL_DATA) "$$path" "$(DESTDIR)$(includedir)/cvc4/$$d"; \
+ sed 's,^\([ \t]*#[ \t]*include[ \t*]\)"\(.*\)"\([ \t]*\)$$,\1<cvc4/\2>\3,' "$$path" > "$$fixpath" || exit 1; \
+ echo $(INSTALL_DATA) "$$fixpath" "$(DESTDIR)$(includedir)/cvc4/$$d"; \
+ $(INSTALL_DATA) "$$fixpath" "$(DESTDIR)$(includedir)/cvc4/$$d" || exit 1; \
done
uninstall-local:
-(echo include/cvc4.h; \
echo include/cvc4_public.h; \
+ echo include/cvc4parser_public.h; \
find * -name '*.h' | \
xargs grep -l '^# *include *"cvc4.*_public\.h"'; \
(cd "$(srcdir)" && find * -name '*.h' | \
#include <strings.h>
-#include "c_interface_defs.h"
+#include "bindings/compat/c/c_interface_defs.h"
#include "compat/cvc3_compat.h"
//#include "vc.h"
//#include "command_line_flags.h"
#ifndef _cvc3__include__c_interface_h_
#define _cvc3__include__c_interface_h_
-#include "c_interface_defs.h"
+#include "bindings/compat/c/c_interface_defs.h"
//! Flags can be NULL
VC vc_createValidityChecker(Flags flags);
#include <string>
#include <jni.h>
#include <typeinfo>
-#include "vcl.h"
-#include "hash_map.h"
-#include "exception.h"
+#include "compat/cvc3_compat.h"
+//#include "vcl.h"
+//#include "hash_map.h"
+//#include "exception.h"
namespace Java_cvc3_JniUtils {
#include "cvc4_private.h"
/* strong dependency; make sure node is included first */
-#include "node.h"
-#include "type_node.h"
+#include "expr/node.h"
+#include "expr/type_node.h"
#ifndef __CVC4__NODE_BUILDER_H
#define __CVC4__NODE_BUILDER_H
#include "cvc4autoconfig.h"
-#include "interactive_shell.h"
+#include "main/interactive_shell.h"
#include "expr/command.h"
#include "parser/input.h"
char* commandGenerator(const char* text, int state);
static const char* const cvc_commands[] = {
-#include "cvc_tokens.h"
+#include "main/cvc_tokens.h"
};/* cvc_commands */
static const char* const smt_commands[] = {
-#include "smt_tokens.h"
+#include "main/smt_tokens.h"
};/* smt_commands */
static const char* const smt2_commands[] = {
-#include "smt2_tokens.h"
+#include "main/smt2_tokens.h"
};/* smt2_commands */
static const char* const* commandsBegin;
#include <unistd.h>
#include "cvc4autoconfig.h"
-#include "main.h"
-#include "interactive_shell.h"
+#include "main/main.h"
+#include "main/interactive_shell.h"
#include "parser/parser.h"
#include "parser/parser_builder.h"
#include "parser/parser_exception.h"
#include "util/stats.h"
#include "cvc4autoconfig.h"
-#include "main.h"
+#include "main/main.h"
using CVC4::Exception;
using namespace std;
#include <antlr3.h>
#include <stdint.h>
-#include "antlr_input.h"
-#include "input.h"
-#include "bounded_token_buffer.h"
-#include "bounded_token_factory.h"
-#include "memory_mapped_input_buffer.h"
-#include "parser_exception.h"
-#include "parser.h"
+#include "parser/antlr_input.h"
+#include "parser/input.h"
+#include "parser/bounded_token_buffer.h"
+#include "parser/bounded_token_factory.h"
+#include "parser/memory_mapped_input_buffer.h"
+#include "parser/parser_exception.h"
+#include "parser/parser.h"
#include "expr/command.h"
#include "expr/type.h"
#include <string>
#include <vector>
-#include "bounded_token_buffer.h"
-#include "parser_exception.h"
-#include "input.h"
+#include "parser/bounded_token_buffer.h"
+#include "parser/parser_exception.h"
+#include "parser/input.h"
#include "util/Assert.h"
#include "util/bitvector.h"
#include <antlr3.h>
#include <sstream>
-#include "antlr_input.h"
-#include "parser.h"
-#include "parser_exception.h"
+#include "parser/antlr_input.h"
+#include "parser/parser.h"
+#include "parser/parser_exception.h"
#include "util/Assert.h"
using namespace std;
#include <antlr3input.h>
#include <antlr3commontoken.h>
#include <antlr3interfaces.h>
-#include "bounded_token_factory.h"
+#include "parser/bounded_token_factory.h"
namespace CVC4 {
namespace parser {
** A super-class for input language parsers
**/
-#include "input.h"
-#include "parser_exception.h"
-#include "parser.h"
+#include "parser/input.h"
+#include "parser/parser_exception.h"
+#include "parser/parser.h"
#include "expr/command.h"
#include "expr/type.h"
#include <iterator>
#include <stdint.h>
-#include "input.h"
-#include "parser.h"
-#include "parser_exception.h"
+#include "parser/input.h"
+#include "parser/parser.h"
+#include "parser/parser_exception.h"
#include "expr/command.h"
#include "expr/expr.h"
#include "expr/kind.h"
#include <string>
-#include "parser_builder.h"
-#include "input.h"
-#include "parser.h"
+#include "parser/parser_builder.h"
+#include "parser/input.h"
+#include "parser/parser.h"
#include "smt/smt.h"
#include "smt2/smt2.h"
#include <antlr3.h>
-#include "smt_input.h"
+#include "parser/smt/smt_input.h"
#include "expr/expr_manager.h"
#include "parser/input.h"
#include "parser/parser.h"
#include <antlr3.h>
-#include "smt2_input.h"
+#include "parser/smt2/smt2_input.h"
#include "expr/expr_manager.h"
#include "parser/input.h"
#include "parser/parser.h"
** \todo document this file
**/
-#include "cnf_proof.h"
+#include "proof/cnf_proof.h"
using namespace CVC4::prop;
namespace CVC4 {
**
**/
-#include "array_info.h"
+#include "theory/arrays/array_info.h"
namespace CVC4 {
namespace theory {
#include "theory/theory.h"
#include "theory/arrays/union_find.h"
#include "util/congruence_closure.h"
-#include "array_info.h"
+#include "theory/arrays/array_info.h"
#include "util/hash.h"
#include "util/ntuple.h"
#include "util/stats.h"
** \todo document this file
**/
-#include "equality_engine.h"
+#include "theory/bv/equality_engine.h"
using namespace CVC4::theory::bv;