diff --git a/CMakeLists.txt b/CMakeLists.txt index 78736751a7..f598aa0ce8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -674,7 +674,7 @@ if(ENABLE_SANITIZE IN_LIST _sanitize_flavor_list) ) set(SANITIZER_ENV_MODS - "LSAN_OPTIONS=set:G_SLICE=always-malloc:suppressions=${CMAKE_SOURCE_DIR}/conf/sanitizer.supp/leak.supp" + "LSAN_OPTIONS=set:G_SLICE=always-malloc:suppressions=${CMAKE_SOURCE_DIR}/deploy/sanitizer.supp/leak.supp" ) set(_result 0) @@ -688,7 +688,7 @@ if(ENABLE_SANITIZE IN_LIST _sanitize_flavor_list) OUTPUT_STRIP_TRAILING_WHITESPACE ) list(APPEND SANITIZER_ENV_MODS - "ASAN_OPTIONS=set:start_deactivated=1:exitcode=1:use_sigaltstack=0:suppressions=${CMAKE_SOURCE_DIR}/conf/sanitizer.supp/address.supp" + "ASAN_OPTIONS=set:start_deactivated=1:exitcode=1:use_sigaltstack=0:suppressions=${CMAKE_SOURCE_DIR}/deploy/sanitizer.supp/address.supp" ) elseif(ENABLE_SANITIZE STREQUAL "thread") execute_process( @@ -698,7 +698,7 @@ if(ENABLE_SANITIZE IN_LIST _sanitize_flavor_list) OUTPUT_STRIP_TRAILING_WHITESPACE ) list(APPEND SANITIZER_ENV_MODS - "TSAN_OPTIONS=set:start_deactivated=1:exitcode=1:second_deadlock_stack=1:suppressions=${CMAKE_SOURCE_DIR}/conf/sanitizer.supp/thread.supp" + "TSAN_OPTIONS=set:start_deactivated=1:exitcode=1:second_deadlock_stack=1:suppressions=${CMAKE_SOURCE_DIR}/deploy/sanitizer.supp/thread.supp" ) elseif(ENABLE_SANITIZE STREQUAL "undefined") execute_process( @@ -708,7 +708,7 @@ if(ENABLE_SANITIZE IN_LIST _sanitize_flavor_list) OUTPUT_STRIP_TRAILING_WHITESPACE ) list(APPEND SANITIZER_ENV_MODS - "UBSAN_OPTIONS=set:start_deactivated=1:exitcode=1:suppressions=${CMAKE_SOURCE_DIR}/conf/sanitizer.supp/undefined.supp" + "UBSAN_OPTIONS=set:start_deactivated=1:exitcode=1:suppressions=${CMAKE_SOURCE_DIR}/deploy/sanitizer.supp/undefined.supp" ) endif() @@ -1081,7 +1081,7 @@ if(ENABLE_VALGRIND) ) set(Valgrind_SUPPRESSION_FILES - ${CMAKE_SOURCE_DIR}/conf/valgrind.supp/mdsplus.supp + ${CMAKE_SOURCE_DIR}/deploy/valgrind.supp/mdsplus.supp ) endif() diff --git a/LabView/Makefile.am b/LabView/Makefile.am deleted file mode 100644 index b8e73786ee..0000000000 --- a/LabView/Makefile.am +++ /dev/null @@ -1,27 +0,0 @@ -labviewdir = $(prefix)/LabView -dist_labview_DATA = \ - MdsClose.vi \ - MdsConnect.vi \ - MdsDescrInt1D.vi \ - MdsDescrInt2D.vi \ - MdsDescrInt.vi \ - MdsDescrSingle1D.vi \ - MdsDescrSingle.vi \ - MdsDescrStr.vi \ - MdsDisconnect.vi \ - MdsGetInt1D.vi \ - MdsGetInt.vi \ - MdsGetSingle1D.vi \ - MdsGetSingle.vi \ - MdsGetStr.vi \ - MdsOpen.vi \ - MdsPut.vi \ - MdsSetEvent.vi \ - MdsWaitForEvent.vi \ - Sample1-GetInt.vi \ - Sample2-PutInt.vi \ - Sample3-PutArray.vi \ - Sample4-PutSignal.vi \ - Sample5-GetSngArray.vi \ - Sample6-GetPutWithEvents.vi \ - Sample7-Put2DArray.vi diff --git a/Makefile.in b/Makefile.in deleted file mode 100644 index 6269c6a53e..0000000000 --- a/Makefile.in +++ /dev/null @@ -1,256 +0,0 @@ -#@(#)$RCSfile$ $Revision$ -# @configure_input@ - -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - - - -JAVA_JAR = \ - java/mdsplus \ - java/mdsplus-api \ - java/mdsobjects \ - java/jdispatcher \ - java/jscope \ - java/jtraverser \ - java/jtraverser2 \ - java/devicebeans \ - java/jdevices \ - java/tests \ - java/mdsplus-api/tests \ - java/mdsobjects/tests - -JAVA_APS = \ - javamds - -ifeq "@HAVE_MOTIF@" "yes" -MOTIF_APS = xmdsshr \ - actions \ - dwscope \ - @IDLMDSWIDGETS@ \ - mitdevices \ - traverser -else -MOTIF_APS = actions -endif -HDF5_APS = hdf5 - -D3D_PACKAGE = d3dshr - -ifeq "@JAVA_ONLY@" "yes" -NON_JAR = -PARTS = $(JAVA_JAR) -else -NON_JAR = \ - mdsshr \ - treeshr \ - tdishr \ - tditest \ - xtreeshr \ - @MDSTCPIP@ \ - mdslibidl \ - mdsdcl \ - @CAMSHR@ \ - @REMCAM@ \ - ccl \ - servershr \ - tcl \ - @TDIC@ \ - mdslib \ - math \ - wfevent \ - setevent \ - mdsmisc \ - scripts \ - rpm \ - mdsobjects/cpp \ - manpages \ - @D3D_PACKAGE@ \ - @JAVA_APS@ \ - @MOTIF_APS@ \ - @MDSSQL@ \ - @IDLMDSEVENT@ \ - @HDF5_APS@ \ - @LV@ \ - LabView \ - @MACOSX@ - -@ENABLE_TESTS_TRUE@ NON_JAR += testing - -PARTS = $(NON_JAR) @JAVA_JAR@ -endif - -.PHONY: all $(PARTS) -all: ##@build build all active submodules -all: ChangeLog $(PARTS) - -DIRECTORIES = $(sort @MAKEBINDIR@ @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKEUIDDIR@) - -$(NON_JAR): $(DIRECTORIES) -@MINGW_FALSE@ $(MAKE) -C $@ @MAKEFLAG_J@ @MAKEFLAG_O@ -@MINGW_TRUE@ $(MAKE) -C $@ -# override parallel flags for java apps -$(JAVA_JAR): $(DIRECTORIES) - $(MAKE) -C $@ - -.PHONY: docs -docs: ##@docs build documentation using doxygen (ref to docs directory) - $(MAKE) -C docs install - - - -clean_DIRS = $(addprefix clean_, $(PARTS)) - -ChangeLog: - if (! git --git-dir=@top_srcdir@/.git log --decorate=full --no-merges > ChangeLog 2>/dev/null); then touch ChangeLog; fi - -.PHONY: clean -clean: ##@build recusively clean all built objects in submodules -clean: $(clean_DIRS) clean_TESTS clean_DOCS - -.PHONY: $(clean_DIRS) -$(clean_DIRS): - $(MAKE) -C $(@:clean_%=%) clean - -clean_DOCS: ##@docs clean generated documentation - $(MAKE) -C docs clean - -.PHONY: distclean - -distclean: ##@build make source directory look like original sources - @cpwd=$$(pwd); \ - cd @top_srcdir@; \ - if [ -r .git ]; \ - then \ - git clean -x -f -d -q; \ - else \ - if [ "$$(pwd)" == "$$cpwd" ]; \ - then make full_clean > /dev/null; \ - fi; \ - rm -Rf ./python/MDSplus/build; \ - fi; \ - cd $$cpwd - -# Testing - -.PHONY: tests -tests: ##@tests recursively perform tests in submodules -@ENABLE_TESTS_TRUE@ $(MAKE) $(AM_MAKEFLAGS) -C testing all tests -@ENABLE_TESTS_FALSE@ @echo "Tests disabled" - -.PHONY: tests-valgrind rebuild-tests -tests-valgrind: ##@tests perform tests using valgrind tool -rebuild-tests: ##@tests rebuild all tests binaries -tests-valgrind rebuild-tests: -@ENABLE_TESTS_TRUE@ $(MAKE) $(AM_MAKEFLAGS) -C testing all $@ -@ENABLE_TESTS_FALSE@ @echo "Tests disabled" - -.PHONY: $(clean_TESTS) -clean_TESTS: ##@tests clean all tests results and compiled tests objects -@ENABLE_TESTS_TRUE@ $(MAKE) -C testing tests-clean - - -.PHONY: full_clean -full_clean: ##@build perform deep clean of build directories -full_clean: clean - @rm -Rf bin bin64 bin32 bin_x86 bin_x86_64 etc \ - lib lib64 lib32 java uid uid64 uid32 \ - config.cache config.log config.status aclocal.m4 \ - include/stamp-h1 autom4te.cache \ - $$(find . -name '.deps') \ - `find . -name '*.in' | \ - $(AWK) '{print substr($$1,0,length($$1)-3)}'` - -.PHONY: depend -depend: - cdir=`pwd`;\ - set -e; for dir in $(PARTS) ; do\ - cd $${dir}; $${MAKE:=make} depend > /dev/null 2> /dev/null; cd $$cdir;\ - done - -MISC_PARTS = tdi pydevices idl trees setup.sh setup.csh include desktop pixmaps matlab php epics xml nodejs python/MDSplus - -install_DIRS = $(addprefix install_, $(PARTS)) -$(install_DIRS): - $(MAKE) -C $(@:install_%=%) install - -.PHONY: install -install: ##@build build and install active modules to prefix directory -install: $(install_DIRS) - $(INSTALL) ChangeLog $(prefix)/ - $(MKDIR_P) $(prefix)/local/tdi - $(MKDIR_P) $(prefix)/java - $(MKDIR_P) $(prefix)/python/MDSplus - - find $(prefix)/java -name '*.class' -delete #### No need to include class files - tar -C ${top_srcdir} \ - --exclude='.gitignore' \ - --exclude='*.pyc' \ - --exclude=__pycache__ \ - --exclude=python/MDSplus/build \ - --exclude=python/MDSplus/docs \ - --exclude=python/MDSplus/tests/*_test.py \ - --exclude=tdi/*Devices/build \ - --exclude='*egg-info' \ - --exclude='*\.in' \ - --exclude='Makefile\.*' \ - -cf - $(MISC_PARTS) | (cd $(exec_prefix); tar -xf -) - tar -C ${top_builddir} -cf - include/mdsplus/mdsconfig.h $$(find . -name _version.py) | (cd $(exec_prefix); tar -xf -) ## TODO: remove this and config.h from headers ... - if [ ! -z "$$MDSPLUS_VERSION" ]; then echo "mdsplus_version='$$MDSPLUS_VERSION'" > $(exec_prefix)/python/MDSplus/mdsplus_version.py; fi - $(INSTALL) ${top_srcdir}/MDSplus-License.txt ${top_srcdir}/MDSplus-License.rtf $(exec_prefix) - (cd $(exec_prefix); chmod -R 755 $(MISC_PARTS)) - -.PHONY: tests-envdump -tests-envdump: - cd python/MDSobjects/tests&&(\ - make tests-envdump;\ - cd ../../..;) - -tests-env: - cd python/MDSplus/tests&&(\ - make tests-env;\ - cd ../../..;) - -@HAVE_WINE_TRUE@wineconsole: -@HAVE_WINE_TRUE@ cd python/MDSplus/tests&&(\ -@HAVE_WINE_TRUE@ make wineconsole;\ -@HAVE_WINE_TRUE@ cd ../../..;) - -# Interdependent directories: -actions: mdsshr tdishr treeshr xmdsshr mdstcpip servershr -camshr: mdsdcl mdstcpip -ccl: camshr mdsshr mdsdcl -tcl: mdsshr treeshr tdishr mdstcpip servershr mdsdcl -dwscope: xmdsshr -javamds: mdstcpip -java/devicebeans: java/mdsobjects java/jscope -java/mdsobjects: java/tests -java/mdsplus-api/tests: java/mdsplus-api java/tests -java/jdevices: java/devicebeans -java/jdispatcher: java/mdsobjects -java/jtraverser: java/mdsobjects java/jscope -java/jtraverser2: java/mdsplus-api -math: mdsshr -mdsdcl: mdsshr treeshr -mdslib: mdstcpip -mdslibidl: tdishr -mdsmisc: tdishr xtreeshr -mdsobjects/cpp: mdstcpip -mdstcpip: tdishr -mitdevices: mdsshr tdishr treeshr xmdsshr -remcam: mdstcpip -servershr: mdsdcl tdishr treeshr mdsshr mdstcpip -setevent: mdsshr -tdic: mdstcpip -tdishr: mdsshr treeshr -tditest: tdishr -traverser: xmdsshr -treeshr: mdsshr -wfevent: tdishr mdsshr -xmdsshr: tdishr -xtreeshr: tdishr - -am--refresh: diff --git a/Makefile.inc.in b/Makefile.inc.in deleted file mode 100644 index d9fc1a9534..0000000000 --- a/Makefile.inc.in +++ /dev/null @@ -1,118 +0,0 @@ -# @configure_input@ -.PHONY: --always ---always: - @ -echo-%: --always - @echo '$* = $($*)' - -DEFAULT_CFLAGS = -O3 - -ifeq "$(NOWARN)" "" -WARNFLAGS = @WARNFLAGS@ -NOWARNFLAGS = @NOWARNFLAGS@ -endif - -AWK ?= @AWK@ -CC = @CC@ -CFLAGS = $(WARNFLAGS) $(NOWARNFLAGS) @CFLAGS@ -DLIBPREFIX=$(or $(LIBPREFIX),MDSplus) -CPPFLAGS = @CPPFLAGS@ -CPP = @CPP@ -CXX = @CXX@ -FC = @FC@ -FCFLAGS = $(WARNFLAGS) @FCFLAGS@ -GREP = @GREP@ -GROFF = @GROFF@ -INSTALL = @INSTALL@ -JAR = @JAR@ -JAVAC = @JAVAC@ -JAVACFLAGS = @JAVACFLAGS@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBS = @LIBS@ -LIBM = @LIBM@ -LIBSOCKET = @LIBSOCKET@ -MKDIR_P = @MKDIR_P@ -RANLIB = @RANLIB@ -SED = @SED@ -TARGET_ARCH = @TARGET_ARCH@ -THREAD = @THREAD@ -# @MAKE_COMMAND_OVERRIDE@ -# export SHELL = ${abs_top_builddir}/dshell - -EXE = @EXEEXT@ - - -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -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@ -sysconfdir = @sysconfdir@ -top_build_prefix = @top_build_prefix@ -tooldir = $(exec_prefix)/$(target_alias) - - -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ - -#FIXME: Hack because this isn't really automake -top_builddir = @abs_top_builddir@ -top_srcdir = @abs_top_srcdir@ - -@MINGW_TRUE@icon.o : icon.rc -@MINGW_TRUE@ @WINDRES@ $^ -o $@ - -$(sort @MAKEBINDIR@ @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKEETCDIR@ @MAKEUIDDIR@ @uiddir@ $(bindir) $(libdir) $(sysconfdir)): - $(MKDIR_P) $@ - -.DEFAULT_GOAL := all - -## enable help command -@TARGET_SELFHELP@ -HELP_DESCRIPTION = This is MDSplus build system, documented targets follow: - -## docker build targets -@AX_DOCKER_BUILD_TARGETS@ - -## git release tags -@AX_GIT_REVISION_TARGETS@ - - -.PHONY: reconfigure -reconfigure: ##@miscellaneous rerun configure script again using last arguments passed - @ \ - echo " -- Reconfiguring build with following parameters: -----------"; \ - echo $(shell $(abs_top_builddir)/config.status --config); \ - echo " -------------------------------------------------------------"; \ - echo ; \ - cd '$(top_builddir)' && \ - $(top_srcdir)/configure $(shell $(abs_top_builddir)/config.status --config); diff --git a/actions/Makefile.in b/actions/Makefile.in deleted file mode 100644 index 935860300d..0000000000 --- a/actions/Makefile.in +++ /dev/null @@ -1,50 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH = @srcdir@ -@AX_RECONFIGURE_TARGET@ - -X_CFLAGS=@X_CFLAGS@ -CFLAGS+=$(X_CFLAGS) @TARGET_ARCH@ -X_LIBS=@X_LIBS@ -X_EXTRA_LIBS=@X_EXTRA_LIBS@ -X_PRE_LIBS=@X_PRE_LIBS@ -UIL=@UIL@ -COMON_LIBS = -lTdiShr -lTreeShr -lMdsShr $(LIBS) -SERVER_LIBS = -lMdsIpShr -lMdsdcl -lMdsServerShr -@HAVE_MOTIF_TRUE@MOTIF_LIBS = -lXmdsShr -lMrm -lXm -lXt -lX11 $(X_PRE_LIBS) $(X_LIBS) $(X_EXTRA_LIBS) - -SOURCES = actlog.c -@MINGW_TRUE@ SOURCES += icon.o -OBJECTS = $(SOURCES:.c=.o) - -@MAKEBINDIR@actlog$(EXE) : $(OBJECTS) - $(CC) -o $@ $(CFLAGS) $^ -L@MAKESHLIBDIR@ $(COMON_LIBS) $(SERVER_LIBS) -@HAVE_MOTIF_TRUE@@MAKEBINDIR@actmon : actmon.o -@HAVE_MOTIF_TRUE@ $(CC) -o $@ $(CFLAGS) actmon.o -L@MAKESHLIBDIR@ $(COMON_LIBS) $(SERVER_LIBS) $(MOTIF_LIBS) -@HAVE_MOTIF_TRUE@@MAKEBINDIR@actions : actions.o -@HAVE_MOTIF_TRUE@ $(CC) -o $@ $(CFLAGS) actions.o -L@MAKESHLIBDIR@ $(COMON_LIBS) $(MOTIF_LIBS) - -@HAVE_MOTIF_TRUE@.SUFFIXES: .uid .uil -@HAVE_MOTIF_TRUE@@MAKEUIDDIR@actmon.uid : @srcdir@/actmon.uil -@HAVE_MOTIF_TRUE@ $(UIL) -o $@ @srcdir@/actmon.uil -@HAVE_MOTIF_TRUE@@MAKEUIDDIR@actions.uid : @srcdir@/actions.uil -@HAVE_MOTIF_TRUE@ $(UIL) -o $@ @srcdir@/actions.uil - -install: $(bindir) -@HAVE_MOTIF_FALSE@ $(INSTALL) -m 755 @MAKEBINDIR@actlog$(EXE) $(bindir) -@HAVE_MOTIF_TRUE@ $(INSTALL) -m 644 @MAKEUIDDIR@actmon.uid @MAKEUIDDIR@actions.uid @uiddir@ -@HAVE_MOTIF_TRUE@ $(INSTALL) -m 755 @MAKEBINDIR@actlog @MAKEBINDIR@actmon @MAKEBINDIR@actions $(bindir) - -clean : -@HAVE_MOTIF_FALSE@ @ $(RM) @MAKEBINDIR@actlog$(EXE) -@HAVE_MOTIF_TRUE@ @ $(RM) @MAKEBINDIR@actlog @MAKEBINDIR@actmon @MAKEBINDIR@actions -@HAVE_MOTIF_TRUE@ @ $(RM) @MAKEUIDDIR@actmon.uid @MAKEUIDDIR@actions.uid - -@HAVE_MOTIF_FALSE@all : @MAKEBINDIR@ @MAKEBINDIR@actlog$(EXE) -@HAVE_MOTIF_TRUE@all : @MAKEBINDIR@ @MAKEBINDIR@actlog @MAKEBINDIR@actmon @MAKEBINDIR@actions @MAKEUIDDIR@actmon.uid @MAKEUIDDIR@actions.uid - -depend: -@HAVE_MOTIF_FALSE@ @makedepend -- $(CFLAGS) -- $(SOURCES) -@HAVE_MOTIF_TRUE@ @makedepend -- $(CFLAGS) -- $(SOURCES) actmon.c actions.c diff --git a/actions/testing/Makefile.am b/actions/testing/Makefile.am deleted file mode 100644 index e15cb9cdc6..0000000000 --- a/actions/testing/Makefile.am +++ /dev/null @@ -1,28 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .sh - -TESTS = \ - ServerShrTest.sh - -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = \ - ./*.log ./*.err\ - *_*.characteristics* *_*.datafile* *_*.tree* -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -#clean-local: clean-local-tests - -check_PROGRAMS = -check_SCRIPTS = $(TESTS) diff --git a/camshr/Makefile.bak b/camshr/Makefile.bak deleted file mode 100644 index 288874eb73..0000000000 --- a/camshr/Makefile.bak +++ /dev/null @@ -1,97 +0,0 @@ -include ../Makefile.inc - -# IMPLIB=$(top_srcdir)/lib64/CamShr.dll.a - -LIBS=-L$(top_srcdir)/lib64/ -lMdsShr -lrt - -MAJOR = 1 -MINOR = 8 -LIBRARYNAME=CamShr -SHLIB = lib$(LIBRARYNAME).so -SHLIB_BUILD = $(top_srcdir)/lib64/$(SHLIB) - -SOURCES = \ - add_entry.c \ - bisearch.c \ - cam_functions.c \ - check_for_file.c \ - check_sema4.c \ - commit_entry.c \ - compare_str.c \ - copy.c \ - create_sema4.c \ - create_tmp_file.c \ - debug.c \ - expand_db.c \ - get_crate_status.c \ - get_db_file_size.c \ - get_file_count.c \ - get_file_name.c \ - get_scsi_device_number.c \ - global.c \ - issort.c \ - lock_file.c \ - lookup_entry.c \ - map_data_file.c \ - map_scsi_device.c \ - msg.c \ - parse_crate_db.c \ - parse_cts_db.c \ - QueryHighwayType.c \ - remove_entry.c \ - scsi_io.c \ - ScsiSystemStatus.c \ - turn_crate_on_off_line.c \ - unlock_file.c \ - xlate_logicalname.c - -OBJECTS = $(SOURCES:.c=.o) - -CTS_SOURCES = cts_commands.c verbs.c - -CTS_OBJECTS = $(CTS_SOURCES:.c=.o) - -all : $(top_srcdir)/bin64/ $(top_srcdir)/lib64/ \ - $(top_srcdir)/bin64/mdscts \ - $(SHLIB_BUILD) \ - $(top_srcdir)/lib64/libcts_commands.so - -.PHONY: clean -clean: - @ $(RM) $(OBJECTS) $(CTS_OBJECTS) - @ $(RM) $(SHLIB_BUILD) $(IMPLIB) - @ $(RM) $(SHLIB_BUILD).$(MAJOR) - @ $(RM) $(SHLIB_BUILD).$(MAJOR).$(MINOR) - @ $(RM) $(top_srcdir)/bin64/mdscts - @ $(RM) $(top_srcdir)/lib64/libcts_commands.so - -depend: - - @makedepend -- $(CFLAGS) -- $(SOURCES) 2>/dev/null - -install: $(libdir) $(bindir) - $(INSTALL) -m 755 $(top_srcdir)/bin64/mdscts $(bindir) - $(INSTALL) -m 755 $(top_srcdir)/lib64/libcts_commands.so $(libdir) - $(INSTALL) -m 755 $(SHLIB_BUILD).$(MAJOR).$(MINOR) $(libdir) - ln -sf $(SHLIB).$(MAJOR).$(MINOR) $(libdir)/$(SHLIB).$(MAJOR) - ln -sf $(SHLIB).$(MAJOR) $(libdir)/$(SHLIB) - -$(top_srcdir)/bin64/mdscts: cts - cp $< $@ - chmod +x $@ - -cdudir = $(top_builddir)/cdu -CDU = $(cdudir)/cdu - -cts_commands.c: cts_commands.ocld - env LD_LIBRARY_PATH=$(top_srcdir)/lib64/ $(CDU) < $< - $(MAKE) depend - -$(top_srcdir)/lib64/libcts_commands.so: $(CTS_OBJECTS) $(SHLIB_BUILD) - $(LINK.c) $(OUTPUT_OPTION) -shared $(CTS_OBJECTS) -L$(top_srcdir)/lib64/ -l$(LIBRARYNAME) -lMdsdcl $(LIBS) - -# MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -$(SHLIB_BUILD) $(IMPLIB): $(OBJECTS) - $(LINK.c) -shared -nostartfiles -Wl,-soname=$(SHLIB) -o $@.$(MAJOR).$(MINOR) $^ -L$(top_srcdir)/lib64/ -lMdsShr $(MAKE_IMPLIB) - ln -sf $(SHLIB).$(MAJOR).$(MINOR) $@.$(MAJOR) - ln -sf $(SHLIB).$(MAJOR) $@ - diff --git a/camshr/Makefile.in b/camshr/Makefile.in deleted file mode 100644 index 72a0d97030..0000000000 --- a/camshr/Makefile.in +++ /dev/null @@ -1,98 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir = @srcdir@ -builddir = @builddir@ -VPATH = @srcdir@ -@AX_RECONFIGURE_TARGET@ - -@MINGW_TRUE@ IMPLIB=@MAKELIBDIR@CamShr.dll.a - -LIBS=-L@MAKESHLIBDIR@ @LIBS@ -lMdsShr - -MAJOR = 1 -MINOR = 8 -LIBRARYNAME=CamShr -SHLIB = @LIBPRE@$(LIBRARYNAME)@SHARETYPE@ -SHLIB_BUILD = @MAKESHLIBDIR@$(SHLIB) - -SOURCES = \ - add_entry.c \ - bisearch.c \ - cam_functions.c \ - check_for_file.c \ - check_sema4.c \ - commit_entry.c \ - compare_str.c \ - copy.c \ - create_sema4.c \ - create_tmp_file.c \ - debug.c \ - expand_db.c \ - get_crate_status.c \ - get_db_file_size.c \ - get_file_count.c \ - get_file_name.c \ - get_scsi_device_number.c \ - global.c \ - issort.c \ - lock_file.c \ - lookup_entry.c \ - map_data_file.c \ - map_scsi_device.c \ - msg.c \ - parse_crate_db.c \ - parse_cts_db.c \ - QueryHighwayType.c \ - remove_entry.c \ - scsi_io.c \ - ScsiSystemStatus.c \ - turn_crate_on_off_line.c \ - unlock_file.c \ - xlate_logicalname.c \ - RemCamMulti.c \ - RemCamSingle.c \ - RemCamIosb.c - -OBJECTS = $(SOURCES:.c=.o) - -CTS_SOURCES = verbs.c - -CTS_OBJECTS = $(CTS_SOURCES:.c=.o) - -all : @MAKEBINDIR@ @MAKESHLIBDIR@ \ - @MAKEBINDIR@mdscts \ - $(SHLIB_BUILD) \ - @MAKESHLIBDIR@@LIBPRE@cts_commands@SHARETYPE@ - -.PHONY: clean -clean: - @ $(RM) $(OBJECTS) $(CTS_OBJECTS) - @ $(RM) $(SHLIB_BUILD) $(IMPLIB) - @ $(RM) $(SHLIB_BUILD).$(MAJOR) - @ $(RM) $(SHLIB_BUILD).$(MAJOR).$(MINOR) - @ $(RM) @MAKEBINDIR@mdscts - @ $(RM) @MAKESHLIBDIR@@LIBPRE@cts_commands@SHARETYPE@ - -depend: - - @makedepend -- $(CFLAGS) -- $(SOURCES) 2>/dev/null - -install: $(libdir) $(bindir) - $(INSTALL) -m 755 @MAKEBINDIR@mdscts $(bindir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@cts_commands@SHARETYPE@ $(libdir) - $(INSTALL) -m 755 $(SHLIB_BUILD).$(MAJOR).$(MINOR) $(libdir) - ln -sf $(SHLIB).$(MAJOR).$(MINOR) $(libdir)/$(SHLIB).$(MAJOR) - ln -sf $(SHLIB).$(MAJOR) $(libdir)/$(SHLIB) - -@MAKEBINDIR@mdscts: cts - cp $< $@ - chmod +x $@ - -@MAKESHLIBDIR@@LIBPRE@cts_commands@SHARETYPE@: $(CTS_OBJECTS) $(SHLIB_BUILD) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(CTS_OBJECTS) -L@MAKESHLIBDIR@ -l$(LIBRARYNAME) -lMdsdcl $(LIBS) - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -$(SHLIB_BUILD) $(IMPLIB): $(OBJECTS) - $(LINK.c) @LINKSHARED@ -nostartfiles -Wl,-soname=$(SHLIB) -o $@.$(MAJOR).$(MINOR) $^ -L@MAKESHLIBDIR@ -lMdsShr -lMdsIpShr $(MAKE_IMPLIB) - ln -sf $(SHLIB).$(MAJOR).$(MINOR) $@.$(MAJOR) - ln -sf $(SHLIB).$(MAJOR) $@ - diff --git a/ccl/Makefile.in b/ccl/Makefile.in deleted file mode 100644 index a97f5a3c34..0000000000 --- a/ccl/Makefile.in +++ /dev/null @@ -1,42 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -SOURCES = ccl_verbs.c -OBJECTS = $(SOURCES:.c=.o) - -@MINGW_TRUE@ MDSCCL=mdsccl.bat -@MINGW_FALSE@ MDSCCL=mdsccl - -all: @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@ccl_commands@SHARETYPE@ @MAKEBINDIR@ @MAKEBINDIR@$(MDSCCL) - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) @MAKESHLIBDIR@@LIBPRE@ccl_commands@SHARETYPE@ - @ $(RM) @MAKEBINDIR@mdsccl - -depend: - - @makedepend -- $(CFLAGS) -- $(SOURCES) 2>/dev/null - -install: $(libdir) $(bindir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@ccl_commands@SHARETYPE@ $(libdir) - $(INSTALL) -m 755 @MAKEBINDIR@$(MDSCCL) $(bindir) - -cdudir = $(top_builddir)/cdu -CDU = $(cdudir)/cdu - -ccl_commands.c_disabled: ccl_commands.ocld - if [ "@LIBPATH@" == "PATH" ]; then env PATH="@MAKESHLIBDIR@:$$(dirname $$(which gcc))" $(CDU) < ccl_commands.ocld;\ - else env @LIBPATH@=@MAKESHLIBDIR@ $(CDU) < ccl_commands.ocld; fi - $(MAKE) depend - -@MAKESHLIBDIR@@LIBPRE@ccl_commands@SHARETYPE@: $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ $(LIBS) -L@MAKESHLIBDIR@ -lMdsdcl -lMdsShr -lCamShr - -@MAKEBINDIR@$(MDSCCL): $(MDSCCL) - cp $< $@ - chmod +x $@ - diff --git a/conf/test-driver b/conf/test-driver deleted file mode 100755 index 912987fbe3..0000000000 --- a/conf/test-driver +++ /dev/null @@ -1,162 +0,0 @@ -#! /bin/sh -# test-driver - basic testsuite driver script. - -scriptversion=2013-07-13.22; # UTC - -# Copyright (C) 2011-2014 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, see . - -# 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. - -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -# Make unconditional expansion of undefined variables an error. This -# helps a lot in preventing typo-related bugs. -# set -u - -usage_error () -{ - echo "$0: $*" >&2 - print_usage >&2 - exit 2 -} - -print_usage () -{ - cat < /dev/null) && export TEST_TAPFILE=${log_file/.log/.tap}; -# (echo "${TEST_FORMAT}" | grep "xml" > /dev/null) && export TEST_XMLFILE=${log_file/.log/.xml}; - (echo "${TEST_FORMAT}" | grep "tap" > /dev/null) && export TEST_TAPFILE=$(echo $log_file | sed -e 's/\(.log\)$/.tap/'); - (echo "${TEST_FORMAT}" | grep "xml" > /dev/null) && export TEST_XMLFILE=$(echo $log_file | sed -e 's/\(.log\)$/.xml/'); -fi - -# add LD_PRELOAD just before the test LOG_COMPILER execution -if [ ${TEST_LD_PRELOAD} ]; then - export LD_PRELOAD=${TEST_LD_PRELOAD}; -fi - -# Test script is run here. -"$@" >$log_file 2>&1 -estatus=$? - -if test $enable_hard_errors = no && test $estatus -eq 99; then - tweaked_estatus=1 -else - tweaked_estatus=$estatus -fi - -case $tweaked_estatus:$expect_failure in - 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;; - 0:*) col=$grn res=PASS recheck=no gcopy=no;; - 77:*) col=$blu res=SKIP recheck=no gcopy=yes;; - 99:*) col=$mgn res=ERROR recheck=yes gcopy=yes;; - *:yes) col=$lgn res=XFAIL recheck=no gcopy=yes;; - *:*) col=$red res=FAIL recheck=yes gcopy=yes;; -esac - -# Report the test outcome and exit status in the logs, so that one can -# know whether the test passed or failed simply by looking at the '.log' -# file, without the need of also peaking into the corresponding '.trs' -# file (automake bug#11814). -echo "$res $test_name (exit status: $estatus)" >>$log_file - -# Report outcome to console. -echo "${col}${res}${std}: $test_name" - -# Register the test result, and other relevant metadata. -echo ":test-result: $res" > $trs_file -echo ":global-test-result: $res" >> $trs_file -echo ":recheck: $recheck" >> $trs_file -echo ":copy-in-global-log: $gcopy" >> $trs_file - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/conf/test-driver.bat b/conf/test-driver.bat deleted file mode 100644 index d26f362234..0000000000 --- a/conf/test-driver.bat +++ /dev/null @@ -1,129 +0,0 @@ -@echo off - -set scriptversion=2015-10-23.10 -set est 0 - -:parse -IF "%~1"=="" GOTO endparse - -IF "%~1"=="--help" ( - echo "This is test driver for win execution of tests" - GOTO exit - ) - -IF "%~1"=="--version" ( - echo %scriptversion% - GOTO exit - ) - -IF "%~1"=="--test-name" ( - set test_name=%~2 - SHIFT - SHIFT - GOTO parse - ) - -IF "%~1"=="--log-file" ( - set log_file=%~2 - SHIFT - SHIFT - GOTO parse - ) - -IF "%~1"=="--trs-file" ( - set trs_file=%~2 - SHIFT - SHIFT - GOTO parse -) - -IF "%~1"=="--color-tests" ( - REM THIS OPTION IS NOT CURRENTLY USED! - SHIFT - SHIFT - GOTO parse -) - -IF "%~1"=="--expect-failure" ( - REM THIS OPTION IS NOT CURRENTLY USED! - SHIFT - SHIFT - GOTO parse -) - -IF "%~1"=="--enable-hard-errors" ( - REM THIS OPTION IS NOT CURRENTLY USED! - SHIFT - SHIFT - GOTO parse -) - -IF "%~1"=="--" ( - REM Explicitly terminate the list of options. - echo terminate - SHIFT -) - -REM Build cmd form remaining args -:cmdbld -if "%1" == "" GOTO endparse -set command=%command% %1 -SHIFT -GOTO cmdbld - -:endparse -REM ready for action! -echo Input command. %* -echo Parsed command. %command% -echo Path........... %PATH% -echo . -echo . -echo . - -%command% - -%command% > %log_file% - - ( set est=1 - set res=FAIL ) -IF ERRORLEVEL 0 ( set est=0 - set res=PASS ) -IF ERRORLEVEL 77 ( set est=77 - set res=SKIP ) -IF ERRORLEVEL 99 ( set est=99 - set res=ERROR ) - - -REM console output -echo %res%: %test_name% - -REM pause - - -REM Register the test result, and other relevant metadata. -echo :test-result: %res% > %trs_file% -echo :global-test-result: %res% >> %trs_file% -echo :recheck: %recheck% >> %trs_file% -echo :copy-in-global-log: %gcopy% >> %trs_file% - - -:exit - -EXIT /B %est% - - - - - - - - - - - - - - - - - diff --git a/conf/valgrind-supp.py b/conf/valgrind-supp.py deleted file mode 100644 index 971c971205..0000000000 --- a/conf/valgrind-supp.py +++ /dev/null @@ -1,55 +0,0 @@ -#!/usr/bin/env python -import sys -import re - -maxdepth = 7 -root = dict() -curr = None -record = -1 -filter = {'fun:UnknownInlinedFun', re.compile(r'fun:.+\.lto_priv\..+'), "obj:*"} - - -for filepath in sys.argv[1:]: - with open(filepath, 'r') as f: - gen = (l for l in f) - for line in gen: - line = line.strip() - if record >= 0: - if line == "}": - record = -1 - curr = None - elif record < maxdepth: - record += 1 - curr = curr.setdefault(line, dict()) - elif line == "{": - record = 0 - curr = root - next(gen) - - -def print_level(curr, pre): - if curr: - for k, v in curr.items(): - print_level(v, pre + [k]) - else: - while True: - for flt in filter: - if isinstance(flt, str): - if flt == pre[-1]: - break - else: - if flt.search(pre[-1]): - break - else: - break - if len(pre) <= 2: - break - pre.pop() - print("{") - print(" %s" % pre[-1].split(":", 2)[-1]) - for l in pre: - print(" %s" % l) - print("}") - - -print_level(root, []) diff --git a/configure.ac b/configure.ac deleted file mode 100644 index 0b47b49052..0000000000 --- a/configure.ac +++ /dev/null @@ -1,1521 +0,0 @@ -dnl Process this file with autoconf to produce a configure script. -dnl @(#)$RCSfile$ $Revision$ -AC_PREREQ([2.69]) -AC_INIT([MDSplus], [7a], [mdsplus@lists.psfc.mit.edu]) -AC_CONFIG_AUX_DIR([conf]) -AC_CONFIG_SRCDIR([include/mdsdescrip.h]) -AC_PREFIX_DEFAULT([/usr/local/mdsplus]) - -dnl docker helpers -AS_VAR_SET([srcdir],[${srcdir}]) -AS_VAR_SET([builddir],[$(pwd)]) -AX_DOCKER_BUILD - -AC_CANONICAL_TARGET - -AM_INIT_AUTOMAKE([foreign subdir-objects]) -AM_MAINTAINER_MODE - -dnl AS_IS_RELEASE ////////////////////////////////////////////////////////////// -dnl see: http://www.gnu.org/software/autoconf-archive/ax_is_release.html -dnl -dnl * git-directory: ax_is_release will be 'no' if a '.git' directory exists -dnl * minor-version: ax_is_release will be 'no' if the minor version number -dnl in $PACKAGE_VERSION is odd; this assumes -dnl $PACKAGE_VERSION follows the 'major.minor.micro' scheme -dnl * micro-version: ax_is_release will be 'no' if the micro version number -dnl in $PACKAGE_VERSION is odd; this assumes -dnl $PACKAGE_VERSION follows the 'major.minor.micro' scheme -dnl * always: ax_is_release will always be 'yes' -dnl * never: ax_is_release will always be 'no' -dnl -AX_IS_RELEASE([always]) - - -# //////////////////////////////////////////////////////////////////////////// # -# ////// RELEASE INFO //////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -dnl get version info from generated file -AX_GIT_REVISION - -dnl add reconfigure target option to autoconf generated Makefile -AX_RECONFIGURE_TARGETS - - -dnl AX_CHECK_ENABLE_DEBUG ////////////////////////////////////////////////////// -dnl see: www.gnu.org/software/autoconf-archive/ax_check_enable_debug.html -dnl -dnl Check for the presence of an --enable-debug option to configure, with the -dnl specified default value used when the option is not present. Return the -dnl value in the variable $ax_enable_debug. -dnl Specifying "yes" adds "-g -O0" to the compilation flags for all languages. -dnl Specifying "info" adds "-g" to the compilation flags. Specifying "profile" -dnl adds "-g -pg" to the compilation flags, and "-pg" to the linker flags. -dnl Otherwise, nothing is added. -dnl -dnl AX_CHECK_ENABLE_DEBUG([enable by default=yes/info/profile/no], -dnl [ENABLE DEBUG VARIABLES ...], [DISABLE DEBUG VARIABLES NDEBUG ...], -dnl [IS-RELEASE],[DEFAULT_RELEASE_FLAGS]) -AX_CHECK_ENABLE_DEBUG([no],,,,[-O3]) - - -dnl AX_TARGET_SELFHELP ///////////////////////////////////////////////////////// -AX_TARGET_SELFHELP - -AC_ARG_ENABLE([java_only], - [AS_HELP_STRING([--enable-java_only], - [Only build java jar files])], - [AS_VAR_SET([JAVA_ONLY],[yes])]) - -AC_ARG_WITH([jars], - [AS_HELP_STRING([--with-jars=directory], - [specify directory tree to find java jars])], - [AS_VAR_SET([JARS_DIR],[$withval])], - [AS_VAR_SET([JARS_DIR],[])]) - -AM_CONDITIONAL([USE_JARS_DIR],[test x"$JARS_DIR" != x]) - -# Checks for programs. -AC_PROG_AWK -AC_PROG_CXX -AC_PROG_CC -AC_PROG_FC -AC_PROG_RANLIB -AC_PROG_MKDIR_P -AC_PROG_INSTALL -AC_PROG_SED -AC_CHECK_TOOL([DLLTOOL], [dlltool], [:]) -AC_CHECK_TOOL([WINDRES], [windres], [:]) - -# Always do the visibility check but don't set AM_CFLAGS on Windows. -# This way things get set properly even on Windows. -AC_MSG_RESULT([before VISIBILITY]) -gl_VISIBILITY -AC_MSG_RESULT([**********VISIBILITY*********$CFLAG_VISIBILITY*******************]) -CFLAGS="$CFLAGS $CFLAG_VISIBILITY" - -dnl See if we need to use native compilers -AS_CASE(["$host"], - [sparc-sun-solaris2*], [${CC=cc}]) - -#AC_CONFIG_HEADER(include/mdsplus/mdsconfig.h) -AC_CHECK_SIZEOF(int *) -AC_SYS_LARGEFILE - -JAVACFLAGS="-encoding UTF-8 -source \$(JAVASOURCE)" -FOR_LINKSHARED="" - -AC_MSG_CHECKING([whether to build shared libraries]) -AC_ARG_ENABLE([shared], - [AS_HELP_STRING([--disable-shared], - [Prevent building shared libraries])], - [], - [enable_shared=yes]) - -LINKWHOLEON= -LINKWHOLEOFF= -AS_CASE([$enable_shared], - [yes], [AS_CASE([$host], - [*apple*], [LINKWHOLEON=-Wl,-force_load], - [*linux*], [LINKWHOLEON=-Wl,--whole-archive;LINKWHOLEOFF=-Wl,--no-whole-archive])]) -AC_SUBST([LINKWHOLE]) -AC_MSG_RESULT([$enable_shared]) - - -dnl See if the linker supports -rpath-link -AC_MSG_CHECKING([whether the linker supports -rpath-link]) -AS_VAR_SET_IF([LDFLAGS], [AS_VAR_SET([save_LDFLAGS], ["$LDFLAGS"])]) -AS_VAR_SET([LDFLAGS], [-Wl,-rpath-link=dummy]) -AC_LINK_IFELSE([AC_LANG_PROGRAM([], [])], - [AS_VAR_SET([RPATHLINK], [-Wl,-rpath-link])]) -AM_CONDITIONAL([RPATHLINK], [AS_VAR_TEST_SET([RPATHLINK])]) -AC_SUBST([RPATHLINK]) -AS_UNSET([LDFLAGS]) -AS_VAR_SET_IF([save_LDFLAGS], [AS_VAR_SET([LDFLAGS], ["$save_LDFLAGS"])]) -AS_UNSET([save_LDFLAGS]) -AM_COND_IF([RPATHLINK], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])]) - -AC_MSG_CHECKING([whether to enable statistics]) -AC_ARG_ENABLE([perf], - [AS_HELP_STRING([--enable-perf], - [enable MDSplus I/O statistics])], - [], - [AS_VAR_SET([enable_perf], [no])]) -AS_CASE([$enable_perf], - [yes], [AC_DEFINE([USE_PERF], [], [Define if you want to collect performance statistics -- linux only])]) -AC_MSG_RESULT([$enable_perf]) - -# //////////////////////////////////////////////////////////////////////////// # -# /// JAVA ///////////////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -AC_MSG_CHECKING([whether to build the java components]) -AC_ARG_ENABLE([java], - [AS_HELP_STRING([--disable-java], [Do not build java libraries and applications])], - [], - [AS_VAR_SET([enable_java], [yes])] -) -AM_CONDITIONAL([ENABLE_JAVA],[test x"$enable_java" = xyes]) -AC_MSG_RESULT([$enable_java]) - -AS_CASE([$enable_java], [yes], [ - dnl This is a workaround to maintain both JAVA_HOME and JDK_DIR env - AS_VAR_SET_IF([JDK_DIR], [AS_VAR_SET([JAVA_HOME],[${JDK_DIR}])]) - AC_CHECK_JAVA_HOME - AS_VAR_SET([JDK_DIR],[${JAVA_HOME}]) - AC_ARG_WITH([jdk], - [AS_HELP_STRING([--with-jdk=JDKDIR], - [specify location of java jdk])], - [], - [ - AS_VAR_SET_IF([JDK_DIR], - [AS_VAR_SET([with_jdk], [$JDK_DIR])], - [AS_VAR_SET([with_jdk], [/etc/alternatives/java_sdk]) - ]) - ]) - AC_ARG_WITH([java_target], - [AS_HELP_STRING([--with-java_target=version], - [specify version of compiled mdsobjects classes (i.e. 6)])], - [AS_VAR_APPEND([JAVACFLAGS], [" -target $withval"])], - [AS_VAR_APPEND([JAVACFLAGS], [" -target \$(JAVASOURCE)"])]) - AC_ARG_WITH([java_bootclasspath], [ - AS_HELP_STRING( - [--with-java_bootclasspath=bootclasspath], - [specify the bootclasspath option for use with --with-java_target (i.e. /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0/jre/lib/rt.jar)] - ) - ], - [AS_VAR_APPEND([JAVACFLAGS], [" -bootclasspath $withval"])], - [AS_VAR_APPEND([JAVACFLAGS], [" \$(JAVABOOTCLASSPATH)"])] - ) - AC_MSG_CHECKING([for presence of Java Development Kit]) - AS_IF([test ! -d $with_jdk ${JRE}], [ - AC_MSG_RESULT([not found]) - AC_MSG_WARN([YOU NEED TO SPECIFY THE JAVA JDK DIRECTORY OR DISABLE JAVA]) - AC_MSG_WARN([The jdk directory can be specified by either defining a JDK_DIR environment]) - AC_MSG_WARN([variable or by using the --with-jdk=DIR option.]) - AC_MSG_WARN([You can disable java by using the --disable-java option.]) - AS_EXIT - ]) - AC_PATH_PROG([JAVAC], [javac], [], [$with_jdk/bin:$PATH]) - AC_PATH_PROG([JAR], [jar], [], [$with_jdk/bin:$PATH]) -]) - -AM_CONDITIONAL([GLOBUSLICENSE], [test -r $exec_prefix/GLOBUS_LICENSE]) - -AC_ARG_WITH([gsi], - [AS_HELP_STRING([--with-gsi=globus-location:flavor], - [Use globus gsi for mdsip communications])], - [], - [AS_VAR_SET([with_gsi], [no])]) -AS_CASE([$with_gsi], - [no], [AS_VAR_SET([MDSTCPIP], [mdstcpip])], - [*pthr*], [AC_MSG_WARN([Do NOT INCLUDE pthr in the globus flavor!]) - AS_EXIT], - [MDSTCPIP="mdstcpip roam" - GLOBUS_LOCATION=`echo $withval | awk -F: '{print $1}'` - GLOBUS_FLAVOR=`echo $withval | awk -F: '{print $2}'` - AS_VAR_IF([GLOBUS_FLAVOR], [], - [AC_MSG_WARN([YOU NEED TO PROVIDE GLOBUS_LOCATION and FLAVOR when using the --with-gsi option]) - AC_MSG_WARN([Format: --with-gsi=globus-install-directory:flavor]) - AC_MSG_WARN([Example: --with-gsi=/usr/local/gt3:gcc32dbg]) - AC_MSG_WARN([]) - AC_MSG_WARN([Note do not include pthr in the flavor as it is automatically added.]) - AS_EXIT])]) - -AC_MSG_CHECKING([for an srb installation]) -AC_ARG_WITH([srb], - [AS_HELP_STRING([--with-srb=srb-install-dir], - [Enable srb capabilities])], - [], - [AS_VAR_SET([with_srb], [no])]) -AS_CASE([$with_srb], - [no], [], - [yes], [AC_MSG_WARN([YOU NEED TO PROVIDE THE LOCATION OF THE unixIO subdirectory of your srb installation]) - AC_MSG_WARN([when using the --with-srb option]) - AC_MSG_WARN([]) - AC_MSG_WARN([Format: --with-srb=srb-install-directory]) - AC_MSG_WARN([Example: --with-srb=/scratch/slocal/testc/SRB3_2client/unixIO]) - AS_EXIT], - [SRBLIB="-L${with_srb} -lsrbUio" - SRBINCLUDE="-I${with_srb}" - AC_DEFINE(SRB,[],["Define if you are using SRB"])]) -AC_MSG_RESULT([$with_srb]) - -dnl Look for labview include file -AC_MSG_CHECKING([for labview]) -AC_ARG_WITH([labview], - [AS_HELP_STRING([--with-labview=labview-top-dir], - [specify location of labview such as /usr/local/natinst/Labview])], - [], - [with_labview=yes]) - -AS_CASE([$with_labview], - [yes], - [AS_VAR_SET_IF([LABVIEW_DIR], - [with_labview=$LABVIEW_DIR], - [AS_IF([test -d ${srcdir}/3rd-party-apis/labview], - [with_labview=\${top_srcdir}/3rd-party-apis/labview], - [with_labview=no])])]) - -AS_CASE([$with_labview], - [no], [], - [yes], [AC_MSG_ERROR([Labview location required])], - [LV_CINTOOLS="$with_labview/cintools" - LV="mdsobjects/labview"]) - -AC_MSG_RESULT([$with_labview]) - -AC_MSG_CHECKING([whether to include idl support]) -AC_ARG_WITH([idl], - [AS_HELP_STRING([[--with-idl[=idl-top-dir]]], - [specify location of idl such as /usr/local/itt/idl, or set IDL_DIR])], - [], - [with_idl=yes]) -AS_CASE([$with_idl], - [yes], [AS_VAR_SET_IF([IDL_DIR], - [AS_VAR_SET([with_idl], [$IDL_DIR])], - [AS_IF([test -d /usr/local/itt/idl], [AS_VAR_SET([with_idl], [/usr/local/itt/idl])], - [test -d /usr/local/rsi/idl], [AS_VAR_SET([with_idl], [/usr/local/rsi/idl])], - [test -d /usr/local/exelis/idl], [AS_VAR_SET([with_idl], [/usr/local/exelis/idl])], - [test -d ${srcdir}/3rd-party-apis/idl], [AS_VAR_SET([with_idl], [\${top_srcdir}/3rd-party-apis/idl])], - [AS_VAR_SET([with_idl], [no])])])]) -AS_CASE([$with_idl], - [no], [AS_UNSET([IDL_DIR]) - AC_MSG_RESULT([$with_idl])], - [AS_VAR_SET([IDL_INC], ["-I$with_idl/external"]) - AS_VAR_SET([IDLMDSEVENT], [idlmdsevent]) - AS_VAR_SET([IDLMDSWIDGETS], [idlmdswidgets]) - AC_MSG_RESULT([yes])]) - -AC_MSG_CHECKING([for mingw]) -AS_CASE([$host], - [*mingw*],[AS_VAR_SET([MINGW])]) -AM_CONDITIONAL([MINGW], [AS_VAR_TEST_SET([MINGW])]) -AM_COND_IF([MINGW], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])]) - - - -AC_MSG_CHECKING([for visual studio]) -AC_ARG_WITH([visual_studio], - [AS_HELP_STRING([--with-visual-studio], - [directory tree containing visual studio compiler, includes and libs])], - [AS_VAR_SET([VS_DIR], [$with_visual_studio])], - [AS_VAR_SET_IF([VS_DIR], - [AS_VAR_SET([with_visual_studio], [$VS_DIR])], - [AS_VAR_SET([with_visual_studio], [no])])]) -AM_CONDITIONAL([VS],[AS_VAR_TEST_SET([VS_DIR])]) -AC_MSG_RESULT([$with_visual_studio]) - -FORLD=ld -LD=ld LD_LDARC="" -LD_LDSHARE="" -IDL_LD="" -LIBPRE="lib" - -CFLAGS="$CFLAGS $GCCPROF -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" -CPPFLAGS=" -I\${top_builddir}/_include -I\${top_srcdir}/_include -I\${top_builddir}/include -I\${top_srcdir}/include $CPPFLAGS" - -if test "$exec_prefix" = "NONE" -a "$prefix" = "NONE" -then - : ${uiddir:=$ac_default_prefix/uid} -elif test "$exec_prefix" = "NONE" -then - : ${uiddir:=$prefix/uid} -else - : ${uiddir:=$exec_prefix/uid} -fi -if nproc&>/dev/null && perl -v&>/dev/null -then - MAKEFLAG_J="-j -l $(perl -e "print $(nproc) * 0.9")" -else - MAKEFLAG_J="-j -l 1" -fi - -AS_IF([test "${prefix}" = "NONE"],[AS_VAR_SET([prefix],[${ac_default_prefix}])]) -AS_IF([test "${exec_prefix}" = "NONE"],[AS_VAR_SET([exec_prefix],[${prefix}])]) - -MAKEFLAG_O="$(if ${MAKE:=make} -v -O&>/dev/null; then echo -O; fi)" -MAKEUIDDIR="\$(top_builddir)/uid/" -MAKESHLIBDIR="\$(top_builddir)/lib/" -MAKEBINDIR="\$(top_builddir)/bin/" -MAKELIBDIR="\$(top_builddir)/lib/" -JDK_LIVECONNECT="$with_jdk/jre/lib/plugin.jar" -TAR_EXCLUDE="-e" -HUP_TO_XINETD="" -HUP_TO_XINETD_SERVICE="" -HUP_TO_INETD="" -JRE="jre" -UILCMD="uil" -FOR_LDFLAGS="" -SHARETYPE=".so" - -THREAD="-pthread" -MITDEVICESIO_TARGETS="" -case "$host" in -*mingw*) - MAKEFLAG_J="" - MAKEFLAG_O="" - LIBPRE="" - CFLAGS="$CFLAGS -fno-strict-aliasing -mno-ms-bitfields -DWIN32 -D_WIN32 "; - LD="$CXX -static-libgcc" - FCFLAGS="$FCFLAGS -fno-range-check" - FORLD="$FC" - if ( echo $host | grep i686 > /dev/null ) - then - SQL_ARCH=32 - BINDIR=bin_x86 - VS_ARCH=x86 - IDL_LIB="-L/mnt/scratch/mdsplus/idl-mingw-libs -lidl64" - else - SQL_ARCH=64 - BINDIR=bin_x86_64 - VS_ARCH=x64 - IDL_LIB="-L/mnt/scratch/mdsplus/idl-mingw-libs -lidl32" - fi - MAKELIBDIR="\$(top_builddir)/${BINDIR}/" - MAKESHLIBDIR="\$(top_builddir)/${BINDIR}/" - MAKEBINDIR="\$(top_builddir)/${BINDIR}/" - FCFLAGS="$FCFLAGS -fno-backslash"; - LDSHARE="-Wl,-Bdynamic "; - LDARC="-Wl,-Bstatic "; - LD_LDSHARE="-Bdynamic "; - LD_LDARC="-Bstatic "; - LINKSHARED="-shared "; - FOR_LINKSHARED="$LINKSHARED"; - LIBPATH="LD_LIBRARY_PATH"; - FOR_LDFLAGS=""; - FEXECLIBDIR="-L"; - SHARETYPE=".dll" - jni_inc_dir="$with_jdk/include"; - jni_md_inc_dir="$with_jdk/include/win32";; - -*86*linux*) - CFLAGS="$CFLAGS -fpic -shared-libgcc -fsigned-char -fno-strict-aliasing "; - FORLD="$FC"; - LD="gcc" - if ( echo $host| grep 64 > /dev/null ) - then - if [[ -d /usr/lib64 -a "${PLATFORM}" = "redhat" ]] - then - D64="64" - else - D64="" - fi - SYB64=$D64 - TARGET_ARCH="-m64" - UILCMD=uil - uiddir="${uiddir}${D64}" - MAKELIBDIR="\$(top_builddir)/lib${D64}/" - MAKESHLIBDIR="\$(top_builddir)/lib${D64}/" - MAKEUIDDIR="\$(top_builddir)/uid${D64}/" - MAKEBINDIR="\$(top_builddir)/bin${D64}/" - else - if [[ -d /usr/lib64 -a "${PLATFORM}" = "redhat" ]] - then - D32="32" - else - D32="" - fi - TARGET_ARCH="-m32" - JAVA_TARGET_ARCH="-d32" - if which uil32 >/dev/null - then UILCMD=uil32 - else UILCMD=uil - fi - uiddir="${uiddir}${D32}" - MAKELIBDIR="\$(top_builddir)/lib${D32}/" - MAKESHLIBDIR="\$(top_builddir)/lib${D32}/" - MAKEUIDDIR="\$(top_builddir)/uid${D32}/" - MAKEBINDIR="\$(top_builddir)/bin${D32}/" - fi - FCFLAGS="$FCFLAGS -fno-range-check" - FOR_LDFLAGS="-lg2c" - FCFLAGS="$FCFLAGS -fpic -fno-backslash"; - LDSHARE="-Wl,-Bdynamic "; - LDARC="-Wl,-Bstatic "; - LD_LDSHARE="-Bdynamic "; - LD_LDARC="-Bstatic "; - LINKSHARED="-shared "; - FOR_LINKSHARED="$LINKSHARED"; - LIBPATH="LD_LIBRARY_PATH"; - FOR_LDFLAGS=""; - FEXECLIBDIR="-L"; - TAR_EXCLUDE="--exclude"; - MITDEVICESIO_TARGETS="${MAKESHLIBDIR}libMitDevicesIO${SHARETYPE} ${MAKELIBDIR}libMitDevicesIO.a ${MAKEBINDIR}daq_server"; - jni_inc_dir="$with_jdk/include"; - jni_md_inc_dir="$with_jdk/include/linux"; - HUP_TO_XINETD="/etc/rc.d/init.d/xinetd restart"; - HUP_TO_XINETD_SERVICE="service xinetd restart"; - HUP_TO_INETD="kill -HUP \`/sbin/pidof inetd\`"; - ;; -*arm-xilinx-linux-gnueabi) echo "configuring for Xylinx zynq board (arm cortex a9)"; - CC=arm-xilinx-linux-gnueabi-gcc; - LD=arm-xilinx-linux-gnueabi-ld; - AR=arm-xilinx-linux-gnueabi-ar; - RANLIB=arm-xilinx-linux-gnueabi-ranlib; - SIZEOF_LONG=4; - SIZEOF_LONG_LONG=8; - D64=""; - CFLAGS="$CFLAGS -fpic -shared-libgcc -fsigned-char -fno-strict-aliasing"; - if (test "$FC" = "gfortran"); then - FCFLAGS="$FCFLAGS -fno-range-check"; - FORLD="$FC" - FOR_LDFLAGS="-lg2c" - fi - FCFLAGS="$FCFLAGS -fpic -fno-backslash"; - LDSHARE="-Wl,-Bdynamic "; - LDARC="-Wl,-Bstatic "; - LD_LDSHARE="-Bdynamic "; - LD_LDARC="-Bstatic "; - LINKSHARED="-shared "; - FOR_LINKSHARED="$LINKSHARED"; - LIBPATH="LD_LIBRARY_PATH"; - FOR_LDFLAGS=""; - FEXECLIBDIR="-L"; - TAR_EXCLUDE="--exclude"; - jni_inc_dir="$with_jdk/include"; - jni_md_inc_dir="$with_jdk/include/linux"; - HUP_TO_XINETD="/etc/rc.d/init.d/xinetd restart"; - HUP_TO_XINETD_SERVICE="service xinetd restart"; - HUP_TO_INETD="kill -HUP \`/sbin/pidof inetd\`";; -*linux*) CFLAGS="$CFLAGS -fpic -fsigned-char -shared-libgcc -fno-strict-aliasing"; - FCFLAGS="$FCFLAGS -fno-range-check"; - FORLD="$FC" - FOR_LDFLAGS="-lg2c" - FCFLAGS="$FCFLAGS -fpic -fno-backslash"; - LDSHARE="-Wl,-Bdynamic "; - LDARC="-Wl,-Bstatic "; - LD_LDSHARE="-Bdynamic "; - LD_LDARC="-Bstatic "; - LINKSHARED="-shared "; - FOR_LINKSHARED="$LINKSHARED"; - LIBPATH="LD_LIBRARY_PATH"; - FOR_LDFLAGS=""; - FEXECLIBDIR="-L"; - TAR_EXCLUDE="--exclude"; - jni_inc_dir="$with_jdk/include"; - jni_md_inc_dir="$with_jdk/include/linux"; - HUP_TO_XINETD="/etc/rc.d/init.d/xinetd restart"; - HUP_TO_XINETD_SERVICE="service xinetd restart"; - HUP_TO_INETD="kill -HUP \`/sbin/pidof inetd\`";; -*apple-darwin*) echo "Configuring for MacOS X"; - THREAD="" - MACOSX="macosx" - CFLAGS="$CFLAGS -fsigned-char -fno-strict-aliasing -Wl,-rpath,@loader_path/..,-rpath,@executable_path/..,-rpath,$exec_prefix"; - FCFLAGS="$FCFLAGS -fno-range-check"; - FORLD="gfortran"; - FOR_LDFLAGS="-shared"; - FEXECLIBDIR="-L"; - LD="$CC"; - LDSHARE="-rpath @loader_path/.. @executable_path/.. $exec_prefix"; - LD_LDSHARE=""; - LDARC=""; - LD_LDARC=""; - UILPATH=${OPENMOTIF-/usr}/bin; - MOTIF_LDARC="-Wl,-bind_at_load -multiply_defined suppress -L${OPENMOTIF-/usr}/lib"; - MOTIF_LD_LDARC="-multiply_defined suppress -L${OPENMOTIF-/usr}/lib"; - LINKSHARED="$LDFLAGS -dynamiclib -install_name @rpath/lib/\$(@F) -headerpad_max_install_names"; - FOR_LINKSHARED="$LDFLAGS -shared"; - LINKMODULE="$LDFLAGS -bundle -undefined dynamic_lookup"; - IDL_LD=""; - LINKJNI="$LINKSHARED"; - jni_inc_dir="$JAVA_HOME/include"; - jni_md_inc_dir="$JAVA_HOME/include/darwin"; - SHARETYPE=".dylib"; - SHARETYPEJNI=".dylib"; - SHARETYPEMOD=".dylib"; - TAR_EXCLUDE="--exclude"; - java_enable="yes"; - LIBPATH="DYLD_LIBRARY_PATH"; - X_EXTRA_LIBS="-lXmu";; -esac - -# add specific flags for fortran depending on compiler version -AX_FORTRAN_FLAGS([FCFLAGS]) -AX_C_FLAGS([CFLAGS]) - -AC_CHECK_SIZEOF(long) - -# Stuff that only non-automake dirs need -AC_SUBST([MAKEETCDIR], ["\$(top_builddir)/etc/"]) - -dnl Check for 0xnnnnll (long long constants) -AC_LANG_SAVE -AC_LANG_C -AC_TRY_COMPILE(,int gub(){return((int)0x1ll);} - ,AC_DEFINE(HAVE_LL_CONSTANTS - ,,"Define if you compiler likes 0xnnnnll long long constants")) -AC_LANG_RESTORE - -AC_MSG_CHECKING(if JNI libraries are different) -if test "$LINKJNI" -then - AC_MSG_RESULT(yes) -else - AC_MSG_RESULT(no) - SHARETYPEJNI="$SHARETYPE" - LINKJNI="$LINKSHARED" -fi - -AC_MSG_CHECKING(if IDL plugins are different) -if test "$LINKMODULE" -then - AC_MSG_RESULT(yes) -else - AC_MSG_RESULT(no) - SHARETYPEMOD="$SHARETYPE" - LINKMODULE="$LINKSHARED" -fi - - -dnl Checks for libraries. - -AC_DEFUN([MDS_SEARCH_LIBS],[ - old_LIBS="$LIBS" - AC_SEARCH_LIBS([$1],[$2],[$3],[$4],[$5]) - LIBS="$old_LIBS" - ]) - -# -# Add TARGET_ARCH to CFLAGS so that all library searches will look for libraries of the correct arch -# -CFLAGS_lib_check_save="$CFLAGS" -AS_VAR_SET_IF([TARGET_ARCH],[CFLAGS="$CFLAGS $TARGET_ARCH"]) -# - -dnl see if we have libdc1394 libraries and what version - -raw_old_libs="$LIBS" #### needed because of nested call to MDS_SEARCH_LIBS -MDS_SEARCH_LIBS([raw1394_get_libversion],[raw1394], -[ - MDS_SEARCH_LIBS([dc1394_new],[dc1394],[DC1394_SUPPORT2="${MAKESHLIBDIR}libdc1394_support2$SHARETYPE"]) - MDS_SEARCH_LIBS([dc1394_get_camera_info],[dc1394],[DC1394_SUPPORT="${MAKESHLIBDIR}libdc1394_support$SHARETYPE"]) -]) -LIBS="$raw_old_libs" - -AC_SEARCH_LIBS([gethostbyname], [nsl socket], - [AS_VAR_IF([ac_cv_search_gethostbyname], ["none required"], [], [LIBSOCKET=$ac_cv_search_gethostbyname])], - [dnl Can't search ws2_32 for gethostbyname using AC_SEARCH_LIBS, because - dnl it requires #include to work. - AC_MSG_CHECKING([for gethostbyname in ws2_32]) - LIBSOCKET="-lws2_32" - mds_old_LIBS="$LIBS" - LIBS="$LIBSOCKET $LIBS" - AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]], - [[gethostbyname ("");]])], - [AC_MSG_RESULT([yes])], - [AC_MSG_RESULT([no]); AS_UNSET([LIBSOCKET])]) - LIBS=$mds_old_LIBS]) -AC_SUBST([LIBSOCKET]) - -MDS_SEARCH_LIBS([pow],[m],[AS_VAR_IF([ac_cv_search_pow],["none required"],[],[AS_VAR_SET([LIBM],[$ac_cv_search_pow])])]) -MDS_SEARCH_LIBS([__dn_skipname],[resolv],[AS_VAR_IF([ac_cv_search___dn_skipname],["none required"],[],[AS_VAR_SET([LIBRESOLV],[$ac_cv_search___dn_skipname])])]) -MDS_SEARCH_LIBS([dlopen],[dl],[AS_VAR_IF([ac_cv_search_dlopen],["none required"],[],[AS_VAR_SET([LIBDL],[$ac_cv_search_dlopen])])]) -MDS_SEARCH_LIBS([getgrgid],[],[AC_DEFINE([HAVE_GETGRGID],[],["Define if you have getgrgid to get group name."])]) -MDS_SEARCH_LIBS([getpwuid],[],[AC_DEFINE([HAVE_GETPWUID],[],["Define if you have getpwuid."])]) -MDS_SEARCH_LIBS([gethostbyname],[dnet_stub],[AS_VAR_IF([ac_cv_search_gethostbyname],["none required"],[],[AS_VAR_SET([DNET_STUB],[$ac_cv_search_gethostbyname])])]) -MDS_SEARCH_LIBS([clock_gettime],[rt], - [ - AC_DEFINE([HAVE_CLOCK_GETTIME],[],["Define if you have the clock_gettime function."]) - AS_VAR_IF([ac_cv_search_clock_gettime],["none required"],[],[AS_VAR_SET([CLOCK_GETTIME_LIB],["$ac_cv_search_clock_gettime"])]) - ]) -MDS_SEARCH_LIBS([gettimeofday],[],[AC_DEFINE([HAVE_GETTIMEOFDAY],[],["Define if you have the gettimeofday function."])]) -MDS_SEARCH_LIBS([getaddrinfo],[],[AC_DEFINE([HAVE_GETADDRINFO],[],["Define if you have the getaddrinfo routine"])]) -MDS_SEARCH_LIBS([strsep],[],[AC_DEFINE([HAVE_GETADDRINFO],[],["Define if you have the getaddrinfo routine"])]) -MDS_SEARCH_LIBS([getrusage],[],[AC_DEFINE(HAVE_GETRUSAGE,,"Define if you have the getrusage routine")]) - -AC_ARG_ENABLE(d3d, - [ --enable-d3d build d3d ptdata access library ], - if test "$enableval" = yes; then - AC_MSG_CHECKING(...D3DLIB_PATH...) - : ${D3DLIB_PATH:?"You must define D3DLIB_PATH to be the directory containing the libd3 library"} - if test -f "$D3DLIB_PATH/libd3.a" -o -f "$D3DLIB_PATH/libd3$SHARETYPE" - then - D3D_PACKAGE="\$(D3D_PACKAGE)"; - D3DLIB="-L$D3DLIB_PATH"; - AC_MSG_RESULT($D3DLIB) - else - AC_MSG_RESULT(libd3.a or libd3$SHARETYPE not found in $D3DLIB_PATH) - exit 0 - fi - fi) - - - -## ////////////////////////////////////////////////////////////////////////// ## -## // READLINE //////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -AC_SEARCH_READLINE([READLINE]) -AM_CONDITIONAL(READLINE, test x"$have_readline" = x"yes") - -dnl sets for retro compatibility -if test x"$have_readline" = x"yes"; then - LIBREADLINE="${READLINE_LIBS}" - TDIC="tdic" - - dnl CPPFLAGS_save="${CPPFLAGS}" - CPPFLAGS="${READLINE_CPPFLAGS} ${CPPFLAGS}" - LDFLAGS="${READLINE_LDFLAGS} ${LDFLAGS}" - AC_CHECK_HEADERS(readline/readline.h readline/history.h - ,,AC_MSG_ERROR("libreadline headers was not found")) - dnl this appears to be used so I add it here also. - AC_CHECK_FUNCS(rl_set_signals) - dnl CPPFLAGS=$CPPFLAGS_save - dnl else - dnl AC_MSG_ERROR(readline library was not found and must be installed.) -fi - -dnl //// discontinued implementation //// -dnl LIBS_save="$LIBS" -dnl AC_SEARCH_LIBS([readline],[readline 'readline -lcurses']) -dnl LIBS="$LIBS_save" -dnl if test "$ac_cv_search_readline" = "no" -dnl then -dnl AC_MSG_RESULT("libreadline is not available so the build of tdic will be skipped") -dnl TDIC="" -dnl LIBREADLINE="" -dnl else -dnl LIBREADLINE="$ac_cv_search_readline" -dnl TDIC="tdic" -dnl fi -dnl AC_SEARCH_LIBS([rl_set_signals],[readline 'readline -lcurses'],AC_DEFINE(HAVE_RL_SET_SIGNALS,,"define variable in code")) -dnl AC_CHECK_HEADERS(readline/readline.h readline/history.h) - - -## ////////////////////////////////////////////////////////////////////////// ## -## // LIBLZMA ///////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## -AC_CHECK_LIB(lzma,lzma_code,LIBLZMA_SETTING=yes,LIBLZMA_SETTING=no,) -AC_CHECK_HEADERS(lzma.h) -if test "$LIBLZMA_SETTING" = "yes" -a "$ac_cv_header_lzma_h" = "yes" ; then - LIBLZMA="-llzma" -else - LIBLZMA_SETTING=no -fi -AC_SUBST(LIBLZMA) - -## ////////////////////////////////////////////////////////////////////////// ## -## // LIBBLAS ///////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -AC_CHECK_LIB([blas], [cdotu_, caxpy_], [have_blas="yes"], [have_blas=no]) -AM_CONDITIONAL(HAVE_BLAS, test x"$have_blas" = x"yes") - -## ////////////////////////////////////////////////////////////////////////// ## -## // LIBXML ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -AM_PATH_XML2('2.0.0', [have_xml=yes], [have_xml=no]) -if test "x$have_xml" != "xyes"; then - AC_MSG_NOTICE([libxml not found using xml2-config, reverting to pkg-config query]) - PKG_CHECK_MODULES([XML], [libxml-2.0], [have_xml=yes], [have_xml=no]) - XML_CPPFLAGS="$XML_CFLAGS" -fi -AC_SUBST(XML_CFLAGS) -AC_SUBST(XML_CPPFLAGS) -AC_SUBST(XML_LIBS) -AM_CONDITIONAL(XML, test x"$have_xml" = x"yes") - -if test "x$have_xml" = "xyes"; then - dnl test also for headers usability required by mdsdcl and mdsshr - CPPFLAGS_save="$CPPFLAGS" - CPPFLAGS="$XML_CPPFLAGS $CPPFLAGS $TARGET_ARCH" - AC_CHECK_HEADERS(libxml/tree.h libxml/parser.h libxml/xpath.h libxml/xpathInternals.h - ,,AC_MSG_ERROR(libxml2 development files was not found and must be installed.)) - CPPFLAGS="$CPPFLAGS_save" -else - AC_MSG_ERROR(libxml2 was not found and must be installed.) -fi - - -## ////////////////////////////////////////////////////////////////////////// ## -## // HEADERS ///////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -dnl Checks for header files. -AC_CHECK_HEADERS(stdarg.h fcntl.h strings.h sys/ioctl.h syslog.h unistd.h sys/filio.h netdb.h resolv.h sys/types.h linux/types.h drm/drm.h pwd.h grp.h) -AC_CHECK_HEADERS(dlfcn.h dl.h vxWorks.h sys/resource.h) -AC_CHECK_HEADERS(malloc.h alloca.h) - - -## PTHREADS ## -AC_CHECK_HEADERS(pthread.h) -AC_CHECK_FUNCS(pthread_lock_global_np) - - - - - - -REMCAM="remcam" -AC_CHECK_HEADERS(scsi/sg.h,DO_CAMSHR="yes",DO_CAMSHR="no") -if test "$DO_CAMSHR" = yes -then - CAMSHR="camshr" - REMCAMLIB="RemCamShr" -else - CAMSHR="" - REMCAMLIB="CamShr" -fi - -AC_CHECK_HEADERS([stdint.h]) - -dnl Check for user specified hdf5 header and library -if test -n "$HDF5_DIR" -a -d "$HDF5_DIR" -then - HDF5_APS="\$(HDF5_APS)" - HDF5_INCS="-I$HDF5_DIR/include" - HDF5_LIBS="$HDF5_LIBS -L$HDF5_DIR/lib" -else - -dnl Check for default hdf5 header and library -HDF5_APS="" -AC_CHECK_HEADERS(hdf5.h, -[ - MDS_SEARCH_LIBS([H5Fopen],[hdf5], - [ - HDF5_APS="\$(HDF5_APS)" - HDF5_INCS="" - HDF5_LIBS="" - ]) -]) - -fi - -dnl Check for jdk files -OLD_CPPFLAGS=$CPPFLAGS -AS_VAR_SET_IF([JNI_INCLUDE_DIR],[jni_inc_dir="$JNI_INCLUDE_DIR"]) -AS_VAR_SET_IF([JNI_MD_INCLUDE_DIR],[jni_md_inc_dir="$JNI_MD_INCLUDE_DIR"]) -CPPFLAGS="$CPPFLAGS -I$jni_inc_dir -I$jni_md_inc_dir" -AC_CHECK_HEADER(jni.h,JDK_CFLAGS="-I$jni_inc_dir") -AC_CHECK_HEADER(jni_md.h,JDK_CFLAGS="$JDK_CFLAGS -I$jni_md_inc_dir") -AS_VAR_SET_IF([JDK_CFLAGS], [AS_CASE([$enable_java], [yes], [JAVA_APS="\$(JAVA_APS)";JAVA_JAR="\$(JAVA_JAR)"])]) -CPPFLAGS="$OLD_CPPFLAGS" - -dnl Checks for typedefs, structures, and compiler characteristics. -AC_C_CONST -AC_HEADER_TIME -AC_STRUCT_TM -AC_TYPE_SIGNAL -AC_TYPE_SIZE_T - -dnl Check if we want to try Named Pipes instead of API -AC_CHECK_HEADERS(sys/msg.h,mdsplus_ok=no,mdsplus_ok=yes) -if test "$mdsplus_ok" = yes; then - AC_CHECK_HEADERS(sys/stat.h, mdsplus_ok=yes, mdsplus_ok=no) - AC_MSG_CHECKING(if we should use pipes for messaging) - if test "$mdsplus_ok" = yes; then - AC_DEFINE(USE_PIPED_MESSAGING,,"Define if use piped messaging") - AC_MSG_RESULT($mdsplus_ok) - fi -fi - -#AC_CACHE_CHECK([for timezone and daylight externals], mdsplus_cv_have_timezone, -# AC_TRY_LINK([#include ], [long z2 = timezone - daylight*3600;], -# mdsplus_cv_have_timezone=yes, mdsplus_cv_have_timezone=no)) -# if test "$mdsplus_cv_have_timezone" = yes; then -# AC_DEFINE(HAVE_TIMEZONE,[],["define HAVE_TIMEZONE"]) -# else -# AC_CACHE_CHECK([for tm_gmtoff in struct tm], mdsplus_cv_tm_gmtoff_in_tm, -# AC_TRY_LINK([#include ], [struct tm tim; tim.tm_gmtoff = 0;], -# mdsplus_cv_tm_gmtoff_in_tm=yes,mdsplus_cv_tm_gmtoff_in_tm=no)) -# fi -# if test "$mdsplus_cv_tm_gmtoff_in_tm" = yes; then -# AC_DEFINE(USE_TM_GMTOFF,[],["define USE_TM_GMTOFF"]) -# fi -AC_CACHE_CHECK([for tm_gmtoff in struct tm], mdsplus_cv_tm_gmtoff_in_tm, - AC_TRY_LINK([#include ], [struct tm tim; tim.tm_gmtoff = 0;], - mdsplus_cv_tm_gmtoff_in_tm=yes,mdsplus_cv_tm_gmtoff_in_tm=no)) - if test "$mdsplus_cv_tm_gmtoff_in_tm" = yes; then - AC_DEFINE(USE_TM_GMTOFF - ,,"Define if use need to use localtime instead of timezone and daylight") - fi - -AC_MSG_CHECKING(for semun union declaration) -AC_TRY_COMPILE([#include -#include ],[union semun arg;], - mdsplus_ok=yes,mdsplus_ok=no) -if test $mdsplus_ok = no; then - AC_DEFINE(NEED_SEMUN,,"Define NEED_SEMUN") -fi -AC_MSG_RESULT($mdsplus_ok) - -AC_MSG_CHECKING(for two byte fd in *FILE) -AC_EGREP_HEADER(_fileL,stdio.h,mdsplus_ok=yes,mdsplus_ok=no) -if test $mdsplus_ok = yes; then - AC_DEFINE(FILE_PTR_HL,,"define FILE_PTR_HL") -fi -AC_MSG_RESULT($mdsplus_ok) - -dnl Checks for library functions. -AC_PROG_GCC_TRADITIONAL -AC_HEADER_STDC -AC_CHECK_FUNCS(gethostname gettimeofday select socket) -AC_CHECK_FUNC(nis_local_host,mdsplus_ok=yes,mdsplus_ok=no) -AC_CHECK_FUNC(malloc) -AC_CHECK_FUNC(sched_setscheduler) - -dnl Check for Sybase -if test "$host_cpu" = "arm" -a "$(echo $host | grep arm-xilinx)" != "" -then - SYBASE_INC="" - SYBASE_LIB="" - SYBASE="" - AC_MSG_RESULT(no sybase open/client) -elif ( echo $host | grep "mingw" >/dev/null ) -then - SYBASE_INC="-DSYBASE" - SYBASE_LIB="-L\${srcdir} -lntwdblib${SQL_ARCH}" - SYBASE="SYBASE" - AC_MSG_RESULT(using Windows mssql) -elif test "$(echo $SYBASE_LIB | grep '\-L')" = "" -then - SYBASE_INC="" - SYBASE_LIB="" - OLDLIBS="$LIBS" - AC_SEARCH_LIBS([dbsqlexec],[sybdb],[SYBASE_LIB="-lsybdb";SYBASE_INC="-DSYBASE";SYBASE="SYBASE",SYBASE_LIB=""],) - LIBS="$OLDLIBS" - if test "$SYBASE_LIB" = "" - then - AC_MSG_CHECKING(for SYBASE open/client or freetds) - if test -f "/usr/lib${SYB64}/libsybdb.so" - then - SYBASE_INC="-DSYBASE" - SYBASE_LIB="-lsybdb" - SYBASE="SYBASE" - AC_MSG_RESULT(have freetds) - else - : ${SYBASE=/usr/local/sybase} - if test -d "$SYBASE/lib" - then SYBASE_LIBDIR="$SYBASE/lib" - elif test -d "$SYBASE/lib${SYB64}" - then SYBASE_LIBDIR="$SYBASE/lib${SYB64}" - fi - if test "$SYBASE_LIBDIR" != "" - then - if test -f "$SYBASE_LIBDIR/libsybdb.a" - then - SYBASE_LIB="-L$SYBASE_LIBDIR $LD_LDARC -lsybdb $LD_LDSHARE" - else - SYBASE_LIB="-L$SYBASE_LIBDIR -lsybdb" - fi - SYBASE_INC="-I$SYBASE/include -DSYBASE" - AC_MSG_RESULT(have sybase) - else - SYBASE="" - AC_MSG_RESULT(no sybase open/client) - fi - fi - fi -else - SYBASE="SYBASE" -fi -AC_MSG_CHECKING(if mdssql should be built) -if test -n "$SYBASE_INC" -then - MDSSQL="mdssql" - AC_MSG_RESULT(have sql so yes.) - AC_DEFINE(HAVE_SYBASE,,"Define if you have the sybase includes (freetds)") -else - MDSSQL="" - AC_MSG_RESULT(missing sql so no.) -fi - -AC_DEFINE_UNQUOTED(SHARELIB_TYPE,"${SHARETYPE}", - [Set SHARELIB_TYPE to ".so",".sl",".a" etc...]) -AC_C_BIGENDIAN - -AC_PATH_XTRA -AS_CASE([$host], - [*darwin*|*apple*], [X_CFLAGS+=" -I${OPENMOTIF-/usr}/include" - X_LIBS+=" -L${OPENMOTIF-/usr}/lib"]) -AS_CASE([$host],[arm*gnueabihf],[X_CFLAGS=""]) -#FIXME: Change the above to AS_VAR_APPEND with a new autoconf version (2.64+?) - -if test $UILCMD = uil32 -then - X_LIBS=`echo $X_LIBS | sed s/lib64/lib/` -fi -## AC_PATH_PROG(UIL,$UILCMD,$UILCMD,$UILPATH:/usr/bin/X11:$PATH:/usr/dt/bin) ## -AC_PATH_PROG(UIL,$UILCMD,$UILCMD,$UILPATH:${UIL}:$PATH:/usr/dt/bin) -AC_MSG_CHECKING(for uil command) -if test ! "$MINGW" = "yes" && ( which $UIL &>/dev/null ) -then - UIL="env LANG=en_US $UIL" - HAVE_MOTIF="yes" - #AC_MSG_RESULT(have uil so openmotif apps will be built.) -else -# IDLMDSEVENT and IDLMDSWIDGETS need MOTIF to build - IDLMDSEVENT="" - IDLMDSWIDGETS="" - #AC_MSG_RESULT(no uil so skipping openmotif apps.openmotif-devel not installed.) -fi -MOTIF_APS="\$(MOTIF_APS)" -AM_CONDITIONAL([HAVE_MOTIF], [AS_VAR_TEST_SET([HAVE_MOTIF])]) -AM_COND_IF([HAVE_MOTIF], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])]) - -XM_LIBS="-lMrm -lXm" -MDS_SEARCH_LIBS([XextAddDisplay],[Xext],[AS_VAR_SET([LIBXEXT],[$ac_cv_search_XextAddDisplay])]) -MDS_SEARCH_LIBS([XpGetDocumentData],[Xp],[AS_VAR_SET([LIBXP],[$ac_cv_search_XpGetDocumentData])]) - -## ////////////////////////////////////////////////////////////////////////// ## -## // PYTHON ///////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -dnl Find a Python interpreter. Python versions prior to 2.6 are not -dnl supported. -AX_PATH_PYTHON([2.6],[$host],,[:]) -AM_CONDITIONAL([HAVE_PYTHON], [test "$PYTHON" != :]) -AX_PYTHON_ARCH(PYTHON_ARCHITECTURE) -AC_SUBST(PYTHON_ARCHITECTURE) - -AC_MSG_CHECKING(PyLib) -PYLIB=${PyLib:-$($PYTHON -c ' -import sys,ctypes.util -name = ("python%d%d" if sys.platform.startswith("win") else "python%d.%d")%sys.version_info[[0:2]] -name = ctypes.util.find_library(name) -if not name is None: print(name) -')} -AC_MSG_RESULT($PYLIB) - - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS ///////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -## MdsTestShr CHECK backend related ## -AC_CHECK_FUNCS(mkstemp) -AC_CHECK_FUNCS(fork) -### maybe needs to be changed. Not sure how to deal with the multiple routines and ac_cv_search_xxxx -AC_CHECK_LIB([rt], [clock_gettime, timer_create, timer_settime, timer_delete], - [LIBRT="-lrt"],[LIBRT=""]) - - -# check that struct timespec is defined in time.h. If not, we need to -# define it in libcompat.h. Note the optional inclusion of pthread.h. -# On MinGW and MinGW-w64, the pthread.h file contains the timespec -# definition. -AC_CHECK_MEMBERS([struct timespec.tv_sec, struct timespec.tv_nsec], [], [AC_DEFINE_UNQUOTED(STRUCT_TIMESPEC_DEFINITION_MISSING, 1, "Need to define the timespec structure")], [ -#include -#if defined(HAVE_PTHREAD) -#include -#endif /* HAVE_PTHREAD */ -]) - -# check that struct itimerspec is defined in time.h. If not, we need to -# define it in libcompat.h. Note the optional inclusion of pthread.h. -# On MinGW and MinGW-w64, the pthread.h file contains the itimerspec -# definition. -AC_CHECK_MEMBERS([struct itimerspec.it_interval, struct itimerspec.it_value], [], [AC_DEFINE_UNQUOTED(STRUCT_ITIMERSPEC_DEFINITION_MISSING, 1, "Need to define the itimerspec structure")], [ -#include -#if defined(HAVE_PTHREAD) -#include -#endif /* HAVE_PTHREAD */ -]) - -AC_CHECK_PROG(HAVE_WINE, wine, yes,no) -AM_CONDITIONAL(HAVE_WINE, test x"${HAVE_WINE}" = x"yes") - -AC_CHECK_PROG(HAVE_WINECONSOLE, wineconsole, yes,no) -AM_CONDITIONAL(HAVE_WINECONSOLE, test x"${HAVE_WINECONSOLE}" = x"yes") - -AX_PERL_MODULE_VERSION(TAP::Parser 0 TAP::Parser::Aggregator 0, - [AS_VAR_SET([have_pl_tap_parser],[yes])], - [AS_VAR_SET([have_pl_tap_parser],[no]) - AC_MSG_WARN([No Perl tap module found]) - ]) -AM_CONDITIONAL([HAVE_PL_TAP_PARSER],[test x"${have_pl_tap_parser}" = x"yes"]) - - # check for valgrind - AX_VALGRIND_CHECK([ENABLE_VALGRIND]) - - # check for sanitizer - AX_ENABLE_SANITIZE([ENABLE_SANITIZE], - [AS_VAR_SET([CPPFLAGS],["${sanitize_flags} $CPPFLAGS"]) - AS_VAR_SET([LIBS],["${sanitize_libs} $LIBS"])], - [echo "sanitizer not available."; exit 111;]) - - -# selects particular envs for build:host -TS_SELECT - -## SKIP JAVA TESTS ## -# AS_VAR_IF([ENABLE_SANITIZE],[no],[],[AS_ECHO(["skipping junit: in sanitize"]); skip_junit=yes]) -AX_CHECK_JAVA_VERSION([1.8],[],[AS_ECHO(["skipping junit: not JDK 1.8"]); skip_junit=yes]) -TS_CHECK_JAVA([],[],[AS_ECHO(["skipping junit: java not found"]); skip_junit=yes]) -AM_CONDITIONAL([SKIP_JUNIT],[test x${skip_junit} = xyes]) - - - - ## test chain substitution ## - AC_SUBST(TESTS_ENVIRONMENT) - AC_SUBST(LOG_COMPILER) - AC_SUBST(LOG_DRIVER) - AC_SUBST(PY_LOG_COMPILER) - AC_SUBST(PY_LOG_FLAGS) - - AC_SUBST(VALGRIND_FLAGS) - AC_SUBST(VALGRIND_memcheck_FLAGS) - - -## ////////////////////////////////////////////////////////////////////////// ## -## // DOXYGEN ///////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -## minimum requred doxygen for cute documentation rendering -DOXYGEN_VERSION_REQUIRED="1.8" - -## versioning check script for sh usign sort builtin command -## check if $2 is a version higher than $1 -function _ver_higher { - ver=`echo -ne "$1\n$2" |sort -Vr |head -n1` - if [[ "$2" == "$1" ]]; then return 1 - elif [[ "$2" == "$ver" ]]; then return 0 - else return 1 - fi -} - -## checking for doxygen bin in path (see also m4 macro below) -AC_CHECK_PROGS([DOXYGEN], [doxygen]) -if test -z "$DOXYGEN"; - then AC_MSG_WARN([Doxygen not found - continuing without Doxygen support]) - AM_CONDITIONAL([HAVE_CUTE_DOXYGEN], [false]) -else - AM_CONDITIONAL([HAVE_CUTE_DOXYGEN], - [_ver_higher $DOXYGEN_VERSION_REQUIRED `$DOXYGEN --version`]) - AM_COND_IF([HAVE_CUTE_DOXYGEN], - [ echo "Doxygen version is cute!" ], - [ AC_MSG_WARN(["Doxygen version outdated, very limited documentation support"]) ]) -fi - -## DEFAULT ACTIVE FEATURES -DX_HTML_FEATURE(ON) -DX_CHM_FEATURE(OFF) -DX_CHI_FEATURE(OFF) -DX_MAN_FEATURE(OFF) -DX_RTF_FEATURE(OFF) -DX_XML_FEATURE(OFF) -DX_PDF_FEATURE(ON) -DX_PS_FEATURE(OFF) - -## refers to ax_prog_doxygen.m4 macro expansion -DX_INIT_DOXYGEN(mdsplus, doxygen.cfg) - -# -# All library searches should be done at this point so remove first -# TARGET_ARCH from CFLAGS as the Make macros will insert TARGET_ARCH later -# as needed. -# -CFLAGS="$CFLAGS_lib_check_save" -# - - -# -# CHECK ASSERT_LINE_TYPE to correctly override assert function in C -# This is needed for testing functions in mdsplus/testing/testing.h -# -AC_DEFUN([AX_TEST_ASSERT_LINE_TYPE],[ -AC_LANG_PUSH([C]) -AC_LINK_IFELSE( [AC_LANG_SOURCE([[ -#include -#define ASSERT_LINE_TYPE ]] [$1] [[ -void __assert_fail (const char *__assertion, const char *__file, - ASSERT_LINE_TYPE __line, const char *__function) {} -int main(void) { assert(1); return 0; } -]])], -[AS_VAR_SET([ASSERT_LINE_TYPE],["$1"]) -$2], -[$3]) -AC_LANG_POP([C]) -]) - -AC_MSG_CHECKING([assert line type]) -AX_TEST_ASSERT_LINE_TYPE([unsigned int], -[AC_MSG_RESULT(["${ASSERT_LINE_TYPE}"])], -[AX_TEST_ASSERT_LINE_TYPE([int], - [AC_MSG_RESULT(["${ASSERT_LINE_TYPE}"])], - [AC_MSG_WARN(["None of the tests succeded to set assert line type"])]) - ]) - - - -# Determine common warning options to apply to C, C++, and Fortran languages -AS_VAR_SET([WARNFLAGS], ["-Wall -Wextra"]) -AS_VAR_SET([NOWARNFLAGS],[]) -AC_MSG_CHECKING([whether to treat warnings as errors]) -AC_ARG_ENABLE([werror], - [AS_HELP_STRING([--enable-werror], - [Treat all warnings as errors])], - [], - [AS_VAR_SET([enable_werror], [no])]) -AS_CASE([$enable_werror], - [yes], [AS_VAR_APPEND([WARNFLAGS], [" -Werror"])], - []) -AC_ARG_ENABLE([wreturns], - [AS_HELP_STRING([--disable-wreturns], - [Disable warnings about unused return value from functions])], - [AS_CASE([$enableval],[no], [AS_VAR_APPEND([NOWARNFLAGS],[" -Wno-unused-result "])])], - []) -AC_SUBST([WARNFLAGS]) -AC_SUBST([NOWARNFLAGS]) -AC_MSG_RESULT([$enable_werror]) - -AC_MSG_CHECKING([whether to warn about implicit conversions]) -AC_ARG_ENABLE([wconversion], - [AS_HELP_STRING([--enable-wconversion], - [Warn about implicit conversions])], - [], - [AS_VAR_SET([enable_wconversion], [no])]) -AS_CASE([$enable_wconversion], - [yes], [AS_VAR_APPEND([WARNFLAGS], [" -Wconversion"])], - []) -AC_SUBST([WARNFLAGS]) -AC_MSG_RESULT([$enable_wconversion]) - - -# //////////////////////////////////////////////////////////////////////////// # -# /// CONFIG_H ///////////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -dnl Here we define all custom autoheader adds to mdsconfig.h.in - -dnl add here what goes on tom of mdsconfig.h -AH_TOP( -#ifndef _MDSCONFIG_H -#define _MDSCONFIG_H -#ifdef _MSC_VER -#define __attribute__(...) -#define EXPORT __declspec(dllexport) -#define MDS_ATTR_FALLTHROUGH -#else -) - -AC_DEFINE_UNQUOTED([EVENT_THREAD_STACK_SIZE_MIN],[1048576],["event handler thread min stack size [1MB]"]) - -AS_VAR_SET_IF([ASSERT_LINE_TYPE], -[AC_DEFINE_UNQUOTED([ASSERT_LINE_TYPE],[$ASSERT_LINE_TYPE],["assert line type"])]) - -AH_VERBATIM([_LL_CONSTANTS], [ -#ifdef HAVE_LL_CONSTANTS -#define LONG_LONG_CONSTANT(value) value##ll -#else -#define LONG_LONG_CONSTANT(value) value -#endif -]) - -AH_VERBATIM([_LL_CONSTANTS], [ -#ifdef HAVE_LL_CONSTANTS -#define LONG_LONG_CONSTANT(value) value##ll -#else -#define LONG_LONG_CONSTANT(value) value -#endif -]) - -AH_VERBATIM([_WIN32], [ -#ifdef _WIN32 -#define EXPORT __declspec(dllexport) -#elif HAVE_VISIBILITY -# define EXPORT __attribute__((__visibility__("default"))) -#else -#define EXPORT -#endif -]) - -AH_VERBATIM([MACOS_ARM64],[ -// This define is used to bracket Apple Silicon specific code. -#if defined(__APPLE__) && defined(__aarch64__) -#define MACOS_ARM64 -#endif -]) - -AH_VERBATIM([MDSPLUS_USE_FFI],[ -// List of platforms that need libffi for variadic functions. -#if defined(MACOS_ARM64) -#define MDSPLUS_USE_FFI -#endif -]) - -dnl add here what goes on bottom of mdsconfig.h -AH_BOTTOM( -#endif // _MSC_VER else -#endif // ifndef _MDSCONFIG_H -) - - - -dnl define custom direcotries substitution -AX_MDSPLUS_DIRECTORIES - -AC_SUBST(DISTNAME) -AC_SUBST(CAMSHR) -AC_SUBST(CLOCK_GETTIME_LIB) -AC_SUBST(D3D_PACKAGE) -AC_SUBST(D3DLIB) -AC_SUBST(D3D_FFLAGS) -AC_SUBST(DNET_STUB) -AC_SUBST(FEXECLIBDIR) -AC_SUBST(FORLD) -AC_SUBST(FOR_LDFLAGS) -AC_SUBST(FOR_LINKSHARED) -AC_SUBST(GEN_DEVICE) -AC_SUBST(GLOBUS_CFLAGS) -AC_SUBST(GLOBUS_FLAVOR) -AC_SUBST(GLOBUS_LIBS) -AC_SUBST(GLOBUS_LOCATION) -AC_SUBST(HDF5_INCS) -AC_SUBST(HDF5_LIBS) -AC_SUBST(HDF5_APS) -AC_SUBST(HUP_TO_INETD) -AC_SUBST(HUP_TO_XINETD) -AC_SUBST(HUP_TO_XINETD_SERVICE) -AC_SUBST(IDL_INC) -AC_SUBST(IDL_LIB) -AC_SUBST(IDLMDSEVENT) -AC_SUBST(IDLMDSWIDGETS) -AC_SUBST(JARS_DIR) -AC_SUBST(JAVA_ONLY) -AC_SUBST(JAVA_APS) -AC_SUBST(JAVA_JAR) -AC_SUBST(JAVAC) -AC_SUBST(JAVACFLAGS) -AC_SUBST(JDK_CFLAGS) -AC_SUBST(JDK_DIR) -AC_SUBST(JDK_LIVECONNECT) -AC_SUBST(LD) -AC_SUBST(LDSHARE) -AC_SUBST(LDARC) -AC_SUBST(LD_LDSHARE) -AC_SUBST(LD_LDARC) -AC_SUBST(LIBDL) -AC_SUBST(LIBM) -AC_SUBST(LIBPATH) -AC_SUBST(LIBPRE) -AC_SUBST(LIBREADLINE) -AC_SUBST(LIBRESOLV) -AC_SUBST(LIBXP) -AC_SUBST(LIBXEXT) -AC_SUBST(LIBRT) -AC_SUBST(LINKSHARED) -AC_SUBST(LINKJNI) -AC_SUBST(LINKMODULE) -AC_SUBST(LV) -AC_SUBST(LV_CINTOOLS) -AC_SUBST(MACOSX) -AC_SUBST(MAKEBINDIR) -AC_SUBST(MAKEFLAG_J) -AC_SUBST(MAKEFLAG_O) -AC_SUBST(MAKELIBDIR) -AC_SUBST(MAKESHLIBDIR) -AC_SUBST(MAKEUIDDIR) -AC_SUBST(MDSSQL) -AC_SUBST(MDSTCPIP) -AC_SUBST(MITDEVICESIO_TARGETS) -AC_SUBST(HAVE_MOTIF) -AC_SUBST(MOTIF_APS) -AC_SUBST(MOTIF_LDSHARE) -AC_SUBST(MOTIF_LDARC) -AC_SUBST(MOTIF_LD_LDSHARE) -AC_SUBST(MOTIF_LD_LDARC) -AC_SUBST(PYTHON_INCLUDE_DIR) -AC_SUBST(PYLIB) -AC_SUBST(NEED_SEMUN) - -AC_SUBST(RELEASE_MAJOR) -AC_SUBST(RELEASE_MINOR) -AC_SUBST(RELEASE_RELEASE) -AC_SUBST(RELEASE_BRANCH) -AC_SUBST(RELEASE_TAG) -AC_SUBST(RELEASE_DATE) - -AC_SUBST([GIT_TAG]) -AC_SUBST([GIT_BRANCH]) -AC_SUBST([GIT_REMOTE]) -AC_SUBST([GIT_REMOTE_URL]) -AC_SUBST([GIT_COMMIT]) -AC_SUBST([GIT_COMMIT_DATE]) - -AC_SUBST(REMCAM) -AC_SUBST(REMCAMLIB) -AC_SUBST(ENABLE_SANITIZE) -AC_SUBST(SHARETYPE) -AC_SUBST(SHARETYPEJNI) -AC_SUBST(SHARETYPEMOD) -AC_SUBST(SRBLIB) -AC_SUBST(SRBINCLUDE) -AC_SUBST(SYBASE_INC) -AC_SUBST(SYBASE_LIB) -AC_SUBST([TARGET_ARCH]) -AC_SUBST(TAR_EXCLUDE) -AC_SUBST(TDIC) -AC_SUBST([THREAD]) -AC_SUBST(UIL) -AC_SUBST(XM_LIBS) -AC_SUBST(uiddir) -AC_SUBST(USE_PIPED_MESSAGING) -AC_SUBST(USE_TM_GMTOFF) -AC_SUBST(DC1394_SUPPORT) -AC_SUBST(DC1394_SUPPORT2) -AC_SUBST(VS) -AC_SUBST(VS_ARCH) -AC_SUBST(VS_DIR) -AC_SUBST(JRE) -AC_SUBST(UIL) -AC_SUBST(JAVA_TARGET_ARCH) - -AC_CONFIG_HEADER(include/mdsplus/mdsconfig.h) - - -AC_OUTPUT( - envsyms - Makefile - Makefile.inc - _include/_mdsversion.h - actions/Makefile - actions/testing/Makefile - camshr/Makefile - ccl/Makefile - d3dshr/Makefile - docs/Makefile - dwscope/Makefile - hdf5/Makefile - idlmdsevent/Makefile - idlmdswidgets/Makefile - java/devicebeans/Makefile - java/jdevices/Makefile - java/jdispatcher/Makefile - java/jscope/Makefile - java/jtraverser/Makefile - java/jtraverser2/Makefile - java/Makefile - java/mdsobjects/docs/Makefile - java/mdsobjects/Makefile - java/mdsobjects/tests/Makefile - java/mdsplus-api/Makefile - java/mdsplus-api/tests/Makefile - java/mdsplus/Makefile - java/tests/Makefile - javamds/Makefile - LabView/Makefile - macosx/Makefile - manpages/Makefile - math/Makefile - math/testing/Makefile - mdsdcl/Makefile - mdsdcl/mdsdclVersionInfo.c - mdslib/docs/Makefile - mdslib/Makefile - mdslib/testing/Makefile - mdslibidl/Makefile - mdsmisc/Makefile - mdsobjects/cpp/docs/Makefile - mdsobjects/cpp/Makefile - mdsobjects/cpp/testing/Makefile - mdsobjects/cpp/testing/testutils/Makefile - mdsobjects/labview/Makefile - mdsshr/docs/Makefile - mdsshr/Makefile - mdsshr/testing/Makefile - mdssql/Makefile - mdstcpip/docs/img/Makefile - mdstcpip/docs/Makefile - mdstcpip/Makefile - mdstcpip/testing/Makefile - mdstcpip/zlib/Makefile - mdsvme/Makefile - mitdevices/Makefile - pydevices/HtsDevices/_version.py - pydevices/MitDevices/_version.py - pydevices/RfxDevices/_version.py - pydevices/W7xDevices/_version.py - python/MDSplus/_version.py - python/MDSplus/docs/Makefile - python/MDSplus/tests/Makefile - remcam/Makefile - roam/Makefile - rpm/envsyms - rpm/Makefile - rpm/post_install_script - scripts/Makefile - servershr/Makefile - setevent/Makefile - tcl/Makefile - tdic/Makefile - tdishr/Makefile - tdishr/testing/Makefile - tditest/Makefile - tditest/testing/Makefile - testing/backends/check/Makefile - testing/Makefile - testing/selftest/Makefile - traverser/Makefile - treeshr/Makefile - treeshr/testing/Makefile - wfevent/Makefile - wfevent/testing/Makefile - xmdsshr/Makefile - xtreeshr/Makefile -) - - - - -AC_OUTPUT_COMMANDS(make depend) -if test "$JAVA_APS" = "" -a "$enable_java" = "yes" -then - AC_MSG_WARN() - AC_MSG_WARN() - AC_MSG_WARN(The development environment for Java applications was not found.) - AC_MSG_WARN(The build of Java applications will be skipped from the build of MDSplus.) - AC_MSG_WARN(Install a Java SDK and reconfigure to build the Java apps.) - AC_MSG_WARN() -fi -if test "$LIBREADLINE" = "" -then - AC_MSG_WARN() - AC_MSG_WARN() - AC_MSG_WARN(The libreadline library was not found) - AC_MSG_WARN(The tdic application will be skipped.) - AC_MSG_WARN(Install the package containing the readline library (perhaps libreadline-devel) and reconfigure to build the tdic application.) - AC_MSG_WARN() - AC_MSG_WARN() -fi -if test "$SYBASE" = "" -then - AC_MSG_WARN() - AC_MSG_WARN() - AC_MSG_WARN(The open sybase software was not found in /usr/local/sybase.) - AC_MSG_WARN(The sqlserver interface libraries will be skipped.) - AC_MSG_WARN() - AC_MSG_WARN() -fi -if test "$HAVE_MOTIF" = "" -a "$MINGW" = "" -a ! "$OS" = "windows" -then - AC_MSG_WARN() - AC_MSG_WARN() - AC_MSG_WARN(The openmotif development environment was not found.) - AC_MSG_WARN(The openmotif based applications and libraries will be skipped.) - AC_MSG_WARN() - AC_MSG_WARN() -fi -if test "$with_idl" = "no" -then - AC_MSG_WARN() - AC_MSG_WARN() - AC_MSG_WARN(The IDL application directory was not found.) - AC_MSG_WARN(The libraries used for interfacing IDL with MDSplus will be skipped.) - AC_MSG_WARN() - AC_MSG_WARN() -fi -if test "$LV" = "" -then - AC_MSG_WARN() - AC_MSG_WARN() - AC_MSG_WARN("Labview include files were not found.) - AC_MSG_WARN("The labview MDSobjects will not be built") - AC_MSG_WARN() - AC_MSG_WARN() -fi diff --git a/d3dshr/Makefile.in b/d3dshr/Makefile.in deleted file mode 100644 index 609c39588f..0000000000 --- a/d3dshr/Makefile.in +++ /dev/null @@ -1,28 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - - -FFLAGS=@FFLAGS@ @D3D_FFLAGS@ -D3DLIB=@D3DLIB@ - -SOURCES = mdsptdata.f -OBJECTS = $(SOURCES:.f=.o) - -all: @MAKELIBDIR@ @MAKELIBDIR@libMdsD3D@SHARETYPE@ - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) @MAKELIBDIR@libMdsD3D@SHARETYPE@ - -install: $(libdir) - $(INSTALL) -m 755 @MAKELIBDIR@libMdsD3D@SHARETYPE@ @libdir@ - -@MAKELIBDIR@libMdsD3D@SHARETYPE@ : $(OBJECTS) - $(LD) -o $@ @LINKSHARED@ $(OBJECTS) $(D3DLIB) -ld3 $(LIBS) @FOR_LDFLAGS@ diff --git a/deploy/build.sh b/deploy/build.sh deleted file mode 100755 index fa78cef0b5..0000000000 --- a/deploy/build.sh +++ /dev/null @@ -1,697 +0,0 @@ -#!/bin/bash -# -# mdsplus-deploy/build.sh -# -# Build mdsplus for a selected operating system for testing or -# generating installers. -# -SRCDIR=$(realpath $(dirname ${0})/..) -export GIT_DIR=${SRCDIR}/.git -export GIT_WORK_TREE=${SRCDIR} -RED() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[31m" - fi -} -GREEN() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[32m" - fi -} -NORMAL() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[0m" - fi -} -printhelp() { - cat <&1 echo "Unknown option(s) specified: ${unknownopts}" - exit 1 - fi -} -opts="$@" -# -# Parse the options provided in the command -# -parsecmd "$opts" - -if [ -z "${DOCKER_SRCDIR}" ] -then - DOCKER_SRCDIR="${SRCDIR}" -fi - -# -# Get the default options for the OS specified. -# -if [ -r "${SRCDIR}/deploy/os/${OS}.opts" ] -then - os_opts=$(grep -v "#" ${SRCDIR}/deploy/os/${OS}.opts) -fi -# -# See if this build was triggered by a trigger job and use -# the command options in the trigger.opts file. -# -if [ -r ${SRCDIR}/trigger.opts ] -then - trigger_opts="$(cat ${SRCDIR}/trigger.opts)" -fi -# -# Reparse the command using the trigger options, the os options and the command line options. -# -cat <&2 echo "None of --test --make-jars --release=version --publish=version --sanitize --valgrind options specified on the command or skipped. Nothing to do!" - exit 0 -fi -# -# Make sure the platform specified is supported. -# -if [ -z "$PLATFORM" ] -then - >&2 echo "No platform specified. Either the --os=osname or the --platform=pname options must be specified." - exit 1 -fi -if [ "PUBLISH" = "yes" -a -z "$DISTNAME" ] -then - >&2 echo "Attempting to publish without a --distname=name option." - exit 1 -fi -if [ ! -d "${SRCDIR}/deploy/platform/${PLATFORM}" ] -then - >&2 echo "Plaform ${PLATFORM} is not supported." - exit 1 -fi -if [ -z "$NEW_WORKSPACE" ] -then - if [ -z "$WORKSPACE" ] - then - WORKSPACE=$(pwd)/build/${OS}/${BRANCH} - fi -else - WORKSPACE=$(realpath ${NEW_WORKSPACE}) -fi - -if [ "$TEST" = "yes" -a "$TEST_RELEASE" = "yes" ] -then - RELEASE=yes -fi - -if [ "$RELEASE" = "yes" -o "$PUBLISH" = "yes" ] -then - if [ -z "$RELEASEDIR" ] - then - RELEASEDIR=${WORKSPACE}/release - fi -else - RELEASEDIR="" -fi - -if [ "$PUBLISH" = "yes" ] -then - if [ -z "$PUBLISHDIR" ] - then - PUBLISHDIR=${WORKSPACE}/publish - fi -else - PUBLISHDIR="" -fi -# -# Convert DOCKERIMAGE and DOCKERFILE options -# from coma delimited to space delimited -# -spacedelim() { - if [ -n "$1" ] - then - if [ "$1" = "skip" ] - then - ans="" - else - IFS=',' read -ra ARR <<< "$1" - ans="${ARR[*]}" - fi - fi - echo $ans -} - -DOCKERFILE="$(spacedelim $DOCKERFILE)" -DOCKERIMAGE="$(spacedelim $DOCKERIMAGE)" -# -# pull docker images if specified. -# -if [ "$DOCKERPULL" = "yes" ] -then - if [ -n "$DOCKERIMAGE" ] - then - for img in ${DOCKERIMAGE} - do - docker pull $img - done - fi -elif [ -n "$DOCKERFILE" ] -then - # - # build docker images if specified. - # - images=( $DOCKERIMAGE ) - files=( $DOCKERFILE ) - if [ "${#images[@]}" != "${#files[@]}" ] - then - >&2 echo "number of dockerfiles does not equal number of dockerimage names" - exit 1 - fi - for index in ${!images[@]} - do - file=files[$index] - image=image[$index] - pushd $(dirname $file) - docker build -t $image . - popd - done -fi -mkdir -p ${WORKSPACE} -if [ -z "$BRANCH" ] -then - BRANCH=$(whoami) -fi -if [ -z "$EVENT_PORT" ] -then - EVENT_PORT=4000 -fi -if [ -z "$TEST_FORMAT" ] -then - TEST_FORMAT=log -fi - -if [ -n "$RELEASEDIR" ] -then - RELEASEDIR=${RELEASEDIR}/${DISTNAME} -fi - -if [ -n "$PUBLISHDIR" ] -then - PUBLISHDIR=${PUBLISHDIR}/${DISTNAME} -fi - -# -# Invoke the platform specific build script -# -OS=${OS} \ - TEST=${TEST} \ - TEST_FORMAT=${TEST_FORMAT} \ - TEST_TIMEUNIT=${TEST_TIMEUNIT} \ - EVENT_PORT=${EVENT_PORT} \ - MAKE_JARS=${MAKE_JARS} \ - RELEASE=${RELEASE} \ - PUBLISH=${PUBLISH} \ - RELEASE_VERSION=${RELEASE_VERSION} \ - PLATFORM=${PLATFORM} \ - VALGRIND_TOOLS=${VALGRIND_TOOLS} \ - SANITIZE=${SANITIZE} \ - SRCDIR=${SRCDIR} \ - DOCKER_SRCDIR="$DOCKER_SRCDIR" \ - BRANCH=${BRANCH} \ - WORKSPACE=${WORKSPACE} \ - RELEASEDIR=${RELEASEDIR} \ - PUBLISHDIR=${PUBLISHDIR} \ - DOCKERIMAGE=${DOCKERIMAGE} \ - DOCKERFILE=${DOCKERFILE} \ - DOCKERNETWORK=${DOCKERNETWORK} \ - KEYS=${KEYS} \ - DISTNAME=${DISTNAME} \ - UPDATEPKG=${UPDATEPKG} \ - COLOR=$COLOR \ - ARCH=${ARCH} \ - INTERACTIVE="$INTERACTIVE" \ - JARS_DIR="$JARS_DIR" \ - CONFIGURE_PARAMS="$CONFIGURE_PARAMS" \ - ${SRCDIR}/deploy/platform/platform_build.sh -if [ "$?" != "0" ] -then - RED - cat <&2 -============================================ - -Failure: The build was unsuccessful! - -============================================ -EOF - NORMAL - exit 1 -else - GREEN - cat < ${LAST_RELEASE_INFO} - fi -fi diff --git a/deploy/commit_type_check.sh b/deploy/commit_type_check.sh deleted file mode 100755 index f4305e68ad..0000000000 --- a/deploy/commit_type_check.sh +++ /dev/null @@ -1,59 +0,0 @@ -#!/bin/bash -# -# Check commit title format of all commits since original commit. -# -# The original commit is passed in as an argument ("origin" for pull requests and -# the last release tag for release builds. -# -# The second argument to this script should be the filespec of the contents of an -# email to be sent to the person who created a commit with an invalid title. -# - -git log $1..HEAD --no-merges --decorate=short --pretty=format:"%<(80,trunc)%s%n%ae" | -awk -v EMAILMSG="$2" -F: '{ IGNORECASE=1 - TITLE=$0 - switch ($1) { - case "Feature": - case "Revert \"Feature": - VERSION="MINOR" - OK="1" - break - case "Fix": - case "Revert \"Fix": - if ( VERSION == "" || VERSION == "SAME" ) { - VERSION="PATCH" - } - OK="1" - break - case "Tests": - case "Revert \"Tests": - case "Docs": - case "Revert \"Docs": - case "Build": - case "Revert \"Build": - if ( VERSION == "" ) { - VERSION="SAME" - } - OK="1" - break - default: - OK="0" - FAIL="TRUE" - break - } - getline - EMAIL=$0 - if ( OK != "1" && EMAILMSG != "" ) { - system("mail -s \"" TITLE "\" " EMAIL " < " EMAILMSG ) - } -} -END { - if ( FAIL == "TRUE" && VERSION == "" ) { - print("BADCOMMIT") - } else if ( VERSION == "" ) { - print("SAME") - } else { - print(VERSION) - } -}' - diff --git a/deploy/git_revision.sh b/deploy/git_revision.sh deleted file mode 100755 index 9becd0d4d3..0000000000 --- a/deploy/git_revision.sh +++ /dev/null @@ -1,104 +0,0 @@ -#!/bin/bash -SRC=$(realpath "$(dirname "$0")/..") -GIT="git --git-dir=${SRC}/.git --work-tree=${SRC}" -GIT_TAG="$(${GIT} describe --tag)" -GIT_BRANCH="$(${GIT} rev-parse --abbrev-ref HEAD)" -GIT_REMOTE="$(${GIT} config branch.${GIT_BRANCH}.remote)" -GIT_REMOTE_URL="$(${GIT} config remote.${GIT_REMOTE}.url)" -GIT_COMMIT="$(${GIT} rev-parse HEAD)" -GIT_COMMIT_DATE="$(${GIT} log -1 --format=%ad)" - -if test -z "${GIT_REMOTE}"; then - GIT_REMOTE=LOCAL - GIT_REMOTE_URL="file:/${SRC}" -fi - -RELEASE_TAG="${GIT_TAG}" -AWK=$(which awk) -if test -n "${AWK}"; then - if test -n "${RELEASE_VERSION}"; then - RELEASE_MAJOR="$(echo ${RELEASE_VERSION} | ${AWK} -F"." '{ print $1 }')" - RELEASE_MINOR="$(echo ${RELEASE_VERSION} | ${AWK} -F"." '{ print $2 }')" - RELEASE_RELEASE="$(echo ${RELEASE_VERSION} | ${AWK} -F"." '{ print $3 }')" - fi - if test -z "${RELEASE_MAJOR}" -o -z "${RELEASE_MINOR}" -o -z "${RELEASE_RELEASE}"; then - RELEASE_MAJOR="$(echo ${RELEASE_TAG} | ${AWK} -F'-' '{ print $2 }')" - RELEASE_MINOR="$(echo ${RELEASE_TAG} | ${AWK} -F'-' '{ print $3 }')" - RELEASE_RELEASE="$(echo ${RELEASE_TAG} | ${AWK} -F'-' '{ print $4 }')" - fi -fi -if test -z "${RELEASE_MAJOR}" -o -z "${RELEASE_MINOR}" -o -z "${RELEASE_RELEASE}"; then - RELEASE_MAJOR=0 - RELEASE_MINOR=0 - RELEASE_RELEASE=0 -fi -RELEASE_VERSION="${RELEASE_MAJOR}.${RELEASE_MINOR}.${RELEASE_RELEASE}" -RELEASE_DATE="$(date)" -# patch branch: maxlength = 12 -RELEASE_BRANCH=${BRANCH::12} -if test -n "${BRANCH::12}" -then RELEASE_BRANCH=${BRANCH::12} -elif test -n "${GIT_BRANCH::12}" -then RELEASE_BRANCH=${GIT_BRANCH::12} -else RELEASE_BRANCH=unknown -fi -RELEASE_TAG="${RELEASE_BRANCH}_release-${RELEASE_MAJOR}-${RELEASE_MINOR}-${RELEASE_RELEASE}" - - -cat - >"${SRC}/m4/ax_git_revision.m4" <: - - - -Where: - - is one of (note the type must be followed by a colon with no spaces): - - Feature (commit is introducing a new feature to MDSplus. - Will eventually trigger "minor" version increment.) - Fix (commit is to fix an existing bug in MDSplus. - Will eventually trigger "path" version increment.) - Build (commit affects build/deploy scripts and configurations. - Does not trigger a new release version.) - Docs (commit affects MDSplus documentation. - Does not trigger a new release version.) - Tests (changes to or additional regression tests. - Does not trigger a new release version.) - -The check on the is case insensitive. - - is a short but meaningful title of the change being made. - is one or more lines describing the commit in detail. While - the purpose and details of the commit are fully understood - by the author of the commit at the time of the commit it - may not be that obvious to other developers and even less - so as time passes. - -Eventually it is planned to automatically generate a formatted release notes -document from the commit messages. If you are adding a series of commits -to add a new feature or fix a bug etc. it would be best to either squash -the commits into one commit or use the same commit type and title in the -commits so the release notes generator can consolidate the details. - diff --git a/deploy/issueNotifications.py b/deploy/issueNotifications.py deleted file mode 100644 index 78d3d0e088..0000000000 --- a/deploy/issueNotifications.py +++ /dev/null @@ -1,156 +0,0 @@ -import smtplib -import requests -import json -from email.mime.multipart import MIMEMultipart -from email.mime.text import MIMEText -from datetime import datetime -from dateutil import tz - - -def skipIt(issue): - for label in issue['labels']: - if label['name'] == 'noremind': - return True - return False - - -def issueText(issue): - issue['emailCreated'] = datetime.strptime(issue['created_at'], "%Y-%m-%dT%H:%M:%SZ").replace( - tzinfo=tz.tzutc()).astimezone(tz.tzlocal()).strftime("%m/%d/%Y") - issue['emailLabels'] = '' - for label in issue['labels']: - issue['emailLabels'] += label['name']+" " - assignees = '' - for assignee in issue['assignees']: - assignees += assignee['login']+" " - if len(assignees) == 0: - issue['emailColspan'] = ' colspan="2"' - issue['emailAssignees'] = '' - else: - issue['emailColspan'] = '' - issue['emailAssignees'] = '%s' % assignees - text = """\ - - %(emailCreated)s - %(title)s - %(emailLabels)s - %(emailAssignees)s - -""" % issue - return text - - -def assignedTo(issue): - ans = list() - for pers in issue['assignees']: - ans.append(pers['login']) - return ans - - -def messageContent(issues, user): - total = 0 - content = """\ - - - - - -

You have outstanding MDSplus issues to deal with.


- - - - - - - - - - -""" - num = 0 - for issue in issues: - if 'pull_request' not in issue: - assigned = assignedTo(issue) - if user in assigned and not skipIt(issue): - num += 1 - content += issueText(issue) - total += num - content += """\ - - - - - - -""" % num - num = 0 - for issue in issues: - if 'pull_request' not in issue: - assigned = assignedTo(issue) - if len(assigned) == 0 and not skipIt(issue): - num += 1 - content += issueText(issue) - total += num - content += """\ - - - -
Issues assigned to you
CreatedTitleLabelsAssignees
Total assigned issues: %d
Issues still currently unassigned
Total unassigned issues: %d
- - -""" % num - if total > 0: - return content - else: - return none - - -def getIssuesFromGithub(): - issues = list() - page = 1 - while True: - r = requests.get("https://api.github.com/repos/MDSplus/mdsplus/issues", - params={'state': 'open', 'page': page}) - if r.ok: - page += 1 - new_issues = json.loads(r.text) - if len(new_issues) > 0: - f = open('issues-%d.txt' % page, 'w') - f.write(r.text.encode('utf-8')) - f.close() - issues += new_issues - else: - break - return issues - - -def getIssuesFromFiles(): - issues = list() - page = 1 - while True: - page += 1 - try: - f = open('issues-%d.txt' % page, 'r') - issues = issues+json.load(f) - except: - break - return issues - - -def sendIssueNotifications(users): - issues = getIssuesFromGithub() - for user in users.keys(): - msgtext = messageContent(issues, user) - if msgtext is None: - continue - msg = MIMEText(msgtext, 'html') - msg['Subject'] = "MDSplus issues" - msg['From'] = "twf@psfc.mit.edu" - msg['To'] = users[user] - s = smtplib.SMTP('mail1.psfc.mit.edu') - s.sendmail("twf@psfc.mit.edu", users[user], msg.as_string()) - s.quit() diff --git a/deploy/os/bootstrap.opts b/deploy/os/bootstrap.opts deleted file mode 100644 index f847adfc53..0000000000 --- a/deploy/os/bootstrap.opts +++ /dev/null @@ -1 +0,0 @@ ---dockerimage=mdsplus/builder:bootstrap --bootstrap \ No newline at end of file diff --git a/deploy/os/fc30.opts b/deploy/os/fc30.opts deleted file mode 100644 index 274756fbf7..0000000000 --- a/deploy/os/fc30.opts +++ /dev/null @@ -1 +0,0 @@ ---platform=redhat --valgrind=memcheck,helgrind --sanitize=address,undefined,thread --dockerimage=mdsplus/builder:fc30 --distname=fc30 diff --git a/deploy/os/fc32.opts b/deploy/os/fc32.opts deleted file mode 100644 index 200a9aaf87..0000000000 --- a/deploy/os/fc32.opts +++ /dev/null @@ -1 +0,0 @@ ---platform=redhat --valgrind=memcheck,helgrind --sanitize=address,undefined,thread --dockerimage=mdsplus/builder:fc32 --distname=fc32 diff --git a/deploy/os/macosx.env b/deploy/os/macosx.env deleted file mode 100644 index 754394c12d..0000000000 --- a/deploy/os/macosx.env +++ /dev/null @@ -1 +0,0 @@ -PATH=/usr/bin:/usr/local/bin:${PATH} diff --git a/deploy/os/macosx.opts b/deploy/os/macosx.opts deleted file mode 100644 index 5e875a5204..0000000000 --- a/deploy/os/macosx.opts +++ /dev/null @@ -1 +0,0 @@ ---platform=macosx --distname=macosx diff --git a/deploy/os/maven.opts b/deploy/os/maven.opts deleted file mode 100644 index 7b3a6c8cf5..0000000000 --- a/deploy/os/maven.opts +++ /dev/null @@ -1 +0,0 @@ ---platform=maven --dockerimage=maven:3.6.1-jdk-8 diff --git a/deploy/os/raspberrypi.env b/deploy/os/raspberrypi.env deleted file mode 100644 index e44699cffc..0000000000 --- a/deploy/os/raspberrypi.env +++ /dev/null @@ -1,6 +0,0 @@ -export JDK_DIR=/usr/lib/jvm/java-7-openjdk-i386; -export DIST=RaspberryPi -export PATH=/gcc-linaro-arm-linux-gnueabihf-raspbian/bin:$PATH -export CFLAGS="-g -O2 -Wl,--allow-shlib-undefined -I/raspberrypi-include" -export FFLAGS="-g -O2 -Wl,--allow-shlib-undefined" -export LIBS="-L /raspberrypi-rootfs/usr/lib/arm-linux-gnueabihf -L /raspberrypi-rootfs/lib/arm-linux-gnuabihf" diff --git a/deploy/os/raspberrypi.opts b/deploy/os/raspberrypi.opts deleted file mode 100644 index 20160d9846..0000000000 --- a/deploy/os/raspberrypi.opts +++ /dev/null @@ -1 +0,0 @@ ---platform=debian --no-test --dockerimage=mdsplus/builder:raspberrypi-32 --distname=RaspberryPi --arch=armhf --jars diff --git a/deploy/platform/alpine/alpine_docker_build.sh b/deploy/platform/alpine/alpine_docker_build.sh deleted file mode 100644 index a46d806803..0000000000 --- a/deploy/platform/alpine/alpine_docker_build.sh +++ /dev/null @@ -1,80 +0,0 @@ -#!/bin/bash -# -# alphine_docker_build is used to build, test, package and add apk's to a -# repository for alpine based systems. -# - -testx86_64="64 x86_64-linux bin lib" -testx86="32 i686-linux bin lib --with-gsi=/usr:gcc32" -testarmhf="arm armv6-alpine-linux-muslgnueabihf bin lib" -srcdir=$(readlink -f $(dirname ${0})/../..) - -gethost() { - case $1 in - x86) echo i686-linux ;; - x86_64) echo x86_64-linux ;; - armhf) echo armv6-alpine-linux-muslgnueabihf ;; - esac -} - -if [ -z "$host" ]; then - host=$(gethost ${ARCH}) -fi - -export CFLAGS="-DASSERT_LINE_TYPE=int" -export CPPFLAGS="-DASSERT_LINE_TYPE=int" - -runtests() { - testarch ${ARCH} ${host} bin lib - checktests -} - -makelist() { - echo -} - -buildrelease() { - ### Build release version of MDSplus and then construct installer debs - set -e - RELEASEBLD=/workspace/releasebld - BUILDROOT=${RELEASEBLD}/buildroot - MDSPLUS_DIR=${BUILDROOT}/usr/local/mdsplus - rm -Rf ${RELEASEBLD} - mkdir -p ${RELEASEBLD} ${BUILDROOT} ${MDSPLUS_DIR} - pushd ${RELEASEBLD} - config ${ARCH} ${host} bin lib ${CONFIGURE_EXTRA} - if [ -z "$NOMAKE" ]; then - $MAKE - $MAKE install - fi - popd - if [ -z "$NOMAKE" ]; then - BUILDROOT=${BUILDROOT} \ - ${srcdir}/deploy/packaging/alpine/build_apks.sh - fi -} - -publish() { - ### DO NOT CLEAN /publish as it may contain valid older release apks - ## this will move new files into publish and update APKINDEX.tar.gz - # if NEW.tar.gz exists or if an old APKINDEX.tar.gz does not yet exist, - # it will create a new repository (takes longer, exspecially on a remote fs) - R=/release/${FLAVOR} - P=/publish/${FLAVOR} - mkdir -p $P/${ARCH} $P/noarch - cd $P - rsync -a $R/${ARCH}/*.apk $P/${ARCH}/ && : - checkstatus abort "Failure: Problem copying arch apks to publish area!" $? - if ! rsync -a $R/noarch/*.apk $P/noarch/; then - echo "Problem copying noarch apks to publish area, maybe they are there already." - fi - if [ -r $P/${ARCH}/APKINDEX.tar.gz -a ! -r $P/${ARCH}/NEW.tar.gz ]; then - apk index -x $P/${ARCH}/APKINDEX.tar.gz -o $P/${ARCH}/NEW.tar.gz $P/${ARCH}/*.apk noarch/*.apk - else - apk index -o $P/${ARCH}/NEW.tar.gz $P/${ARCH}/*.apk noarch/*.apk - fi - checkstatus abort "Failure: Problem updating apk repository in publish!" $? - abuild-sign -k /sign_keys/mdsplus@mdsplus.org-589e05b6.rsa $P/${ARCH}/NEW.tar.gz - checkstatus abort "Failure: Problem signing apk repository in publish!" $? - mv -f $P/${ARCH}/NEW.tar.gz $P/${ARCH}/APKINDEX.tar.gz -} diff --git a/deploy/platform/bootstrap/bootstrap_build.sh b/deploy/platform/bootstrap/bootstrap_build.sh deleted file mode 100755 index ec2493dbed..0000000000 --- a/deploy/platform/bootstrap/bootstrap_build.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash -# -# runs $srcdir/bootstrap in a controlled manner -cid=$(mktemp -d)/bootstrap-docker-cid -cleanup() { - if [ -f $cid ] - then - docker rm -f $(cat $cid) - rm -f $cid - rmdir $(dirname $cid) - fi -} -trap cleanup EXIT INT -docker run -t -a stdout -a stderr --cidfile=$cid \ - -u $(id -u):$(id -g) --privileged \ - -e "HOME=/tmp" \ - -e "BRANCH" \ - -e "RELEASE_VERSION" \ - -v "${SRCDIR}:${DOCKER_SRCDIR}" \ - ${DOCKERIMAGE} "${DOCKER_SRCDIR}/bootstrap" diff --git a/deploy/platform/debian/debian_build.sh b/deploy/platform/debian/debian_build.sh deleted file mode 100644 index 4e05297962..0000000000 --- a/deploy/platform/debian/debian_build.sh +++ /dev/null @@ -1,8 +0,0 @@ -# Sourced by mdsplus/deploy/platform/platform_build.sh -default_build -if [ "${RELEASE}" = "yes" ] -then - # clean up repo before creating a new release - rm -Rf ${RELEASEDIR}/repo -fi -rundocker diff --git a/deploy/platform/debian/debian_docker_build.sh b/deploy/platform/debian/debian_docker_build.sh deleted file mode 100755 index b08de99282..0000000000 --- a/deploy/platform/debian/debian_docker_build.sh +++ /dev/null @@ -1,196 +0,0 @@ -#!/bin/bash -# -# debian_docker_build is used to build, test, package and add deb's to a -# repository for debian based systems. -# -# release: -# /release/repo -> repository -# /release/$branch/DEBS/$arch/*.deb -# -# publish: -# /publish/repo -> repository -# /publish/$branch/DEBS/$arch/*.deb -# - -srcdir=$(readlink -e $(dirname ${0})/../..) - -# configure based on ARCH -case "${ARCH}" in -"amd64") - host=x86_64-linux - gsi_param="--with-gsi=/usr:gcc64" - bits=64 - ;; -"armhf") - host=arm-linux-gnueabihf - gsi_param="--with-gsi=/usr:gcc32" - bits=32 - ;; -*) - host=i686-linux - gsi_param="--with-gsi=/usr:gcc32" - bits=32 - ;; -esac - -if [ "$OS" == "debian_wheezy" -o "${OS:0:7}" = "debian7" ]; then - export JDK_DIR=/usr/lib/jvm/java-7-openjdk-${ARCH} -fi -config_param="${bits} ${host} bin lib ${gsi_param}" -runtests() { - testarch ${config_param} - checktests -} -makelist() { - dpkg -c $1 | - grep -v MDSplus/dist | - grep -v MDSplus/build | - grep -v MDSplus/doc | - grep -v egg-info | - grep -v '/$' | - awk '{for (i=6; i "); print a[1]}' | - sort -} -debtopkg() { - if (echo $1 | grep mdsplus${2}_${3} >/dev/null); then - echo "" - else - echo ${1:8+${#2}:-${#3}-${#4}-6} - fi -} -buildrelease() { - ### Build release version of MDSplus and then construct installer debs - set -e - # ${RELEASEDIR}/${FLAVOR}/DEBS will be cleaned in debian_build.sh - RELEASEDEBS=/release/${FLAVOR}/DEBS/${ARCH} - RELEASEBLD=/workspace/releasebld - PACKAGESDIR=/workspace/packages - BUILDROOT=${RELEASEBLD}/buildroot - MDSPLUS_DIR=${BUILDROOT}/usr/local/mdsplus - rm -Rf ${RELEASEBLD}/${bits} ${BUILDROOT} ${PACKAGESDIR} - mkdir -p ${RELEASEBLD}/${bits} ${BUILDROOT} ${MDSPLUS_DIR} ${PACKAGESDIR} - pushd ${RELEASEBLD}/${bits} - config ${config_param} ${CONFIGURE_EXTRA} - if [ -z "$NOMAKE" ]; then - $MAKE - $MAKE install - fi - popd - if [ -z "$NOMAKE" ]; then - mkdir -p ${RELEASEDEBS} - BUILDROOT=${BUILDROOT} \ - ${srcdir}/deploy/packaging/debian/debian_build_debs.py - baddeb=0 - for deb in $(find ${RELEASEDEBS} -name "*${RELEASE_VERSION}_*\.deb"); do - pkg=$(debtopkg $(basename $deb) "${BNAME}" ${RELEASE_VERSION} ${ARCH}) - if [ "${#pkg}" = "0" ]; then - continue - fi - if [ "${pkg: -4}" = "_bin" ]; then # ends with _bin - checkfile=${srcdir}/deploy/packaging/${PLATFORM}/$pkg.$ARCH - else - checkfile=${srcdir}/deploy/packaging/${PLATFORM}/$pkg.noarch - fi - if [ "$UPDATEPKG" = "yes" ]; then - mkdir -p ${srcdir}/deploy/packaging/${PLATFORM} - makelist $deb >${checkfile} - else - set +e - echo "Checking contents of $(basename $deb)" - if (diff <(makelist $deb) <(sort ${checkfile})); then - echo "Contents of $(basename $deb) is correct." - else - checkstatus baddeb "Failure: Problem with contents of $(basename $deb)" 1 - fi - set -e - fi - done - checkstatus abort "Failure: Problem with contents of one or more debs. (see above)" $baddeb - if [ -z "$abort" ] || [ "$abort" = "0" ]; then - echo "Building repo" - mkdir -p /release/repo/conf /release/repo/db /release/repo/dists /release/repo/pool - if [ "${FLAVOR}" = "alpha" -o "${FLAVOR}" = "stable" ]; then - component="" - else - component=" ${FLAVOR}" - fi - GPG_HOME="" - if [ -d /sign_keys/${OS}/.gnupg ]; then - GPG_HOME="/sign_keys/${OS}" - elif [ -d /sign_keys/.gnupg ]; then - GPG_HOME="/sign_keys" - fi - if [ ! -z "$GPG_HOME" ]; then - SIGN_WITH="SignWith: MDSplus" - rsync -a ${GPG_HOME}/.gnupg /tmp - fi - cat - </release/repo/conf/distributions -Origin: MDSplus Development Team -Label: MDSplus -Codename: MDSplus -Architectures: ${ARCHES} -Components: alpha stable${component} -Description: MDSplus packages -${SIGN_WITH} - -Origin: MDSplus Development Team -Label: MDSplus-previous -Codename: MDSplus-previous -Architectures: ${ARCHES} -Components: alpha stable${component} -Description: Previous MDSplus release packages -${SIGN_WITH} -EOF - pushd /release/repo - reprepro clearvanished - for deb in $(find /release/${FLAVOR}/DEBS/${ARCH} -name "*${RELEASE_VERSION}_*\.deb"); do - if [ -z "$abort" ] || [ "$abort" = "0" ]; then - : && HOME=/tmp reprepro -V -C ${FLAVOR} includedeb MDSplus $deb - checkstatus abort "Failure: Problem installing $deb into repository." $? - else - break - fi - done - popd - - pushd ${MDSPLUS_DIR} - tar -czf $PACKAGESDIR/mdsplus_${FLAVOR}_${RELEASE_VERSION}_${OS}_${ARCH}.tgz * - popd - - pushd ${RELEASEDEBS} - tar -czf $PACKAGESDIR/mdsplus_${FLAVOR}_${RELEASE_VERSION}_${OS}_${ARCH}_debs.tgz *.deb - popd - fi #abort - fi #nomake -} - -publish() { - ### DO NOT CLEAN /publish as it may contain valid older release packages - mkdir -p /publish/${FLAVOR}/DEBS - rsync -a /release/${FLAVOR}/DEBS/${ARCH} /publish/${FLAVOR}/DEBS/ - LAST_RELEASE_INFO=/publish/${FLAVOR}_${OS} - if [ ! -r /publish/repo ]; then - : && rsync -a /release/repo /publish/ - checkstatus abort "Failure: Problem copying repo into publish area." $? - else - pushd /publish/repo - rsync -a /release/repo/conf/distributions /publish/repo/conf/ - reprepro clearvanished - : && env HOME=/sign_keys reprepro -V --keepunused -C ${FLAVOR} includedeb MDSplus ../${FLAVOR}/DEBS/${ARCH}/*${RELEASE_VERSION}_*.deb || - env HOME=/sign_keys reprepro export MDSplus - checkstatus abort "Failure: Problem installing ${FLAVOR} into debian repository." $? - if [ -f ${LAST_RELEASE_INFO} ]; then - PREVIOUS_VERSION="$(cat ${LAST_RELEASE_INFO})" - else - PREVIOUS_VERSION= - fi - echo "PREVIOUS_VERSION=${PREVIOUS_VERSION}" - if [ -n $PREVIOUS_VERSION ]; then - : && env HOME=/sign_keys reprepro -V --keepunused -C ${FLAVOR} includedeb MDSplus-previous ../${FLAVOR}/DEBS/${ARCH}/*${PREVIOUS_VERSION}_*.deb || - env HOME=/sign_keys reprepro export MDSplus-previous - checkstatus abort "Failure: Problem installing previous ${FLAVOR} into debian repository." $? - fi - popd - fi -} diff --git a/deploy/platform/macosx/macosx_build.sh b/deploy/platform/macosx/macosx_build.sh deleted file mode 100755 index 740fb96927..0000000000 --- a/deploy/platform/macosx/macosx_build.sh +++ /dev/null @@ -1,139 +0,0 @@ -#!/bin/bash -# -# platform/macosx/macosx_build.sh -# -# Invoked by mdsplus/deploy/platform/platform_build.sh for windows platform. -# -# -RED() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[31m" - fi -} -GREEN() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[32m" - fi -} -NORMAL() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[0m" - fi -} -set -e - -if [ -r ${SRCDIR}/deploy/os/${OS}.env ] -then - source ${SRCDIR}/deploy/os/${OS}.env -fi - -MAKE=${MAKE:="make"} -if [ -z "$JARS_DIR" ] -then - JAVA_OPTS="--with-java_target=6 --with-java_bootclasspath=${SRCDIR}/rt.jar" -else - JAVA_OPTS="--with-jars=${JARS_DIR}" -fi - -export PYTHONDONTWRITEBYTECODE=no -if [ "$TEST" = "yes" ] -then - rm -Rf ${WORKSPACE}/test - mkdir -p ${WORKSPACE}/test - MDSPLUS_DIR=${WORKSPACE}/test/buildroot/usr/local/mdsplus - mkdir -p ${MDSPLUS_DIR} - pushd ${WORKSPACE}/test/ - ${SRCDIR}/configure \ - --prefix=${MDSPLUS_DIR} \ - --exec_prefix=${MDSPLUS_DIR} \ - ${JAVA_OPTS} \ - --enable-debug - $MAKE - $MAKE install - if ( ! $MAKE -k tests 2>&1 ) - then - RED - cat <&2 -====================================================== - -Failure doing normal tests. - -====================================================== -EOF - NORMAL - exit 1 - fi - popd -fi - -if [ "$RELEASE" = "yes" ] -then - mkdir -p ${RELEASEDIR}/${BRANCH} - rm -Rf ${RELEASEDIR}/${BRANCH}/* - ### - ### Clean up workspace - ### - rm -Rf ${WORKSPACE}/releasebld - ### - ### Build release version of MDSplus and then construct installer rpms - ### - MDSPLUS_DIR=${WORKSPACE}/releasebld/buildroot/usr/local/mdsplus - mkdir -p ${MDSPLUS_DIR} - cp ${SRCDIR}/deploy/platform/macosx/MDSplus.pkgproj ${WORKSPACE}/releasebld/ - cp ${SRCDIR}/deploy/platform/macosx/postInstall.sh ${WORKSPACE}/releasebld/ - pushd ${WORKSPACE}/releasebld/ - ${SRCDIR}/configure \ - --prefix=${MDSPLUS_DIR} \ - --exec_prefix=${MDSPLUS_DIR} \ - ${JAVA_OPTS} ${CONFIGURE_EXTRA} - $MAKE - $MAKE install - popd - if [ "$BRANCH" == "stable" ] - then - BNAME="" - else - BNAME="-${BRANCH}" - fi - IFS='.' read -ra VERS <<< "${RELEASE_VERSION}" - /usr/local/bin/packagesbuild -v -F ${SRCDIR} ${WORKSPACE}/releasebld/MDSplus.pkgproj - if [ "$?" == "0" ] - then - mv ${WORKSPACE}/releasebld/buildroot/MDSplus.pkg ${RELEASEDIR}/${BRANCH}/MDSplus${BNAME}-${VERS[0]}-${VERS[1]}-${VERS[2]}-osx.pkg - fi -# /Developer/usr/bin/packagemaker \ -# --title "MDSplus%(pkgflavor)s" \ -# --version "%(major)d.%(minor)d.%(release)d" \ -# --scripts ${SRCDIR}/macosx/scripts \ -# --install-to "/" \ -# --target "10.5" \ -# -r ${WORKSPACE}/releasebld/buildroot -v -i "MDSplus${BNAME}" \ -# -o ${RELEASEDIR}/${BRANCH}/MDSplus${BNAME}-${VERS[0]}-${VERS[1]}-${VERS[2]}-osx.pkg - if [ "$?" != "0" ] - then - RED - cat <&2 -====================================================== - -Failure: Error building installer - -====================================================== -EOF - NORMAL - exit 1 - fi -fi - -if [ "$PUBLISH" = "yes" ] -then - set -e - mkdir -p ${PUBLISHDIR}/${BRANCH} - if [ "$BRANCH" == "stable" ] - then - BNAME="" - else - BNAME="-${BRANCH}" - fi - IFS='.' read -ra VERS <<< "${RELEASE_VERSION}" - rsync -a ${RELEASEDIR}/${BRANCH}/MDSplus${BNAME}-${VERS[0]}-${VERS[1]}-${VERS[2]}-osx.pkg ${PUBLISHDIR}/${BRANCH}/ -fi diff --git a/deploy/platform/platform_build.sh b/deploy/platform/platform_build.sh deleted file mode 100755 index db332e1ec9..0000000000 --- a/deploy/platform/platform_build.sh +++ /dev/null @@ -1,214 +0,0 @@ -#!/bin/bash -# -# platform/platform_build.sh -# -# Invoked by mdsplus/deploy/build.sh. -# -# Run docker image to build mdsplus -# -set -e -volume() { - if [ -n "$1" ]; then - echo "-v $(realpath ${1}):${2}" - fi -} -RED() { - if [ "$COLOR" = "yes" ]; then - echo -e "\033[31m" - fi -} -GREEN() { - if [ "$COLOR" = "yes" ]; then - echo -e "\033[32m" - fi -} -NORMAL() { - if [ "$COLOR" = "yes" ]; then - echo -e "\033[0m" - fi -} -spacedelim() { - if [ -n "$1" ]; then - if [ "$1" = "skip" ]; then - ans="" - else - IFS=',' read -ra ARR <<<"$1" - ans="${ARR[*]}" - fi - fi - echo $ans -} -rundocker() { - images=(${DOCKERIMAGE}) - ARCH="$(spacedelim ${ARCH})" - arches=(${ARCH}) - SANITIZE="$(spacedelim $SANITIZE)" - VALGRIND_TOOLS="$(spacedelim $VALGRIND_TOOLS)" - idx=0 - if [ -z "$INTERACTIVE" ]; then - # stdio="-a stdout -a stderr" - stdio="--detach" - program="${DOCKER_SRCDIR}/deploy/platform/platform_docker_build.sh" - else - stdio="-i" - program="/bin/bash" - fi - while [[ $idx -lt ${#images[*]} ]]; do - image=${images[$idx]} - arch=${arches[$idx]} - echo "Building installers for ${arch} using ${image}" - if [ -n "$INTERACTIVE" ]; then - echo "env: source ${DOCKER_SRCDIR}/deploy/os/${OS}.env" - echo "run: ${DOCKER_SRCDIR}/deploy/platform/platform_docker_build.sh" - echo "or: NOMAKE=1 ${DOCKER_SRCDIR}/deploy/platform/platform_docker_build.sh" - fi - # - # If there are both 32-bit and 64-bit packages for the platform - # only build the deb's after both 32-bit and 64-bit builds are - # complete. Likewise only publish the release once. - # - if [ -z $JARS_DIR ]; then - jars_dir= - else - jars_dir=/jars_dir - fi - if [ -z $FORWARD_PORT ]; then - port_forwarding= - else - port_forwarding="-p ${FORWARD_PORT}:${FORWARD_PORT}" - echo $port_forwarding - fi - - function kill_docker() { - if [ -r ${WORKSPACE}/${OS}_docker-cid ]; then - docker kill $(cat ${WORKSPACE}/${OS}_docker-cid) 2>/dev/null || true - docker rm $(cat ${WORKSPACE}/${OS}_docker-cid) 2>/dev/null || true - rm -f ${WORKSPACE}/${OS}_docker-cid - fi - if [ ! -z $DOCKERNETWORK ]; then - docker network rm ${DOCKERNETWORK} || true - fi - } - - function abort() { - kill_docker - exit 1 - } - - trap abort SIGINT - - status=127 - loop_count=0 - while [ $status = 127 -a $loop_count -lt 5 ]; do - let loop_count=$loop_count+1 - - network="" - if [ ! -z $DOCKERNETWORK ]; then - docker network create ${DOCKERNETWORK} - network="--network=${DOCKERNETWORK}" - fi - - docker run --cap-add=SYS_PTRACE -t $stdio $network \ - --cidfile=${WORKSPACE}/${OS}_docker-cid \ - -u $(id -u):$(id -g) --privileged -h $DISTNAME -e "srcdir=${DOCKER_SRCDIR}" \ - -e "ARCH=${arch}" \ - -e "ARCHES=${ARCH}" \ - -e "BRANCH" \ - -e "BNAME" \ - -e "FLAVOR" \ - -e "COLOR" \ - -e "DISPLAY" \ - -e "DISTNAME" \ - -e "GIT_COMMIT" \ - -e "OS" \ - -e "PLATFORM" \ - -e "PUBLISH" \ - -e "RELEASE" \ - -e "RELEASE_VERSION" \ - -e "SANITIZE" \ - -e "TEST" \ - -e "TESTFORMAT" \ - -e "UPDATEPKG" \ - -e "VALGRIND_TOOLS" \ - -e "MAKE_JARS" \ - -e "CONFIGURE_PARAMS" \ - -e "mdsevent_port=$EVENT_PORT" \ - -e "HOME=/workspace" \ - -e "JARS_DIR=$jars_dir" \ - -e "TEST_TIMEUNIT" \ - -e "CONFIGURE_EXTRA" \ - -v ${SRCDIR}:${DOCKER_SRCDIR} \ - -v ${WORKSPACE}:/workspace $port_forwarding $(volume "${JARS_DIR}" /jars_dir) \ - $(volume "${RELEASEDIR}" /release) \ - $(volume "${PUBLISHDIR}" /publish) \ - $(volume "${KEYS}" /sign_keys) \ - ${image} $program - status=$? - - if [ -z "$INTERACTIVE" ]; then - cid=$(cat ${WORKSPACE}/${OS}_docker-cid) - - # Wait for the container to exit - docker logs --follow $cid - - status=$(docker inspect $cid --format='{{.State.ExitCode}}') - fi - - kill_docker - - done - if [ ! "$status" = "0" ]; then - RED - cat <&2 -====================================================== - -Docker ${PLATFORM}_docker_build.sh returned failure -status when exiting from ${image} - -====================================================== -EOF - NORMAL - exit $status - fi - let idx=idx+1 - done - exit $status -} -default_build() { - if [ "${RELEASE}" = "yes" ]; then - rm -Rf ${RELEASEDIR}/${FLAVOR} - mkdir -p ${RELEASEDIR}/${FLAVOR} - fi - if [ "${PUBLISH}" = "yes" ]; then - mkdir -p ${PUBLISHDIR}/${FLAVOR} - fi -} - -case "$BRANCH" in - stable) - export CONFIGURE_EXTRA= - export FLAVOR="stable" - export BNAME="" - ;; - alpha) - export CONFIGURE_EXTRA=--enable-debug=info - export FLAVOR="alpha" - export BNAME="-alpha" - ;; - *) - export CONFIGURE_EXTRA=--enable-debug=info - export FLAVOR="other" - export BNAME="-other" - ;; -esac - -set +e -platform_build="${SRCDIR}/deploy/platform/${PLATFORM}/${PLATFORM}_build.sh" -if [ -f "${platform_build}" ]; then - echo "running ${platform_build}." - source ${platform_build} "$@" -else - echo "Using default script." - default_build - rundocker -fi diff --git a/deploy/platform/platform_docker_build.sh b/deploy/platform/platform_docker_build.sh deleted file mode 100755 index bf6c9a58ba..0000000000 --- a/deploy/platform/platform_docker_build.sh +++ /dev/null @@ -1,225 +0,0 @@ -#!/bin/bash -# -# platform/platform_docker_build.sh -# -# Invoked by mdsplus/deploy/platform_build.sh. -# -# Build script from within a docker image -# - -srcdir=$(readlink -f $(dirname ${0})/../..) -RED() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[31m" - fi -} -GREEN() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[32m" - fi -} -NORMAL() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[0m" - fi -} -tio(){ - :&& ${srcdir}/deploy/platform/timeout.sh "$@"; - return $?; -} -getenv() { - eval "echo \$$1" -} -testarch(){ - archlist="${archlist} $1" - echo archlist=${archlist} - sanitize $@; - normaltest $@; -} -config() { - if [ -z "$JARS_DIR" ] - then - JAVA_OPTS= - else - JAVA_OPTS="--with-jars=${JARS_DIR}" - fi - :&& ${srcdir}/configure \ - --prefix=${MDSPLUS_DIR} \ - --exec_prefix=${MDSPLUS_DIR} \ - --host=$2 \ - --bindir=${MDSPLUS_DIR}/$3 \ - --libdir=${MDSPLUS_DIR}/$4 \ - ${CONFIGURE_PARAMS} \ - ${JAVA_OPTS} \ - --enable-werror \ - $5 $6 $7 $8 $9; - status=$? -} -config_test(){ - export MDSPLUS_DIR; - export WINEPATH="Z:${MDSPLUS_DIR}/$3" - rm -Rf $(dirname "${MDSPLUS_DIR}"); - mkdir -p ${MDSPLUS_DIR}; - cp -rf ${srcdir}/xml ${MDSPLUS_DIR}/xml; - MDS_PATH=${MDSPLUS_DIR}/tdi; - pushd ${MDSPLUS_DIR}/..; - config $@ --enable-debug; -} -checkstatus(){ -# checkstatus flagname "error message" $? - if [ ! -z "$3" -a "$3" != "0" ] - then - RED - if [ "$1" = "abort" ] - then - ABORT=" Build ABORTED" - fi - cat <&2 -====================================================== - -$2 -$ABORT -====================================================== -EOF - NORMAL - if [ "$1" = "abort" ] - then - exit $3 - else - let $1=$3 - return $3 - fi - fi -} - -checktestarch() { - set +e - ### Check status of all tests. If errors found print error messages and then exit with failure - checkstatus failed "Failure: ${1}-bit make failed." $(getenv "make_${1}") - checkstatus failed "Failure: ${1}-bit install failed." $(getenv "install_${1}") - checkstatus failed "Failure: ${1}-bit test suite failed." $(getenv "tests_${1}") - checkstatus failed "Failure: ${1}-bit valgrind test suite failed." $(getenv "tests_${1}_val") - for test in address thread undefined; do - checkstatus failed "Failure: ${1}-bit santize with ${test} make failed." $(getenv "make_${1}_san_${test}") - checkstatus failed "Failure: ${1}-bit santize with ${test} install failed." $(getenv "install_${1}_san_${test}") - checkstatus failed "Failure: ${1}-bit santize with ${test} tests failed." $(getenv "tests_${1}_san_${test}") - done; -} - -checktests() { - if [ -z "$NOMAKE" ]; then - echo "TEST RESULTS:" - for arch in ${archlist};do - checktestarch $arch - done - checkstatus abort "Failure: One or more tests have failed (see above)." $failed - GREEN - echo "SUCCESS" - NORMAL - fi -} - -sanitize() { - ### Build with sanitizers and run tests with each sanitizer - if [ -n "$SANITIZE" ] - then - for test in ${SANITIZE}; do - echo Doing sanitize ${test} - MDSPLUS_DIR=/workspace/tests/${1}-san-${test}/buildroot; - config_test $@ --enable-sanitize=${test} - if [ "$status" = "111" ]; then - echo "Sanitizer ${test} not supported. Skipping." - elif [ "$status" = "0" ]; then - if [ -z "$NOMAKE" ]; then - $MAKE - checkstatus abort "Failure compiling $1-bit with sanitize-${test}." $? - $MAKE install - checkstatus abort "Failure installing $1-bit with sanitize-${test}." $? - :&& tio 1800 $MAKE -k tests 2>&1 - checkstatus tests_${1}_san_${test} "Failure testing $1-bit with sanitize-${test}." $? - fi - else - echo "configure returned status $?" - let tests_${1}_san_${test}=$status - fi - popd - done - fi -} -make_jars() { - rm -Rf /workspace/jars - mkdir -p /workspace/jars - pushd /workspace/jars - ${srcdir}/configure --enable-java_only - if [ -z "$NOMAKE" ]; then - $MAKE - fi - popd -} - -normaltest() { - if [ "$TEST" = "yes" -o -n "$VALGRIND_TOOLS" ] - then - gettimeout() { - declare -i n=1800*$# - echo $n - } - ### Build with debug to run regular and valgrind tests - MDSPLUS_DIR=/workspace/tests/$1/buildroot; - config_test $@ - if [ -z "$NOMAKE" ]; then - $MAKE - checkstatus abort "Failure compiling $1-bit." $? - $MAKE install - checkstatus abort "Failure installing $1-bit." $? - if [ "$TEST" = "yes" ] - then - ### Run standard tests - :&& tio 600 $MAKE -k tests 2>&1 - checkstatus tests_$1 "Failure testing $1-bit." $? - fi - if [ -n "$VALGRIND_TOOLS" ] - then - ### Test with valgrind - to=$( gettimeout $VALGRIND_TOOLS ) - :&& tio $to $MAKE -k rebuild-tests VALGRIND_BUILD=yes 2>&1 - checkstatus tests_${1}_val "Failure building tests $1-bit with valgrind." $? - :&& tio $to $MAKE -k tests-valgrind 2>&1 - checkstatus tests_${1}_val "Failure testing $1-bit with valgrind." $? - fi - fi - popd - fi -} - -main(){ - MAKE=${MAKE:="make"} - if [ -r ${srcdir}/deploy/os/${OS}.env ] - then - source ${srcdir}/deploy/os/${OS}.env - fi - set +e - runtests - if [ "$MAKE_JARS" = "yes" ] - then - set +e - make_jars - fi - if [ "$RELEASE" = "yes" ] - then - set +e - buildrelease - fi - if [ -z "$NOMAKE" ] && [ "$PUBLISH" = "yes" ] - then - set +e - publish - fi -} - -source ${srcdir}/deploy/platform/${PLATFORM}/${PLATFORM}_docker_build.sh -if [ ! -z "$0" ] && [ ${0:0:1} != "-" ] && [ "$( basename $0 )" = "platform_docker_build.sh" ] -then - env - main -fi diff --git a/deploy/platform/redhat/redhat_docker_build.sh b/deploy/platform/redhat/redhat_docker_build.sh deleted file mode 100755 index e939d3a480..0000000000 --- a/deploy/platform/redhat/redhat_docker_build.sh +++ /dev/null @@ -1,161 +0,0 @@ -#!/bin/bash -# -# redhat_docker_build.sh is used to build, test, package and add rpms's to a -# repository for redhat based systems. -# -# release: -# /release/$branch/{BUILD,RPMS,SOURCES,SPECS,SRPMS} -# /release/$branch/RPMS/$arch/*.rpm -# -# publish: -# /publish/$branch/{BUILD,RPMS,SOURCES,SPECS,SRPMS} -# /publish/$branch/RPMS/$arch/*.rpm -# /publish/$branch/cache/$arch/*.rpm-* -# - -do_createrepo() { - repodir=$1 - tmpdir=$(mktemp -d) - trap 'rm -Rf ${tmpdir}' EXIT - if [ -d ${repodir}/${FLAVOR}/RPMS/repodata ]; then - rsync -a ${repodir}/${FLAVOR}/RPMS/repodata ${tmpdir} - update_args="--update --cachedir ${repodir}/${FLAVOR}/cache ${use_deltas}" - fi - : && createrepo -q $update_args -o ${tmpdir} ${repodir}/${FLAVOR}/RPMS - checkstatus abort "Failure: Problem creating rpm repository in ${repodir}!" $? - rm -f ${tmpdir}/repodata/repomd.xml.asc - if [ -d /sign_keys/.gnupg ]; then - GNUPGHOME=/sign_keys/.gnupg gpg --local-user MDSplus --detach-sign --armor ${tmpdir}/repodata/repomd.xml - fi - : && rsync -a ${tmpdir}/repodata ${repodir}/${FLAVOR}/RPMS/ -} - -srcdir=$(readlink -e $(dirname ${0})/../..) - -test64="64 x86_64-linux bin64 lib64 --with-gsi=/usr:gcc64" -test32="32 i686-linux bin32 lib32 --with-gsi=/usr:gcc32 --with-valgrind-lib=/usr/lib32/valgrind" - -runtests() { - # run tests with the platform specific params read from test32 and test64 - testarch ${test64} - if [ "${ARCHES}" != "amd64" ]; then - if [ -f /usr/bin/python-i686 ]; then - PYTHON=/usr/bin/python-i686 testarch ${test32} - else - testarch ${test32} - fi - fi - checktests -} -makelist() { - rpm2cpio $1 | - cpio --list --quiet | - grep -v MDSplus/dist | - grep -v MDSplus/doc | - grep -v MDSplus/build | - grep -v egg-info | - grep -v '\.build\-id' | - sort -} -buildrelease() { - set -e - RELEASEBLD=/workspace/releasebld - BUILDROOT=${RELEASEBLD}/buildroot - PACKAGESDIR=/workspace/packages - MDSPLUS_DIR=${BUILDROOT}/usr/local/mdsplus - rm -Rf ${RELEASEBLD} /release/${FLAVOR} ${PACKAGESDIR} - mkdir -p ${RELEASEBLD}/64 ${BUILDROOT} ${MDSPLUS_DIR} ${PACKAGESDIR} - pushd ${RELEASEBLD}/64 - config ${test64} ${CONFIGURE_EXTRA} - if [ -z "$NOMAKE" ]; then - $MAKE - $MAKE install - fi - popd - if [ "${ARCHES}" != "amd64" ]; then - mkdir -p ${RELEASEBLD}/32 - pushd ${RELEASEBLD}/32 - config ${test32} ${CONFIGURE_EXTRA} - if [ -z "$NOMAKE" ]; then - $MAKE - $MAKE install - fi - popd - fi - if [ -z "$NOMAKE" ]; then - echo "Building rpms" - ### - ### Setup repository rpm info - ### - mkdir -p ${BUILDROOT}/etc/yum.repos.d - mkdir -p ${BUILDROOT}/etc/pki/rpm-gpg/ - if [ -d /sign_keys/.gnupg ]; then - GPGCHECK="1" - else - echo "WARNING: Signing Keys Unavailable. Building unsigned RPMS" - GPGCHECK="0" - fi - if [ -r /sign_keys/RPM-GPG-KEY-MDSplus ]; then - cp /sign_keys/RPM-GPG-KEY-MDSplus ${BUILDROOT}/etc/pki/rpm-gpg/ - fi - cat - >${BUILDROOT}/etc/yum.repos.d/mdsplus${BNAME}.repo </dev/null) || (echo ${pkg} | grep repo >/dev/null); then - continue - fi - pkg=${pkg}.$(echo $(basename $rpm) | cut -f5 -d- | cut -f3 -d.) - checkfile=${srcdir}/deploy/packaging/${PLATFORM}/$pkg - if [ "$UPDATEPKG" = "yes" ]; then - mkdir -p ${srcdir}/deploy/packaging/${PLATFORM}/ - makelist $rpm >${checkfile} - else - echo "Checking contents of $(basename $rpm)" - if (diff <(makelist $rpm) <(sort ${checkfile})); then - echo "Contents of $(basename $rpm) is correct." - else - checkstatus badrpm "Failure: Problem with contents of $(basename $rpm)" 1 - fi - fi - done - checkstatus abort "Failure: Problem with contents of one or more rpms. (see above)" $badrpm - - pushd ${MDSPLUS_DIR} - tar -czf $PACKAGESDIR/mdsplus_${FLAVOR}_${RELEASE_VERSION}_${OS}_${ARCH}.tgz * - popd - - pushd /release/${FLAVOR}/RPMS - tar -czf $PACKAGESDIR/mdsplus_${FLAVOR}_${RELEASE_VERSION}_${OS}_${ARCH}_rpms.tgz */*.rpm - popd - fi #nomake -} - -publish() { - ### DO NOT CLEAN /publish as it may contain valid older release rpms - mkdir -p /publish/${FLAVOR} - : && rsync -a --exclude=repodata /release/${FLAVOR}/* /publish/${FLAVOR} - checkstatus abort "Failure: Problem copying release rpms to publish area!" $? - if (createrepo -h | grep '\-\-deltas' >/dev/null); then - use_deltas="--deltas" - fi - do_createrepo /publish - checkstatus abort "Failure: Problem updating rpm repository in publish area!" $? -} diff --git a/deploy/platform/timeout.sh b/deploy/platform/timeout.sh deleted file mode 100755 index 2acca4605b..0000000000 --- a/deploy/platform/timeout.sh +++ /dev/null @@ -1,35 +0,0 @@ -#!/bin/bash -( - waitandkill() { - # waitandkill seconds pid SIGNAL exitcode - # send signal to pid after seconds - # or exits with exitcode - sleep ${1}s - if ( -z kill -s 0 $2 ) - then - echo WARNING: Sending $3 after $1 - kill -s $3 $2 - else - exit $4 - fi - } - # kill wiith sigabrt to trigger core dump - waitandkill $1 $$ SIGABRT 3 - ## try to interrupt main program at first - #waitandkill $1 $$ SIGINT 0 - ## try to gracefully terminate main program if sigint did not help - #waitandkill 10 $$ SIGTERM 1 - ## kill main program if sigterm did not help - #waitandkill 5 $$ SIGKILL 2 -) 2> /dev/null & -# store pid of watchdog fork -watchdog=$! -# strip timeout.sh from args -shift -# execute main program in same pid -:&& exec "$@" -# store exitcode -status=$? -# terminate watchdog -kill -s SIGTERM $watchdog -exit $status diff --git a/deploy/platform/windows/windows_docker_build.sh b/deploy/platform/windows/windows_docker_build.sh deleted file mode 100755 index 77a0d3e220..0000000000 --- a/deploy/platform/windows/windows_docker_build.sh +++ /dev/null @@ -1,78 +0,0 @@ -#!/bin/bash -# -# windows_docker_build.sh - build windows installer -# -# release: -# /release/$flavor/MDSplus-*.exe -# -# publish: -# /publish/$flavor/MDSplus-*.exe -# - -srcdir=$(readlink -e $(dirname ${0})/../..) - -export JNI_INCLUDE_DIR=${srcdir}/3rd-party-apis/windows-jdk -export JNI_MD_INCLUDE_DIR=${srcdir}/3rd-party-apis/windows-jdk/win32 -mkdir -p /workspace/winebottle64 -test64="64 x86_64-w64-mingw32 bin_x86_64 bin_x86_64 --with-winebottle=/workspace/winebottle64" -mkdir -p /workspace/winebottle32 -test32="32 i686-w64-mingw32 bin_x86 bin_x86 --with-winebottle=/workspace/winebottle32" - -runtests() { - # run tests with the platform specific params read from test32 and test64 - testarch ${test64} - testarch ${test32}; - checktests; -} - -buildrelease() { - abort=0 - ### Clean up workspace - rm -Rf /workspace/releasebld - ### Build release version of MDSplus and then construct installer rpms - set -e - MDSPLUS_DIR=/workspace/releasebld/buildroot - mkdir -p ${MDSPLUS_DIR}; - mkdir -p /workspace/releasebld/64; - pushd /workspace/releasebld/64; - config ${test64} ${CONFIGURE_EXTRA} - if [ -z "$NOMAKE" ]; then - $MAKE - $MAKE install - fi - popd; - mkdir -p /workspace/releasebld/32; - pushd /workspace/releasebld/32; - config ${test32} ${CONFIGURE_EXTRA} - if [ -z "$NOMAKE" ]; then - $MAKE - $MAKE install - fi - popd - if [ -z "$NOMAKE" ]; then - pushd /workspace/releasebld/32/mdsobjects/cpp - $MAKE generate-libs-from-dlls - popd - pushd /workspace/releasebld/64/mdsobjects/cpp - $MAKE generate-libs-from-dlls - HOME=/workspace/winebottle64 WINEARCH=win64\ - wine cmd /C ${srcdir}/deploy/platform/windows/visual-studio-build.bat - cp /workspace/releasebld/64/bin_x86_64/MdsObjectsCppShr-VS.dll ${MDSPLUS_DIR}/bin_x86_64/ - cp /workspace/releasebld/64/bin_x86_64/*.lib ${MDSPLUS_DIR}/bin_x86_64/ - cp /workspace/releasebld/32/bin_x86/*.lib ${MDSPLUS_DIR}/bin_x86/ - cp -r ${srcdir}/icons ${MDSPLUS_DIR}/ - popd - fi - ### - ### pack installer - ### - if [ -z "$NOMAKE" ]; then - source ${srcdir}/deploy/packaging/windows/create_installer.sh - fi # NOMAKE -} -publish() { - major=$(echo ${RELEASE_VERSION} | cut -d. -f1) - minor=$(echo ${RELEASE_VERSION} | cut -d. -f2) - release=$(echo ${RELEASE_VERSION} | cut -d. -f3) - rsync -a /release/${FLAVOR}/MDSplus${BNAME}-${major}.${minor}-${release}.exe /publish/${FLAVOR} -} diff --git a/deploy/promote.sh b/deploy/promote.sh deleted file mode 100755 index 445346db16..0000000000 --- a/deploy/promote.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash -BRANCH=$1 -PROMOTED_RELEASE_TAG=$2 -if [[ "${PROMOTED_RELEASE_TAG}" =~ ^alpha_release-[0-9]+-[0-9]+-[0-9]+$ ]] -then - set +x - git reset --hard - git merge ${PROMOTED_RELEASE_TAG} --strategy ours -m"Build: promoted ${PROMOTED_RELEASE_TAG}" --log - git rm -rfq --cached . - git checkout ${PROMOTED_RELEASE_TAG} . - git commit --amend --no-edit - git clean -fxdq - if ! git diff --name-only --exit-code ${BRANCH} ${PROMOTED_RELEASE_TAG} - then exit 1 - fi - TAG=${PROMOTED_RELEASE_TAG/alpha_/${BRANCH}_} - git push --set-upstream origin ${BRANCH} -else - echo "Can only promote to alpha_release-* tags" - echo "Got \"$PROMOTED_RELEASE_TAG\" instead" - exit 1 -fi diff --git a/conf/sanitizer.supp/address.supp b/deploy/sanitizer.supp/address.supp similarity index 100% rename from conf/sanitizer.supp/address.supp rename to deploy/sanitizer.supp/address.supp diff --git a/conf/sanitizer.supp/leak.supp b/deploy/sanitizer.supp/leak.supp similarity index 100% rename from conf/sanitizer.supp/leak.supp rename to deploy/sanitizer.supp/leak.supp diff --git a/conf/sanitizer.supp/thread.supp b/deploy/sanitizer.supp/thread.supp similarity index 100% rename from conf/sanitizer.supp/thread.supp rename to deploy/sanitizer.supp/thread.supp diff --git a/conf/sanitizer.supp/undefined.supp b/deploy/sanitizer.supp/undefined.supp similarity index 100% rename from conf/sanitizer.supp/undefined.supp rename to deploy/sanitizer.supp/undefined.supp diff --git a/deploy/tap-to-junit.py b/deploy/tap-to-junit.py deleted file mode 100755 index 4e114893c8..0000000000 --- a/deploy/tap-to-junit.py +++ /dev/null @@ -1,81 +0,0 @@ -#!/usr/bin/env python3 - -import argparse -import os -import sys - -from pathlib import Path - -import xml.etree.ElementTree as xml - -parser = argparse.ArgumentParser() - -parser.add_argument( - '--junit-suite-name', - metavar='', - help='', -) - -args = parser.parse_args() - -# Using pathlib.Path.glob instead of glob.glob because it doesn't follow symlinks -# and the windows build directory has recursive symlinks -tap_filename_list = Path('.').glob('**/*.trs') - -all_tests = {} -failed_test_count = 0 - -for tap_filename in tap_filename_list: - - name = os.path.relpath(os.path.splitext(tap_filename)[0], os.getcwd()) - - log_filename = os.path.splitext(tap_filename)[0] + '.log' - if not os.path.exists(log_filename): - print(log_filename, 'not found') - log_filename = None - - result = None - - lines = open(tap_filename, 'rt').readlines() - for line in lines: - line = line.strip() - if line.startswith(':test-result: '): - result = line.removeprefix(':test-result: ') - - if result == 'FAIL': - failed_test_count += 1 - - all_tests[name] = { - 'log': log_filename, - 'result': result, - } - -root = xml.Element('testsuites') -root.attrib['tests'] = str(len(all_tests)) -root.attrib['failures'] = str(failed_test_count) - -testsuite = xml.SubElement(root, 'testsuite') - -# TODO: Improve -testsuite.attrib['name'] = 'mdsplus' -if args.junit_suite_name is not None: - testsuite.attrib['name'] = args.junit_suite_name - -for test_name, test in all_tests.items(): - testcase = xml.SubElement(testsuite, 'testcase') - testcase.attrib['name'] = test_name - - system_out = xml.SubElement(testcase, 'system-out') - system_out.text = open(test['log']).read() - - if test['result'] == 'FAIL': - failure = xml.SubElement(testcase, 'failure') - failure.attrib['message'] = 'Failed' - - if test['result'] == 'SKIP': - failure = xml.SubElement(testcase, 'skipped') - failure.attrib['message'] = 'Skipped' - -print(f'Writing JUnit output to mdsplus-junit.xml') -with open('mdsplus-junit.xml', 'wb') as f: - f.write(xml.tostring(root)) \ No newline at end of file diff --git a/deploy/trigger.sh b/deploy/trigger.sh deleted file mode 100755 index ad79dc7720..0000000000 --- a/deploy/trigger.sh +++ /dev/null @@ -1,569 +0,0 @@ -#!/bin/bash -# -# mdsplus-deploy/trigger.sh -# -# Configure a build for generating new releases in jenkins. -# This sets build options to be imported into jenkins build jobs -# for the various operating systems supported. -# -RED() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[31m" - fi -} -GREEN() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[32m" - fi -} -NORMAL() { - if [ "$COLOR" = "yes" ] - then echo -e "\033[0m" - fi -} -printhelp() { - cat <&1 echo "Unknown option(s) specified: ${unknownopts}" - exit 1 - fi -} - - -cmdopts="$@" - -# -# Parse the options provided in the command -# -parsecmd "$cmdopts" - -if [ "$RELEASE" = "yes" -a "$PUBLISH" = "yes" ] -then - RED - cat <&2 -=============================================== - -Do not use both --release and --publish in the -same trigger. Use --release to trigger creation -of new releases first and if successful follow -with a separate --publish to install the new -release in public release area. -FAILURE - -=============================================== -EOF - NORMAL - exit 1 -fi - -BRANCH=${GIT_BRANCH##*/} -if [ -z "${BRANCH}" ] -then - BRANCH=$(git describe --tags | cut -d- -f1 | cut -d_ -f1) -fi -opts="$opts --branch=$BRANCH" - -if [ "$BUILD_CAUSE" = "GHPRBCAUSE" ] -then - if [ $(${SRCDIR}/deploy/commit_type_check.sh origin/$ghprbTargetBranch ${SRCDIR}/deploy/inv_commit_title.msg) = "BADCOMMIT" ] - then - RED - cat <&2 -========================================================= - -WARNING: Pull request contains an invalid commit title. - -========================================================= -EOF - NORMAL -# exit 1 - fi -fi - -if [ ! -z "${PROMOTED}" ] -then - PROMOTED_RELEASE_TAG=$(git describe --tags --abbrev=0 --match ${PROMOTED}_release* origin/${PROMOTED}) - if ( ${SRCDIR}/deploy/promote.sh ${BRANCH} ${PROMOTED_RELEASE_TAG} ) - then - MAJOR=$(echo $PROMOTED_RELEASE_TAG | cut -f2 -d-) - MINOR=$(echo $PROMOTED_RELEASE_TAG | cut -f3 -d-) - RELEASEV=$(echo $PROMOTED_RELEASE_TAG | cut -f4 -d-) - else - RED - cat <&2 -========================================================= - -ERROR: Problem promoting ${PROMOTED} to ${BRANCH} - -========================================================= -EOF - NORMAL - exit 1 - fi -fi - -# -# Make sure submodules have been updated -# -if [ ! -r ${SRCDIR}/3rd-party-apis/.git ] -then - ${SRCDIR}/conf/update_submodules -fi - -if [ "$RELEASE" = "yes" ] -then - NEW_RELEASE=no - if [ -z ${RELEASE_TAG} ] - then - RELEASE_TAG=$(git describe --tags | cut -d- -f1,2,3,4); - fi - if [ -z ${RELEASE_TAG} ] - then - RELEASE_TAG="${BRANCH}_release-1-0-0" - fi - if [ -z "${PROMOTED}" ] - then - MAJOR=$(echo $RELEASE_TAG | cut -f2 -d-); - MINOR=$(echo $RELEASE_TAG | cut -f3 -d-); - RELEASEV=$(echo $RELEASE_TAG | cut -f4 -d-); - fi - GIT_COMMIT=$(git rev-list -n 1 HEAD) - LAST_RELEASE_COMMIT=$(git rev-list -n 1 $RELEASE_TAG) - if [ "${LAST_RELEASE_COMMIT}" != "${GIT_COMMIT}" ] - then - if [ -z "${PROMOTED}" ] - then # ${SRCDIR}/deploy/inv_commit_title.msg - version_inc=$(${SRCDIR}/deploy/commit_type_check.sh "${LAST_RELEASE_COMMIT}") - else - version_inc=PROMOTE - fi - case "$version_inc" in - PROMOTE) - NEW_RELEASE=yes - ;; - BADCOMMIT) - RED - cat <&2 -========================================================= - -WARNING: Commit contains an invalid commit title. - -========================================================= -EOF - NORMAL - #exit 1 - NEW_RELEASE=yes - let RELEASEV=$RELEASEV+1 - ;; - SAME) - GREEN - cat <&2 -========================================================= - -INFO: All commits are of category Build, Docs or Tests. - No new release generated. - -========================================================= - -EOF - NORMAL - NEW_RELEASE=no - ;; - MINOR) - GREEN - cat <&2 -========================================================= - -INFO: New features added. New release will be a minor - version increase. - -========================================================= - -EOF - NORMAL - NEW_RELEASE=yes - let MINOR=$MINOR+1 - let RELEASEV=0 - ;; - PATCH) - GREEN - cat <&2 -========================================================= - -INFO: No new features added. Fix commits added so - new release will be generated with patch version - incremented. - -========================================================= - -EOF - NORMAL - NEW_RELEASE=yes - let RELEASEV=$RELEASEV+1 - ;; - *) - GREEN $RED - cat <&2 -========================================================= - -INFO: Unknown release check return of $version_inc - A patch releases will be created. - -========================================================= - -EOF - NORMAL - NEW_RELEASE=yes - let RELEASEV=$RELEASEV+1 - ;; - esac - fi - RELEASE_TAG=${BRANCH}_release-${MAJOR}-${MINOR}-${RELEASEV}; - if [ "$NEW_RELEASE" = "yes" ] - then - git tag -f last_release ${LAST_RELEASE_COMMIT} - git tag -f ${RELEASE_TAG} - fi - GREEN - cat <&2 -======================================== - -Error running bootstrap. Trigger failed. - -======================================== -EOF - NORMAL - exit 1 - fi -fi - - -if [ ! -z "${MAKE_JARS}" ] -then - if ( ! ${SRCDIR}/deploy/build.sh --make-jars --os=${MAKE_JARS} --workspace=${SRCDIR} ${BUILD_OPTS} ) - then - RED - cat <&2 -=============================================== - -Error creating java jar files. Trigger failed. - -=============================================== -EOF - NORMAL - exit 1 - fi -fi - -if [ ! -z "${MAKE_EPYDOCS}" ] -then - if ( ! ${SRCDIR}/python/MDSplus/makedoc.sh ${SRCDIR}/python/MDSplus/doc ${BUILD_OPTS} ) - then - RED - cat <&2 -=============================================== - -Error creating python documentation. Trigger failed. -Look at make_epydocs.log artifact for more info . - -=============================================== -EOF - NORMAL - exit 1 - fi -fi - -if [ "$TAG_RELEASE" = "yes" ] -then - if ( git tag | grep last_release >/dev/null ) - then - RELEASE_TAG=$(git describe --tags | cut -d- -f1,2,3,4) - curl --data @- -H "Authorization: token $(cat $KEYS/.git_token)" "https://api.github.com/repos/MDSplus/mdsplus/releases" > ${WORKSPACE}/tag_release.log 2>&1 < /dev/null ) - then - curl --data @- -H "Authorization: token $(cat $KEYS/.git_token)" "https://api.github.com/repos/MDSplus/mdsplus/releases" > ${WORKSPACE}/tag_release.log 2>&1 < /dev/null ) - then - RED - cat <&2 -========================================================= - -Failed to tag a new release on github. Response/error -content follows. -FAILURE - -========================================================= -EOF - cat ${WORKSPACE}/tag_release.log - NORMAL - exit 1 - fi - fi -fi -echo $opts > ${SRCDIR}/trigger.opts diff --git a/deploy/updatepkg.sh b/deploy/updatepkg.sh deleted file mode 100755 index 04f49a0eda..0000000000 --- a/deploy/updatepkg.sh +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/bash -# -# Update expected packaging files -# -# Run in a separate build directory outside of source directory for best results. -# -# For example: -# -# mkdir ~/build -# cd ~/build -# ~/mdsplus/deploy/updatepkg.sh -# -# This will update the expected packaging content files in -# ~/mdsplus/deploy/packaging... If the changes, if any, look good commit -# these changes to your branch before making a pull request. -# -# Note this requires a running docker service on your system and your -# account to be enabled to run docker. -# -# ensure we are in source folder, so build path is found -if [ -z $1 ] -then -logfile=/dev/stdout -logmessage= -else -logfile=$(realpath $1) -logmessage=" Check '$logfile' for details." -fi -cd $(dirname $0)/.. - - -echo "$(date) updating package files for $(pwd)" -# bootstrap makefiles -deploy/build.sh --os=bootstrap > "$logfile" 2>&1 -# build jars on first cycle (build on debian9-64) -jars="" -build_dir="$(pwd)/build/updatepkg" -# debian-amd64 debian-i386 debian-armhf redhat-* -for os in debian9-64 debian7-32 raspberrypi fc25 -do - echo "$(date) Build of $os starting" - mkdir -p ${build_dir}/$os - if ( deploy/build.sh --os=$os --workspace=${build_dir}/$os --test=skip --release ${jars} --updatepkg >> "$logfile" 2>&1 ) - then - echo "$(date) Build of $os completed successfully" - else - stat=$? - echo "$(date) Build of $os failed.${logmessage}" - exit $stat - fi - # use jars from first build in subsequention cycles - jars="--jars-dir=${build_dir}/debian9-64/releasebld/64" -done diff --git a/conf/valgrind.supp/fc32.supp b/deploy/valgrind.supp/fc32.supp similarity index 100% rename from conf/valgrind.supp/fc32.supp rename to deploy/valgrind.supp/fc32.supp diff --git a/conf/valgrind.supp/mdsplus.supp b/deploy/valgrind.supp/mdsplus.supp similarity index 100% rename from conf/valgrind.supp/mdsplus.supp rename to deploy/valgrind.supp/mdsplus.supp diff --git a/docs/Makefile.am b/docs/Makefile.am deleted file mode 100644 index 3f65340734..0000000000 --- a/docs/Makefile.am +++ /dev/null @@ -1,125 +0,0 @@ - -include @top_builddir@/Makefile.inc -include config/doxygen.am - - -# //////////////////////////////////////////////////////////////////////////// # -# DOXYGEN CONFIG # - -DX_CONFIG = "${top_srcdir}/docs/config/doxygen.cfg" -DX_DOCDIR = docs -DX_PACKAGE_NAME = docs -DX_TITLE = MDSplus -DX_BRIEF = "online code documentation" - - -DX_PAGES = \ - index.md \ - mdsplus_components.md \ - lib_treeshr.md \ - lib_mdsshr.md \ - lib_tdishr.md \ - lib_mdsip.md \ - lib_mdsobjects.md \ - use_docs.md \ - data_types.md \ - dt_integer.md \ - dt_float.md \ - dt_string.md \ - dt_action.md \ - dt_call.md \ - dt_dimension.md \ - dt_conglom.md \ - dt_dispatch.md \ - dt_function.md \ - dt_ident.md \ - dt_method.md \ - dt_range.md \ - dt_routine.md \ - dt_signal.md \ - dt_window.md \ - dt_with_error.md \ - dt_with_units.md - - -DX_EXCLUDE_PAGES = - -DX_TAGFILES = mdsip.tag \ - mdsshr.tag \ - mdsobjects/cpp/docs \ - python/MDSplus/docs \ - mdsobjects/java/docs \ - mdslib/docs \ - javascope/docs - - -MOSTLYCLEANFILES = $(DX_CLEANFILES) \ - ${DX_TAGDIR}/taglist.txt \ - ${DESTDIR}${datadir}/doc/@PACKAGE@/index.html - -# //////////////////////////////////////////////////////////////////////////// # -# LOCAL TARGETS # - - -html: doxygen-run -pdf: doxygen-pdf - - - -# //////////////////////////////////////////////////////////////////////////// # -# RECURSIVE SUBDIRECTORIES DOCUMENT GENERATION # - -# Add here all subdirectories that contain a doxygen documentation Makefile -# -DX_SUBDIRS = \ - ../mdsshr/docs/ \ - ../mdstcpip/docs/ \ - ../mdsobjects/cpp/docs/ \ - ../python/MDSplus/docs/ \ - ../mdsobjects/java/docs/ \ - ../mdslib/docs/ \ - ../javascope/docs \ - . - -build_all: - list='$(DX_SUBDIRS)' - for subdir in $$list; do echo "Making $$target in $$subdir"; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) build_tag) \ - done; - for subdir in $$list; do echo "Making $$target in $$subdir"; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) doxygen-doc) \ - done; - - -install_all: - list='$(DX_SUBDIRS)' - for subdir in $$list; do echo "Making $$target in $$subdir"; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) install_tag) \ - done; \ - for subdir in $$list; do echo "Making $$target in $$subdir"; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) doxygen-install) \ - done; - -clean_all: - list='$(DX_SUBDIRS)' - for subdir in $$list; do echo "Making $$target in $$subdir"; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) clean) \ - done; - - -# This is a html main page that resides into the root directory of the web -# server and provides a redirection to the docs directory -# -${DESTDIR}${datadir}/doc/@PACKAGE@/index.html: - touch $@; \ - echo " " > $@; - -main_index: ${DESTDIR}${datadir}/doc/@PACKAGE@/index.html - - -# The default behavior from here is to build all docs for MDSplus -# subdirectories. -# -all: build_all - -install-data-local: install_all main_index diff --git a/docs/config/doxygen.am b/docs/config/doxygen.am deleted file mode 100644 index d27a9bf8c0..0000000000 --- a/docs/config/doxygen.am +++ /dev/null @@ -1,284 +0,0 @@ -# Copyright (C) 2004 Oren Ben-Kiki -# This file is distributed under the same terms as the Automake macro files. - -# Generate automatic documentation using Doxygen. Goals and variables values -# are controlled by the various DX_COND_??? conditionals set by autoconf. -# -# The provided goals are: -# doxygen-doc: Generate all doxygen documentation. -# doxygen-run: Run doxygen, which will generate some of the documentation -# (HTML, CHM, CHI, MAN, RTF, XML) but will not do the post -# processing required for the rest of it (PS, PDF, and some MAN). -# doxygen-man: Rename some doxygen generated man pages. -# doxygen-ps: Generate doxygen PostScript documentation. -# doxygen-pdf: Generate doxygen PDF documentation. -# -# Note that by default these are not integrated into the automake goals. If -# doxygen is used to generate man pages, you can achieve this integration by -# setting man3_MANS to the list of man pages generated and then adding the -# dependency: -# -# $(man3_MANS): doxygen-doc -# -# This will cause make to run doxygen and generate all the documentation. -# -# The following variable is intended for use in Makefile.am: -# -# DX_CLEANFILES = everything to clean. -# -# This is usually added to MOSTLYCLEANFILES. - -## --------------------------------- ## -## Format-independent Doxygen rules. ## -## --------------------------------- ## - -if DX_COND_doc - -## ------------------------------- ## -## Rules specific for HTML output. ## -## ------------------------------- ## - -if DX_COND_html - -DX_CLEAN_HTML = ${DX_DESTDIR}/html - -endif DX_COND_html - -## ------------------------------ ## -## Rules specific for MAN output. ## -## ------------------------------ ## - -if DX_COND_man - -DX_CLEAN_MAN = ${DX_DESTDIR}/man - -endif DX_COND_man - - -## ------------------------------ ## -## Rules specific for PDF output. ## -## ------------------------------ ## - -if DX_COND_pdf - -DX_CLEAN_PDF = ${DX_DESTDIR}/${DX_PACKAGE_NAME}.pdf - -DX_PDF_GOAL = doxygen-pdf - -doxygen-pdf: doxygen-run ${DX_DESTDIR}/${DX_PACKAGE_NAME}.pdf - -${DX_DESTDIR}/${DX_PACKAGE_NAME}.pdf: ${DX_DESTTAG} - cd ${DX_DESTDIR}/latex; \ - rm -f *.aux *.toc *.idx *.ind *.ilg *.log *.out; \ - $(DX_PDFLATEX) refman.tex; \ - $(DX_MAKEINDEX) refman.idx; \ - $(DX_PDFLATEX) refman.tex; \ - countdown=5; \ - while $(DX_EGREP) 'Rerun (LaTeX|to get cross-references right)' \ - refman.log > /dev/null 2>&1 \ - && test $$countdown -gt 0; do \ - $(DX_PDFLATEX) refman.tex; \ - countdown=`expr $$countdown - 1`; \ - done; \ - mv refman.pdf ../${DX_PACKAGE_NAME}.pdf - -endif DX_COND_pdf - -## ------------------------------------------------- ## -## Rules specific for LaTeX (shared for PS and PDF). ## -## ------------------------------------------------- ## - -if DX_COND_latex - -DX_CLEAN_LATEX = ${DX_DESTDIR}/latex - -endif DX_COND_latex - - -## ------------------------------------------ ## -## GENERAL ENV To be passed into config file ## -## ------------------------------------------ ## - - - -DX_INSTALLDIR = $(abs_top_builddir) -DX_DESTDIR = ${DX_INSTALLDIR}/${DX_DOCDIR} -DX_TAGDIR = ${DX_INSTALLDIR}/docs/dtags -DX_DESTTAG = ${DX_TAGDIR}/${DX_PACKAGE_NAME}.tag -DX_SEARCHFILE = ${DX_TAGDIR}/${DX_PACKAGE_NAME}.xml -DX_LAYOUT ?= ${top_srcdir}/docs/config/general_layout.xml -DX_LOGO ?= ${top_srcdir}/docs/config/style/logo.jpg -DX_IMAGE_PATH ?= img -DX_PARENT_TAG = docs.tag - -if HAVE_CUTE_DOXYGEN - DX_HTML_HEADER = ${top_srcdir}/docs/config/style/header.html - DX_HTML_FOOTER = ${top_srcdir}/docs/config/style/footer.html - DX_HTML_STYLESHEET = ${top_srcdir}/docs/config/style/mds_style.css -endif HAVE_CUTE_DOXYGEN - -DX_STYLE_FILES = ${DX_HTML_HEADER} \ - ${DX_HTML_FOOTER} \ - ${DX_HTML_STYLESHEET} - - -DX_ENVCOMMON = \ - srcdir='${srcdir}' \ - top_srcdir='${top_srcdir}' \ - DX_PACKAGE_NAME='${DX_PACKAGE_NAME}' \ - DX_PAGES='${addprefix $(srcdir)/,${DX_PAGES}}' \ - DX_EXCLUDE_PAGES='${addprefix $(srcdir)/,${DX_EXCLUDE_PAGES}}' \ - DX_IMAGE_PATH='${addprefix $(srcdir)/,${DX_IMAGE_PATH}}' \ - DX_INSTALLDIR='${DX_INSTALLDIR}' \ - DX_TITLE='${DX_TITLE}' \ - DX_BRIEF='${DX_BRIEF}' \ - DX_HTML_HEADER='${DX_HTML_HEADER}' \ - DX_HTML_FOOTER='${DX_HTML_FOOTER}' \ - DX_HTML_STYLESHEET='${DX_HTML_STYLESHEET}' \ - DX_LAYOUT='${DX_LAYOUT}' \ - DX_LOGO='${DX_LOGO}' - - -DX_DESTENV = ${DX_ENV} \ - ${DX_ENVCOMMON} \ - DX_DESTDIR='${DX_DESTDIR}' - - - -### TARGETS: ################################################################### - - - - - - -.ONESHELL: -.PHONY: doxygen-run doxygen-doc build_tag install_tag test_nav $(DX_PS_GOAL) $(DX_PDF_GOAL) -.INTERMEDIATE: doxygen-run $(DX_PS_GOAL) $(DX_PDF_GOAL) - -test_nav: - if [ -a ${DX_DESTDIR}/html/nav.html ] ; then rm ${DX_DESTDIR}/html/nav.html; fi - if [ -a ${DX_DESTDIR}/html/nav.xml ] ; then rm ${DX_DESTDIR}/html/nav.xml; fi - - ## - ## Write navigation file - ## - if test '${DX_PARENT_TAG}'; then \ - for i in ${DX_PARENT_TAG}; do \ - ## - ## extract correct html target relative path - ## - line=`grep $${i} ${DX_TAGDIR}/taglist.txt | sed 's|=|=${top_builddir}/|'`; \ - nav_dir=`echo $${line} | sed 's|.*=||'`; \ - cat ${DX_DESTDIR}/$${nav_dir}/nav.html >> ${DX_DESTDIR}/html/nav.html; \ - tags="$${tags} $${line}"; \ - done \ - else \ - echo "No tag list found!"; \ - fi; - - _url=${DX_DOCDIR}/html; \ - echo "" >> ${DX_DESTDIR}/html/nav.html - - echo "" >> ${DX_DESTDIR}/html/nav.xml; \ - echo "" >> ${DX_DESTDIR}/html/nav.xml; \ - echo "${top_builddir}/../" >> ${DX_DESTDIR}/html/nav.xml; \ - cat ${DX_DESTDIR}/html/nav.html >> ${DX_DESTDIR}/html/nav.xml; \ - echo "" >> ${DX_DESTDIR}/html/nav.xml; - - - -${DX_DESTTAG}: ${DX_PAGES} - $(MKDIR_P) ${DX_DESTDIR} - ${MKDIR_P} ${DX_TAGDIR} - - ## - ## Start Doxygen generation - ## - $(DX_DESTENV) \ - GENERATE_HTML="YES" \ - GENERATE_LATEX="NO" \ - DX_DESTTAG="${DX_DESTTAG}" \ - DX_SEARCHFILE="${DX_SEARCHFILE}" \ - DX_TAGFILES= \ - $(DX_DOXYGEN) $(DX_CONFIG) 2>&1 > /dev/null; - - -${DX_TAGDIR}/taglist.txt: ${DX_DESTTAG} - ## - ## generate taglist to keep track of geenerated symbols. - ## - touch $@; \ - if grep -q ${DX_DESTTAG} ${DX_TAGDIR}/taglist.txt; then \ - echo "Name Found list not updated ..."; \ - else \ - echo "Adding tag to list ... "; \ - echo "${DX_DESTTAG}=${DX_DOCDIR}/html" >> ${DX_TAGDIR}/taglist.txt; \ - fi; - -build_tag: ${DX_TAGDIR}/taglist.txt test_nav - -install_tag: DX_INSTALLDIR=${DESTDIR}${datadir}/doc/@PACKAGE@ -install_tag: ${DX_TAGDIR}/taglist.txt test_nav - - - - -${DX_DESTDIR}/doxygen.stamp: ${DX_PAGES} ${DX_TAGDIR}/taglist.txt ${DX_STYLE_FILES} - $(MKDIR_P) ${DX_DESTDIR} - - ## - ## Getting tags from generated taglist - ## - if test '${DX_TAGFILES}'; then \ - for i in ${DX_TAGFILES}; do \ - ## - ## extract correct html target relative path - ## - line=`grep $${i} ${DX_TAGDIR}/taglist.txt | sed 's|=|=${top_builddir}/../|'`; \ - tags="$${tags} $${line}"; \ - done \ - else \ - echo "No tag list found!"; \ - fi; - echo "Adding selected tag entries: $${tags}" - - ## - ## Start Doxygen generation - ## - $(DX_DESTENV) \ - DX_TAGFILES="$${tags}" \ - DX_DESTTAG= \ - DX_SEARCHFILE= \ - $(DX_DOXYGEN) $(DX_CONFIG); - touch $@ - - - - -doxygen-run: build_tag ${DX_DESTDIR}/doxygen.stamp - -doxygen-doc: DX_INSTALLDIR = $(abs_top_builddir) -doxygen-doc: doxygen-run $(DX_PS_GOAL) $(DX_PDF_GOAL) test_nav - -doxygen-install: DX_INSTALLDIR = ${DESTDIR}${datadir}/doc/@PACKAGE@ -doxygen-install: doxygen-run $(DX_PS_GOAL) $(DX_PDF_GOAL) test_nav - - - -DX_CLEANFILES = \ - ${DX_DESTDIR}/doxygen.stamp \ - ${DX_DESTTAG} \ - ${DX_SEARCHFILE} \ - -r \ - $(DX_CLEAN_HTML) \ - $(DX_CLEAN_CHM) \ - $(DX_CLEAN_CHI) \ - $(DX_CLEAN_MAN) \ - $(DX_CLEAN_RTF) \ - $(DX_CLEAN_XML) \ - $(DX_CLEAN_PS) \ - $(DX_CLEAN_PDF) \ - $(DX_CLEAN_LATEX) - -endif DX_COND_doc diff --git a/dwscope/Makefile.am b/dwscope/Makefile.am deleted file mode 100644 index 606a1b8cc7..0000000000 --- a/dwscope/Makefile.am +++ /dev/null @@ -1,41 +0,0 @@ -# Global variables -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(NOWARNFLAGS) - -#AC_PATH_XTRA puts CPPFLAGS in a CFLAGS variable. Adjust here. -AM_CPPFLAGS = $(X_CFLAGS) -D_NO_DXm -if RPATHLINK -AM_LDFLAGS = $(RPATHLINK)=@MAKESHLIBDIR@ -endif -LDADD = -L@MAKESHLIBDIR@ $(X_PRE_LIBS) $(X_LIBS) $(MOTIF_LIBS) $(X_EXTRA_LIBS) - -#MOTIF_LIBS = @MOTIF_LDSHARE@ @LIBXP@ @LIBXEXT@ -MOTIF_LIBS = -lMrm -lXm -lXt -lX11 - -# Static data installed to lib -datadir = $(libdir) -data_DATA = dwscope_setup.ps - -# Scripts that are copied directly -bin_SCRIPTS = ScopePrinters dwscopePrint - -# dw programs -bin_PROGRAMS = dwscope -dwscope_SOURCES = dwscope.c dwscopesubs.c evaluate.c -dwscope_CPPFLAGS = $(AM_CPPFLAGS) -D_LOCAL_ACCESS -dwscope_LDADD = $(LDADD) -lMdsShr -lTdiShr -lTreeShr -lXmdsShr - -bin_PROGRAMS += dwscope_remote -dwscope_remote_SOURCES = $(dwscope_SOURCES) RemoteDummies.c -dwscope_remote_LDADD = $(LDADD) -lMdsIpShr @MAKESHLIBDIR@/libXmdsShr.a -lm - -bin_PROGRAMS += dwpad -dwpad_SOURCES = dwpad.c dwscopesubs.c -dwpad_LDADD = $(LDADD) -lXmdsShr - -# User interface descriptions, installed as generic data but with build rules -uiddir = @uiddir@ -uid_DATA = dwscope.uid dwpad.uid -%.uid: %.uil - @UIL@ -I$(top_srcdir)/include -o $@ $< - -MOSTLYCLEANFILES = $(uid_DATA) diff --git a/envsyms.in b/envsyms.in deleted file mode 100644 index bb9d8f13bc..0000000000 --- a/envsyms.in +++ /dev/null @@ -1,36 +0,0 @@ -# envsyms - Defines MDSplus development environment variables -# used by setup.csh and setup.sh -# Format: -# -# varname value [(>|<)delimiter] -# -# If third parameter is >; then if varname is already defined -# append a semicolon and the value to the end of the definition. -# -MDSPLUS `pwd` -# -# TDI Functions -# -MDS_PATH ${MDSPLUS}/tdi >; -# -# Test trees -# -main_path ${MDSPLUS}/trees >; -subtree_path ${main_path}/subtree >; -# -# UID path -# -XAPPLRESDIR ${MDSPLUS} <: -# -# IDL path -# -IDL_PATH \+${MDSPLUS}/idl <: -# -# MDSIP_CONNECT_TIMEOUT - default timeout for MDSIP connects -# -MDSIP_CONNECT_TIMEOUT 1 -# -# LIBRARY path -# -@LIBPATH@ ${MDSPLUS}/lib <: -@LIBPATH@ /usr/X11R6/lib <: diff --git a/examples/demoadc/Makefile.in b/examples/demoadc/Makefile.in deleted file mode 100644 index 12397aa130..0000000000 --- a/examples/demoadc/Makefile.in +++ /dev/null @@ -1,48 +0,0 @@ -include @top_builddir@/Makefile.inc - -SHELL=/bin/sh -CC=@CC@ -top_srcdir=@top_srcdir@ -RM=$(top_srcdir)/devscripts/rm_if -prefix=@prefix@ -exec_prefix=@exec_prefix@ -LDFLAGS=@LDFLAGS@ -LIBS=@LIBS@ -INSTALL=@top_srcdir@/conf/install-sh -c - -SOURCES = DemoAdc.c -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@libDemoAdcShr@SHARETYPE@ @MAKELIBDIR@libDemoAdcShr.a - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKESHLIBDIR@libDemoAdcShr@SHARETYPE@ - @ $(RM) @MAKELIBDIR@libDemoAdcShr.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: - if [ ! -d @libdir@ ] ; then \ - mkdir @libdir@; \ - chmod 755 @libdir@; \ - fi; - $(INSTALL) -m 755 @MAKESHLIBDIR@libDemoAdcShr@SHARETYPE@ @libdir@ - if test @SHARETYPE@ != .a ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@libDemoAdcShr.a @libdir@; \ - fi; - - -@MAKESHLIBDIR@libDemoAdcShr@SHARETYPE@ : $(OBJECTS) - $(LD) -o $@ @LINKSHARED@ $(OBJECTS) $(LIBS) - -@MAKELIBDIR@libDemoAdcShr.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -@MAKELIBDIR@ : - mkdir @MAKELIBDIR@ - - diff --git a/hdf5/Makefile.in b/hdf5/Makefile.in deleted file mode 100644 index 29fc49a666..0000000000 --- a/hdf5/Makefile.in +++ /dev/null @@ -1,56 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS+=@HDF5_INCS@ -I. -DH5_USE_16_API @TARGET_ARCH@ -LD_FLAGS=$(LDFLAGS) @TARGET_ARCH@ -LIBS=-L@MAKESHLIBDIR@ @LIBS@ -lTdiShr -lTreeShr -lMdsShr @HDF5_LIBS@ -lhdf5 - -SOURCES = \ - hdf5tdi.c \ - hdf5ToMds.c \ - MDSplus2HDF5.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@libhdf5tdi@SHARETYPE@ @MAKELIBDIR@libhdf5tdi.a \ - @MAKEBINDIR@ @MAKEBINDIR@hdf5ToMds @MAKEBINDIR@MDSplus2HDF5 - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKELIBDIR@libhdf5tdi.a - @ $(RM) @MAKESHLIBDIR@libhdf5tdi@SHARETYPE@ - @ $(RM) @MAKEBINDIR@hdf5ToMds - @ $(RM) @MAKEBINDIR@MDSplus2HDF5 - -install: $(libdir) $(bindir) - $(INSTALL) -m 755 @MAKESHLIBDIR@libhdf5tdi@SHARETYPE@ @libdir@ - if (test @SHARETYPE@ != .a) then \ - $(INSTALL) -m 644 @MAKELIBDIR@libhdf5tdi.a @libdir@; \ - fi; - $(INSTALL) -m 755 @MAKEBINDIR@hdf5ToMds @bindir@ - $(INSTALL) -m 755 @MAKEBINDIR@MDSplus2HDF5 @bindir@ - -@MAKESHLIBDIR@libhdf5tdi@SHARETYPE@ : hdf5tdi.o - $(LD) -o $@ @LINKSHARED@ hdf5tdi.o $(LIBS) $(LD_FLAGS) - -@MAKELIBDIR@libhdf5tdi.a: hdf5tdi.o - $(AR) -cr $@ $^ - @RANLIB@ $@ - -hdf5tdi.exports: hdf5tdi.def - sed -e /LIBRARY/\;/\;/d MdsShr.def > $@ - -@MAKEBINDIR@hdf5ToMds: hdf5ToMds.o - $(CC) -o $@ $< $(LIBS) $(CFLAGS) - -@MAKEBINDIR@MDSplus2HDF5 : MDSplus2HDF5.o - $(CC) -o $@ $< $(LIBS) $(CFLAGS) - diff --git a/idlmdsevent/Makefile.in b/idlmdsevent/Makefile.in deleted file mode 100644 index 6d1de2c6dd..0000000000 --- a/idlmdsevent/Makefile.in +++ /dev/null @@ -1,45 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -MKDIR_P=@MKDIR_P@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS+=@IDL_INC@ @X_CFLAGS@ @TARGET_ARCH@ -LDFLAGS=@LDFLAGS@ @IDL_LIB@ @TARGET_ARCH@ -X_LIBS=@X_LIBS@ -X_EXTRA_LIBS=@X_EXTRA_LIBS@ -X_PRE_LIBS=@X_PRE_LIBS@ - -@MINGW_FALSE@ XLIBS = $(X_LIBS) $(X_PRE_LIBS) -lXt -lX11 $(X_EXTRA_LIBS) - -LIBS=@LIBS@ $(XLIBS) @DNET_STUB@ @LIBSOCKET@ -lMdsIpShr -lMdsShr - -SOURCES = \ -mdsevent.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKELIBDIR@libIdlMdsEvent@SHARETYPEMOD@ @MAKELIBDIR@libIdlMdsEvent.a - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKELIBDIR@libIdlMdsEvent@SHARETYPEMOD@ - @ $(RM) @MAKELIBDIR@libIdlMdsEvent.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 644 @MAKELIBDIR@libIdlMdsEvent.a @libdir@ - $(INSTALL) -m 755 @MAKELIBDIR@libIdlMdsEvent@SHARETYPEMOD@ @libdir@ - -@MAKELIBDIR@libIdlMdsEvent@SHARETYPEMOD@ : $(OBJECTS) - $(LINK.c) -o $@ @LINKMODULE@ $(OBJECTS) -L@MAKELIBDIR@ $(LDFLAGS) $(LIBS) - -@MAKELIBDIR@libIdlMdsEvent.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - diff --git a/idlmdswidgets/Makefile.in b/idlmdswidgets/Makefile.in deleted file mode 100644 index 4488bc2a95..0000000000 --- a/idlmdswidgets/Makefile.in +++ /dev/null @@ -1,47 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS+=@IDL_INC@ @X_CFLAGS@ @TARGET_ARCH@ -LDFLAGS=@LDFLAGS@ @IDL_LIB@ @TARGET_ARCH@ -X_LIBS=@X_LIBS@ -X_EXTRA_LIBS=@X_EXTRA_LIBS@ -X_PRE_LIBS=@X_PRE_LIBS@ -XLIBS = $(X_LIBS) $(X_PRE_LIBS) -lXt -lX11 $(X_EXTRA_LIBS) -MOTIF_LIBS = @MOTIF_LD_LDARC@ @XM_LIBS@ @MOTIF_LD_LDSHARE@ $(XLIBS) @LIBXP@ @LIBXEXT@ -LIBS=@LIBS@ @DNET_STUB@ @LIBSOCKET@ -lMdsIpShr -lMdsShr -lMdsMath -UIL=@UIL@ -I$(top_srcdir)/include - -SOURCES = \ -cw_wveditv5.c \ - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKELIBDIR@libIdlMdsWidgets@SHARETYPEMOD@ @MAKELIBDIR@libIdlMdsWidgets.a @MAKEUIDDIR@cw_wvedit.uid - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKELIBDIR@libIdlMdsWidgets@SHARETYPEMOD@ - @ $(RM) @MAKELIBDIR@libIdlMdsWidgets.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: - $(INSTALL) -m 644 @MAKELIBDIR@libIdlMdsWidgets.a @libdir@ - $(INSTALL) -m 755 @MAKELIBDIR@libIdlMdsWidgets@SHARETYPEMOD@ @libdir@ - $(INSTALL) -m 644 @MAKEUIDDIR@cw_wvedit.uid @uiddir@ - -@MAKELIBDIR@libIdlMdsWidgets@SHARETYPEMOD@ : $(OBJECTS) - $(LINK.c) -o $@ @LINKMODULE@ $(OBJECTS) -L@MAKELIBDIR@ $(LDFLAGS) $(LIBS) $(X_LIBS) $(MOTIF_LIBS) $(LIBS) -lXmdsShr - - -@MAKELIBDIR@libIdlMdsWidgets.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -@MAKEUIDDIR@cw_wvedit.uid : cw_wvedit.uil ; $(UIL) -o $@ $^ diff --git a/java/Makefile.am b/java/Makefile.am deleted file mode 100644 index 479b53c8a1..0000000000 --- a/java/Makefile.am +++ /dev/null @@ -1,49 +0,0 @@ -MVN=mvn -Dmaven.repo.local=/workspace/.m2/repository -DsourceDirectory=$(top_srcdir)/java - -.PHONY: maven-build maven-tests maven-clean java java_tests - -maven-build: - $(MVN) package -DskipTests - -maven-deploy: - pushd $(top_srcdir)/java &&( find . -name pom.xml -exec /bin/sh -c 'mkdir -p $(dirname $1);cp -f $0 $1' '{}' $(abs_builddir)'{}' ';'; popd)&&\ - $(MVN) versions:set -DgenerateBackupPoms=false -DnewVersion=$(RELEASE_VERSION) -DartifactId=* &&\ - $(MVN) -s /sign_keys/.m2/settings.xml -Dsettings.security=/sign_keys/.m2/settings-security.xml -DskipTests deploy - -maven-tests: - $(TESTS_ENVIRONMENT) $(MVN) test - -maven-clean: - $(MVN) clean - -JAVA_DIRS = mdsplus mdsplus-api jtraverser2 jscope mdsobjects jtraverser devicebeans jdevices jdispatcher - -.PHONY: $(all_DIRS) $(clean_DIRS) - -all_DIRS = $(addprefix all_, $(JAVA_DIRS) $(TEST_DIRS) tests) -$(all_DIRS): - @ $(MAKE) $(AM_MAKEFLAGS) -C $(@:all_%=%) all -all: $(all_DIRS) - -clean_DIRS = $(addprefix clean_, $(JAVA_DIRS) $(TEST_DIRS) tests) -$(clean_DIRS): - @ $(MAKE) $(AM_MAKEFLAGS) -C $(@:clean_%=%) clean -clean: $(clean_DIRS) - - -TEST_DIRS = \ - mdsplus-api/tests \ - mdsobjects/tests - -.PHONY: $(tests_DIRS) $(clean_tests_DIRS) - -tests_DIRS = $(addprefix tests_, $(TEST_DIRS)) -$(tests_DIRS): - @ $(MAKE) $(AM_MAKEFLAGS) -C $(@:tests_%=%) tests -tests: $(tests_DIRS) - -clean_tests_DIRS = $(addprefix clean_, $(TEST_DIRS)) -$(clean_tests_DIRS): - @ $(MAKE) $(AM_MAKEFLAGS) -C $(@:clean_%=%) clean -clean_TESTS: $(clean_tests_DIRS) -clean_tests: $(clean_tests_DIRS) diff --git a/java/Makefile.inc.am b/java/Makefile.inc.am deleted file mode 100644 index bfebf00e87..0000000000 --- a/java/Makefile.inc.am +++ /dev/null @@ -1,51 +0,0 @@ -# common makefile for java packages - -JSCH = $(top_srcdir)/java/jsch-0.1.54.jar -$(JSCH): - wget -O $@ http://sourceforge.net/projects/jsch/files/jsch.jar/0.1.54/jsch-0.1.54.jar/download - -MDSPLUS_API_JAR = $(abs_top_builddir)/java/mdsplus-api/mdsplus-api.jar -JTRAVERSER_JAR = $(abs_top_builddir)/java/jtraverser/jTraverser.jar -JTRAVERSER2_JAR = $(abs_top_builddir)/java/jtraverser2/jTraverser2.jar -MDSOBJECTS_JAR = $(abs_top_builddir)/java/mdsobjects/mdsobjects.jar -JSCOPE_JAR = $(abs_top_builddir)/java/jscope/jScope.jar -DEVICEBEANS_JAR = $(abs_top_builddir)/java/devicebeans/DeviceBeans.jar - -n := -s := $(n) # -c := : -CLASSPATH = $(JAVAROOT):$(strip $(subst $(s),$(c),$(strip $(DEPENDENCIES)))) -CLASSPATH_ENV = CLASSPATH=$(CLASSPATH) - -JAVAROOT = $(builddir)/classes -bin_SCRIPTS = $(JAVAROOT) -MANIFEST = $(builddir)/MANIFEST.MF - -javadir = $(exec_prefix)/java/classes -docsdir = $(exec_prefix)/java/classes/docs -CLEANFILES = -r $(bin_SCRIPTS) $(java_DATA) MANIFEST.MF - -JAVA_RES = $(wildcard $(addprefix $(java_resdir)/,$(RESOURCES))) -java_SRC = $(subst $(java_srcdir)/,,$(java_JAVA)) - -if USE_JARS_DIR - -java_JAVA = - -else - -java_JAVA = $(wildcard $(addprefix $(java_srcdir)/,$(SOURCE) debug/DEBUG.java)) - -endif - -$(JAVAROOT): - mkdir -p $@ - -$(MANIFEST): - @ echo "Specification-Version: $(RELEASE_VERSION)" >$@ - @ echo "Implementation-Version: $(RELEASE_VERSION)" >>$@ - @ echo "Implementation-Vendor-Id: org.mdsplus" >>$@ - -$(DEPENDENCIES): - @ echo $(MAKE) $(AM_MAKEFLAGS) -C $(dir $@) - @ $(MAKE) $(AM_MAKEFLAGS) -C $(dir $@) diff --git a/java/Makefile.tests.am b/java/Makefile.tests.am deleted file mode 100644 index 4c2956f800..0000000000 --- a/java/Makefile.tests.am +++ /dev/null @@ -1,39 +0,0 @@ -include @top_builddir@/Makefile.inc -include $(top_srcdir)/testing/testing.am -include $(top_srcdir)/java/Makefile.inc.am - -TAPTEST_JAR = $(top_builddir)/java/tests/taptest.jar -java_DATA = tests.jar - - -JUNIT_JARS = $(wildcard $(top_srcdir)/java/tests/*.jar) -DEPENDENCIES = $(TAPTEST_JAR) $(JUNIT_JARS) - -if USE_JARS_DIR -$(java_DATA): @JARS_DIR@$(subst $(abs_top_srcdir),,$(abs_srcdir))/$(java_DATA) - cp $< $@ -else -$(java_DATA): $(TAPTEST_JAR) $(DEPENDENCIES) $(JAVAROOT) classjava.stamp - @ echo "Creating JAR: $@ ...";\ - $(JAR) cf $@ -C $(JAVAROOT) . -endif - -CLEANFILES += *.tree *.datafile *.characteristics *.log *.tap *.trs *.xml - -TESTS_ENVIRONMENT += $(CLASSPATH_ENV):tests.jar -TESTS_ENVIRONMENT += JUNITTEST=org.junit.runner.TapTestRunner - -VALGRIND_SUPPRESSIONS_FILES = $(top_srcdir)/java/valgrind.supp - -@SKIP_JUNIT_TRUE@LOG_COMPILER = /bin/sh -c "exit 77";: -@SKIP_JUNIT_FALSE@LOG_COMPILER = $(abs_top_srcdir)/java/junittest $(srcdir) - -# override so it will not be installed -install-javaDATA: $(java_DATA) - -@SKIP_JUNIT_TRUE@$(TESTS): -@SKIP_JUNIT_FALSE@$(TESTS): $(MAIN_JARS) $(TAPTEST_JAR) $(java_DATA) - -# needed to set java for 32 (where available) -TESTS_ENVIRONMENT += JAVA_TARGET_ARCH=$(JAVA_TARGET_ARCH) -TESTS_ENVIRONMENT += JAVA_PATH_NAME=$(JAVA_PATH_NAME) diff --git a/java/devicebeans/Makefile.am b/java/devicebeans/Makefile.am deleted file mode 100644 index edd64fbbfe..0000000000 --- a/java/devicebeans/Makefile.am +++ /dev/null @@ -1,24 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am - -java_srcdir = $(srcdir)/src/main/java -java_resdir = $(srcdir)/src/main/resources -java_DATA = DeviceBeans.jar -DEPENDENCIES = $(MDSOBJECTS_JAR) $(JSCOPE_JAR) - -if USE_JARS_DIR - -DeviceBeans.jar: @JARS_DIR@/java/devicebeans/DeviceBeans.jar - cp $< $@ - -else - -DeviceBeans.jar: $(JAVAROOT) $(DEPENDENCIES) classjava.stamp $(srcdir)/DeviceBeansManifest.mf - @ echo "Creating JAR: $@ ...";\ - cp -f $(JAVA_RES) $(JAVAROOT)/ &&\ - $(JAR) cfm $@ $(srcdir)/DeviceBeansManifest.mf -C $(JAVAROOT) . -endif - -SOURCE = *.java\ - mds/devices/*.java -RESOURCES = *.gif diff --git a/java/jdevices/Makefile.am b/java/jdevices/Makefile.am deleted file mode 100644 index 427702d5d5..0000000000 --- a/java/jdevices/Makefile.am +++ /dev/null @@ -1,26 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am - -EXTRA_DIST = *.form - -java_srcdir = $(srcdir)/src/main/java -java_resdir = $(srcdir)/src/main/resources -java_DATA = jDevices.jar -DEPENDENCIES = $(DEVICEBEANS_JAR) - -if USE_JARS_DIR - -$(java_DATA): @JARS_DIR@/java/jdevices/jDevices.jar - cp $< $@ - -else - -$(java_DATA): $(DEPENDENCIES) classjava.stamp - @ echo "Creating JAR: $@ ...";\ - rsync -r $(java_resdir)/ $(JAVAROOT) &&\ - $(JAR) cf $@ -C $(JAVAROOT) . - -endif - -SOURCE = *.java -RESOURCES = *.form diff --git a/java/jdispatcher/Makefile.am b/java/jdispatcher/Makefile.am deleted file mode 100644 index 81348bf837..0000000000 --- a/java/jdispatcher/Makefile.am +++ /dev/null @@ -1,36 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am -java_srcdir = $(srcdir)/src/main/java -dist_java_DATA = src/main/resources/mds/jdispatcher/jDispatcher.properties -java_DATA = jDispatcher.jar -DEPENDENCIES = $(MDSOBJECTS_JAR) - -if USE_JARS_DIR - -$(java_DATA): @JARS_DIR@/java/jdispatcher/jDispatcher.jar - cp $< $@ - -else - -$(java_DATA): $(DEPENDENCIES) $(MANIFEST) classjava.stamp - @ echo "Creating JAR: $@ ...";\ - echo "Main-Class: mds.jdispatcher.jDispatchMonitor" >> $(MANIFEST) &&\ - echo "Class-Path: mdsobjects.jar" >> $(MANIFEST) &&\ - $(JAR) cf $@ -C $(JAVAROOT) . - -endif - -if MINGW -bin_SCRIPTS += jDispatcherIp.bat jDispatchMonitor.bat jServer.bat -else -bin_SCRIPTS += jDispatcherIp jDispatchMonitor jServer -EXTRA_DIST = jDispatcherIp.template jDispatchMonitor.template jServer.template -jDispatcherIp: jDispatcherIp.template - cp $< $@ -jDispatchMonitor: jDispatchMonitor.template - cp $< $@ -jServer: jServer.template - cp $< $@ -endif - -SOURCE = mds/jdispatcher/*.java diff --git a/java/jscope/Makefile.am b/java/jscope/Makefile.am deleted file mode 100644 index e30eab454c..0000000000 --- a/java/jscope/Makefile.am +++ /dev/null @@ -1,50 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am - -java_srcdir = $(srcdir)/src/main/java -java_resdir = $(srcdir)/src/main/resources -dist_java_DATA = jScope.properties -java_DATA = jScope.jar -DEPENDENCIES = $(JSCH) $(MDSOBJECTS_JAR) - -if USE_JARS_DIR - -jScope.jar: @JARS_DIR@/java/jscope/jScope.jar - cp $< $@ - -else - -jScope.jar: $(DEPENDENCIES) $(MANIFEST) classjava.stamp - @ echo "Creating JAR: $@ ...";\ - echo "Main-Class: mds.jscope.jScope" >> $(MANIFEST) &&\ - echo "Class-Path: mdsobjects.jar" >> $(MANIFEST) &&\ - rsync -r $(java_resdir)/ $(JAVAROOT) &&\ - cp -f $(JSCH) $@ &&\ - $(JAR) umf $(MANIFEST) $@ -C $(JAVAROOT) . - -endif - -jScope.properties: $(java_resdir)/mds/jscope/jScope.properties - cp $< $@ - -if MINGW -bin_SCRIPTS += jScope.bat -else -bin_SCRIPTS += jScope -EXTRA_DIST = jScope.template -jScope: $(srcdir)/jScope.template - cp $< $@ -endif - -SOURCE =\ - mds/connection/*.java\ - mds/jscope/*.java\ - mds/provider/*.java\ - mds/provider/browser/*.java\ - mds/provider/mds/*.java\ - mds/wave/*.java -RESOURCES =\ - mds/jscope/about.jpg\ - mds/jscope/jScope.properties\ - mds/wave/colors1.tbl - diff --git a/java/jtraverser/Makefile.am b/java/jtraverser/Makefile.am deleted file mode 100644 index 6f0f6fa822..0000000000 --- a/java/jtraverser/Makefile.am +++ /dev/null @@ -1,48 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am - -EXTRA_DIST = - - -java_srcdir = $(srcdir)/src/main/java -java_resdir = $(srcdir)/src/main/resources -java_DATA = jTraverser.jar -DEPENDENCIES = $(MDSOBJECTS_JAR) $(JSCOPE_JAR) - -if USE_JARS_DIR - -jTraverser.jar: @JARS_DIR@/java/jtraverser/jTraverser.jar - cp $< $@ - -else - -jTraverser.jar: $(DEPENDENCIES) $(MANIFEST) classjava.stamp - @ echo "Creating JAR: $@ ...";\ - echo "Main-Class: mds.jtraverser.jTraverser" >> $(MANIFEST) &&\ - echo "Class-Path: mdsobjects.jar DeviceBeans.jar jScope.jar jDevices.jar" >> $(MANIFEST) &&\ - rsync -r $(java_resdir)/ $(JAVAROOT) &&\ - $(JAR) cmf $(MANIFEST) $@ -C $(JAVAROOT) . - -endif - -if MINGW -bin_SCRIPTS += jTraverser.bat -else -bin_SCRIPTS += jTraverser -bin_SCRIPTS += CompileTree -bin_SCRIPTS += DecompileTree -EXTRA_DIST += jTraverser.template -EXTRA_DIST += CompileTree.template -EXTRA_DIST += DecompileTree.template -jTraverser: $(srcdir)/jTraverser.template - cp $< $@ -CompileTree: $(srcdir)/CompileTree.template - cp $< $@ -DecompileTree: $(srcdir)/DecompileTree.template - cp $< $@ -endif - -SOURCE = \ - mds/jtraverser/*.java\ - mds/devices/*.java -RESOURCES = mds/jtraverser/*.gif diff --git a/java/jtraverser2/Makefile.am b/java/jtraverser2/Makefile.am deleted file mode 100644 index c6d68d51c5..0000000000 --- a/java/jtraverser2/Makefile.am +++ /dev/null @@ -1,45 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am - -java_srcdir = $(srcdir)/src/main/java -java_resdir = $(srcdir)/src/main/resources -java_DATA = jTraverser2.jar -DEPENDENCIES = $(MDSPLUS_API_JAR) - -LAUNCHER = jTraverser2 setupDevice - - -if USE_JARS_DIR - -$(java_DATA): @JARS_DIR@/java/jtraverser2/jTraverser2.jar - cp $< $@ - -else - -$(java_DATA): $(DEPENDENCIES) $(MANIFEST) classjava.stamp - @ echo "Creating JAR: $@ ...";\ - echo "Main-Class: mds.jtraverser.jTraverser" >> $(MANIFEST) &&\ - echo "Class-Path: mdsplus-api.jar DeviceBeans.jar WaveDisplay.jar mdsobjects.jar jDevices.jar" >> $(MANIFEST) &&\ - rsync -r $(java_resdir)/ $(JAVAROOT) &&\ - $(JAR) cmf $(MANIFEST) $@ -C $(JAVAROOT) . - -endif - -if MINGW -bin_SCRIPTS += $(LAUNCHER:=.bat) -else -bin_SCRIPTS += $(LAUNCHER) -EXTRA_DIST = $(LAUNCHER:=.template) -$(LAUNCHER): % : $(srcdir)/%.template - cp $< $@ -endif - -SOURCE =\ - mds/jtraverser/*.java\ - mds/jtraverser/dialogs/*.java\ - mds/jtraverser/editor/*.java\ - mds/jtraverser/editor/usage/*.java\ - mds/jtraverser/tools/*.java\ - mds/devices/*.java\ - mds/devices/acq4xx/*.java -RESOURCES = mds/jtraverser/*.gif diff --git a/java/mdsobjects/Makefile.am b/java/mdsobjects/Makefile.am deleted file mode 100644 index 3ad424cd1b..0000000000 --- a/java/mdsobjects/Makefile.am +++ /dev/null @@ -1,28 +0,0 @@ -JAVASOURCE = 8 -DEPENDENCIES = $(srcdir)/src/main/resources/javax.json-1.0.4.jar -include ../Makefile.inc.am - -java_srcdir = $(srcdir)/src/main/java -java_resdir = $(srcdir)/src/main/resources -java_DATA = mdsobjects.jar - -if USE_JARS_DIR - -$(java_DATA): @JARS_DIR@/java/mdsobjects/mdsobjects.jar - cp $< $@ - -else - -$(java_DATA): $(DEPENDENCIES) classjava.stamp - $(JAR) xvf $(java_resdir)/javax.json-1.0.4.jar - mv org classes/org - mv javax classes/javax - @ echo "Creating JAR: $@ ..."; \ - rsync -r $(java_resdir)/ $(JAVAROOT) &&\ - $(JAR) cf $@ -C $(JAVAROOT) . - -endif - -SOURCE =\ - MDSplus/*.java\ - mds/connection/*.java diff --git a/java/mdsobjects/docs/Makefile.am b/java/mdsobjects/docs/Makefile.am deleted file mode 100644 index bb93878dfd..0000000000 --- a/java/mdsobjects/docs/Makefile.am +++ /dev/null @@ -1,31 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../../docs/config/doxygen.am - -# //////////////////////////////////////////////////////////////////////////// # -# DOXYGEN CONFIG # - -DX_CONFIG = ${top_srcdir}/docs/config/doxygen_cpp.cfg -DX_DOCDIR = mdsobjects/java/docs -DX_PACKAGE_NAME = mdsobjects_java -DX_TITLE = MDSplus Java interface -DX_BRIEF = "MDSplus object oriented interface" - -DX_PAGES = ../src/main/java/MDSplus \ - index.md - -DX_EXCLUDE_PAGES = - -DX_TAGFILES = docs.tag - -MOSTLYCLEANFILES = $(DX_CLEANFILES) - -# //////////////////////////////////////////////////////////////////////////// # -# TARGETS # - -all: html - -html: doxygen-run -pdf: doxygen-pdf - -install-data-local: doxygen-install diff --git a/java/mdsobjects/tests/Makefile.am b/java/mdsobjects/tests/Makefile.am deleted file mode 100644 index 8fc7b4d0c9..0000000000 --- a/java/mdsobjects/tests/Makefile.am +++ /dev/null @@ -1,27 +0,0 @@ -JAVASOURCE = 8 -include ../../Makefile.tests.am - -java_srcdir = $(srcdir)/../src/test/java - -DEPENDENCIES += $(MDSOBJECTS_JAR) - -SOURCE = \ - MDSplus/*.java - -TESTS_ENVIRONMENT += java_test_path=$(abs_builddir) - -TESTS = \ - MDSplus.MdsDataTest\ - MDSplus.MdsConglomTest\ - MDSplus.MdsConnectionTest\ - MDSplus.MdsDimensionTest\ - MDSplus.MdsEventTest\ - MDSplus.MdsExpressionCompileTest\ - MDSplus.MdsFunctionTest\ - MDSplus.MdsRangeTest\ - MDSplus.MdsSignalTest\ - MDSplus.MdsStringTest\ - MDSplus.MdsTreeNodeTest\ - MDSplus.MdsTreeTest\ - MDSplus.MdsWindowTest -# MDSplus.MdsRemoteEventTest diff --git a/java/mdsplus-api/Makefile.am b/java/mdsplus-api/Makefile.am deleted file mode 100644 index fb81709cdf..0000000000 --- a/java/mdsplus-api/Makefile.am +++ /dev/null @@ -1,33 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am - -java_srcdir = $(srcdir)/src/main/java -java_DATA = mdsplus-api.jar -DEPENDENCIES = $(JSCH) - -if USE_JARS_DIR - -$(java_DATA): @JARS_DIR@/java/mdsplus-api/mdsplus-api.jar - cp $< $@ - -else - -$(java_DATA): $(JSCH) $(MANIFEST) classjava.stamp - @ echo "Creating JAR: $@ ...";\ - cp -f $(JSCH) $@ &&\ - $(JAR) umf $(MANIFEST) $@ -C $(JAVAROOT) . - -endif - -SOURCE =\ - mds/*.java\ - mds/data/*.java\ - mds/data/descriptor/*.java\ - mds/data/descriptor_a/*.java\ - mds/data/descriptor_apd/*.java\ - mds/data/descriptor_r/*.java\ - mds/data/descriptor_r/function/*.java\ - mds/data/descriptor_s/*.java\ - mds/mdslib/*.java\ - mds/mdsip/*.java - diff --git a/java/mdsplus-api/tests/Makefile.am b/java/mdsplus-api/tests/Makefile.am deleted file mode 100644 index 8a87535d7e..0000000000 --- a/java/mdsplus-api/tests/Makefile.am +++ /dev/null @@ -1,25 +0,0 @@ -JAVASOURCE = 8 -include ../../Makefile.tests.am - -java_srcdir = $(srcdir)/../src/test/java - -DEPENDENCIES += $(MDSPLUS_API_JAR) - -SOURCE = \ - mds/*.java \ - mds/data/*.java \ - mds/data/descriptor/*.java \ - mds/data/descriptor_r/*.java - -TESTS = \ - mds.Mds_Test\ - mds.MdsShr_Test\ - mds.TdiShr_Test\ - mds.TreeShr_Test\ - mds.data.CONST_Test\ - mds.data.FLOAT_Test\ - mds.data.TREE_Test\ - mds.data.descriptor.Descriptor_A_Test\ - mds.data.descriptor.Descriptor_CA_Test\ - mds.data.descriptor.Descriptor_S_Test\ - mds.data.descriptor_r.Function_Test diff --git a/java/mdsplus/Makefile.am b/java/mdsplus/Makefile.am deleted file mode 100644 index 4712490d69..0000000000 --- a/java/mdsplus/Makefile.am +++ /dev/null @@ -1,20 +0,0 @@ -JAVASOURCE = 8 -include ../Makefile.inc.am - -java_srcdir = $(srcdir)/src/main/java -java_DATA = MdsPlus.jar -DEPENDENCIES = -if USE_JARS_DIR - -$(java_DATA): @JARS_DIR@/java/mdsplus/MdsPlus.jar - cp $< $@ - -else - -$(java_DATA): $(DEPENDENCIES) classjava.stamp - @ echo "Creating JAR: $@ ..."; \ - $(JAR) cf $@ -C $(JAVAROOT) . - -endif - -SOURCE = MdsPlus/*.java diff --git a/java/tests/Makefile.am b/java/tests/Makefile.am deleted file mode 100644 index 08fd722ffd..0000000000 --- a/java/tests/Makefile.am +++ /dev/null @@ -1,22 +0,0 @@ -JAVASOURCE = 8 -include @top_builddir@/Makefile.inc -include ../Makefile.inc.am - -java_srcdir = ${srcdir} -java_DATA = taptest.jar - -SOURCE = org/junit/runner/TapTestRunner.java - -DEPENDENCIES = $(wildcard $(top_srcdir)/java/tests/*.jar) - -# override so it will not be installed -install-javaDATA: $(java_DATA) - -if USE_JARS_DIR -$(java_DATA): @JARS_DIR@/java/tests/taptest.jar - cp $< $@ -else -$(java_DATA): classjava.stamp - @ echo "Creating JAR: $@ ...";\ - $(JAR) cf $@ -C $(JAVAROOT) . -endif diff --git a/javamds/Makefile.in b/javamds/Makefile.in deleted file mode 100644 index c6cac1264c..0000000000 --- a/javamds/Makefile.in +++ /dev/null @@ -1,27 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS += -I /media/sf_FedoraShared/include/ -I /media/sf_FedoraShared/include/win32 $(THREAD) @JDK_CFLAGS@ - -SOURCES = ServerSupport.c mdsobjects.c -OBJECTS = $(SOURCES:.c=.o) - -all: @MAKELIBDIR@ @MAKELIBDIR@@LIBPRE@JavaMds@SHARETYPEJNI@ - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) @MAKELIBDIR@@LIBPRE@JavaMds@SHARETYPEJNI@ - -install: $(libdir) - $(INSTALL) -m 755 @MAKELIBDIR@@LIBPRE@JavaMds@SHARETYPEJNI@ @libdir@ - -@MAKELIBDIR@@LIBPRE@JavaMds@SHARETYPEJNI@ : $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKJNI@ $(THREAD) $^ -L@MAKELIBDIR@ -lMdsShr -lMdsIpShr -lTreeShr -lTdiShr $(LIBS) - diff --git a/m4/ac_defun_local.m4 b/m4/ac_defun_local.m4 deleted file mode 100644 index a6b999debd..0000000000 --- a/m4/ac_defun_local.m4 +++ /dev/null @@ -1,84 +0,0 @@ - -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ac_local_scope.html -# =========================================================================== -# -# SYNOPSIS -# -# AC_DEFUN_LOCAL([namespace],[funcname],[function definition]) -# -# DESCRIPTION -# -# This simply defines a m4 macro using autoconf AC_DEFUN but prepending to -# the function name a namespace prefix that should be uniquely defined. Using -# the namespace one can write a set of function inside a macro file that are -# visible with the provided funcion names only within the AC_PUSH_LOCAL and -# AC_POP_LOCAL calls. -# -# EXAMPLE -# -# AC_DEFUN([AX_TEST_LOCAL_NAMESPACE],[ -# AC_PUSH_LOCAL([my_unique_namespace_name]) -# PRINT_HELLO_WORLD -# AC_POP_LOCAL([my_unique_namespace_name]) -# ]) -# -# AC_DEFUN_LOCAL([my_unique_namespace_name],[AS_BANNER],[ -# AS_ECHO -# AS_BOX([// LOCAL!! $1 //////], [\/]) -# AS_ECHO -# ]) -# -# AC_DEFUN_LOCAL([my_unique_namespace_name],[PRINT_HELLO], -# [AS_BANNER(["hello $1"])]) -# -# AC_DEFUN_LOCAL([my_unique_namespace_name],[PRINT_HELLO_WORLD], -# [PRINT_HELLO(world)]) -# -# -# LICENSE -# -# Copyright (c) 2016 Andrea Rigoni Garola -# -# 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 3 of the License, 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 1 - -AC_DEFUN([AC_DEFUN_LOCAL], - [m4_defun([$1_$2],[$3]) - m4_append_uniq([$1_FUNCS],[[[$2]]],[,])]) - -AC_DEFUN([AC_PUSH_LOCAL], - [m4_foreach([func],[$1_FUNCS],[m4_pushdef(func,m4_defn($1_[]func))])]) - -AC_DEFUN([AC_POP_LOCAL], - [m4_foreach([func],[$1_FUNCS],[m4_popdef(func)])]) - - - - - diff --git a/m4/ac_defun_local_example.m4 b/m4/ac_defun_local_example.m4 deleted file mode 100644 index 77e56e74c3..0000000000 --- a/m4/ac_defun_local_example.m4 +++ /dev/null @@ -1,21 +0,0 @@ - - -AC_DEFUN([AX_TEST_LOCAL_NAMESPACE],[ - AC_PUSH_LOCAL([my_unique_namespace_name]) - PRINT_HELLO_WORLD - AC_POP_LOCAL([my_unique_namespace_name]) -]) - -AC_DEFUN_LOCAL([my_unique_namespace_name],[AS_BANNER],[ - AS_ECHO - AS_BOX([// LOCAL!! $1 //////], [\/]) - AS_ECHO - ]) - -AC_DEFUN_LOCAL([my_unique_namespace_name],[PRINT_HELLO], - [AS_BANNER(["hello $1"])]) - -AC_DEFUN_LOCAL([my_unique_namespace_name],[PRINT_HELLO_WORLD], - [PRINT_HELLO(world)]) - - diff --git a/m4/ax_check_busybox.m4 b/m4/ax_check_busybox.m4 deleted file mode 100644 index 6949a63a02..0000000000 --- a/m4/ax_check_busybox.m4 +++ /dev/null @@ -1,61 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ac_git_revision.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_IS_BUSYBOX([shell_cmd],[action if true],[action if false]) -# -# DESCRIPTION -# Find if a command is provided by busybox -# -# LICENSE -# -# Copyright (c) 2019 Andrea Rigoni Garola -# -# 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 3 of the License, 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 1 - -# //////////////////////////////////////////////////////////////////////////// # -# ////// IS BUSYBOX ////////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -AC_DEFUN([AX_PROG_BUSYBOX],[ - AC_CHECK_TOOL([BUSYBOX],[busybox]) -]) - -AC_DEFUN([AX_IS_BUSYBOX],[ - AC_REQUIRE([AX_PROG_BUSYBOX]) - echo which ${BUSYBOX} - if test -n "${BUSYBOX}"; then - AS_IF([cmp $(which [$1]) $(which ${BUSYBOX})],[$2],[$3]) - else - $3 - fi -]) - diff --git a/m4/ax_check_java_home.m4 b/m4/ax_check_java_home.m4 deleted file mode 100644 index a656f62f4f..0000000000 --- a/m4/ax_check_java_home.m4 +++ /dev/null @@ -1,82 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_check_java_home.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_CHECK_JAVA_HOME -# -# DESCRIPTION -# -# Check for Sun Java (JDK / JRE) installation, where the 'java' VM is in. -# If found, set environment variable JAVA_HOME = Java installation home, -# else left JAVA_HOME untouch, which in most case means JAVA_HOME is -# empty. -# -# - JAVA_HOME: must point to installation directory of JDK. -# - JRE_HOME: must point to installation directory of JRE. -# - CLASSPATH: contains libraries path which JVM will look for. -# - PATH: normal environment variable on Windows. -# -# LICENSE -# -# Copyright (c) 2008 Gleen Salmon -# -# This program is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by the -# Free Software Foundation; either version 2 of the License, or (at your -# option) any later version. -# -# 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 7 - -AU_ALIAS([AC_CHECK_JAVA_HOME], [AX_CHECK_JAVA_HOME]) - -AC_DEFUN([AX_CHECK_JAVA_HOME], -[AC_MSG_CHECKING([for JAVA_HOME]) -# We used a fake loop so that we can use "break" when the result is found. -while true -do - # If the user defined JAVA_HOME, don't touch it. - test -n "${JAVA_HOME}" && break - - # On Mac OS X 10.5 and following, run /usr/libexec/java_home to get - # the value of JAVA_HOME to use. - # (http://developer.apple.com/library/mac/#qa/qa2001/qa1170.html). - JAVA_HOME=`/usr/libexec/java_home 2>/dev/null` - test -n "${JAVA_HOME}" && break - - AC_PATH_PROG([JAVAC_PATH_NAME], [javac]) - AC_CHECK_TOOL([READLINK],[readlink]) - test -n "${READLINK}" && AS_VAR_SET([JAVAC_PATH_NAME],[`${READLINK} -f ${JAVAC_PATH_NAME}`]) - test -f ${JAVAC_PATH_NAME} && JAVA_HOME=`echo "${JAVAC_PATH_NAME}" \ - | sed "s/\(.*\)[[/]]bin[[/]]java.*/\1/"` - test -n "${JAVA_HOME}" && break - - - AC_MSG_NOTICE([Could not compute JAVA_HOME]) - break -done -AC_MSG_RESULT([$JAVA_HOME]) -]) - diff --git a/m4/ax_compare_version.m4 b/m4/ax_compare_version.m4 deleted file mode 100644 index 74dc0fdd9a..0000000000 --- a/m4/ax_compare_version.m4 +++ /dev/null @@ -1,177 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_compare_version.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_COMPARE_VERSION(VERSION_A, OP, VERSION_B, [ACTION-IF-TRUE], [ACTION-IF-FALSE]) -# -# DESCRIPTION -# -# This macro compares two version strings. Due to the various number of -# minor-version numbers that can exist, and the fact that string -# comparisons are not compatible with numeric comparisons, this is not -# necessarily trivial to do in a autoconf script. This macro makes doing -# these comparisons easy. -# -# The six basic comparisons are available, as well as checking equality -# limited to a certain number of minor-version levels. -# -# The operator OP determines what type of comparison to do, and can be one -# of: -# -# eq - equal (test A == B) -# ne - not equal (test A != B) -# le - less than or equal (test A <= B) -# ge - greater than or equal (test A >= B) -# lt - less than (test A < B) -# gt - greater than (test A > B) -# -# Additionally, the eq and ne operator can have a number after it to limit -# the test to that number of minor versions. -# -# eq0 - equal up to the length of the shorter version -# ne0 - not equal up to the length of the shorter version -# eqN - equal up to N sub-version levels -# neN - not equal up to N sub-version levels -# -# When the condition is true, shell commands ACTION-IF-TRUE are run, -# otherwise shell commands ACTION-IF-FALSE are run. The environment -# variable 'ax_compare_version' is always set to either 'true' or 'false' -# as well. -# -# Examples: -# -# AX_COMPARE_VERSION([3.15.7],[lt],[3.15.8]) -# AX_COMPARE_VERSION([3.15],[lt],[3.15.8]) -# -# would both be true. -# -# AX_COMPARE_VERSION([3.15.7],[eq],[3.15.8]) -# AX_COMPARE_VERSION([3.15],[gt],[3.15.8]) -# -# would both be false. -# -# AX_COMPARE_VERSION([3.15.7],[eq2],[3.15.8]) -# -# would be true because it is only comparing two minor versions. -# -# AX_COMPARE_VERSION([3.15.7],[eq0],[3.15]) -# -# would be true because it is only comparing the lesser number of minor -# versions of the two values. -# -# Note: The characters that separate the version numbers do not matter. An -# empty string is the same as version 0. OP is evaluated by autoconf, not -# configure, so must be a string, not a variable. -# -# The author would like to acknowledge Guido Draheim whose advice about -# the m4_case and m4_ifvaln functions make this macro only include the -# portions necessary to perform the specific comparison specified by the -# OP argument in the final configure script. -# -# LICENSE -# -# Copyright (c) 2008 Tim Toolan -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 11 - -dnl ######################################################################### -AC_DEFUN([AX_COMPARE_VERSION], [ - AC_REQUIRE([AC_PROG_AWK]) - - # Used to indicate true or false condition - ax_compare_version=false - - # Convert the two version strings to be compared into a format that - # allows a simple string comparison. The end result is that a version - # string of the form 1.12.5-r617 will be converted to the form - # 0001001200050617. In other words, each number is zero padded to four - # digits, and non digits are removed. - AS_VAR_PUSHDEF([A],[ax_compare_version_A]) - A=`echo "$1" | sed -e 's/\([[0-9]]*\)/Z\1Z/g' \ - -e 's/Z\([[0-9]]\)Z/Z0\1Z/g' \ - -e 's/Z\([[0-9]][[0-9]]\)Z/Z0\1Z/g' \ - -e 's/Z\([[0-9]][[0-9]][[0-9]]\)Z/Z0\1Z/g' \ - -e 's/[[^0-9]]//g'` - - AS_VAR_PUSHDEF([B],[ax_compare_version_B]) - B=`echo "$3" | sed -e 's/\([[0-9]]*\)/Z\1Z/g' \ - -e 's/Z\([[0-9]]\)Z/Z0\1Z/g' \ - -e 's/Z\([[0-9]][[0-9]]\)Z/Z0\1Z/g' \ - -e 's/Z\([[0-9]][[0-9]][[0-9]]\)Z/Z0\1Z/g' \ - -e 's/[[^0-9]]//g'` - - dnl # In the case of le, ge, lt, and gt, the strings are sorted as necessary - dnl # then the first line is used to determine if the condition is true. - dnl # The sed right after the echo is to remove any indented white space. - m4_case(m4_tolower($2), - [lt],[ - ax_compare_version=`echo "x$A -x$B" | sed 's/^ *//' | sort -r | sed "s/x${A}/false/;s/x${B}/true/;1q"` - ], - [gt],[ - ax_compare_version=`echo "x$A -x$B" | sed 's/^ *//' | sort | sed "s/x${A}/false/;s/x${B}/true/;1q"` - ], - [le],[ - ax_compare_version=`echo "x$A -x$B" | sed 's/^ *//' | sort | sed "s/x${A}/true/;s/x${B}/false/;1q"` - ], - [ge],[ - ax_compare_version=`echo "x$A -x$B" | sed 's/^ *//' | sort -r | sed "s/x${A}/true/;s/x${B}/false/;1q"` - ],[ - dnl Split the operator from the subversion count if present. - m4_bmatch(m4_substr($2,2), - [0],[ - # A count of zero means use the length of the shorter version. - # Determine the number of characters in A and B. - ax_compare_version_len_A=`echo "$A" | $AWK '{print(length)}'` - ax_compare_version_len_B=`echo "$B" | $AWK '{print(length)}'` - - # Set A to no more than B's length and B to no more than A's length. - A=`echo "$A" | sed "s/\(.\{$ax_compare_version_len_B\}\).*/\1/"` - B=`echo "$B" | sed "s/\(.\{$ax_compare_version_len_A\}\).*/\1/"` - ], - [[0-9]+],[ - # A count greater than zero means use only that many subversions - A=`echo "$A" | sed "s/\(\([[0-9]]\{4\}\)\{m4_substr($2,2)\}\).*/\1/"` - B=`echo "$B" | sed "s/\(\([[0-9]]\{4\}\)\{m4_substr($2,2)\}\).*/\1/"` - ], - [.+],[ - AC_WARNING( - [illegal OP numeric parameter: $2]) - ],[]) - - # Pad zeros at end of numbers to make same length. - ax_compare_version_tmp_A="$A`echo $B | sed 's/./0/g'`" - B="$B`echo $A | sed 's/./0/g'`" - A="$ax_compare_version_tmp_A" - - # Check for equality or inequality as necessary. - m4_case(m4_tolower(m4_substr($2,0,2)), - [eq],[ - test "x$A" = "x$B" && ax_compare_version=true - ], - [ne],[ - test "x$A" != "x$B" && ax_compare_version=true - ],[ - AC_WARNING([illegal OP parameter: $2]) - ]) - ]) - - AS_VAR_POPDEF([A])dnl - AS_VAR_POPDEF([B])dnl - - dnl # Execute ACTION-IF-TRUE / ACTION-IF-FALSE. - if test "$ax_compare_version" = "true" ; then - m4_ifvaln([$4],[$4],[:])dnl - m4_ifvaln([$5],[else $5])dnl - fi -]) dnl AX_COMPARE_VERSION diff --git a/m4/ax_compiler_vendor.m4 b/m4/ax_compiler_vendor.m4 deleted file mode 100644 index 39ca3c0f33..0000000000 --- a/m4/ax_compiler_vendor.m4 +++ /dev/null @@ -1,87 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_compiler_vendor.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_COMPILER_VENDOR -# -# DESCRIPTION -# -# Determine the vendor of the C/C++ compiler, e.g., gnu, intel, ibm, sun, -# hp, borland, comeau, dec, cray, kai, lcc, metrowerks, sgi, microsoft, -# watcom, etc. The vendor is returned in the cache variable -# $ax_cv_c_compiler_vendor for C and $ax_cv_cxx_compiler_vendor for C++. -# -# LICENSE -# -# Copyright (c) 2008 Steven G. Johnson -# Copyright (c) 2008 Matteo Frigo -# -# 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 3 of the License, 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 15 - -AC_DEFUN([AX_COMPILER_VENDOR], -[AC_CACHE_CHECK([for _AC_LANG compiler vendor], ax_cv_[]_AC_LANG_ABBREV[]_compiler_vendor, - dnl Please add if possible support to ax_compiler_version.m4 - [# note: don't check for gcc first since some other compilers define __GNUC__ - vendors="intel: __ICC,__ECC,__INTEL_COMPILER - ibm: __xlc__,__xlC__,__IBMC__,__IBMCPP__ - pathscale: __PATHCC__,__PATHSCALE__ - clang: __clang__ - cray: _CRAYC - fujitsu: __FUJITSU - gnu: __GNUC__ - sun: __SUNPRO_C,__SUNPRO_CC - hp: __HP_cc,__HP_aCC - dec: __DECC,__DECCXX,__DECC_VER,__DECCXX_VER - borland: __BORLANDC__,__CODEGEARC__,__TURBOC__ - comeau: __COMO__ - kai: __KCC - lcc: __LCC__ - sgi: __sgi,sgi - microsoft: _MSC_VER - metrowerks: __MWERKS__ - watcom: __WATCOMC__ - portland: __PGI - tcc: __TINYC__ - unknown: UNKNOWN" - for ventest in $vendors; do - case $ventest in - *:) vendor=$ventest; continue ;; - *) vencpp="defined("`echo $ventest | sed 's/,/) || defined(/g'`")" ;; - esac - AC_COMPILE_IFELSE([AC_LANG_PROGRAM(,[ - #if !($vencpp) - thisisanerror; - #endif - ])], [break]) - done - ax_cv_[]_AC_LANG_ABBREV[]_compiler_vendor=`echo $vendor | cut -d: -f1` - ]) -]) diff --git a/m4/ax_compiler_version.m4 b/m4/ax_compiler_version.m4 deleted file mode 100644 index 10ac77514e..0000000000 --- a/m4/ax_compiler_version.m4 +++ /dev/null @@ -1,492 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_compiler_version.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_COMPILER_VERSION -# -# DESCRIPTION -# -# This macro retrieves the compiler version and returns it in the cache -# variable $ax_cv_c_compiler_version for C and $ax_cv_cxx_compiler_version -# for C++. -# -# Version is returned as epoch:major.minor.patchversion -# -# Epoch is used in order to have an increasing version number in case of -# marketing change. -# -# Epoch use: * borland compiler use chronologically 0turboc for turboc -# era, -# -# 1borlanc BORLANC++ before 5, 2cppbuilder for cppbuilder era, -# 3borlancpp for return of BORLANC++ (after version 5.5), -# 4cppbuilder for cppbuilder with year version, -# and 5xe for XE era. -# -# An empty string is returned otherwise. -# -# LICENSE -# -# Copyright (c) 2014 Bastien ROUCARIES -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 4 - -# for intel -AC_DEFUN([_AX_COMPILER_VERSION_INTEL], - [ dnl - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - [__INTEL_COMPILER/100],, - AC_MSG_FAILURE([[[$0]] unknown intel compiler version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - [(__INTEL_COMPILER%100)/10],, - AC_MSG_FAILURE([[[$0]] unknown intel compiler version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [(__INTEL_COMPILER%10)],, - AC_MSG_FAILURE([[[$0]] unknown intel compiler version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# for IBM -AC_DEFUN([_AX_COMPILER_VERSION_IBM], - [ dnl - dnl check between z/OS C/C++ and XL C/C++ - AC_COMPILE_IFELSE([ - AC_LANG_PROGRAM([], - [ - #if defined(__COMPILER_VER__) - choke me; - #endif - ])], - [ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - [__xlC__/100],, - AC_MSG_FAILURE([[[$0]] unknown IBM compiler major version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - [__xlC__%100],, - AC_MSG_FAILURE([[[$0]] unknown IBM compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [__xlC_ver__/0x100],, - AC_MSG_FAILURE([[[$0]] unknown IBM compiler patch version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_build, - [__xlC_ver__%0x100],, - AC_MSG_FAILURE([[[$0]] unknown IBM compiler build version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_build" - ], - [ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [__xlC__%1000],, - AC_MSG_FAILURE([[[$0]] unknown IBM compiler patch version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - [(__xlC__/10000)%10],, - AC_MSG_FAILURE([[[$0]] unknown IBM compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - [(__xlC__/100000)%10],, - AC_MSG_FAILURE([[[$0]] unknown IBM compiler major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) -]) - -# for pathscale -AC_DEFUN([_AX_COMPILER_VERSION_PATHSCALE],[ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - __PATHCC__,, - AC_MSG_FAILURE([[[$0]] unknown pathscale major])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - __PATHCC_MINOR__,, - AC_MSG_FAILURE([[[$0]] unknown pathscale minor])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [__PATHCC_PATCHLEVEL__],, - AC_MSG_FAILURE([[[$0]] unknown pathscale patch level])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# for clang -AC_DEFUN([_AX_COMPILER_VERSION_CLANG],[ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - __clang_major__,, - AC_MSG_FAILURE([[[$0]] unknown clang major])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - __clang_minor__,, - AC_MSG_FAILURE([[[$0]] unknown clang minor])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [__clang_patchlevel__],,0) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# for crayc -AC_DEFUN([_AX_COMPILER_VERSION_CRAY],[ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - _RELEASE,, - AC_MSG_FAILURE([[[$0]] unknown crayc release])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - _RELEASE_MINOR,, - AC_MSG_FAILURE([[[$0]] unknown crayc minor])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor" - ]) - -# for fujitsu -AC_DEFUN([_AX_COMPILER_VERSION_FUJITSU],[ - AC_COMPUTE_INT(ax_cv_[]_AC_LANG_ABBREV[]_compiler_version, - __FCC_VERSION,, - AC_MSG_FAILURE([[[$0]]unknown fujitsu release])) - ]) - -# for GNU -AC_DEFUN([_AX_COMPILER_VERSION_GNU],[ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - __GNUC__,, - AC_MSG_FAILURE([[[$0]] unknown gcc major])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - __GNUC_MINOR__,, - AC_MSG_FAILURE([[[$0]] unknown gcc minor])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [__GNUC_PATCHLEVEL__],, - AC_MSG_FAILURE([[[$0]] unknown gcc patch level])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# For sun -AC_DEFUN([_AX_COMPILER_VERSION_SUN],[ - m4_define([_AX_COMPILER_VERSION_SUN_NUMBER], - [ - #if defined(__SUNPRO_CC) - __SUNPRO_CC - #else - __SUNPRO_C - #endif - ]) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_until59, - !!(_AX_COMPILER_VERSION_SUN_NUMBER < 0x1000),, - AC_MSG_FAILURE([[[$0]] unknown sun release version])) - AS_IF([test "X$_ax_[]_AC_LANG_ABBREV[]_compiler_version_until59" = X1], - [dnl - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - _AX_COMPILER_VERSION_SUN_NUMBER % 0x10,, - AC_MSG_FAILURE([[[$0]] unknown sun patch version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - (_AX_COMPILER_VERSION_SUN_NUMBER / 0x10) % 0x10,, - AC_MSG_FAILURE([[[$0]] unknown sun minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - (_AX_COMPILER_VERSION_SUN_NUMBER / 0x100),, - AC_MSG_FAILURE([[[$0]] unknown sun major version])) - ], - [dnl - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - _AX_COMPILER_VERSION_SUN_NUMBER % 0x10,, - AC_MSG_FAILURE([[[$0]] unknown sun patch version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - (_AX_COMPILER_VERSION_SUN_NUMBER / 0x100) % 0x100,, - AC_MSG_FAILURE([[[$0]] unknown sun minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - (_AX_COMPILER_VERSION_SUN_NUMBER / 0x1000),, - AC_MSG_FAILURE([[[$0]] unknown sun major version])) - ]) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" -]) - -AC_DEFUN([_AX_COMPILER_VERSION_HP],[ - m4_define([_AX_COMPILER_VERSION_HP_NUMBER], - [ - #if defined(__HP_cc) - __HP_cc - #else - __HP_aCC - #endif - ]) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_untilA0121, - !!(_AX_COMPILER_VERSION_HP_NUMBER <= 1),, - AC_MSG_FAILURE([[[$0]] unknown hp release version])) - AS_IF([test "X$_ax_[]_AC_LANG_ABBREV[]_compiler_version_untilA0121" = X1], - [dnl By default output last version with this behavior. - dnl it is so old - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="01.21.00" - ], - [dnl - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - (_AX_COMPILER_VERSION_HP_NUMBER % 100),, - AC_MSG_FAILURE([[[$0]] unknown hp release version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - ((_AX_COMPILER_VERSION_HP_NUMBER / 100)%100),, - AC_MSG_FAILURE([[[$0]] unknown hp minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - ((_AX_COMPILER_VERSION_HP_NUMBER / 10000)%100),, - AC_MSG_FAILURE([[[$0]] unknown hp major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) -]) - -AC_DEFUN([_AX_COMPILER_VERSION_DEC],[dnl - m4_define([_AX_COMPILER_VERSION_DEC_NUMBER], - [ - #if defined(__DECC_VER) - __DECC_VER - #else - __DECCXX_VER - #endif - ]) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - (_AX_COMPILER_VERSION_DEC_NUMBER % 10000),, - AC_MSG_FAILURE([[[$0]] unknown dec release version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - ((_AX_COMPILER_VERSION_DEC_NUMBER / 100000UL)%100),, - AC_MSG_FAILURE([[[$0]] unknown dec minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - ((_AX_COMPILER_VERSION_DEC_NUMBER / 10000000UL)%100),, - AC_MSG_FAILURE([[[$0]] unknown dec major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# borland -AC_DEFUN([_AX_COMPILER_VERSION_BORLAND],[dnl - m4_define([_AX_COMPILER_VERSION_TURBOC_NUMBER], - [ - #if defined(__TURBOC__) - __TURBOC__ - #else - choke me - #endif - ]) - m4_define([_AX_COMPILER_VERSION_BORLANDC_NUMBER], - [ - #if defined(__BORLANDC__) - __BORLANDC__ - #else - __CODEGEARC__ - #endif - ]) - AC_COMPILE_IFELSE( - [AC_LANG_PROGRAM(, - _AX_COMPILER_VERSION_TURBOC_NUMBER)], - [dnl TURBOC - AC_COMPUTE_INT( - _ax_[]_AC_LANG_ABBREV[]_compiler_version_turboc_raw, - _AX_COMPILER_VERSION_TURBOC_NUMBER,, - AC_MSG_FAILURE([[[$0]] unknown turboc version])) - AS_IF( - [test $_ax_[]_AC_LANG_ABBREV[]_compiler_version_turboc_raw -lt 661 || test $_ax_[]_AC_LANG_ABBREV[]_compiler_version_turboc_raw -gt 1023], - [dnl compute normal version - AC_COMPUTE_INT( - _ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - _AX_COMPILER_VERSION_TURBOC_NUMBER % 0x100,, - AC_MSG_FAILURE([[[$0]] unknown turboc minor version])) - AC_COMPUTE_INT( - _ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - (_AX_COMPILER_VERSION_TURBOC_NUMBER/0x100)%0x100,, - AC_MSG_FAILURE([[[$0]] unknown turboc major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="0turboc:$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor"], - [dnl special version - AS_CASE([$_ax_[]_AC_LANG_ABBREV[]_compiler_version_turboc_raw], - [661],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="0turboc:1.00"], - [662],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="0turboc:1.01"], - [663],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="0turboc:2.00"], - [ - AC_MSG_WARN([[[$0]] unknown turboc version between 0x295 and 0x400 please report bug]) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="" - ]) - ]) - ], - # borlandc - [ - AC_COMPUTE_INT( - _ax_[]_AC_LANG_ABBREV[]_compiler_version_borlandc_raw, - _AX_COMPILER_VERSION_BORLANDC_NUMBER,, - AC_MSG_FAILURE([[[$0]] unknown borlandc version])) - AS_CASE([$_ax_[]_AC_LANG_ABBREV[]_compiler_version_borlandc_raw], - dnl BORLANC++ before 5.5 - [512] ,[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="1borlanc:2.00"], - [1024],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="1borlanc:3.00"], - [1024],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="1borlanc:3.00"], - [1040],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="1borlanc:3.1"], - [1106],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="1borlanc:4.0"], - [1280],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="1borlanc:5.0"], - [1312],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="1borlanc:5.02"], - dnl C++ Builder era - [1328],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="2cppbuilder:3.0"], - [1344],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="2cppbuilder:4.0"], - dnl BORLANC++ after 5.5 - [1360],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="3borlancpp:5.5"], - [1361],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="3borlancpp:5.51"], - [1378],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="3borlancpp:5.6.4"], - dnl C++ Builder with year number - [1392],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="4cppbuilder:2006"], - [1424],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="4cppbuilder:2007"], - [1555],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="4cppbuilder:2009"], - [1569],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="4cppbuilder:2010"], - dnl XE version - [1584],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="5xe"], - [1600],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="5xe:2"], - [1616],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="5xe:3"], - [1632],[ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="5xe:4"], - [ - AC_MSG_WARN([[[$0]] Unknow borlanc compiler version $_ax_[]_AC_LANG_ABBREV[]_compiler_version_borlandc_raw please report bug]) - ]) - ]) - ]) - -# COMO -AC_DEFUN([_AX_COMPILER_VERSION_COMEAU], - [ dnl - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - [__COMO_VERSION__%100],, - AC_MSG_FAILURE([[[$0]] unknown comeau compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - [(__COMO_VERSION__/100)%10],, - AC_MSG_FAILURE([[[$0]] unknown comeau compiler major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor" - ]) - -# KAI -AC_DEFUN([_AX_COMPILER_VERSION_KAI],[ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [__KCC_VERSION%100],, - AC_MSG_FAILURE([[[$0]] unknown kay compiler patch version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - [(__KCC_VERSION/100)%10],, - AC_MSG_FAILURE([[[$0]] unknown kay compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - [(__KCC_VERSION/1000)%10],, - AC_MSG_FAILURE([[[$0]] unknown kay compiler major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -dnl LCC -dnl LCC does not output version... - -# SGI -AC_DEFUN([_AX_COMPILER_VERSION_SGI],[ - m4_define([_AX_COMPILER_VERSION_SGI_NUMBER], - [ - #if defined(_COMPILER_VERSION) - _COMPILER_VERSION - #else - _SGI_COMPILER_VERSION - #endif - ]) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [_AX_COMPILER_VERSION_SGI_NUMBER%10],, - AC_MSG_FAILURE([[[$0]] unknown SGI compiler patch version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - [(_AX_COMPILER_VERSION_SGI_NUMBER/10)%10],, - AC_MSG_FAILURE([[[$0]] unknown SGI compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - [(_AX_COMPILER_VERSION_SGI_NUMBER/100)%10],, - AC_MSG_FAILURE([[[$0]] unknown SGI compiler major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# microsoft -AC_DEFUN([_AX_COMPILER_VERSION_MICROSOFT],[ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - _MSC_VER%100,, - AC_MSG_FAILURE([[[$0]] unknown microsoft compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - (_MSC_VER/100)%100,, - AC_MSG_FAILURE([[[$0]] unknown microsoft compiler major version])) - dnl could be overriden - _ax_[]_AC_LANG_ABBREV[]_compiler_version_patch=0 - _ax_[]_AC_LANG_ABBREV[]_compiler_version_build=0 - # special case for version 6 - AS_IF([test "X$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major" = "X12"], - [AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - _MSC_FULL_VER%1000,, - _ax_[]_AC_LANG_ABBREV[]_compiler_version_patch=0)]) - # for version 7 - AS_IF([test "X$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major" = "X13"], - [AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - _MSC_FULL_VER%1000,, - AC_MSG_FAILURE([[[$0]] unknown microsoft compiler patch version])) - ]) - # for version > 8 - AS_IF([test $_ax_[]_AC_LANG_ABBREV[]_compiler_version_major -ge 14], - [AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - _MSC_FULL_VER%10000,, - AC_MSG_FAILURE([[[$0]] unknown microsoft compiler patch version])) - ]) - AS_IF([test $_ax_[]_AC_LANG_ABBREV[]_compiler_version_major -ge 15], - [AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_build, - _MSC_BUILD,, - AC_MSG_FAILURE([[[$0]] unknown microsoft compiler build version])) - ]) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_build" - ]) - -# for metrowerks -AC_DEFUN([_AX_COMPILER_VERSION_METROWERKS],[dnl - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - __MWERKS__%0x100,, - AC_MSG_FAILURE([[[$0]] unknown metrowerks compiler patch version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - (__MWERKS__/0x100)%0x10,, - AC_MSG_FAILURE([[[$0]] unknown metrowerks compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - (__MWERKS__/0x1000)%0x10,, - AC_MSG_FAILURE([[[$0]] unknown metrowerks compiler major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# for watcom -AC_DEFUN([_AX_COMPILER_VERSION_WATCOM],[dnl - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - __WATCOMC__%100,, - AC_MSG_FAILURE([[[$0]] unknown watcom compiler minor version])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - (__WATCOMC__/100)%100,, - AC_MSG_FAILURE([[[$0]] unknown watcom compiler major version])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor" - ]) - -# for PGI -AC_DEFUN([_AX_COMPILER_VERSION_PORTLAND],[ - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_major, - __PGIC__,, - AC_MSG_FAILURE([[[$0]] unknown pgi major])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor, - __PGIC_MINOR__,, - AC_MSG_FAILURE([[[$0]] unknown pgi minor])) - AC_COMPUTE_INT(_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch, - [__PGIC_PATCHLEVEL__],, - AC_MSG_FAILURE([[[$0]] unknown pgi patch level])) - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version="$_ax_[]_AC_LANG_ABBREV[]_compiler_version_major.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_minor.$_ax_[]_AC_LANG_ABBREV[]_compiler_version_patch" - ]) - -# tcc -AC_DEFUN([_AX_COMPILER_VERSION_TCC],[ - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version=[`tcc -v | $SED 's/^[ ]*tcc[ ]\+version[ ]\+\([0-9.]\+\).*/\1/g'`] - ]) -# main entry point -AC_DEFUN([AX_COMPILER_VERSION],[dnl - AC_REQUIRE([AX_COMPILER_VENDOR]) - AC_REQUIRE([AC_PROG_SED]) - AC_CACHE_CHECK([for _AC_LANG compiler version], - ax_cv_[]_AC_LANG_ABBREV[]_compiler_version, - [ dnl - AS_CASE([$ax_cv_[]_AC_LANG_ABBREV[]_compiler_vendor], - [intel],[_AX_COMPILER_VERSION_INTEL], - [ibm],[_AX_COMPILER_VERSION_IBM], - [pathscale],[_AX_COMPILER_VERSION_PATHSCALE], - [clang],[_AX_COMPILER_VERSION_CLANG], - [cray],[_AX_COMPILER_VERSION_CRAY], - [fujitsu],[_AX_COMPILER_VERSION_FUJITSU], - [gnu],[_AX_COMPILER_VERSION_GNU], - [sun],[_AX_COMPILER_VERSION_SUN], - [hp],[_AX_COMPILER_VERSION_HP], - [dec],[_AX_COMPILER_VERSION_DEC], - [borland],[_AX_COMPILER_VERSION_BORLAND], - [comeau],[_AX_COMPILER_VERSION_COMEAU], - [kai],[_AX_COMPILER_VERSION_KAI], - [sgi],[_AX_COMPILER_VERSION_SGI], - [microsoft],[_AX_COMPILER_VERSION_MICROSOFT], - [metrowerks],[_AX_COMPILER_VERSION_METROWERKS], - [watcom],[_AX_COMPILER_VERSION_WATCOM], - [portland],[_AX_COMPILER_VERSION_PORTLAND], - [tcc],[_AX_COMPILER_VERSION_TCC], - [ax_cv_[]_AC_LANG_ABBREV[]_compiler_version=""]) - ]) -]) diff --git a/m4/ax_reconfigure_targets.m4 b/m4/ax_reconfigure_targets.m4 deleted file mode 100644 index ef6a04a77c..0000000000 --- a/m4/ax_reconfigure_targets.m4 +++ /dev/null @@ -1,117 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_reconfigure_targets.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_RECONFIGURE_TARGETS() -# -# USAGE -# Add @AX_RECONFIGURE_TARGET@ in Makefile.in after standard directories definition -# -# DESCRIPTION -# Add auto reconfigure targets that trigger a reconfigure action upon changes on -# config.status file and configure script itself. This emulate the Automake config -# behavior also in pure autoconf Makefiles. -# IMPORTANT NOTE: -# The implementation needs the srcdir, builddir, top_srcdir etc ... to be set -# before the @AX_RECONFIGURE_TARGET@ call in any Makefile.in -# -# LICENSE -# -# Copyright (c) 2016 Andrea Rigoni Garola -# -# 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 3 of the License, 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 1 - -AC_DEFUN([AX_RECONFIGURE_TARGETS],[ - AC_PUSH_LOCAL([ax_reconifgure_targets]) - AC_ARG_ENABLE(reconfigure, [AS_HELP_STRING([--disable-reconfigure],[disable reconfigure targets for autoconf])]) - AS_IF([test -z "${enable_reconfigure}"], [AS_VAR_SET([enable_reconfigure],[yes])]) - AS_VAR_IF([enable_reconfigure],[yes],[ - SET_RECONFIGURE_TARGET - ]) - AC_POP_LOCAL([ax_reconifgure_targets]) -]) - - - - - -AC_DEFUN_LOCAL([ax_reconifgure_targets],[SET_RECONFIGURE_TARGET],[ -AS_VAR_READ([AX_RECONFIGURE_TARGET],[ - -# trigger reconfigure if config.status has been touched -Makefile: \$(srcdir)/Makefile.in \$(top_builddir)/config.status - cd '\$(top_builddir)' && \$(SHELL) ./config.status; - -# trigger reconfigure at configure changes -\$(top_builddir)/config.status: \$(top_srcdir)/configure - \$(info -------------------------------------------------------------------------------------)\ - \$(info INFO: A reconfigure is needed because the configure does not match with config.status)\ - \$(info -------------------------------------------------------------------------------------)\ - cd '\$(top_builddir)' && \$(SHELL) ./config.status --recheck; - -]) -AC_SUBST([AX_RECONFIGURE_TARGET]) -m4_ifdef([AM_SUBST_NOTMAKE], [AM_SUBST_NOTMAKE([AX_RECONFIGURE_TARGET])]) -]) - - - - - - - - - - - - - - - - - -dnl //////////////////////////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// -dnl // Utility functions - -AC_DEFUN_LOCAL([ax_reconifgure_targets],[AS_BANNER],[ - AS_ECHO - AS_BOX([// $1 //////], [\/]) - AS_ECHO - ]) - - -AC_DEFUN_LOCAL([ax_reconifgure_targets],[AS_VAR_READ],[ -read -d '' $1 << _as_read_EOF -$2 -_as_read_EOF -]) diff --git a/m4/ax_target_selfhelp.m4 b/m4/ax_target_selfhelp.m4 deleted file mode 100644 index 3b10463723..0000000000 --- a/m4/ax_target_selfhelp.m4 +++ /dev/null @@ -1,137 +0,0 @@ -## ////////////////////////////////////////////////////////////////////////// // -## -## This file is part of the autoconf-bootstrap project. -## Copyright 2018 Andrea Rigoni Garola . -## -## 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 3 of the License, 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, see . -## -## ////////////////////////////////////////////////////////////////////////// // - - - - -AC_DEFUN([AX_TARGET_SELFHELP],[ - AC_PUSH_LOCAL([ax_target_selfhelp]) - SET_SELFHELP([uno],[due]) - AC_POP_LOCAL([ax_target_selfhelp]) -]) - -AC_DEFUN_LOCAL([ax_target_selfhelp],[SET_SELFHELP],[ -AS_VAR_READ([TARGET_SELFHELP],[ - -SH_GREEN ?= \$(shell tput -Txterm setaf 2) -SH_WHITE ?= \$(shell tput -Txterm setaf 7) -SH_YELLOW ?= \$(shell tput -Txterm setaf 3) -SH_RESET ?= \$(shell tput -Txterm sgr0) - -HELP_DESCRIPTION ?= Documented targets follow - -ifndef SELFHELP_FUNC -SELFHELP_FUNC = \\\\ - %help; \\\\ - while(<>) { \\\\ - if(/^([[a-zA-Z0-9_\\\\-\\\\.]]+):.*\\\\[#]\\\\[#](?:@(\\\\w+))?\\\\s(.*)\$\$/) { \\\\ - push(@{\$\$help{\$\$[2]}}, @<:@\$\$[1], \$\$[3]@:>@); \\\\ - } \\\\ - }; \\\\ - print "\\\\n"; \\\\ - print "| \${HELP_DESCRIPTION}\\\\n"; \\\\ - print "| \\\\n"; \\\\ - print "| \${SH_GREEN}usage: make [target]\${SH_RESET}\\\\n"; \\\\ - print "| \\\\n"; \\\\ - for ( sort keys %help ) { \\\\ - print "| \${SH_YELLOW}\$\$_\${SH_RESET}:\\\\n"; \\\\ - printf("| %-20s %-60s\\\\n", \$\$_->[[0]], \$\$_->[[1]]) for @{\$\$help{\$\$_}}; \\\\ - print "| \\\\n"; \\\\ - } \\\\ - print "\\\\n"; - -SELFHELP_ADVANCED_FUNC = \\\\ - %help; \\\\ - while(<>) { \\\\ - if(/^([[a-zA-Z0-9_\\\\-\\\\.]]+):.*\\\\[#]\\\\[#](?:@(\\\\w+))?\\\\s(.*)\$\$/) { \\\\ - push(@{\$\$help{\$\$[2]}}, @<:@\$\$[1], \$\$[3]@:>@); \\\\ - } \\\\ - if(/^([[a-zA-Z0-9_\\\\-\\\\.]]+):.*\\\\[#]\\\\[#](?:@@(\\\\w+))?\\\\s(.*)\$\$/) { \\\\ - push(@{\$\$help{\$\$[2]}}, @<:@\$\$[1], \$\$[3]@:>@); \\\\ - } \\\\ - }; \\\\ - print "\\\\n"; \\\\ - print ", \${SH_GREEN}ADVANCED TARGETS \${SH_RESET}\\\\n"; \\\\ - print "| \\\\n"; \\\\ - for ( sort keys %help ) { \\\\ - print "| \${SH_YELLOW}\$\$_\${SH_RESET}:\\\\n"; \\\\ - printf("| %-20s %-60s\\\\n", \$\$_->[[0]], \$\$_->[[1]]) for @{\$\$help{\$\$_}}; \\\\ - print "| \\\\n"; \\\\ - } \\\\ - print "\\\\n"; - -SELFHELP_PRINT_TARGET_LIST_FUNC = \\\\ - %help; \\\\ - while(<>) { \\\\ - if(/^([[a-zA-Z0-9_\\\\-\\\\.]]+):.*\\\\[#]\\\\[#](?:@(\\\\w+))?\\\\s(.*)\$\$/) { \\\\ - push(@{\$\$help{\$\$[2]}}, @<:@\$\$[1], \$\$[3]@:>@); } \\\\ - if(/^([[a-zA-Z0-9_\\\\-\\\\.]]+):.*\\\\[#]\\\\[#](?:@@(\\\\w+))?\\\\s(.*)\$\$/) { \\\\ - push(@{\$\$help{\$\$[2]}}, @<:@\$\$[1], \$\$[3]@:>@); } \\\\ - }; \\\\ - for ( sort keys %help ) { \\\\ - printf("%s ", \$\$_->[[0]]) for @{\$\$help{\$\$_}}; \\\\ - } \\\\ - -SELFHELP_TARGETS = \$(shell perl -e '\$(SELFHELP_PRINT_TARGET_LIST_FUNC)' \$(MAKEFILE_LIST)) - -help: ##@miscellaneous Show this help. -help-more: ##@miscellaneous get help on advanced targets. -help-targets: ##@@miscellaneous get list of target with help signature - -help-targets: - @ \$(info \$(SELFHELP_TARGETS)):; - -help: - @perl -e '\$(SELFHELP_FUNC)' \$(MAKEFILE_LIST) - -help-more: - @perl -e '\$(SELFHELP_ADVANCED_FUNC)' \$(MAKEFILE_LIST) - -endif - -]) - AC_SUBST([TARGET_SELFHELP]) - m4_ifdef([AM_SUBST_NOTMAKE], [AM_SUBST_NOTMAKE([TARGET_SELFHELP])]) -]) - - - -AC_DEFUN_LOCAL([ax_target_selfhelp],[AS_VAR_READ],[ -read -d '' $1 << _as_read_EOF -$2 -_as_read_EOF -]) - - - - -dnl SELFHELP_FUNC = \ -dnl %help; \ -dnl while(<>) { \ -dnl if(/^([a-z0-9_-]+):.*\#\#(?:@(\w+))?\s(.*)$$/) { \ -dnl push(@{$$help{$$2}}, [$$1, $$3]); \ -dnl } \ -dnl }; \ -dnl print "${GREEN}usage: make [target]${WHITE}\n\n"; \ -dnl for ( sort keys %help ) { \ -dnl print "${YELLOW}$$_${WHITE}:\n"; \ -dnl printf(" %-20s %s\n", $$_->[0], $$_->[1]) for @{$$help{$$_}}; \ -dnl print "\n"; \ -dnl } diff --git a/m4/m4_ac_search_readline.m4 b/m4/m4_ac_search_readline.m4 deleted file mode 100644 index b73460017a..0000000000 --- a/m4/m4_ac_search_readline.m4 +++ /dev/null @@ -1,102 +0,0 @@ -dnl // Search macro for libreadline // -dnl -dnl usage: -dnl AC_SEARCH_READLINE([RL]) -dnl AM_CONDITIONAL(RL, test x"$have_readline" = x"yes") -dnl -dnl The --with-readline option is added in configure that scans also for the -dnl presence of READLINE_DIR environment variable. -dnl This defines the following variables to be added in compilation lines: -dnl RL_CPPFLAGS, RL_LDFLAGS, RL_LIBS -dnl - - -AC_DEFUN([AC_SEARCH_READLINE], -[ - AC_ARG_WITH([readline], - AC_HELP_STRING([--with-readline=READLINE_DIR], [look for the readline library in READLINE_DIR]), - [], - [AS_VAR_SET_IF([READLINE_DIR], - [AS_VAR_SET([with_readline], [$READLINE_DIR])],[])]) - - if test x"$with_readline" != x"no" ; then - if test -d "${with_readline}" ; then - _readline_cppflags="-I${with_readline}/include" - _readline_ldflags="-L${with_readline}/lib" - fi - - dnl // search for all possible terminal combinations // - for _termcap in "" "-ltermcap" "-lcurses" "-lncurses" ; do - _combo="readline${_termcap:+ $_termcap}" - - LIBS_save=$LIBS - CPPFLAGS_save=$CPPFLAGS - LDFLAGS_save=$LDFLAGS - - dnl // setting test program flags // - LIBS="-l$_combo $LIBS" - CPPFLAGS="${_readline_cppflags} $CPPFLAGS $TARGET_ARCH" - LDFLAGS="${_readline_ldflags} $LDFLAGS $TARGET_ARCH" - - AC_MSG_CHECKING([whether readline via "$_combo" is present and sane]) - dnl //////////////////////////////////////////////////////////////////// - dnl // test program source //////////////////////////////////////////// - dnl //////////////////////////////////////////////////////////////////// - AC_TRY_RUN( - AC_LANG_SOURCE([[ -//////////////////////////////////////////////////////////////////////////////// -//////////////////////////////////////////////////////////////////////////////// -#include -#include -#include -#include -#include -#include -int main(int argc, char **argv) -{ - int fd; - char *line; - close(0); - close(1); - fd = open("/dev/null", 2); - dup(fd); - line = readline("giveittome> "); - printf("got <%s>\n", line); - return 0; - } -//////////////////////////////////////////////////////////////////////////////// - ]]), - dnl action if true: - [have_readline=yes], - dnl action if false: - [have_readline=no], - dnl action if cross compiling: - dnl If cross compilation is done the configure is not able to run the test - AC_SEARCH_LIBS([readline],[$_combo],[have_readline=yes],[have_readline=no]) - ) dnl AC_TRY_RUN - - AC_MSG_RESULT([$have_readline]) - - dnl restore LIBS - LIBS=$LIBS_save - CPPFLAGS=$CPPFLAGS_save - LDFLAGS=$LDFLAGS_save - - if test $have_readline = yes ; then - AC_SUBST($1[]_CPPFLAGS,"$_readline_cppflags") - AC_SUBST($1[]_LDFLAGS, "$_readline_ldflags") - AC_SUBST($1[]_LIBS,"-l$_combo") - break - fi - done - dnl end for - - - unset _termcap - unset LIBS_save - unset CPPFLAGS_save - unset LDFLAGS_save - unset _combo - fi -]) - diff --git a/m4/m4_am_path_xml2.m4 b/m4/m4_am_path_xml2.m4 deleted file mode 100644 index 9342ebdd4d..0000000000 --- a/m4/m4_am_path_xml2.m4 +++ /dev/null @@ -1,188 +0,0 @@ -# Configure paths for LIBXML2 -# Mike Hommey 2004-06-19 -# use CPPFLAGS instead of CFLAGS -# Toshio Kuratomi 2001-04-21 -# Adapted from: -# Configure paths for GLIB -# Owen Taylor 97-11-3 - -dnl AM_PATH_XML2([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) -dnl Test for XML, and define XML_CPPFLAGS and XML_LIBS -dnl -AC_DEFUN([AM_PATH_XML2],[ -AC_ARG_WITH(xml-prefix, - [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], - xml_config_prefix="$withval", xml_config_prefix="") -AC_ARG_WITH(xml-exec-prefix, - [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], - xml_config_exec_prefix="$withval", xml_config_exec_prefix="") -AC_ARG_ENABLE(xmltest, - [ --disable-xmltest Do not try to compile and run a test LIBXML program],, - enable_xmltest=yes) - - if test x$xml_config_exec_prefix != x ; then - xml_config_args="$xml_config_args" - if test x${XML2_CONFIG+set} != xset ; then - XML2_CONFIG=$xml_config_exec_prefix/bin/xml2-config - fi - fi - if test x$xml_config_prefix != x ; then - xml_config_args="$xml_config_args --prefix=$xml_config_prefix" - if test x${XML2_CONFIG+set} != xset ; then - XML2_CONFIG=$xml_config_prefix/bin/xml2-config - fi - fi - - AC_PATH_PROG(XML2_CONFIG, xml2-config, no) - min_xml_version=ifelse([$1], ,2.0.0,[$1]) - AC_MSG_CHECKING(for libxml - version >= $min_xml_version) - no_xml="" - if test "$XML2_CONFIG" = "no" ; then - no_xml=yes - else - XML_CPPFLAGS=`$XML2_CONFIG $xml_config_args --cflags` - XML_LIBS=`$XML2_CONFIG $xml_config_args --libs` - xml_config_major_version=`$XML2_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - xml_config_minor_version=`$XML2_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` - xml_config_micro_version=`$XML2_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` - if test "x$enable_xmltest" = "xyes" ; then - ac_save_CPPFLAGS="$CPPFLAGS" - ac_save_LIBS="$LIBS" - CPPFLAGS="$XML_CPPFLAGS $CPPFLAGS $TARGET_ARCH" - LIBS="$XML_LIBS $LIBS" -dnl -dnl Now check if the installed libxml is sufficiently new. -dnl (Also sanity checks the results of xml2-config to some extent) -dnl - rm -f conf.xmltest - AC_TRY_RUN([ -#include -#include -#include -#include - -int -main() -{ - int xml_major_version, xml_minor_version, xml_micro_version; - int major, minor, micro; - char *tmp_version; - - system("touch conf.xmltest"); - - /* Capture xml2-config output via autoconf/configure variables */ - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = (char *)strdup("$min_xml_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string from xml2-config\n", "$min_xml_version"); - exit(1); - } - free(tmp_version); - - /* Capture the version information from the header files */ - tmp_version = (char *)strdup(LIBXML_DOTTED_VERSION); - if (sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) { - printf("%s, bad version string from libxml includes\n", "LIBXML_DOTTED_VERSION"); - exit(1); - } - free(tmp_version); - - /* Compare xml2-config output to the libxml headers */ - if ((xml_major_version != $xml_config_major_version) || - (xml_minor_version != $xml_config_minor_version) || - (xml_micro_version != $xml_config_micro_version)) - { - printf("*** libxml header files (version %d.%d.%d) do not match\n", - xml_major_version, xml_minor_version, xml_micro_version); - printf("*** xml2-config (version %d.%d.%d)\n", - $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); - return 1; - } -/* Compare the headers to the library to make sure we match */ - /* Less than ideal -- doesn't provide us with return value feedback, - * only exits if there's a serious mismatch between header and library. - */ - LIBXML_TEST_VERSION; - - /* Test that the library is greater than our minimum version */ - if ((xml_major_version > major) || - ((xml_major_version == major) && (xml_minor_version > minor)) || - ((xml_major_version == major) && (xml_minor_version == minor) && - (xml_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", - xml_major_version, xml_minor_version, xml_micro_version); - printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", - major, minor, micro); - printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); - printf("***\n"); - printf("*** If you have already installed a sufficiently new version, this error\n"); - printf("*** probably means that the wrong copy of the xml2-config shell script is\n"); - printf("*** being found. The easiest way to fix this is to remove the old version\n"); - printf("*** of LIBXML, but you can also set the XML2_CONFIG environment to point to the\n"); - printf("*** correct copy of xml2-config. (In this case, you will have to\n"); - printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); - printf("*** so that the correct libraries are found at run-time))\n"); - } - return 1; -} -],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) - CPPFLAGS="$ac_save_CPPFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - if test "x$no_xml" = x ; then - AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) - ifelse([$2], , :, [$2]) - else - AC_MSG_RESULT(no) - if test "$XML2_CONFIG" = "no" ; then - echo "*** The xml2-config script installed by LIBXML could not be found" - echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" - echo "*** your path, or set the XML2_CONFIG environment variable to the" - echo "*** full path to xml2-config." - else - if test -f conf.xmltest ; then - : - else - echo "*** Could not run libxml test program, checking why..." - CPPFLAGS="$CPPFLAGS $XML_CPPFLAGS" - LIBS="$LIBS $XML_LIBS" - AC_TRY_LINK([ -#include -#include -], [ LIBXML_TEST_VERSION; return 0;], - [ echo "*** The test program compiled, but did not run. This usually means" - echo "*** that the run-time linker is not finding LIBXML or finding the wrong" - echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" - echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" - echo "*** to the installed location Also, make sure you have run ldconfig if that" - echo "*** is required on your system" - echo "***" - echo "*** If you have an old version installed, it is best to remove it, although" - echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], - [ echo "*** The test program failed to compile or link. See the file config.log for the" - echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" - echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" - echo "*** may want to edit the xml2-config script: $XML2_CONFIG" ]) - CPPFLAGS="$ac_save_CPPFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - XML_CPPFLAGS="" - XML_LIBS="" - ifelse([$3], , :, [$3]) - fi - AC_SUBST(XML_CPPFLAGS) - AC_SUBST(XML_LIBS) - rm -f conf.xmltest -]) diff --git a/m4/m4_ax_c_flags.m4 b/m4/m4_ax_c_flags.m4 deleted file mode 100644 index 850a73bc34..0000000000 --- a/m4/m4_ax_c_flags.m4 +++ /dev/null @@ -1,21 +0,0 @@ -# -# SYNOPSIS -# -# AX_C_FLAGS([C variable name]) -# -# DESCRIPTION -# - -# AX_C_FLAGS([C variable name]) -# -AC_DEFUN([AX_C_FLAGS],[ - AX_COMPILER_VERSION - - if [ test x"$GCC" = x"yes" ]; then - # GCC 12+ triggers a lot of false-positives - AX_COMPARE_VERSION([${ax_cv_c_compiler_version}], [ge], [12.0.0], - [AS_VAR_SET([_c_cxx_flags_fix],["-Wno-strict-aliasing -Wno-uninitialized -Wno-clobbered -Wno-stringop-overflow -Wno-array-bounds -Wno-use-after-free -Wno-nonnull"])]) - AS_VAR_APPEND([$1],[" ${_c_cxx_flags_fix}"]) - fi -]) - diff --git a/m4/m4_ax_check_enable_debug.m4 b/m4/m4_ax_check_enable_debug.m4 deleted file mode 100644 index 5122401bf6..0000000000 --- a/m4/m4_ax_check_enable_debug.m4 +++ /dev/null @@ -1,126 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_check_enable_debug.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_CHECK_ENABLE_DEBUG([enable by default=yes/info/profile/no], [ENABLE DEBUG VARIABLES ...], [DISABLE DEBUG VARIABLES NDEBUG ...], [IS-RELEASE]) -# -# DESCRIPTION -# -# Check for the presence of an --enable-debug option to configure, with -# the specified default value used when the option is not present. Return -# the value in the variable $ax_enable_debug. -# -# Specifying 'yes' adds '-g -O0' to the compilation flags for all -# languages. Specifying 'info' adds '-g' to the compilation flags. -# Specifying 'profile' adds '-g -pg' to the compilation flags and '-pg' to -# the linking flags. Otherwise, nothing is added. -# -# Define the variables listed in the second argument if debug is enabled, -# defaulting to no variables. Defines the variables listed in the third -# argument if debug is disabled, defaulting to NDEBUG. All lists of -# variables should be space-separated. -# -# If debug is not enabled, ensure AC_PROG_* will not add debugging flags. -# Should be invoked prior to any AC_PROG_* compiler checks. -# -# IS-RELEASE can be used to change the default to 'no' when making a -# release. Set IS-RELEASE to 'yes' or 'no' as appropriate. By default, it -# uses the value of $ax_is_release, so if you are using the AX_IS_RELEASE -# macro, there is no need to pass this parameter. -# -# AX_IS_RELEASE([git-directory]) -# AX_CHECK_ENABLE_DEBUG() -# -# LICENSE -# -# Copyright (c) 2011 Rhys Ulerich -# Copyright (c) 2014, 2015 Philip Withnall -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. - -#serial 5 - -AC_DEFUN([AX_CHECK_ENABLE_DEBUG],[ - AC_BEFORE([$0],[AC_PROG_CC])dnl - AC_BEFORE([$0],[AC_PROG_CXX])dnl - AC_BEFORE([$0],[AC_PROG_F77])dnl - AC_BEFORE([$0],[AC_PROG_FC])dnl - - AC_MSG_CHECKING(whether to enable debugging) - - ax_enable_debug_default=m4_tolower(m4_normalize(ifelse([$1],,[no],[$1]))) - ax_enable_debug_is_release=m4_tolower(m4_normalize(ifelse([$4],, - [$ax_is_release], - [$4]))) - - # If this is a release, override the default. - AS_IF([test "$ax_enable_debug_is_release" = "yes"], - [ax_enable_debug_default="no"]) - - m4_define(ax_enable_debug_vars,[m4_normalize(ifelse([$2],,,[$2]))]) - m4_define(ax_disable_debug_vars,[m4_normalize(ifelse([$3],,[NDEBUG],[$3]))]) - - AC_ARG_ENABLE(debug, - [AS_HELP_STRING([--enable-debug=]@<:@yes/info/profile/no@:>@,[compile with debugging])], - [],enable_debug=$ax_enable_debug_default) - - # empty mean debug yes - AS_IF([test "x$enable_debug" = "x"], - [enable_debug="yes"]) - - # case of debug - AS_CASE([$enable_debug], - [yes],[ - AC_MSG_RESULT(yes) - CFLAGS="${CFLAGS} -g -DWITH_DEBUG_SYMBOLS -O0" - CXXFLAGS="${CXXFLAGS} -g -DWITH_DEBUG_SYMBOLS -O0" - FCFLAGS="${FCFLAGS} -g -O0" - OBJCFLAGS="${OBJCFLAGS} -g -O0" - ], - [define],[ - AC_MSG_RESULT(yes) - CFLAGS="${CFLAGS} -g -O0 -DDEBUG -DWITH_DEBUG_SYMBOLS " - CXXFLAGS="${CXXFLAGS} -g -O0 -DDEBUG -DWITH_DEBUG_SYMBOLS " - FCFLAGS="${FCFLAGS} -g -O0" - OBJCFLAGS="${OBJCFLAGS} -g -O0" - ], - [info],[ - AC_MSG_RESULT(info) - CFLAGS="${CFLAGS} -g -DWITH_DEBUG_SYMBOLS $5" - CXXFLAGS="${CXXFLAGS} -g -DWITH_DEBUG_SYMBOLS $5" - FCFLAGS="${FCFLAGS} -g $5" - OBJCFLAGS="${OBJCFLAGS} -g $5" - ], - [profile],[ - AC_MSG_RESULT(profile) - CFLAGS="${CFLAGS} -g -pg -DWITH_DEBUG_SYMBOLS $5" - CXXFLAGS="${CXXFLAGS} -g -pg -DWITH_DEBUG_SYMBOLS $5" - FCFLAGS="${FCFLAGS} -g -pg $5" - OBJCFLAGS="${OBJCFLAGS} -g -pg $5" - LDFLAGS="${LDFLAGS} -pg $5" - ], - [ - AC_MSG_RESULT(no) - dnl Ensure AC_PROG_CC/CXX/F77/FC/OBJC will not enable debug flags - dnl by setting any unset environment flag variables - AS_IF([test "x${CFLAGS+set}" != "xset"], - [CFLAGS="$5"]) - AS_IF([test "x${CXXFLAGS+set}" != "xset"], - [CXXFLAGS="$5"]) - AS_IF([test "x${FCFLAGS+set}" != "xset"], - [FCFLAGS="$5"]) - AS_IF([test "x${OBJCFLAGS+set}" != "xset"], - [OBJCFLAGS="$5"]) - ]) - - dnl Define various variables if debugging is disabled. - dnl assert.h is a NOP if NDEBUG is defined, so define it by default. - AS_IF([test "x$enable_debug" = "xyes"], - [m4_map_args_w(ax_enable_debug_vars, [AC_DEFINE(], [,,[Define if debugging is enabled])])], - [m4_map_args_w(ax_disable_debug_vars, [AC_DEFINE(], [,,[Define if debugging is disabled])])]) - ax_enable_debug=$enable_debug -]) diff --git a/m4/m4_ax_check_java_version.m4 b/m4/m4_ax_check_java_version.m4 deleted file mode 100644 index a6ce3d9f5e..0000000000 --- a/m4/m4_ax_check_java_version.m4 +++ /dev/null @@ -1,15 +0,0 @@ -# -# SYNOPSIS -# -# AX_CHECK_JAVA_VERSION(min_version,ifok,ifnotok) -# -# DESCRIPTION -# -# Checks for java with at least the given version. -# - -AC_DEFUN([AX_CHECK_JAVA_VERSION], [ - AC_MSG_CHECKING([for version $1 or higher of java]) - version=`java -version 2>&1|head -n 1|grep -oe '[[0-9]]*\.[[0-9]]*\.[[0-9]]*'||echo 1.5` - AX_COMPARE_VERSION([$version], [ge], [$1], [AC_MSG_RESULT([yes]);$2], [AC_MSG_RESULT([no]);$3]) -]) diff --git a/m4/m4_ax_configure_args.m4 b/m4/m4_ax_configure_args.m4 deleted file mode 100644 index 0726b1bc8a..0000000000 --- a/m4/m4_ax_configure_args.m4 +++ /dev/null @@ -1,70 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_configure_args.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_CONFIGURE_ARGS -# -# DESCRIPTION -# -# Helper macro for AX_ENABLE_BUILDDIR. -# -# The traditional way of starting a subdir-configure is running the script -# with ${1+"$@"} but since autoconf 2.60 this is broken. Instead we have -# to rely on eval'ing $ac_configure_args however some old autoconf -# versions do not provide that. To ensure maximum portability of autoconf -# extension macros this helper can be AC_REQUIRE'd so that -# $ac_configure_args will alsways be present. -# -# Sadly, the traditional "exec $SHELL" of the enable_builddir macros is -# spoiled now and must be replaced by "eval + exit $?". -# -# Example: -# -# AC_DEFUN([AX_ENABLE_SUBDIR],[dnl -# AC_REQUIRE([AX_CONFIGURE_ARGS])dnl -# eval $SHELL $ac_configure_args || exit $? -# ...]) -# -# LICENSE -# -# Copyright (c) 2008 Guido U. Draheim -# -# 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 3 of the License, 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 9 - -AC_DEFUN([AX_CONFIGURE_ARGS],[ - # [$]@ is unsable in 2.60+ but earlier autoconf had no ac_configure_args - if test "${ac_configure_args+set}" != "set" ; then - ac_configure_args= - for ac_arg in ${1+"[$]@"}; do - ac_configure_args="$ac_configure_args '$ac_arg'" - done - fi -]) diff --git a/m4/m4_ax_docker_build.m4 b/m4/m4_ax_docker_build.m4 deleted file mode 100644 index 34c4e7e88a..0000000000 --- a/m4/m4_ax_docker_build.m4 +++ /dev/null @@ -1,614 +0,0 @@ -# =========================================================================== -# https://www.gnu.org/software/autoconf-archive/ax_docker_build.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_DOCKER_BUILD() -# -# DESCRIPTION -# -# This macro starts a docker container and runs configure inside, it also -# defines a dshell script that can be used by make to enter the running -# container performing target compilation inside. A set of targets and -# definitions are substituted in Makefile by the @AX_DOCKER_BUILD_TARGETS@ -# symbol. -# -# LICENSE -# -# Copyright (c) 2016 Andrea Rigoni Garola -# -# 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 3 of the License, 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 1 - -AC_DEFUN([AX_DOCKER_BUILD],[ - AC_PUSH_LOCAL([m4_ax_docker_build]) - - AS_VAR_SET_IF([HAVE_DOCKER],, - [AC_CHECK_PROG([HAVE_DOCKER],[docker],[yes],[no])]) - - AC_ARG_WITH(docker-image, - [AS_HELP_STRING([--with-docker-image],[specify docker images])], - [], - [AS_VAR_SET_IF([DOCKER_IMAGE], - [AS_VAR_SET([with_docker_image], ["${DOCKER_IMAGE}"])], - [])]) - AS_VAR_SET_IF([with_docker_image], - AS_IF( [test x"${with_docker_image}" != x"no"], - [AS_VAR_SET([DOCKER_IMAGE],["${with_docker_image}"])], - [AS_UNSET([DOCKER_IMAGE])] - )) - - AC_ARG_WITH(docker-container, - [AS_HELP_STRING([--with-docker-container],[specify docker container])], - [], - [AS_VAR_SET_IF([DOCKER_CONTAINER], - [AS_VAR_SET([with_docker_container], ["${DOCKER_CONTAINER}"])], - [])]) - AS_VAR_SET_IF([with_docker_container], - AS_IF( [test x"${with_docker_container}" != x"no"], - [AS_VAR_SET([DOCKER_CONTAINER],["${with_docker_container}"])], - [AS_UNSET([DOCKER_CONTAINER])] - )) - - AC_ARG_WITH(docker-url, - [AS_HELP_STRING([--with-docker-url],[specify docker url])], - [], - [AS_VAR_SET_IF([DOCKER_URL], - [AS_VAR_SET([with_docker_url], ["${DOCKER_URL}"])], - [])]) - AS_VAR_SET_IF([with_docker_url],[ - AS_IF( [test x"${with_docker_url}" != x"no"], - [AS_VAR_SET([DOCKER_URL],["${with_docker_url}"])], - [AS_UNSET([DOCKER_URL])] - )]) - - - - AC_ARG_WITH(docker-profile, - [AS_HELP_STRING([--with-docker-profile],[specify docker profile])], - [], - [AS_VAR_SET_IF([DOCKER_PROFILE], - [AS_VAR_SET([with_docker_profile], ["${DOCKER_PROFILE}"])], - [])]) - AC_ARG_ENABLE(debug) - AS_VAR_SET_IF([enable_debug],[ - AS_VAR_IF([enable_debug],[no],,[ - AS_VAR_SET_IF([with_docker_profile],,[ - AS_VAR_IF([enable_debug],[yes],AS_VAR_SET([with_docker_profile],[debug]), - AS_VAR_SET([with_docker_profile],[${enable_debug}]))]) - ])]) - AS_VAR_SET_IF([with_docker_profile],[ - AS_IF( [test x"${with_docker_profile}" != x"no"], - [AS_VAR_SET([DOCKER_PROFILE],["${with_docker_profile}"])], - [AS_UNSET([DOCKER_PROFILE])] - )]) - - - AS_VAR_IF([HAVE_DOCKER],[yes], [ - AS_VAR_SET_IF([DOCKER_URL], - [AS_BANNER(["BUILDING IMAGE FOR URL: ${DOCKER_URL}"]) - DK_SET_DOCKER_IMAGE - DK_START_URL(${DOCKER_URL},${DOCKER_IMAGE})]) - - AS_VAR_SET_IF([DOCKER_IMAGE], - [AS_BANNER(["STARTING CONTAINER IN DOCKER IMAGE: ${DOCKER_IMAGE}"]) - DK_START_IMGCNT(${DOCKER_IMAGE})], - [AS_VAR_SET_IF([DOCKER_CONTAINER], - [AS_BANNER(["STARTING CONTAINER: ${DOCKER_CONTAINER}"]) - DK_START_CNT(${DOCKER_CONTAINER})]) - ]) - - AS_VAR_SET_IF([DOCKER_CONTAINER],[ - dk_set_user_env - DK_WRITE_DSHELLFILE - DK_SET_TARGETS - ]) - - AS_VAR_SET_IF([DOCKER_CONTAINER],[ - AS_BANNER(["EXECUTING CONFIGURE IN DOCKER CONTAINER: ${DOCKER_CONTAINER}"]) - _dk_set_docker_build_debug - - dk_set_user_env - DK_WRITE_DSHELLFILE - dnl execute bootstrap in container - AS_IF([test -n "$1"], - [AS_ECHO("Docker config - performing autogen: cd ${srcdir} && ./$1")] - [$(cd ${srcdir} && ./$1)]) - dnl configure in container - DK_CONFIGURE - dnl and exit - exit 0; - ]) - ],[ - AS_VAR_SET_IF([DOCKER_CONTAINER],[ - dk_set_user_env - DK_SET_TARGETS - ]) - ]) - - AC_POP_LOCAL([m4_ax_docker_build]) -]) - - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_GET_CONFIGURE_ARGS],[ -AX_CONFIGURE_ARGS -push_IFS(["'"]) - for x in ${ac_configure_args}; do - # try to figure out if quoting was required for the $x - AS_IF([test "$x" == " "],,[ - AS_IF([test "$x" != "${x%%=*}"], - [AS_VAR_SET([x],[${x%%=*}"=\""${x#*=}"\""])], - [AS_IF([test "$x" != "${x%\[\[:space:\]\]*}"], - [AS_VAR_SET([x],["\""$x"\""])], - [AS_VAR_SET([x],["$x"])]) - ]) - AS_VAR_SET([$1],["$$1 '$x'"]) - ]) - done -pop_IFS -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_GET_CONFIGURE_ARGS_WITHOUT_DOCKER],[ -DK_GET_CONFIGURE_ARGS([_args]) -push_IFS(["'"]) - for x in ${_args}; do - AS_IF([test "$x" == " "],[:], - AS_IF([test "$x" != "${x%--with-docker-*}"],[:], - AS_VAR_SET([$1],["$$1 $x"]))) - done -pop_IFS -]) - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[dk_set_user_env], [ -dnl AS_VAR_SET([user_entry], [$(awk -F: "{if (\$[]1 == \"${USER}\") {print \$[]0} }" /etc/passwd)]) - AS_VAR_SET([user_id], [$(id -u)]) - AS_VAR_SET([user_group], [$(id -g)]) -dnl AS_VAR_SET([user_home], [$(echo ${user_entry} | awk -F: '{print $[]6}')]) -dnl AS_VAR_SET([group_entry],[$(awk -F: "{if (\$[]3 == \"${user_group}\") {print \$[]0} }" /etc/group)]) -dnl AS_VAR_SET([user_groups],[$(id -G ${USER} | sed 's/ /,/g')]) -AS_VAR_SET([user_home],${HOME}) -AS_VAR_SET([abs_builddir],[$(pwd)]) -AS_VAR_SET([abs_srcdir],[$(cd ${srcdir}; pwd)]) - -# Docker profiles -AS_VAR_SET([DOCKER_PROFILE_debug],["--cap-add=SYS_PTRACE --security-opt seccomp=unconfined"]) - -]) - - - - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_CMD_CNTRUN], [ - dnl set user variables - dk_set_user_env - AS_VAR_SET_IF([DOCKER_SHARES],[ - for _share in ${DOCKER_SHARES}; do - AS_VAR_APPEND([DOCKER_SHARES_VAR],"-v ${_share} "); - done - ]) - AS_VAR_SET_IF([DOCKER_NETWORKS],[ - for _n in ${DOCKER_NETWORKS}; do - AS_VAR_APPEND([DOCKER_NETWORKS_VAR],"--network=$_n "); - done - ]) - AS_VAR_SET_IF([DOCKER_PROFILE],[ - AS_VAR_SET([DOCKER_PROFILE_VAR],[$(eval echo \${DOCKER_PROFILE_${DOCKER_PROFILE}})]) - AS_ECHO("DOCKER_PROFILE: ${DOCKER_PROFILE}") - ]) - AS_ECHO("DOCKER_ENTRYPOINT->|${DOCKER_ENTRYPOINT}|") - AS_IF([test -n "${DOCKER_ENTRYPOINT}"],,AS_VAR_SET([DOCKER_ENTRYPOINT],${SHELL})) - AS_ECHO("DOCKER_ENTRYPOINT->|${DOCKER_ENTRYPOINT}|") - dnl run container - m4_normalize([ docker run -d -it --entrypoint=${DOCKER_ENTRYPOINT} \ - -e USER=${USER} \ - -e DISPLAY=${DISPLAY} \ - -e LANG=${LANG} \ - -e http_proxy=${http_proxy} \ - -e https_proxy=${https_proxy} \ - -v /tmp/.X11-unix:/tmp/.X11-unix \ - -v /etc/resolv.conf:/etc/resolv.conf \ - -v ${abs_srcdir}:${abs_srcdir} \ - -v ${user_home}:${user_home} \ - -v $(pwd):$(pwd) \ - ${DOCKER_SHARES_VAR} \ - ${DOCKER_NETWORKS_VAR} \ - ${DOCKER_PROFILE_VAR} \ - -w $(pwd) \ - --name $2 \ - $1; - ]) - dnl set user option inside container - m4_normalize([ docker exec --user root $2 ${SHELL} -c " - groupadd -g ${user_group} ${USER}; - useradd -d ${user_home} -u ${user_id} -g ${user_group} ${USER}; - "; - ]) -]) - - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_CONFIGURE],[ - - dnl remove docker related options in configure args - AS_VAR_SET([dk_configure_args]) - DK_GET_CONFIGURE_ARGS_WITHOUT_DOCKER([dk_configure_args]) - AS_VAR_APPEND([dk_configure_args],[" "]) - AS_VAR_SET_IF([DOCKER_IMAGE],AS_VAR_APPEND([dk_configure_args], - ["DOCKER_IMAGE=\"${DOCKER_IMAGE}\" "])) - AS_VAR_SET_IF([DOCKER_CONTAINER],AS_VAR_APPEND([dk_configure_args], - ["DOCKER_CONTAINER=\"${DOCKER_CONTAINER}\" "])) - AS_VAR_SET_IF([DOCKER_FILE],AS_VAR_APPEND([dk_configure_args], - ["DOCKER_FILE=\"${DOCKER_FILE}\" "])) - - m4_pushdef([dk_configure_cmd], m4_normalize([ - ENABLE_KCONFIG=no - docker exec -t - --user ${USER} - ${DOCKER_CONTAINER} bash -l - -c \"cd ${srcdir}\; cd $(pwd)\; - DK_ADD_ESCAPE([ENABLE_KCONFIG=\"no\"]) - DK_ADD_ESCAPE([HAVE_DOCKER=\"no\"]) - ${0} DK_ADD_ESCAPE(${dk_configure_args}) \"; - ])) - - AS_ECHO(" ------------------------- ") - AS_ECHO(" DOCKER CONFIGURE COMMAND: ") - AS_ECHO(" dk_configure_cmd ") - AS_ECHO(" ------------------------- ") - - dnl execute configuration inside docker container - eval dk_configure_cmd - - m4_popdef([dk_configure_cmd]) -]) - - - -dnl sets DOCKER_CONTAINER var if not set to a unique name based on pwd dir. -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_SET_DOCKER_CONTAINER], [ - AS_VAR_SET_IF([DOCKER_CONTAINER],,AS_VAR_SET([DOCKER_CONTAINER], - [build_$(echo $(pwd) | md5sum | awk '{print $[]1}')])) -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_SET_DOCKER_IMAGE], [ - AS_VAR_SET_IF([DOCKER_IMAGE],,AS_VAR_SET([DOCKER_IMAGE], - [build_$(echo $(pwd) | md5sum | awk '{print $[]1}')])) -]) - - -dnl test_docker_container [cnt_name] [status] [action_if_yes] [action_if_no] -AC_DEFUN_LOCAL([m4_ax_docker_build],[if_docker_container_string],[ - AS_VAR_SET([cnt_id], $(docker ps -a -f name=$1 -q)) - AS_VAR_SET([cnt_status], $(docker ps -a -f name=$1 -f state=$2 -q)) - AS_CONTAINS([${cnt_status}],[${cnt_id}],[$3],[$4]) - ]) - -dnl test_docker_container_status [cnt_name] [status] [action_if_yes] [action_if_no] -dnl status = created, restarting, running, paused, exited -AC_DEFUN_LOCAL([m4_ax_docker_build],[if_docker_container_status],[ - AS_VAR_SET([id_cnt_status],[$(docker ps -a -f name=$1 -f status=$2 -q)]) - AS_IF([test -n "${id_cnt_status}"],[eval $3], [eval $4]) -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[test_docker_container_status],[ - if_docker_container_status([$1],[$2], - [AS_SET_STATUS(0),AS_SET_STATUS(1)]) -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[get_docker_container_status],[ - if_docker_container_status([$2],[created],AS_VAR_SET($1,[created])) - if_docker_container_status([$2],[restarting],AS_VAR_SET($1,[restarting])) - if_docker_container_status([$2],[running],AS_VAR_SET($1,[running])) - if_docker_container_status([$2],[paused],AS_VAR_SET($1,[paused])) - if_docker_container_status([$2],[exited],AS_VAR_SET($1,[exited])) -]) - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[get_docker_image_id],[ - AS_VAR_SET([$1], [$(docker images -a | ${AWK} -v _img=$2 {if ($1 ":" $2 == _img) {print $3}} )]) -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[get_docker_container_id],[ - AS_VAR_SET([$1],[$(docker ps -a -f name=$2 -q)])]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[get_docker_container_image],[ - AS_VAR_SET([$1],[$(docker inspect --format='{{.Config.Image}}' $2)]) -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[if_docker_image_exist],[ - AS_VAR_SET([id_img_exist],[$(docker images -a -q $1 )]) - AS_IF([test -n "${id_img_exist}"],[eval $2], [eval $3]) -]) - - -dnl start existing [container] -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_START_CNT],[ - AS_VAR_SET([DOCKER_CONTAINER],[$1]) - get_docker_container_status([dk_status],[${DOCKER_CONTAINER}]) - AS_CASE([${dk_status}], - [running], [AS_ECHO("RUNNING")], - [paused], [AS_ECHO("UNPAUSE")];[eval docker unpause ${DOCKER_CONTAINER}], - [exited], [AS_ECHO("RESTART")];[eval docker restart ${DOCKER_CONTAINER}], - [AC_MSG_ERROR("container not found.")]) - - get_docker_container_status([dk_status],[${DOCKER_CONTAINER}]) - AS_CASE([${dk_status}], - [running], [AS_ECHO("docker container: ${DOCKER_CONTAINER} is running.")], - [AS_ECHO("could not start docker container")]) -]) - - - - -dnl start a container form [image] -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_START_IMGCNT], [ - DK_SET_DOCKER_CONTAINER - DK_GET_CONFIGURE_ARGS([dk_configure_args]) - - AS_ECHO("Pulling image: $1") - docker pull $1; - - AS_ECHO("Starting container from image: $1") - - dnl find if container exists and belongs to selected image - get_docker_container_id([dk_id],${DOCKER_CONTAINER}) - get_docker_container_image([dk_img],${DOCKER_CONTAINER}) - AS_ECHO("id: ${dk_id} img: ${dk_img}") - AS_IF([test -n "${dk_id}" -a -n "${dk_img}"], - [AS_IF([test x"${dk_img}" == x"$1"], - [AC_MSG_NOTICE("container found of the correct image")], - [AC_MSG_ERROR("container does not belong to the correct image")])]) - - dnl find if container exists or start it - AS_IF([test -n "${dk_id}"],, - [AS_ECHO("CREATE ")];[DK_CMD_CNTRUN($1,${DOCKER_CONTAINER})]) - DK_START_CNT(${DOCKER_CONTAINER}) -]) - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_START_URL], [ - AS_VAR_SET([dk_build_args]) - AS_VAR_SET_IF([http_proxy], [AS_VAR_APPEND([dk_build_args],["--build-arg http_proxy=\"${http_proxy}\" "])]) - AS_VAR_SET_IF([https_proxy],[AS_VAR_APPEND([dk_build_args],["--build-arg https_proxy=\"${https_proxy}\" "])]) - - dnl TODO: check status - AS_VAR_SET_IF([DOCKER_URL], - [echo docker build ${dk_build_args} -t $2 $1]; - [eval docker build ${dk_build_args} -t $2 $1]) - -]) - - - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[_dk_set_docker_build_debug],[ - AS_ECHO(" --------------------------------- ") - AS_ECHO(" docker-image = ${DOCKER_IMAGE}") - AS_ECHO(" docker-container = ${DOCKER_CONTAINER}") - AS_ECHO(" ac_configure_args = ${ac_configure_args}") - AS_ECHO(" --------------------------------- ") - ]) - - - - - - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_SET_TARGETS],[ -AS_VAR_READ([AX_DOCKER_BUILD_TARGETS],[ - -# //////////////////////////////////////////////////////////////////////////// # -# //// DOCKER TARGETS /////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -DOCKER_CONTAINER = ${DOCKER_CONTAINER} -DOCKER_IMAGE = ${DOCKER_IMAGE} -DOCKER_ENTRYPOINT ?= \${SHELL} -DOCKER_PS1 ?= [[\\\u@${DOCKER_IMAGE}:\\\h \\\W]]\$ - -user_id = ${user_id} -user_group = ${user_group} -user_groups = ${user_groups} -user_home = ${user_home} - -# if MAKESHELL is not defined use local dshell to enter docker container -docker_SHELL := \$(if \${MAKESHELL},\${MAKESHELL},\${abs_top_builddir}/dshell) -local_SHELL := \$(if \${SHELL},\${SHELL},/bin/sh) -export SHELL := \${docker_SHELL} -\$(foreach x,\$(NODOCKERBUILD),\$(eval \$x: override SHELL=\${local_SHELL})) - -# fix local_SHELL for automake targets -Makefile Makefile.in \$(ACLOCAL_M4) \$(top_srcdir)/configure am--refresh: SHELL = \$(local_SHELL) -AUTOMAKE += --add-missing --copy -W none - -.PHONY: docker -ifeq (docker,\$(MAKECMDGOALS)) -docker: - @ \ - echo ; \ - echo " This build was set to work with Docker: "; \ - echo " ---------------------------------------------------------------- "; \ - echo " This means that you should see a running docker container named: "; \ - echo " ${DOCKER_CONTAINER}. " ; \ - echo " Using a map of the current srcdir and builddir and some envs the "; \ - echo " build system should be able to launch make inside the container. "; \ - echo " Use the usual make command and targets to build inside docker. "; \ - echo ; \ - echo " Additional targets: " ; \ - echo " make docker start <- run the docker container " ; \ - echo " make docker stop <- stop and remove the docker container " ; \ - echo " make docker shell <- launch a shell inside the container " ; \ - echo " make docker shell USER=root <- launch the shell as root " ; \ - echo " make docker inspect <- get container info (such as ipaddr)" ; \ - echo ; -else -docker: - @ \ - echo " --- docker build setup --- "; -endif - -ifeq (docker,\$(filter docker,\$(MAKECMDGOALS))) -export SHELL = \${local_SHELL} - -.PHONY: info start stop shell inspect run -inspect: ##@docker inspect running container properties - @echo "info:"; - docker inspect \${DOCKER_CONTAINER} - -start: ##@docker start new session of configured container - @echo "Starting docker container:"; - m4_normalize( docker run -d -it --entrypoint=\${DOCKER_ENTRYPOINT} - -e USER=\${USER} - -e DISPLAY=\${DISPLAY} - -e LANG=\${LANG} - -e http_proxy=\${http_proxy} - -e https_proxy=\${https_proxy} - -e PS1="\${DOCKER_PS1}" - -v /tmp/.X11-unix:/tmp/.X11-unix - -v /etc/resolv.conf:/etc/resolv.conf - -v \${abs_top_srcdir}:\${abs_top_srcdir} - -v \${abs_top_builddir}:\${abs_top_builddir} - -v \${user_home}:\${user_home} - \$(foreach share,\${DOCKER_SHARES},-v \$(share) ) - \$(foreach net,\${DOCKER_NETWORKS},--network=\$(net) ) - \${DOCKER_PROFILE_\${DOCKER_PROFILE}} - -w \${abs_top_builddir} - --privileged - --cap-add=SYS_PTRACE --security-opt seccomp=unconfined - --name \${DOCKER_CONTAINER} - \${DOCKER_IMAGE}; ) - m4_normalize( docker exec --user root \${DOCKER_CONTAINER} - \${SHELL} -c " - groupadd -g \${user_group} \${USER}; - useradd -d \${user_home} -u \${user_id} -g \${user_group} \${USER}; - ";) - -stop: ##@docker stop running container session - @echo "Stopping docker container:"; - docker stop \${DOCKER_CONTAINER}; - docker rm \${DOCKER_CONTAINER}; - -shell: ##@docker start a shell inside running container (use: USER=root for privleges) - @echo "Starting docker shell"; - docker exec -ti --user \${USER} \${DOCKER_CONTAINER} \ - \${SHELL} -c "cd \$(shell pwd); export MAKESHELL=\${SHELL}; export PS1='\${DOCKER_PS1} '; bash -l " - -endif - - -]) -AC_SUBST([AX_DOCKER_BUILD_TARGETS]) -m4_ifdef([AM_SUBST_NOTMAKE], [AM_SUBST_NOTMAKE([AX_DOCKER_BUILD_TARGETS])]) -]) - - - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_WRITE_DSHELLFILE],[ -AS_VAR_READ([DK_DSHELLFILE],m4_escape([ -#!/bin/bash -# //////////////////////////////////////////////////////////////////////////// # -# //// DOCKER SHELL ///////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -DOCKER_CONTAINER=${DOCKER_CONTAINER} -DOCKER_IMAGE=${DOCKER_IMAGE} - -abs_srcdir=${abs_srcdir} -abs_builddir=${abs_builddir} -user_id=${user_id} -user_group=${user_group} -user_groups=${user_groups} -user_home=${user_home} - -export SHELL=/bin/bash -export M_PATH=\$PATH -M_ENV="\$(export -p | awk '{printf("%s; ",\@S|@0)}')" -xhost local:${USER} > /dev/null ->&2 echo "Docker: Entering container \${DOCKER_CONTAINER} "; -quoted_args="\$(printf " %q" "\$\@")" -if [ -n "\${MAKESHELL}" ]; then - \${MAKESHELL} \${quoted_args}; -else - [ -t AS_ORIGINAL_STDIN_FD -o -t 0 ] && INT=-ti || INT= - docker exec \${INT} --user \${USER} \${DOCKER_CONTAINER} /bin/bash -l -c "save_path=\\\\\$PATH; \$M_ENV export PATH=\\\\\$save_path; cd \$(pwd); export MAKESHELL=/bin/bash; /bin/bash \${quoted_args}"; -fi -])) - -AS_ECHO(" Writing dshell file: ${abs_builddir}/dshell ") -AS_ECHO("${DK_DSHELLFILE}") > ${abs_builddir}/dshell -chmod +x dshell - -]) - - - - -dnl //////////////////////////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// -dnl // Utility functions - -AC_DEFUN_LOCAL([m4_ax_docker_build],[AS_BANNER],[ - AS_ECHO - AS_BOX([// $1 //////], [\/]) - AS_ECHO - ]) - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[AS_VAR_READ],[ -read -d '' $1 << _as_read_EOF -$2 -_as_read_EOF -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[AS_CONTAINS],[ - AS_VAR_SET([string],"$1") - AS_VAR_SET([substring],"$2") - AS_IF([test "${string#*$substring}" != "$string"], [eval $3], [eval $4])]) - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[push_IFS],[ -AS_VAR_SET([_save_IFS],[$IFS]) -AS_VAR_SET([IFS],[$1]) -]) - -AC_DEFUN_LOCAL([m4_ax_docker_build],[pop_IFS],[ -AS_VAR_SET([IFS],[${_save_IFS}]) -]) - - -AC_DEFUN_LOCAL([m4_ax_docker_build],[DK_ADD_ESCAPE],$([ -dnl TODO: make this for all quote char in sh using awk -echo $1 | sed 's/\\/\\\\/g' | sed 's/\"/\\\"/g'; -])) diff --git a/m4/m4_ax_fortran_flags.m4 b/m4/m4_ax_fortran_flags.m4 deleted file mode 100644 index c8651c4a71..0000000000 --- a/m4/m4_ax_fortran_flags.m4 +++ /dev/null @@ -1,28 +0,0 @@ -# -# SYNOPSIS -# -# AX_FORTRAN_FLAGS([variable name]) -# -# DESCRIPTION -# - -#serial 1 - -# AX_FORTRAN_FLAGS([variable name]) -# if compiler is gcc and version is greater than 10 we need compiler flags to fix error in argument mismatch -# WARNING: all this should be removed once the actual fortran code is fixed -# -AC_DEFUN([AX_FORTRAN_FLAGS],[ - AX_COMPILER_VERSION - - # WARNING: gfortran 10 dangerous fixes ... actual fortran code must be reviewed asap - # see: https://gcc.gnu.org/gcc-10/porting_to.html - # added flags in m4/m4_as_fortran_flags.m4 - # -fallow-invalid-boz -fallow-argument-mismatch - if [ test x"$GCC" = x"yes" ]; then - AX_COMPARE_VERSION([${ax_cv_c_compiler_version}], [ge], [10.0.0], - [AS_VAR_SET([_fortran_flags_fix],["-fallow-invalid-boz -fallow-argument-mismatch"])]) - AS_VAR_APPEND([$1],[" ${_fortran_flags_fix}"]) - fi -]) - diff --git a/m4/m4_ax_is_release.m4 b/m4/m4_ax_is_release.m4 deleted file mode 100644 index 9ec6746990..0000000000 --- a/m4/m4_ax_is_release.m4 +++ /dev/null @@ -1,69 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_is_release.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_IS_RELEASE(POLICY) -# -# DESCRIPTION -# -# Determine whether the code is being configured as a release, or from -# git. Set the ax_is_release variable to 'yes' or 'no'. -# -# If building a release version, it is recommended that the configure -# script disable compiler errors and debug features, by conditionalising -# them on the ax_is_release variable. If building from git, these -# features should be enabled. -# -# The POLICY parameter specifies how ax_is_release is determined. It can -# take the following values: -# -# * git-directory: ax_is_release will be 'no' if a '.git' directory exists -# * minor-version: ax_is_release will be 'no' if the minor version number -# in $PACKAGE_VERSION is odd; this assumes -# $PACKAGE_VERSION follows the 'major.minor.micro' scheme -# * micro-version: ax_is_release will be 'no' if the micro version number -# in $PACKAGE_VERSION is odd; this assumes -# $PACKAGE_VERSION follows the 'major.minor.micro' scheme -# * always: ax_is_release will always be 'yes' -# * never: ax_is_release will always be 'no' -# -# Other policies may be added in future. -# -# LICENSE -# -# Copyright (c) 2015 Philip Withnall -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. - -#serial 3 - -AC_DEFUN([AX_IS_RELEASE],[ - AC_BEFORE([AC_INIT],[$0]) - - m4_case([$1], - [git-directory],[ - # $is_release = (.git directory does not exist) - AS_IF([test -d .git],[ax_is_release=no],[ax_is_release=yes]) - ], - [minor-version],[ - # $is_release = ($minor_version is even) - minor_version=`echo "$PACKAGE_VERSION" | sed 's/[[^.]][[^.]]*.\([[^.]][[^.]]*\).*/\1/'` - AS_IF([test "$(( $minor_version % 2 ))" -ne 0], - [ax_is_release=no],[ax_is_release=yes]) - ], - [micro-version],[ - # $is_release = ($micro_version is even) - micro_version=`echo "$PACKAGE_VERSION" | sed 's/[[^.]]*\.[[^.]]*\.\([[^.]]*\).*/\1/'` - AS_IF([test "$(( $micro_version % 2 ))" -ne 0], - [ax_is_release=no],[ax_is_release=yes]) - ], - [always],[ax_is_release=yes], - [never],[ax_is_release=no], - [ - AC_MSG_ERROR([Invalid policy. Valid policies: git-directory, minor-version.]) - ]) -]) diff --git a/m4/m4_ax_mdsplus_directories.m4 b/m4/m4_ax_mdsplus_directories.m4 deleted file mode 100644 index 05de144951..0000000000 --- a/m4/m4_ax_mdsplus_directories.m4 +++ /dev/null @@ -1,77 +0,0 @@ - - -dnl FROM /usr/share/autoconf/autoconf/general.m4 -dnl -dnl AC_SUBST([bindir], ['${exec_prefix}/bin'])dnl -dnl AC_SUBST([sbindir], ['${exec_prefix}/sbin'])dnl -dnl AC_SUBST([libexecdir], ['${exec_prefix}/libexec'])dnl -dnl AC_SUBST([datarootdir], ['${prefix}/share'])dnl -dnl AC_SUBST([datadir], ['${datarootdir}'])dnl -dnl AC_SUBST([sysconfdir], ['${prefix}/etc'])dnl -dnl AC_SUBST([sharedstatedir], ['${prefix}/com'])dnl -dnl AC_SUBST([localstatedir], ['${prefix}/var'])dnl -dnl AC_SUBST([includedir], ['${prefix}/include'])dnl -dnl AC_SUBST([oldincludedir], ['/usr/include'])dnl -dnl AC_SUBST([docdir], [m4_ifset([AC_PACKAGE_TARNAME], -dnl ['${datarootdir}/doc/${PACKAGE_TARNAME}'], -dnl ['${datarootdir}/doc/${PACKAGE}'])])dnl -dnl AC_SUBST([infodir], ['${datarootdir}/info'])dnl -dnl AC_SUBST([htmldir], ['${docdir}'])dnl -dnl AC_SUBST([dvidir], ['${docdir}'])dnl -dnl AC_SUBST([pdfdir], ['${docdir}'])dnl -dnl AC_SUBST([psdir], ['${docdir}'])dnl -dnl AC_SUBST([libdir], ['${exec_prefix}/lib'])dnl -dnl AC_SUBST([localedir], ['${datarootdir}/locale'])dnl -dnl AC_SUBST([mandir], ['${datarootdir}/man'])dnl - - - -AC_DEFUN([AX_MDSPLUS_DIRECTORIES],[ - - -AS_VAR_IF([exec_prefix],["NONE"], - AS_VAR_SET([exec_prefix],["${prefix}"])) - -AS_VAR_IF([bindir],["\${exec_prefix}/bin"], - AS_VAR_SET([bindir],["${exec_prefix}/bin"])) - -AS_VAR_IF([sbindir],["\${exec_prefix}/sbin"], - AS_VAR_SET([sbindir],["${exec_prefix}/sbin"])) - -AS_VAR_IF([libexecdir],["\${exec_prefix}/libexec"], - AS_VAR_SET([libexecdir],["${exec_prefix}/libexec"])) - -AS_VAR_IF([datarootdir],["\${prefix}/share"], - AS_VAR_SET([datarootdir],["${prefix}/share"])) - -AS_VAR_IF([datadir],["\${datarootdir}"], - AS_VAR_SET([datadir],["${datarootdir}"])) - -AS_VAR_IF([sysconfdir],["\${prefix}/etc"], - AS_VAR_SET([sysconfdir],["${prefix}/etc"])) - -AS_VAR_IF([sharedstatedir],["\${prefix}/com"], - AS_VAR_SET([sharedstatedir],["${exec_prefix}/com"])) - -AS_VAR_IF([localstatedir],["\${prefix}/var"], - AS_VAR_SET([localstatedir],["${prefix}/var"])) - -AS_VAR_IF([includedir],["\${prefix}/include"], - AS_VAR_SET([includedir],["${prefix}/include"])) - - - -AS_VAR_IF([libdir],["\${exec_prefix}/lib"], - AS_VAR_SET([libdir],["${exec_prefix}/lib"])) - -AS_VAR_IF([localedir],["\${datarootdir}/locale"], - AS_VAR_SET([localedir],["${datarootdir}/locale"])) - -AS_VAR_IF([mandir],["\${datarootdir}/man"], - AS_VAR_SET([mandir],["${datarootdir}/man"])) - - -]) - - - diff --git a/m4/m4_ax_mdsplus_testing.m4 b/m4/m4_ax_mdsplus_testing.m4 deleted file mode 100644 index e0a6071878..0000000000 --- a/m4/m4_ax_mdsplus_testing.m4 +++ /dev/null @@ -1,319 +0,0 @@ - -AC_DEFUN([TS_VAR_YN], [ - AS_CASE([${$1}], - [yes|Yes|YES|Y|y],$2, - [no|No|NO|N|n],$3, - [*],$4 ) - ]) - -AC_DEFUN([TS_DEBUG_VAR],[AS_ECHO("DEBUG: $1 = ${$1}")]) - - -dnl //////////////////////////////////////////////////////////////////////////// -dnl /// TS WINE ///////////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// - -dnl # test for wine path binary -AC_DEFUN([TS_PROG_WINEPATH],[ - AC_CHECK_PROG([HAVE_WINEPATH],[winepath],[yes],[no]) - AS_VAR_IF([HAVE_WINEPATH],[no], - [AC_MSG_WARN([winepath command not found]) - AC_MSG_WARN([winepath is required by wine to properly set the tests path])]) -]) - -dnl # compile a winepath env using specified directories. Wine supports the -dnl # WINEPATH variable. If, in your Unix Shell, you export WINEPATH, once you -dnl # launch wine it will use this to populate the PATH environment variable -dnl # inside wine. -dnl # -dnl # Usage: TS_WINEPATH [variable],[dir_list] -dnl # -AC_DEFUN([TS_WINEPATH],[ - AC_REQUIRE([TS_PROG_WINEPATH]) - # reset variable $1 - AS_VAR_SET_IF([$1],,AS_VAR_SET([$1])) - AS_VAR_IF([HAVE_WINEPATH],[yes], - [for _i in m4_normalize([$2]); do - # AS_VAR_SET([_dir],[$(eval cd $_i; pwd)]) - # AS_VAR_APPEND([$1],["$(eval winepath -w $_i 2>/dev/null);"]); - AS_VAR_APPEND([$1],["\$(shell winepath -w $_i 2>/dev/null);"]); - done]) -]) - -dnl # inline unix to windows path conversion -AC_DEFUN([TS_U2WPATH],[$(eval winepath -w $1 2>/dev/null)]) - -dnl # Automatically add mingw compiler library to wine path -dnl # usage: TS_WINE_LIBRARIESPATH [LIBDIR] -AC_DEFUN([TS_WINE_LIBRARIESPATH],[ - m4_pushdef([libdir], [m4_default([$2], [${MAKESHLIBDIR}])]) - AC_REQUIRE([AC_PROG_SED]) - AC_REQUIRE([AC_PROG_GREP]) - AS_VAR_SET([_libs], [$(${CC} --print-search-dir | \ - ${GREP} "libraries:" | \ - ${SED} 's/^libraries: =//' | \ - ${SED} 's/:/ /g')]) - AS_VAR_APPEND([_libs],[" "]) - - AS_VAR_SET([_prog], [$(${CC} --print-search-dir | \ - ${GREP} "programs:" | \ - ${SED} 's/^programs: =//' | \ - ${SED} 's/:/ /g')]) - AS_VAR_APPEND([_libs],["${_prog} "]) - - dnl # this is a workaround for build_mingw (centos7) docker image - AS_VAR_SET([_sysroot],[$(${CC} --print-sysroot)]) - AS_VAR_APPEND([_libs],["${_sysroot}/mingw/bin "]) - AS_VAR_APPEND([_libs],["${_sysroot}/mingw/lib "]) - AS_VAR_APPEND([_libs],m4_join([" "],libdir)) - - AS_VAR_SET($1) - TS_WINEPATH([$1],[${_libs}]) - m4_popdef([libdir]) -]) - - -dnl # Set Wineprefix and check for winebottle -dnl # usage: TS_WINE_ENV [WINEPREFIX] [WINEARCH] -AC_DEFUN([TS_WINE_ENV],[ - - dnl # select wine architecture - AS_CASE([${host}], - [i686*mingw*], - [AS_VAR_SET([winebottle_name],["winebottle_mingw32"]) AS_VAR_SET([$2],["win32"])], - [x86_64*mingw*], - [AS_VAR_SET([winebottle_name],["winebottle_mingw64"]) AS_VAR_SET([$2],["win64"])] ) - - dnl # select a wine bottle - AC_ARG_WITH([winebottle], - [AS_HELP_STRING([--with-winebottle],[specify bottle])], - [AC_MSG_NOTICE([using wine bottle: ${with_winebottle}])], - [AS_VAR_SET_IF([WINEPREFIX], - [AS_VAR_SET([with_winebottle], ["${WINEPREFIX}"])], - [AS_VAR_SET([with_winebottle], ["\$(top_builddir)/${winebottle_name}"])])]) - AS_VAR_SET([$1],[${with_winebottle}]) - - - dnl # launch boot in wine bottle (creating new one if it does not exist) - AS_VAR_SET_IF([HAVE_WINEBOOT],,[AC_CHECK_PROG(HAVE_WINEBOOT,wineboot,yes,no)]) - AS_VAR_IF([HAVE_WINEBOOT],[yes], - [# Creating bottle using wineboot - # WINEDLLOVERRIDES prevents asking to install mono and geko here - AS_IF([test -d ${$1}], - [$(eval WINEDLLOVERRIDES="mscoree,mshtml=" WINEPREFIX=${$1} WINEARCH=${$2} wineboot -f -r)], - [$(eval WINEDLLOVERRIDES="mscoree,mshtml=" WINEPREFIX=${$1} WINEARCH=${$2} wineboot -f -u)])], - [AS_IF([test -d ${$1}], - [AC_MSG_WARN([unable to update winebottle])], - [AC_MSG_ERROR([unable to create or find winebottle])]) - ]) -]) - - - - -dnl //////////////////////////////////////////////////////////////////////////// -dnl /// TS PYTHON ///////////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// - -AC_DEFUN([TS_CHECK_NOSETESTS],[ - AC_CHECK_PROG([NOSETESTS], [nosetests], [nosetests]) - AS_IF(test x"${NOSETESTS}" != x"", - [$2], - [$3]) -]) - -dnl TEST for python modules -AC_DEFUN([TS_CHECK_PYTHON_TAP],[ - AC_PYTHON_MODULE(tap) - AC_PYTHON_MODULE_CLASS(tap, TAPTestRunner, [have_tappy="yes"],) - AC_CHECK_PROG([NOSETESTS], [nosetests], [nosetests]) - AS_IF(test x"${have_tappy}" == x"yes" -a x"${NOSETESTS}" != x"", - [$2], - [$3]) -]) - - - -dnl //////////////////////////////////////////////////////////////////////////// -dnl /// TS JAVA ///////////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// - -AC_DEFUN([TS_CHECK_JAVA],[ - # AS_VAR_SET([JDK_VERSION],["$(java -d64 -version 2>&1 )"]) - # AC_PATH_PROG([JAVAC_PATH_NAME], [javac]) - AC_PATH_PROG([JAVA_PATH_NAME], [java]) - AS_IF([${JAVA_PATH_NAME} ${JAVA_TARGET_ARCH} -version 2>&1 > /dev/null], - [$2], - [$3]) -]) - - -dnl generate SKIP log_compiler -AC_DEFUN([TS_LOG_SKIP],[ - AS_VAR_SET([$1],["sh -c \"exit 77\"; :"]) -]) - -dnl //////////////////////////////////////////////////////////////////////////// -dnl /// TS SELECT HOST //////////////////////////////////////////////////////// -dnl //////////////////////////////////////////////////////////////////////////// - -dnl -dnl This function select from current build_os and host target the proper env to -dnl correctly call the test chain. -dnl The test chain is composed by: [tests_env] [log_driver] [log_compiler] [test_flags] -dnl -AC_DEFUN([TS_SELECT],[ - AS_VAR_SET([LOG_DRIVER],["\$(SHELL) \$(top_srcdir)/conf/test-driver"]) - AS_VAR_SET([abs_srcdir],$(cd ${srcdir}; pwd)) - - dnl TS_CHECK_NOSETESTS( [$PYTHON],, - dnl [AC_MSG_WARN("python-nose not found")]) - dnl TS_CHECK_PYTHON_TAP( [$PYTHON],, - dnl [AC_MSG_WARN("Tap plugin for python-nose not found")]) - dnl LD_PRELOAD=${ENABLE_SANITIZE_LIBPATH}; - AS_VAR_APPEND([PY_LOG_FLAGS], [""]) - - AS_CASE(["${build_os}:${host}"], - # - # LINUX->MINGW - # - [*linux*:*mingw*], - [ - AS_VAR_SET([ENABLE_TESTS],[yes]) - AS_ECHO("Set tests environment for linux->mingw") - AS_VAR_SET([skip_junit],[yes]) # skipping java tests (JUNIT) in windows - AS_VAR_SET_IF([HAVE_WINE],,[AC_CHECK_PROG(HAVE_WINE,wine,yes,no)]) - AS_VAR_IF([HAVE_WINE],[yes], - [ - TS_WINE_ENV([WINEPREFIX],[WINEARCH]) - TS_WINE_LIBRARIESPATH([WINEPATH]) - TS_WINEPATH([WINEPATH],["\$(top_builddir)/wfevent" "\$(top_builddir)/setevent"]) - AS_VAR_SET([PYTHONHOME],"TS_U2WPATH([/python27])") - AS_VAR_APPEND([TESTS_ENVIRONMENT],["WINEARCH='${WINEARCH}' WINEPREFIX='${WINEPREFIX}' "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["WINEDEBUG=-all "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["MDSPLUS_DIR='TS_U2WPATH([${srcdir}])' "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["MDS_PATH='TS_U2WPATH([${srcdir}/tdi])' "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["MDS_PYDEVICE_PATH='TS_U2WPATH([${srcdir}/pydevices]);TS_U2WPATH([${srcdir}/python/MDSplus/tests/devices])' "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["main_path='.;TS_U2WPATH([${srcdir}/trees])' "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["subtree_path='.;TS_U2WPATH([${srcdir}/trees/subtree])' "]) - AS_VAR_IF([WINEARCH],[win64], - [# WINEARCH win64 - AS_VAR_APPEND([WINEPATH],["${PYTHONHOME}"]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["PYTHONHOME='${PYTHONHOME}' "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT], - ["PYTHONPATH='%PYTHONHOME%\\Lib;%PYTHONHOME%\\Lib\\site-packages;TS_U2WPATH([${srcdir}/python])' "]) - AS_VAR_APPEND([TESTS_ENVIRONMENT],["PyLib='python27' "]) - AS_VAR_SET([PYTHON],["\$(abs_top_srcdir)/testing/winpython python"]) - AS_VAR_APPEND([PY_LOG_COMPILER], - ["\${PYTHON} -B \$(abs_top_srcdir)/testing/testing.py"])], - [# WINEARCH win32 - TS_LOG_SKIP([PY_LOG_COMPILER])]) - # any wine flavor - AS_VAR_APPEND([TESTS_ENVIRONMENT],"WINEPATH='${WINEPATH}' ") - AS_VAR_APPEND([LOG_COMPILER],"wine ") - # WINE Valgrind tuning .. - # see: http://wiki.winehq.org/WineAndValgrind - # - # ensures that bitmap-related code, such as GetBitmapBits(), works under Valgrind - AS_VAR_APPEND([VALGRIND_FLAGS],"--vex-iropt-register-updates=allregs-at-mem-access ") - # - # quiets warnings about accesses slightly below the stack pointer. This is due - # to a known but benign piece of code in Wine's ntdll - # (see Bug #26263 for details) - AS_VAR_APPEND([VALGRIND_memcheck_FLAGS],"--workaround-gcc296-bugs=yes ") - ],[ - TS_LOG_SKIP([LOG_COMPILER]) - TS_LOG_SKIP([PY_LOG_COMPILER]) - ] - ) - ], - # - # LINUX->LINUX - # - [*linux*:*linux*], - [ - AS_VAR_SET([ENABLE_TESTS],[yes]) - AS_ECHO("Set tests environment for linux->linux") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"PATH=${MAKEBINDIR}:${MAKEBINDIR}/../setevent:${MAKEBINDIR}/../wfevent:\$(abs_top_srcdir)/testing:\${PATH} ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"MDSPLUS_DIR=\$(abs_top_srcdir) ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"MDS_PATH=\$(abs_top_srcdir)/tdi ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"MDS_PYDEVICE_PATH='\$(abs_top_srcdir)/pydevices;\$(abs_top_srcdir)/python/MDSplus/tests/devices' ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"main_path='.;\$(abs_top_srcdir)/trees' ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"subtree_path='.;\$(abs_top_srcdir)/trees/subtree' ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"${LIBPATH}=${MAKESHLIBDIR}\${${LIBPATH}:+:\${${LIBPATH}}} ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"PYTHONPATH=\$(abs_top_srcdir)/python\${PYTHONPATH:+:\${PYTHONPATH}} PYTHONDONTWRITEBYTECODE=yes ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"PyLib=\${PYLIB} ") - AS_VAR_APPEND([TESTS_ENVIRONMENT],"PYTHON=\${PYTHON} ") - AS_VAR_APPEND([PY_LOG_COMPILER], ["\${PYTHON} -B \$(top_srcdir)/testing/testing.py"]) - ], - # - # OTHER - # - [*], - [ # in all other platform tests are disabled for now - AS_VAR_SET([ENABLE_TESTS],[no]) - ]) -# MACOS: add --dsymutil=yes to valgrind - -# Set ENABLE_TESTS - AC_SUBST([ENABLE_TESTS]) - AM_CONDITIONAL([ENABLE_TESTS],[test x"${ENABLE_TESTS}" = x"yes"]) - m4_ifdef([AM_SUBST_NOTMAKE], [AM_SUBST_NOTMAKE([ENABLE_TESTS])]) - -]) - - - - - - -dnl --- TEST CHAIN --- - -dnl LOG_DRIVER = $(SHELL) $(top_srcdir)/conf/test-driver -dnl LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS) -dnl PY_LOG_DRIVER = $(SHELL) $(top_srcdir)/conf/test-driver -dnl PY_LOG_COMPILE = $(PY_LOG_COMPILER) $(AM_PY_LOG_FLAGS) $(PY_LOG_FLAGS) - -dnl am__test_logs1 = $(TESTS:=.log) -dnl am__test_logs2 = $(am__test_logs1:.log=.log) -dnl TEST_LOGS = $(am__test_logs2:.test.log=.log) -dnl TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/conf/test-driver -dnl TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) $(TEST_LOG_FLAGS) -dnl DIST_SUBDIRS = $(SUBDIRS) - -dnl buildtest.log: buildtest$(EXEEXT) -dnl @p='buildtest$(EXEEXT)'; \ -dnl b='buildtest'; \ -dnl $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ -dnl --log-file $$b.log --trs-file $$b.trs \ -dnl $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ -dnl "$$tst" $(AM_TESTS_FD_REDIRECT) - -dnl .py.log: -dnl @p='$<'; \ -dnl $(am__set_b); \ -dnl $(am__check_pre) $(PY_LOG_DRIVER) --test-name "$$f" \ -dnl --log-file $$b.log --trs-file $$b.trs \ -dnl $(am__common_driver_flags) $(AM_PY_LOG_DRIVER_FLAGS) $(PY_LOG_DRIVER_FLAGS) -- $(PY_LOG_COMPILE) \ -dnl "$$tst" $(AM_TESTS_FD_REDIRECT) - - - -dnl # -dnl # nosetests alternative TODO: add this with nosetests check -dnl # -dnl _tap_py_execute = \ -dnl import unittest; \ -dnl import tap; \ -dnl import os; \ -dnl import sys; \ -dnl pt = os.path.dirname(os.path.curdir); \ -dnl loader = unittest.TestLoader(); \ -dnl tests = loader.loadTestsFromName(sys.argv[1]); \ -dnl tr = tap.TAPTestRunner(); \ -dnl tr.set_stream(1); \ -dnl tr.run(tests); - -dnl #prova: -dnl # echo $(TEST_LOGS); -dnl # python -c "${_tap_py_execute}" pyex1; diff --git a/m4/m4_ax_perl_module_version.m4 b/m4/m4_ax_perl_module_version.m4 deleted file mode 100644 index 5754ea947e..0000000000 --- a/m4/m4_ax_perl_module_version.m4 +++ /dev/null @@ -1,85 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_perl_module_version.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_PERL_MODULE_VERSION([MODULE VERSION], [ACTION-IF-TRUE], [ACTION-IF-FALSE]) -# -# DESCRIPTION -# -# Checks to see if the list of 'Module Version' are avaiable in the -# system. If all the modules in the list are avaiable ACTION-IF-TRUE is -# executed. Case one module is not avaiable ACTION-IF-FALSE is executed -# and the macro execution is aborted. NOTE: Perl is needed. -# -# Example: -# -# AX_PERL_MODULE_VERSION(CGI::Test 0.104 CGI::Ajax 0.694, , -# AC_MSG_ERROR(Need some Perl modules)) -# -# LICENSE -# -# Copyright (c) 2009 Marco Gomes -# Copyright (c) 2009 Ruben Fonseca -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 7 - -AU_ALIAS([AC_PERL_MODULE_VERSION], [AX_PERL_MODULE_VERSION]) -AC_DEFUN([AX_PERL_MODULE_VERSION],[dnl -ac_perl_list_modules="$1" -# Make sure we have perl -if test -z "$PERL"; then -AC_CHECK_PROG(PERL,perl,perl) -fi - -# Check the number of arguments -args_num=`echo $ac_perl_list_modules | wc -w` -check_args=$(( $args_num % 2 )) -if test "$check_args" = "1" ; then - AC_MSG_ERROR(syntax error) -else - eval -fi - -if test "x$PERL" != x; then - ac_failed=0 - while test ${#ac_perl_list_modules} -gt 2 ; do - module_name=`echo $ac_perl_list_modules | cut -d " " -f 1` - module_version=`echo $ac_perl_list_modules | cut -d " " -f 2` - ac_perl_list_modules=`echo $ac_perl_list_modules | cut -d " " -f 3-` - AC_MSG_CHECKING(for perl module $module_name version $module_version) - - $PERL "-M$module_name" -e exit > /dev/null 2>&1 - if test $? -ne 0; then - AC_MSG_RESULT(no); - ac_failed=1 - ac_perl_list_modules="" - else - version=`$PERL "-M$module_name" -e 'print $'"$module_name::VERSION" 2>&1` - $PERL -e 'exit(shift cmp shift)' "$version" "$module_version" - if test $? -eq 0 -o $? -eq 1 ; then - AC_MSG_RESULT(ok); - else - AC_MSG_RESULT(no) - ac_failed=1 - ac_perl_list_modules="" - fi - fi; - done - - if test "$ac_failed" = 0; then - : - $2 - else - : - $3 - fi -else - AC_MSG_ERROR(could not find perl) -fi])dnl diff --git a/m4/m4_ax_prog_doxygen.m4 b/m4/m4_ax_prog_doxygen.m4 deleted file mode 100644 index 7c3b0f8df8..0000000000 --- a/m4/m4_ax_prog_doxygen.m4 +++ /dev/null @@ -1,537 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_prog_doxygen.html -# =========================================================================== -# -# SYNOPSIS -# -# DX_INIT_DOXYGEN(PROJECT-NAME, DOXYFILE-PATH, [OUTPUT-DIR]) -# DX_DOXYGEN_FEATURE(ON|OFF) -# DX_DOT_FEATURE(ON|OFF) -# DX_HTML_FEATURE(ON|OFF) -# DX_CHM_FEATURE(ON|OFF) -# DX_CHI_FEATURE(ON|OFF) -# DX_MAN_FEATURE(ON|OFF) -# DX_RTF_FEATURE(ON|OFF) -# DX_XML_FEATURE(ON|OFF) -# DX_PDF_FEATURE(ON|OFF) -# DX_PS_FEATURE(ON|OFF) -# -# DESCRIPTION -# -# The DX_*_FEATURE macros control the default setting for the given -# Doxygen feature. Supported features are 'DOXYGEN' itself, 'DOT' for -# generating graphics, 'HTML' for plain HTML, 'CHM' for compressed HTML -# help (for MS users), 'CHI' for generating a seperate .chi file by the -# .chm file, and 'MAN', 'RTF', 'XML', 'PDF' and 'PS' for the appropriate -# output formats. The environment variable DOXYGEN_PAPER_SIZE may be -# specified to override the default 'a4wide' paper size. -# -# By default, HTML, PDF and PS documentation is generated as this seems to -# be the most popular and portable combination. MAN pages created by -# Doxygen are usually problematic, though by picking an appropriate subset -# and doing some massaging they might be better than nothing. CHM and RTF -# are specific for MS (note that you can't generate both HTML and CHM at -# the same time). The XML is rather useless unless you apply specialized -# post-processing to it. -# -# The macros mainly control the default state of the feature. The use can -# override the default by specifying --enable or --disable. The macros -# ensure that contradictory flags are not given (e.g., -# --enable-doxygen-html and --enable-doxygen-chm, -# --enable-doxygen-anything with --disable-doxygen, etc.) Finally, each -# feature will be automatically disabled (with a warning) if the required -# programs are missing. -# -# Once all the feature defaults have been specified, call DX_INIT_DOXYGEN -# with the following parameters: a one-word name for the project for use -# as a filename base etc., an optional configuration file name (the -# default is 'Doxyfile', the same as Doxygen's default), and an optional -# output directory name (the default is 'doxygen-doc'). -# -# Automake Support -# -# The following is a template aminclude.am file for use with Automake. -# Make targets and variables values are controlled by the various -# DX_COND_* conditionals set by autoconf. -# -# The provided targets are: -# -# doxygen-doc: Generate all doxygen documentation. -# -# doxygen-run: Run doxygen, which will generate some of the -# documentation (HTML, CHM, CHI, MAN, RTF, XML) -# but will not do the post processing required -# for the rest of it (PS, PDF, and some MAN). -# -# doxygen-man: Rename some doxygen generated man pages. -# -# doxygen-ps: Generate doxygen PostScript documentation. -# -# doxygen-pdf: Generate doxygen PDF documentation. -# -# Note that by default these are not integrated into the automake targets. -# If doxygen is used to generate man pages, you can achieve this -# integration by setting man3_MANS to the list of man pages generated and -# then adding the dependency: -# -# $(man3_MANS): doxygen-doc -# -# This will cause make to run doxygen and generate all the documentation. -# -# The following variable is intended for use in Makefile.am: -# -# DX_CLEANFILES = everything to clean. -# -# Then add this variable to MOSTLYCLEANFILES. -# -# ----- begin aminclude.am ------------------------------------- -# -# ## --------------------------------- ## -# ## Format-independent Doxygen rules. ## -# ## --------------------------------- ## -# -# if DX_COND_doc -# -# ## ------------------------------- ## -# ## Rules specific for HTML output. ## -# ## ------------------------------- ## -# -# if DX_COND_html -# -# DX_CLEAN_HTML = @DX_DOCDIR@/html -# -# endif DX_COND_html -# -# ## ------------------------------ ## -# ## Rules specific for CHM output. ## -# ## ------------------------------ ## -# -# if DX_COND_chm -# -# DX_CLEAN_CHM = @DX_DOCDIR@/chm -# -# if DX_COND_chi -# -# DX_CLEAN_CHI = @DX_DOCDIR@/@PACKAGE@.chi -# -# endif DX_COND_chi -# -# endif DX_COND_chm -# -# ## ------------------------------ ## -# ## Rules specific for MAN output. ## -# ## ------------------------------ ## -# -# if DX_COND_man -# -# DX_CLEAN_MAN = @DX_DOCDIR@/man -# -# endif DX_COND_man -# -# ## ------------------------------ ## -# ## Rules specific for RTF output. ## -# ## ------------------------------ ## -# -# if DX_COND_rtf -# -# DX_CLEAN_RTF = @DX_DOCDIR@/rtf -# -# endif DX_COND_rtf -# -# ## ------------------------------ ## -# ## Rules specific for XML output. ## -# ## ------------------------------ ## -# -# if DX_COND_xml -# -# DX_CLEAN_XML = @DX_DOCDIR@/xml -# -# endif DX_COND_xml -# -# ## ----------------------------- ## -# ## Rules specific for PS output. ## -# ## ----------------------------- ## -# -# if DX_COND_ps -# -# DX_CLEAN_PS = @DX_DOCDIR@/@PACKAGE@.ps -# -# DX_PS_GOAL = doxygen-ps -# -# doxygen-ps: @DX_DOCDIR@/@PACKAGE@.ps -# -# @DX_DOCDIR@/@PACKAGE@.ps: @DX_DOCDIR@/@PACKAGE@.tag -# cd @DX_DOCDIR@/latex; \ -# rm -f *.aux *.toc *.idx *.ind *.ilg *.log *.out; \ -# $(DX_LATEX) refman.tex; \ -# $(MAKEINDEX_PATH) refman.idx; \ -# $(DX_LATEX) refman.tex; \ -# countdown=5; \ -# while $(DX_EGREP) 'Rerun (LaTeX|to get cross-references right)' \ -# refman.log > /dev/null 2>&1 \ -# && test $$countdown -gt 0; do \ -# $(DX_LATEX) refman.tex; \ -# countdown=`expr $$countdown - 1`; \ -# done; \ -# $(DX_DVIPS) -o ../@PACKAGE@.ps refman.dvi -# -# endif DX_COND_ps -# -# ## ------------------------------ ## -# ## Rules specific for PDF output. ## -# ## ------------------------------ ## -# -# if DX_COND_pdf -# -# DX_CLEAN_PDF = @DX_DOCDIR@/@PACKAGE@.pdf -# -# DX_PDF_GOAL = doxygen-pdf -# -# doxygen-pdf: @DX_DOCDIR@/@PACKAGE@.pdf -# -# @DX_DOCDIR@/@PACKAGE@.pdf: @DX_DOCDIR@/@PACKAGE@.tag -# cd @DX_DOCDIR@/latex; \ -# rm -f *.aux *.toc *.idx *.ind *.ilg *.log *.out; \ -# $(DX_PDFLATEX) refman.tex; \ -# $(DX_MAKEINDEX) refman.idx; \ -# $(DX_PDFLATEX) refman.tex; \ -# countdown=5; \ -# while $(DX_EGREP) 'Rerun (LaTeX|to get cross-references right)' \ -# refman.log > /dev/null 2>&1 \ -# && test $$countdown -gt 0; do \ -# $(DX_PDFLATEX) refman.tex; \ -# countdown=`expr $$countdown - 1`; \ -# done; \ -# mv refman.pdf ../@PACKAGE@.pdf -# -# endif DX_COND_pdf -# -# ## ------------------------------------------------- ## -# ## Rules specific for LaTeX (shared for PS and PDF). ## -# ## ------------------------------------------------- ## -# -# if DX_COND_latex -# -# DX_CLEAN_LATEX = @DX_DOCDIR@/latex -# -# endif DX_COND_latex -# -# .PHONY: doxygen-run doxygen-doc $(DX_PS_GOAL) $(DX_PDF_GOAL) -# -# .INTERMEDIATE: doxygen-run $(DX_PS_GOAL) $(DX_PDF_GOAL) -# -# doxygen-run: @DX_DOCDIR@/@PACKAGE@.tag -# -# doxygen-doc: doxygen-run $(DX_PS_GOAL) $(DX_PDF_GOAL) -# -# @DX_DOCDIR@/@PACKAGE@.tag: $(DX_CONFIG) $(pkginclude_HEADERS) -# rm -rf @DX_DOCDIR@ -# $(DX_ENV) $(DX_DOXYGEN) $(srcdir)/$(DX_CONFIG) -# echo Timestamp >$@ -# -# DX_CLEANFILES = \ -# @DX_DOCDIR@/@PACKAGE@.tag \ -# -r \ -# $(DX_CLEAN_HTML) \ -# $(DX_CLEAN_CHM) \ -# $(DX_CLEAN_CHI) \ -# $(DX_CLEAN_MAN) \ -# $(DX_CLEAN_RTF) \ -# $(DX_CLEAN_XML) \ -# $(DX_CLEAN_PS) \ -# $(DX_CLEAN_PDF) \ -# $(DX_CLEAN_LATEX) -# -# endif DX_COND_doc -# -# ----- end aminclude.am --------------------------------------- -# -# LICENSE -# -# Copyright (c) 2009 Oren Ben-Kiki -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 13 - -## ----------## -## Defaults. ## -## ----------## - -DX_ENV="" -AC_DEFUN([DX_FEATURE_doc], ON) -AC_DEFUN([DX_FEATURE_dot], OFF) -AC_DEFUN([DX_FEATURE_man], OFF) -AC_DEFUN([DX_FEATURE_html], ON) -AC_DEFUN([DX_FEATURE_chm], OFF) -AC_DEFUN([DX_FEATURE_chi], OFF) -AC_DEFUN([DX_FEATURE_rtf], OFF) -AC_DEFUN([DX_FEATURE_xml], OFF) -AC_DEFUN([DX_FEATURE_pdf], ON) -AC_DEFUN([DX_FEATURE_ps], ON) - -## --------------- ## -## Private macros. ## -## --------------- ## - -# DX_ENV_APPEND(VARIABLE, VALUE) -# ------------------------------ -# Append VARIABLE="VALUE" to DX_ENV for invoking doxygen. -AC_DEFUN([DX_ENV_APPEND], [ - AC_SUBST([DX_ENV], ["$DX_ENV $1='$2'"]) - ]) - -# DX_DIRNAME_EXPR -# --------------- -# Expand into a shell expression prints the directory part of a path. -AC_DEFUN([DX_DIRNAME_EXPR], - [[expr ".$1" : '\(\.\)[^/]*$' \| "x$1" : 'x\(.*\)/[^/]*$']]) - -# DX_IF_FEATURE(FEATURE, IF-ON, IF-OFF) -# ------------------------------------- -# Expands according to the M4 (static) status of the feature. -AC_DEFUN([DX_IF_FEATURE], [ifelse(DX_FEATURE_$1, ON, [$2], [$3])]) - -# DX_REQUIRE_PROG(VARIABLE, PROGRAM) -# ---------------------------------- -# Require the specified program to be found for the DX_CURRENT_FEATURE to work. -AC_DEFUN([DX_REQUIRE_PROG], [ -AC_PATH_TOOL([$1], [$2]) -if test "$DX_FLAG_[]DX_CURRENT_FEATURE$$1" = 1; then - AC_MSG_WARN([$2 not found - will not DX_CURRENT_DESCRIPTION]) - AC_SUBST(DX_FLAG_[]DX_CURRENT_FEATURE, 0) -fi -]) - -# DX_TEST_FEATURE(FEATURE) -# ------------------------ -# Expand to a shell expression testing whether the feature is active. -AC_DEFUN([DX_TEST_FEATURE], [test "$DX_FLAG_$1" = 1]) - -# DX_CHECK_DEPEND(REQUIRED_FEATURE, REQUIRED_STATE) -# ------------------------------------------------- -# Verify that a required features has the right state before trying to turn on -# the DX_CURRENT_FEATURE. -AC_DEFUN([DX_CHECK_DEPEND], [ -test "$DX_FLAG_$1" = "$2" \ -|| AC_MSG_ERROR([doxygen-DX_CURRENT_FEATURE ifelse([$2], 1, - requires, contradicts) doxygen-DX_CURRENT_FEATURE]) -]) - -# DX_CLEAR_DEPEND(FEATURE, REQUIRED_FEATURE, REQUIRED_STATE) -# ---------------------------------------------------------- -# Turn off the DX_CURRENT_FEATURE if the required feature is off. -AC_DEFUN([DX_CLEAR_DEPEND], [ -test "$DX_FLAG_$1" = "$2" || AC_SUBST(DX_FLAG_[]DX_CURRENT_FEATURE, 0) -]) - -# DX_FEATURE_ARG(FEATURE, DESCRIPTION, -# CHECK_DEPEND, CLEAR_DEPEND, -# REQUIRE, DO-IF-ON, DO-IF-OFF) -# -------------------------------------------- -# Parse the command-line option controlling a feature. CHECK_DEPEND is called -# if the user explicitly turns the feature on (and invokes DX_CHECK_DEPEND), -# otherwise CLEAR_DEPEND is called to turn off the default state if a required -# feature is disabled (using DX_CLEAR_DEPEND). REQUIRE performs additional -# requirement tests (DX_REQUIRE_PROG). Finally, an automake flag is set and -# DO-IF-ON or DO-IF-OFF are called according to the final state of the feature. -AC_DEFUN([DX_ARG_ABLE], [ - AC_DEFUN([DX_CURRENT_FEATURE], [$1]) - AC_DEFUN([DX_CURRENT_DESCRIPTION], [$2]) - AC_ARG_ENABLE(doxygen-$1, - [AS_HELP_STRING(DX_IF_FEATURE([$1], [--disable-doxygen-$1], - [--enable-doxygen-$1]), - DX_IF_FEATURE([$1], [don't $2], [$2]))], - [ -case "$enableval" in -#( -y|Y|yes|Yes|YES) - AC_SUBST([DX_FLAG_$1], 1) - $3 -;; #( -n|N|no|No|NO) - AC_SUBST([DX_FLAG_$1], 0) -;; #( -*) - AC_MSG_ERROR([invalid value '$enableval' given to doxygen-$1]) -;; -esac -], [ -AC_SUBST([DX_FLAG_$1], [DX_IF_FEATURE([$1], 1, 0)]) -$4 -]) -if DX_TEST_FEATURE([$1]); then - $5 - : -fi -AM_CONDITIONAL(DX_COND_$1, DX_TEST_FEATURE([$1])) -if DX_TEST_FEATURE([$1]); then - $6 - : -else - $7 - : -fi -]) - -## -------------- ## -## Public macros. ## -## -------------- ## - -# DX_XXX_FEATURE(DEFAULT_STATE) -# ----------------------------- -AC_DEFUN([DX_DOXYGEN_FEATURE], [AC_DEFUN([DX_FEATURE_doc], [$1])]) -AC_DEFUN([DX_DOT_FEATURE], [AC_DEFUN([DX_FEATURE_dot], [$1])]) -AC_DEFUN([DX_MAN_FEATURE], [AC_DEFUN([DX_FEATURE_man], [$1])]) -AC_DEFUN([DX_HTML_FEATURE], [AC_DEFUN([DX_FEATURE_html], [$1])]) -AC_DEFUN([DX_CHM_FEATURE], [AC_DEFUN([DX_FEATURE_chm], [$1])]) -AC_DEFUN([DX_CHI_FEATURE], [AC_DEFUN([DX_FEATURE_chi], [$1])]) -AC_DEFUN([DX_RTF_FEATURE], [AC_DEFUN([DX_FEATURE_rtf], [$1])]) -AC_DEFUN([DX_XML_FEATURE], [AC_DEFUN([DX_FEATURE_xml], [$1])]) -AC_DEFUN([DX_XML_FEATURE], [AC_DEFUN([DX_FEATURE_xml], [$1])]) -AC_DEFUN([DX_PDF_FEATURE], [AC_DEFUN([DX_FEATURE_pdf], [$1])]) -AC_DEFUN([DX_PS_FEATURE], [AC_DEFUN([DX_FEATURE_ps], [$1])]) - -# DX_INIT_DOXYGEN(PROJECT, [CONFIG-FILE], [OUTPUT-DOC-DIR]) -# --------------------------------------------------------- -# PROJECT also serves as the base name for the documentation files. -# The default CONFIG-FILE is "Doxyfile" and OUTPUT-DOC-DIR is "doxygen-doc". -AC_DEFUN([DX_INIT_DOXYGEN], [ - -# Files: -AC_SUBST([DX_PROJECT], [$1]) -AC_SUBST([DX_CONFIG], [ifelse([$2], [], doxygen.cfg, [$2])]) -AC_SUBST([DX_DOCDIR], [ifelse([$3], [], docs, [$3])]) - -# Environment variables used inside doxygen.cfg: -# TODO: should remove some of these -abs_srcdir=`(cd $srcdir && pwd)` -DX_ENV_APPEND(SRCDIR, $abs_srcdir) -DX_ENV_APPEND(PROJECT, $DX_PROJECT) -DX_ENV_APPEND(DOCDIR, $DX_DOCDIR) -DX_ENV_APPEND(VERSION, $PACKAGE_VERSION) - -# Doxygen itself: -DX_ARG_ABLE(doc, [generate any doxygen documentation], - [], - [], - [DX_REQUIRE_PROG([DX_DOXYGEN], doxygen) - DX_REQUIRE_PROG([DX_PERL], perl)], - [DX_ENV_APPEND(PERL_PATH, $DX_PERL)]) - -# Dot for graphics: -DX_ARG_ABLE(dot, [generate graphics for doxygen documentation], - [DX_CHECK_DEPEND(doc, 1)], - [DX_CLEAR_DEPEND(doc, 1)], - [DX_REQUIRE_PROG([DX_DOT], dot)], - [DX_ENV_APPEND(HAVE_DOT, YES) - DX_ENV_APPEND(DOT_PATH, [`DX_DIRNAME_EXPR($DX_DOT)`])], - [DX_ENV_APPEND(HAVE_DOT, NO)]) - -# Man pages generation: -DX_ARG_ABLE(man, [generate doxygen manual pages], - [DX_CHECK_DEPEND(doc, 1)], - [DX_CLEAR_DEPEND(doc, 1)], - [], - [DX_ENV_APPEND(GENERATE_MAN, YES)], - [DX_ENV_APPEND(GENERATE_MAN, NO)]) - -# RTF file generation: -DX_ARG_ABLE(rtf, [generate doxygen RTF documentation], - [DX_CHECK_DEPEND(doc, 1)], - [DX_CLEAR_DEPEND(doc, 1)], - [], - [DX_ENV_APPEND(GENERATE_RTF, YES)], - [DX_ENV_APPEND(GENERATE_RTF, NO)]) - -# XML file generation: -DX_ARG_ABLE(xml, [generate doxygen XML documentation], - [DX_CHECK_DEPEND(doc, 1)], - [DX_CLEAR_DEPEND(doc, 1)], - [], - [DX_ENV_APPEND(GENERATE_XML, YES)], - [DX_ENV_APPEND(GENERATE_XML, NO)]) - -# (Compressed) HTML help generation: -DX_ARG_ABLE(chm, [generate doxygen compressed HTML help documentation], - [DX_CHECK_DEPEND(doc, 1)], - [DX_CLEAR_DEPEND(doc, 1)], - [DX_REQUIRE_PROG([DX_HHC], hhc)], - [DX_ENV_APPEND(HHC_PATH, $DX_HHC) - DX_ENV_APPEND(GENERATE_HTML, YES) - DX_ENV_APPEND(GENERATE_HTMLHELP, YES)], - [DX_ENV_APPEND(GENERATE_HTMLHELP, NO)]) - -# Seperate CHI file generation. -DX_ARG_ABLE(chi, [generate doxygen seperate compressed HTML help index file], - [DX_CHECK_DEPEND(chm, 1)], - [DX_CLEAR_DEPEND(chm, 1)], - [], - [DX_ENV_APPEND(GENERATE_CHI, YES)], - [DX_ENV_APPEND(GENERATE_CHI, NO)]) - -# Plain HTML pages generation: -DX_ARG_ABLE(html, [generate doxygen plain HTML documentation], - [DX_CHECK_DEPEND(doc, 1) DX_CHECK_DEPEND(chm, 0)], - [DX_CLEAR_DEPEND(doc, 1) DX_CLEAR_DEPEND(chm, 0)], - [], - [DX_ENV_APPEND(GENERATE_HTML, YES)], - [DX_TEST_FEATURE(chm) || DX_ENV_APPEND(GENERATE_HTML, NO)]) - -# PostScript file generation: -DX_ARG_ABLE(ps, [generate doxygen PostScript documentation], - [DX_CHECK_DEPEND(doc, 1)], - [DX_CLEAR_DEPEND(doc, 1)], - [DX_REQUIRE_PROG([DX_LATEX], latex) - DX_REQUIRE_PROG([DX_MAKEINDEX], makeindex) - DX_REQUIRE_PROG([DX_DVIPS], dvips) - DX_REQUIRE_PROG([DX_EGREP], egrep)]) - -# PDF file generation: -DX_ARG_ABLE(pdf, [generate doxygen PDF documentation], - [DX_CHECK_DEPEND(doc, 1)], - [DX_CLEAR_DEPEND(doc, 1)], - [DX_REQUIRE_PROG([DX_PDFLATEX], pdflatex) - DX_REQUIRE_PROG([DX_MAKEINDEX], makeindex) - DX_REQUIRE_PROG([DX_EGREP], egrep)]) - -# LaTeX generation for PS and/or PDF: -AM_CONDITIONAL(DX_COND_latex, DX_TEST_FEATURE(ps) || DX_TEST_FEATURE(pdf)) -if DX_TEST_FEATURE(ps) || DX_TEST_FEATURE(pdf); then - DX_ENV_APPEND(GENERATE_LATEX, YES) -else - DX_ENV_APPEND(GENERATE_LATEX, NO) -fi - -# Paper size for PS and/or PDF: -AC_ARG_VAR(DOXYGEN_PAPER_SIZE, - [a4wide (default), a4, letter, legal or executive]) -case "$DOXYGEN_PAPER_SIZE" in -#( -"") - AC_SUBST(DOXYGEN_PAPER_SIZE, "") -;; #( -a4wide|a4|letter|legal|executive) - DX_ENV_APPEND(PAPER_SIZE, $DOXYGEN_PAPER_SIZE) -;; #( -*) - AC_MSG_ERROR([unknown DOXYGEN_PAPER_SIZE='$DOXYGEN_PAPER_SIZE']) -;; -esac - -#For debugging: -#echo DX_FLAG_doc=$DX_FLAG_doc -#echo DX_FLAG_dot=$DX_FLAG_dot -#echo DX_FLAG_man=$DX_FLAG_man -#echo DX_FLAG_html=$DX_FLAG_html -#echo DX_FLAG_chm=$DX_FLAG_chm -#echo DX_FLAG_chi=$DX_FLAG_chi -#echo DX_FLAG_rtf=$DX_FLAG_rtf -#echo DX_FLAG_xml=$DX_FLAG_xml -#echo DX_FLAG_pdf=$DX_FLAG_pdf -#echo DX_FLAG_ps=$DX_FLAG_ps -#echo DX_ENV=$DX_ENV -]) diff --git a/m4/m4_ax_prog_wine.m4 b/m4/m4_ax_prog_wine.m4 deleted file mode 100644 index a504d55d19..0000000000 --- a/m4/m4_ax_prog_wine.m4 +++ /dev/null @@ -1,5 +0,0 @@ - -dnl # TO BE CONTINUED: -dnl # -dnl # currently wine check resides in m4_ax_mdsplus_testing.m4 - diff --git a/m4/m4_ax_python_architecture.m4 b/m4/m4_ax_python_architecture.m4 deleted file mode 100644 index f8dda91f3c..0000000000 --- a/m4/m4_ax_python_architecture.m4 +++ /dev/null @@ -1,16 +0,0 @@ - -AC_DEFUN([AX_PYTHON_ARCH], [ - AX_PYTHON_MODULE([platform], [required], [${PYTHON}]) - AC_MSG_CHECKING([for python architecture]) - AS_VAR_SET([_python_arch], - [`${PYTHON} -c "import sys, platform; sys.stdout.write(platform.architecture()[[0]])"`]) - - AS_VAR_IF([_python_arch],[64bit],[ - ${PYTHON} -c "import sys; sys.exit(sys.maxsize <= 2**32)" - AS_IF([test $? -eq 0],[],[ - AS_VAR_SET([_python_arch],[32bit])]) - ]) - - AC_MSG_RESULT([${_python_arch}]) - AS_VAR_SET([$1],[${_python_arch}]) -]) diff --git a/m4/m4_ax_python_config_var.m4 b/m4/m4_ax_python_config_var.m4 deleted file mode 100644 index fe467b447a..0000000000 --- a/m4/m4_ax_python_config_var.m4 +++ /dev/null @@ -1,114 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_python_config_var.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_PYTHON_CONFIG_VAR(PYTHON_VARIABLE, [SHELL_VARIABLE]) -# AX_PYTHON_CONFIG_H -# AX_PYTHON_MAKEFILE -# -# DESCRIPTION -# -# AX_PYTHON_CONFIG_VAR: -# -# Using the Python module distutils.sysconfig[1], return a Python -# configuration variable. PYTHON_VARIABLE is the name of the variable to -# request from Python, and SHELL_VARIABLE is the name of the shell -# variable into which the results should be deposited. If SHELL_VARIABLE -# is not specified, the macro wil prefix PY_ to the PYTHON_VARIABLE, e.g., -# LIBS -> PY_LIBS. -# -# SHELL_VARIABLE is AC_SUBST'd. No action is taken if an error occurs. -# Note if $PYTHON is not set, AC_CHECK_PROG(PYTHON, python, python) will -# be run. -# -# Example: -# -# AX_PYTHON_CONFIG_VAR(LINKFORSHARED, PY_LFS) -# -# AX_PYTHON_CONFIG_H: -# -# Using the Python module distutils.sysconfig[1], put the full pathname of -# the config.h file used to compile Python into the shell variable -# PY_CONFIG_H. PY_CONFIG_H is AC_SUBST'd. Note if $PYTHON is not set, -# AC_CHECK_PROG(PYTHON, python, python) will be run. -# -# AX_PYTHON_MAKEFILE: -# -# Using the Python module distutils.sysconfig[1], put the full pathname of -# the Makefile file used to compile Python into the shell variable -# PY_MAKEFILE. PY_MAKEFILE is AC_SUBST'd. Note if $PYTHON is not set, -# AC_CHECK_PROG(PYTHON, python, python) will be run. -# -# [1] -# http://www.python.org/doc/current/dist/module-distutils.sysconfig.html -# -# LICENSE -# -# Copyright (c) 2008 Dustin J. Mitchell -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 9 - -AC_DEFUN([AX_PYTHON_CONFIG_VAR], -[ - AC_MSG_CHECKING(for Python config variable $1) - if test -z "$PYTHON" - then - AC_CHECK_PROG(PYTHON,python,python) - fi - py_error="no" - pyval=`$PYTHON -c "from distutils import sysconfig;dnl -print sysconfig.get_config_var('$1')"` || py_error="yes" - if test "$py_error" = "yes" - then - AC_MSG_RESULT(no - an error occurred) - else - AC_MSG_RESULT($pyval) - m4_ifval([$2],[$2],[PY_$1])="$pyval" - AC_SUBST(m4_ifval([$2],[$2],[PY_$1])) - fi -]) - -AC_DEFUN([AX_PYTHON_CONFIG_H], -[ - AC_MSG_CHECKING(location of Python's config.h) - if test -z "$PYTHON" - then - AC_CHECK_PROG(PYTHON,python,python) - fi - py_error="no" - PY_CONFIG_H=`$PYTHON -c "from distutils import sysconfig;dnl -print sysconfig.get_config_h_filename()"` || py_error = "yes" - if test "$py_error" = "yes" - then - AC_MSG_RESULT(no - an error occurred) - else - AC_MSG_RESULT($PY_CONFIG_H) - AC_SUBST(PY_CONFIG_H) - fi -]) - -AC_DEFUN([AX_PYTHON_MAKEFILE], -[ - AC_MSG_CHECKING(location of Python's Makefile) - if test -z "$PYTHON" - then - AC_CHECK_PROG(PYTHON,python,python) - fi - py_error="no" - PY_MAKEFILE=`$PYTHON -c "from distutils import sysconfig;dnl -print sysconfig.get_makefile_filename()"` || py_error = "yes" - if test "$py_error" = "yes" - then - AC_MSG_RESULT(no - an error occurred) - else - AC_MSG_RESULT($PY_MAKEFILE) - AC_SUBST(PY_MAKEFILE) - fi -]) diff --git a/m4/m4_ax_python_devel.m4 b/m4/m4_ax_python_devel.m4 deleted file mode 100644 index f18ed8a01c..0000000000 --- a/m4/m4_ax_python_devel.m4 +++ /dev/null @@ -1,327 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_python_devel.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_PYTHON_DEVEL([version]) -# -# DESCRIPTION -# -# Note: Defines as a precious variable "PYTHON_VERSION". Don't override it -# in your configure.ac. -# -# This macro checks for Python and tries to get the include path to -# 'Python.h'. It provides the $(PYTHON_CPPFLAGS) and $(PYTHON_LIBS) output -# variables. It also exports $(PYTHON_EXTRA_LIBS) and -# $(PYTHON_EXTRA_LDFLAGS) for embedding Python in your code. -# -# You can search for some particular version of Python by passing a -# parameter to this macro, for example ">= '2.3.1'", or "== '2.4'". Please -# note that you *have* to pass also an operator along with the version to -# match, and pay special attention to the single quotes surrounding the -# version number. Don't use "PYTHON_VERSION" for this: that environment -# variable is declared as precious and thus reserved for the end-user. -# -# This macro should work for all versions of Python >= 2.1.0. As an end -# user, you can disable the check for the python version by setting the -# PYTHON_NOVERSIONCHECK environment variable to something else than the -# empty string. -# -# If you need to use this macro for an older Python version, please -# contact the authors. We're always open for feedback. -# -# LICENSE -# -# Copyright (c) 2009 Sebastian Huber -# Copyright (c) 2009 Alan W. Irwin -# Copyright (c) 2009 Rafael Laboissiere -# Copyright (c) 2009 Andrew Collier -# Copyright (c) 2009 Matteo Settenvini -# Copyright (c) 2009 Horst Knorr -# Copyright (c) 2013 Daniel Mullner -# -# 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 3 of the License, 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, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 18 - -AU_ALIAS([AC_PYTHON_DEVEL], [AX_PYTHON_DEVEL]) -AC_DEFUN([AX_PYTHON_DEVEL],[ - # - # Allow the use of a (user set) custom python version - # - AC_ARG_VAR([PYTHON_VERSION],[The installed Python - version to use, for example '2.3'. This string - will be appended to the Python interpreter - canonical name.]) - - AC_PATH_PROG([PYTHON],[python[$PYTHON_VERSION]]) - if test -z "$PYTHON"; then - AC_MSG_ERROR([Cannot find python$PYTHON_VERSION in your system path]) - PYTHON_VERSION="" - fi - - # - # Check for a version of Python >= 2.1.0 - # - AC_MSG_CHECKING([for a version of Python >= '2.1.0']) - ac_supports_python_ver=`$PYTHON -c "import sys; \ - ver = sys.version.split ()[[0]]; \ - print (ver >= '2.1.0')"` - if test "$ac_supports_python_ver" != "True"; then - if test -z "$PYTHON_NOVERSIONCHECK"; then - AC_MSG_RESULT([no]) - AC_MSG_FAILURE([ -This version of the AC@&t@_PYTHON_DEVEL macro -doesn't work properly with versions of Python before -2.1.0. You may need to re-run configure, setting the -variables PYTHON_CPPFLAGS, PYTHON_LIBS, PYTHON_SITE_PKG, -PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand. -Moreover, to disable this check, set PYTHON_NOVERSIONCHECK -to something else than an empty string. -]) - else - AC_MSG_RESULT([skip at user request]) - fi - else - AC_MSG_RESULT([yes]) - fi - - # - # if the macro parameter ``version'' is set, honour it - # - if test -n "$1"; then - AC_MSG_CHECKING([for a version of Python $1]) - ac_supports_python_ver=`$PYTHON -c "import sys; \ - ver = sys.version.split ()[[0]]; \ - print (ver $1)"` - if test "$ac_supports_python_ver" = "True"; then - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - AC_MSG_ERROR([this package requires Python $1. -If you have it installed, but it isn't the default Python -interpreter in your system path, please pass the PYTHON_VERSION -variable to configure. See ``configure --help'' for reference. -]) - PYTHON_VERSION="" - fi - fi - - # - # Check if you have distutils, else fail - # - AC_MSG_CHECKING([for the distutils Python package]) - ac_distutils_result=`$PYTHON -c "import distutils" 2>&1` - if test -z "$ac_distutils_result"; then - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - AC_MSG_ERROR([cannot import Python module "distutils". -Please check your Python installation. The error was: -$ac_distutils_result]) - PYTHON_VERSION="" - fi - - # - # Check for Python include path - # - AC_MSG_CHECKING([for Python include path]) - if test -z "$PYTHON_CPPFLAGS"; then - python_path=`$PYTHON -c "import distutils.sysconfig; \ - print (distutils.sysconfig.get_python_inc ());"` - plat_python_path=`$PYTHON -c "import distutils.sysconfig; \ - print (distutils.sysconfig.get_python_inc (plat_specific=1));"` - if test -n "${python_path}"; then - if test "${plat_python_path}" != "${python_path}"; then - python_path="-I$python_path -I$plat_python_path" - else - python_path="-I$python_path" - fi - fi - PYTHON_CPPFLAGS=$python_path - fi - AC_MSG_RESULT([$PYTHON_CPPFLAGS]) - AC_SUBST([PYTHON_CPPFLAGS]) - - # - # Check for Python library path - # - AC_MSG_CHECKING([for Python library path]) - if test -z "$PYTHON_LIBS"; then - # (makes two attempts to ensure we've got a version number - # from the interpreter) - ac_python_version=`cat<]], - [[Py_Initialize();]]) - ],[pythonexists=yes],[pythonexists=no]) - AC_LANG_POP([C]) - # turn back to default flags - CPPFLAGS="$ac_save_CPPFLAGS" - LIBS="$ac_save_LIBS" - LDFLAGS="$ac_save_LDFLAGS" - - AC_MSG_RESULT([$pythonexists]) - - if test ! "x$pythonexists" = "xyes"; then - AC_MSG_FAILURE([ - Could not link test program to Python. Maybe the main Python library has been - installed in some non-standard library path. If so, pass it to configure, - via the LIBS environment variable. - Example: ./configure LIBS="-L/usr/non-standard-path/python/lib" - ============================================================================ - ERROR! - You probably have to install the development version of the Python package - for your distribution. The exact name of this package varies among them. - ============================================================================ - ]) - PYTHON_VERSION="" - fi - - # - # all done! - # -]) diff --git a/m4/m4_ax_python_module.m4 b/m4/m4_ax_python_module.m4 deleted file mode 100644 index 89d24149ce..0000000000 --- a/m4/m4_ax_python_module.m4 +++ /dev/null @@ -1,71 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_python_module.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_PYTHON_MODULE(modname[, fatal, python]) -# -# DESCRIPTION -# -# Checks for Python module. -# -# If fatal is non-empty then absence of a module will trigger an error. -# The third parameter can either be "python" for Python 2 or "python3" for -# Python 3; defaults to Python 3. -# -# LICENSE -# -# Copyright (c) 2008 Andrew Collier -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 8 - -AU_ALIAS([AC_PYTHON_MODULE], [AX_PYTHON_MODULE]) -AC_DEFUN([AX_PYTHON_MODULE],[ - if test -z $PYTHON; - then - if test -z "$3"; - then - PYTHON="python3" - else - PYTHON="$3" - fi - fi - PYTHON_NAME=`basename $PYTHON` - AC_MSG_CHECKING($PYTHON_NAME module: $1) - $PYTHON -c "import $1" 2>/dev/null - if test $? -eq 0; - then - AC_MSG_RESULT(yes) - eval AS_TR_CPP(HAVE_PYMOD_$1)=yes - else - AC_MSG_RESULT(no) - eval AS_TR_CPP(HAVE_PYMOD_$1)=no - # - if test -n "$2" - then - AC_MSG_ERROR(failed to find required module $1) - exit 1 - fi - fi -]) - - -dnl AC_PYTHON_CLASS(module,class,[action-if-true],[action-if-false],[python]) -AU_ALIAS([AC_PYTHON_MODULE_CLASS],[AX_PYTHON_MODULE_CLASS]) -AC_DEFUN([AX_PYTHON_MODULE_CLASS],[ - AX_PYTHON_MODULE($1,,$5) - AC_MSG_CHECKING(python class $1.$2) - AS_IF([ test "$PYTHON" == : ], - [AC_MSG_ERROR(no python executable was found); AS_EXIT],) - - $PYTHON -c "import inspect,$1; exit(inspect.isclass($1.$2) != True);" 2>/dev/null - AS_IF([test $? -eq 0], - [AC_MSG_RESULT(yes); eval $3], - [AC_MSG_RESULT(no); eval $4]) -]) diff --git a/m4/m4_ax_python_module_version.m4 b/m4/m4_ax_python_module_version.m4 deleted file mode 100644 index 0ffb7b09cc..0000000000 --- a/m4/m4_ax_python_module_version.m4 +++ /dev/null @@ -1,37 +0,0 @@ -# ============================================================================ -# http://www.gnu.org/software/autoconf-archive/ax_python_module_version.html -# ============================================================================ -# -# SYNOPSIS -# -# AX_PYTHON_MODULE_VERSION(modname, min_version[, python]) -# -# DESCRIPTION -# -# Checks for Python module with at least the given version. -# -# Triggers an error if module is absent or present but at a lower version. -# The third parameter can either be "python" for Python 2 or "python3" for -# Python 3; defaults to Python 3. -# -# LICENSE -# -# Copyright (c) 2015 Endless Mobile, Inc.; contributed by Philip Chimento and Kurt von Laven -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 2 - -AC_DEFUN([AX_PYTHON_MODULE_VERSION], [ - AX_PYTHON_MODULE([$1], [required], [$3]) - AC_MSG_CHECKING([for version $2 or higher of $1]) - $PYTHON -c "import sys, $1; from distutils.version import StrictVersion; sys.exit(StrictVersion($1.__version__) < StrictVersion('$2'))" 2> /dev/null - AS_IF([test $? -eq 0], [], [ - AC_MSG_RESULT([no]) - AC_MSG_ERROR([You need at least version $2 of the $1 Python module.]) - ]) - AC_MSG_RESULT([yes]) -]) diff --git a/m4/m4_ax_python_version.m4 b/m4/m4_ax_python_version.m4 deleted file mode 100644 index e98ba6c5cf..0000000000 --- a/m4/m4_ax_python_version.m4 +++ /dev/null @@ -1,222 +0,0 @@ -# AX_PATH_PYTHON([MINIMUM-VERSION], [HOST], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) -# --------------------------------------------------------------------------- -# Adds support for distributing Python modules and packages. To -# install modules, copy them to $(pythondir), using the python_PYTHON -# automake variable. To install a package with the same name as the -# automake package, install to $(pkgpythondir), or use the -# pkgpython_PYTHON automake variable. -# -# The variables $(pyexecdir) and $(pkgpyexecdir) are provided as -# locations to install python extension modules (shared libraries). -# Another macro is required to find the appropriate flags to compile -# extension modules. -# -# If your package is configured with a different prefix to python, -# users will have to add the install directory to the PYTHONPATH -# environment variable, or create a .pth file (see the python -# documentation for details). -# -# If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will -# cause an error if the version of python installed on the system -# doesn't meet the requirement. MINIMUM-VERSION should consist of -# numbers and dots only. -AC_DEFUN([AX_PATH_PYTHON], - [ - dnl Find a Python interpreter. Python versions prior to 2.0 are not - dnl supported. (2.0 was released on October 16, 2000). - m4_define_default([_AM_PYTHON_INTERPRETER_LIST], -[python3 python2 python dnl - python3.7 python3.6 python3.5 python3.4 python3.3 python3.2 python3.1 python3.0 dnl - python2.7 python2.6]) - - AC_ARG_VAR([PYTHON], [the Python interpreter]) - - m4_if([$1],[],[ - dnl No version check is needed. - # Find any Python interpreter. - if test -z "$PYTHON"; then - AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :) - fi - am_display_PYTHON=python - ], [ - dnl A version check is needed. - if test -n "$PYTHON"; then - # If the user set $PYTHON, use it and don't search something else. - AC_MSG_CHECKING([whether $PYTHON meets requirements (numpy,nose,version>=$1,$2)]) - AX_PYTHON_CHECK_VERSION([$PYTHON], [$1], [$2], - [AC_MSG_RESULT([yes])], - [AC_MSG_RESULT([no]) - AC_MSG_ERROR([Python interpreter does not meet requirements])]) - am_display_PYTHON=$PYTHON - else - # Otherwise, try each interpreter until we find one that satisfies - # VERSION. - AC_CACHE_CHECK([for a Python interpreter meeting requirements (numpy,nose,version>=$1,$2)], - [am_cv_pathless_PYTHON],[ - for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do - test "$am_cv_pathless_PYTHON" = none && break - AX_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [$2], [break]) - done]) - # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON. - if test "$am_cv_pathless_PYTHON" = none; then - PYTHON=: - else - AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON]) - fi - am_display_PYTHON=$am_cv_pathless_PYTHON - fi - ]) - - if test "$PYTHON" = :; then - dnl Run any user-specified action, or abort. - m4_default([$4], [AC_MSG_ERROR([no suitable Python interpreter found])]) - else - - dnl Query Python for its version number. Getting [:3] seems to be - dnl the best way to do this; it's what "site.py" does in the standard - dnl library. - - AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version], - [am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[[:3]])"`]) - AC_SUBST([PYTHON_VERSION], [$am_cv_python_version]) - - dnl Use the values of $prefix and $exec_prefix for the corresponding - dnl values of PYTHON_PREFIX and PYTHON_EXEC_PREFIX. These are made - dnl distinct variables so they can be overridden if need be. However, - dnl general consensus is that you shouldn't need this ability. - - AC_SUBST([PYTHON_PREFIX], ['${prefix}']) - AC_SUBST([PYTHON_EXEC_PREFIX], ['${exec_prefix}']) - - dnl At times (like when building shared libraries) you may want - dnl to know which OS platform Python thinks this is. - - AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform], - [am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`]) - AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform]) - - # Just factor out some code duplication. - am_python_setup_sysconfig="\ -import sys -# Prefer sysconfig over distutils.sysconfig, for better compatibility -# with python 3.x. See automake bug#10227. -try: - import sysconfig -except ImportError: - can_use_sysconfig = 0 -else: - can_use_sysconfig = 1 -# Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs: -# -try: - from platform import python_implementation - if python_implementation() == 'CPython' and sys.version[[:3]] == '2.7': - can_use_sysconfig = 0 -except ImportError: - pass" - - dnl Set up 4 directories: - - dnl pythondir -- where to install python scripts. This is the - dnl site-packages directory, not the python standard library - dnl directory like in previous automake betas. This behavior - dnl is more consistent with lispdir.m4 for example. - dnl Query distutils for this directory. - AC_CACHE_CHECK([for $am_display_PYTHON script directory], - [am_cv_python_pythondir], - [if test "x$prefix" = xNONE - then - am_py_prefix=$ac_default_prefix - else - am_py_prefix=$prefix - fi - am_cv_python_pythondir=`$PYTHON -c " -$am_python_setup_sysconfig -if can_use_sysconfig: - sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'}) -else: - from distutils import sysconfig - sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix') -sys.stdout.write(sitedir)"` - case $am_cv_python_pythondir in - $am_py_prefix*) - am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'` - am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"` - ;; - *) - case $am_py_prefix in - /usr|/System*) ;; - *) - am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages - ;; - esac - ;; - esac - ]) - AC_SUBST([pythondir], [$am_cv_python_pythondir]) - - dnl pkgpythondir -- $PACKAGE directory under pythondir. Was - dnl PYTHON_SITE_PACKAGE in previous betas, but this naming is - dnl more consistent with the rest of automake. - - AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE]) - - dnl pyexecdir -- directory for installing python extension modules - dnl (shared libraries) - dnl Query distutils for this directory. - AC_CACHE_CHECK([for $am_display_PYTHON extension module directory], - [am_cv_python_pyexecdir], - [if test "x$exec_prefix" = xNONE - then - am_py_exec_prefix=$am_py_prefix - else - am_py_exec_prefix=$exec_prefix - fi - am_cv_python_pyexecdir=`$PYTHON -c " -$am_python_setup_sysconfig -if can_use_sysconfig: - sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'}) -else: - from distutils import sysconfig - sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix') -sys.stdout.write(sitedir)"` - case $am_cv_python_pyexecdir in - $am_py_exec_prefix*) - am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'` - am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"` - ;; - *) - case $am_py_exec_prefix in - /usr|/System*) ;; - *) - am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages - ;; - esac - ;; - esac - ]) - AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir]) - - dnl pkgpyexecdir -- $(pyexecdir)/$(PACKAGE) - - AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE]) - - dnl Run any user-specified action. - $3 - fi - -]) - -# AX_PYTHON_CHECK_VERSION(PROG, VERSION, ARCH, [ACTION-IF-TRUE], [ACTION-IF-FALSE]) -# --------------------------------------------------------------------------- -# Run ACTION-IF-TRUE if the Python interpreter meets requirements, i.e. nose numpy version and bits -# Run ACTION-IF-FALSE otherwise. -AC_DEFUN([AX_PYTHON_CHECK_VERSION], - [prog="import sys,nose,numpy -is32 = sys.maxsize == 0x7fffffff -archok = is32 if 'i686' in '$3' else not is32 -minver = tuple(map(int, '$2'.split('.'))) -verok = minver<=sys.version_info -# xrange is not present in Python 3.0 and range returns an iterator -sys.exit(not (verok and archok))" - AS_IF([AM_RUN_LOG([$1 -c "$prog" 2>/dev/null])], [$4], [$5])]) diff --git a/m4/m4_ax_sanitize_check.m4 b/m4/m4_ax_sanitize_check.m4 deleted file mode 100644 index 6a2a014694..0000000000 --- a/m4/m4_ax_sanitize_check.m4 +++ /dev/null @@ -1,112 +0,0 @@ -# -# SYNOPSIS -# -# AX_ENABLE_SANITIZE([variable name],[action if sanitizer found], -# [action if sanitizer not found]) -# -# DESCRIPTION -# - - -#serial 1 - - -# AX_CHECK_SANITIZE([name],[flags],[action if found],[action if not found]) -# if found defines: sanitize_flags sanitize_libs sanitize_env sanitize_libpath -# -AC_DEFUN([AX_SANITIZER_CHECK],[ - m4_pushdef([_xsan],m4_tolower($1)) - m4_pushdef([_XSAN],m4_toupper($1)) - - LDD=ldd - AC_CHECK_LIB(_xsan,[_init],[have_[]_xsan=yes]) - AS_VAR_IF([have_[]_xsan],[yes], - [AS_VAR_SET([CPPFLAGS_save],[$CPPFLAGS]) - AS_VAR_SET([LIBS_save],[$LIBS]) - AS_VAR_SET([CPPFLAGS],[$2]) - AS_VAR_SET([LIBS],[-l[]_xsan]) - AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]], - [[int x; (void)x;]])], - [AS_VAR_SET([sanitize_flags],[$CPPFLAGS]) - AS_VAR_SET([sanitize_libs],[$LIBS]) - AS_VAR_SET([sanitize_env],[_XSAN[]_OPTIONS]) - AS_VAR_SET([sanitize_libpath], [$($LDD conftest$EXEEXT \ - | grep [lib]_xsan[].so | $AWK '{ print $[]3 }')]) - AS_VAR_SET([have_[]_xsan],[yes])], - [AS_VAR_SET([have_[]_xsan],[no])]) - AS_VAR_SET_IF([sanitize_libpath], - [AC_MSG_NOTICE([found library path for] _xsan: $sanitize_libpath)], - [AC_MSG_WARN([library path not found for] _xsan)]) - AS_VAR_SET([CPPFLAGS],[${CPPFLAGS_save}]) - AS_VAR_SET([LIBS],[${LIBS_save}])]) - AS_VAR_IF([have_[]_xsan],[yes],[$3],[$4]) - m4_popdef([_xsan]) - m4_popdef([_XSAN]) -]) - - -# AX_ENABLE_SANITIZE([variable name],[action if sanitizer found], -# [action if sanitizer not found]) -AC_DEFUN([AX_ENABLE_SANITIZE],[ - m4_pushdef([ax_enable_sanitize],m4_default($1,[ENABLE_SANITIZE])) - - AC_ARG_ENABLE([sanitize], - [AS_HELP_STRING([--enable-sanitize=flavor], - [Enable compile sanitizer with flavor in (address | thread | undefined) [[default=address]] ])], - [AS_VAR_SET([enable_sanitize],[${enableval}])], - [AS_VAR_SET_IF(ax_enable_sanitize, - [AS_VAR_SET([enable_sanitize],${ax_enable_sanitize})], - [AS_VAR_SET([enable_sanitize],[no])])]) - - # by default yes is the address sanitizer - AS_VAR_IF([enable_sanitize],[yes], - [AS_VAR_SET([enable_sanitize],[address])]) - - if [ test x"$enable_sanitize" != x"no" -a "$GCC" = "yes" ]; then - AX_COMPILER_VERSION - AC_MSG_CHECKING([for Sanitize-able gcc version]) - AX_COMPARE_VERSION([${ax_cv_c_compiler_version}], [ge], [4.8.0], - [AC_MSG_RESULT([yes])], - [AC_MSG_RESULT([no, gcc 4.8.0 or higher required]) - AS_VAR_SET([enable_sanitize],[no])]) - - AS_CASE([${enable_sanitize}], - # address sanitizer - [address], - [AX_SANITIZER_CHECK([asan],["-fsanitize=address -fno-omit-frame-pointer -O3"],, - [AS_VAR_SET([enable_sanitize],[no])])], - # thread sanitizer - [thread], - [AX_SANITIZER_CHECK([tsan],["-fsanitize=thread -fno-omit-frame-pointer -O3"],, - [AX_SANITIZER_CHECK([tsan],["-fsanitize=thread -fno-omit-frame-pointer -fPIE -O3"],, - [AS_VAR_SET([enable_sanitize],[no])])])], - # undefined sanitizer - [undefined], - [AX_SANITIZER_CHECK([ubsan],["-fsanitize=undefined -fno-omit-frame-pointer -O3"],, - [AS_VAR_SET([enable_sanitize],[no])])], - # default - [no],, - [AC_MSG_WARN([sanitizer flavor ${enable_sanitize} not found]) - AS_VAR_SET([enable_sanitize],[no])]) - - AS_VAR_IF([enable_sanitize],[no],$3) - fi - - AS_VAR_IF([enable_sanitize],[no], - [AS_VAR_SET(ax_enable_sanitize,[no]) - AS_VAR_SET(ax_enable_sanitize[]_OPTIONS,[SAN_OPTIONS]) - AS_VAR_SET(ax_enable_sanitize[]_LIBPATH)], - [AS_VAR_SET(ax_enable_sanitize,[${enable_sanitize}]) - AS_VAR_SET(ax_enable_sanitize[]_OPTIONS,[${sanitize_env}]) - AS_VAR_SET(ax_enable_sanitize[]_LIBPATH,[${sanitize_libpath}]) - $2 ]) - - AM_CONDITIONAL(ax_enable_sanitize, [test "${enable_sanitize}" != "no"] ) - AC_SUBST(ax_enable_sanitize) - AC_SUBST(ax_enable_sanitize[]_OPTIONS) - AC_SUBST(ax_enable_sanitize[]_LIBPATH) - - m4_popdef([ax_enable_sanitize]) -]) - - diff --git a/m4/m4_ax_valgrind_check.m4 b/m4/m4_ax_valgrind_check.m4 deleted file mode 100644 index 8507706e3f..0000000000 --- a/m4/m4_ax_valgrind_check.m4 +++ /dev/null @@ -1,372 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_valgrind_check.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_VALGRIND_CHECK() -# -# DESCRIPTION -# -# Checks whether Valgrind is present and, if so, allows running `make -# check` under a variety of Valgrind tools to check for memory and -# threading errors. -# -# Defines VALGRIND_CHECK_RULES which should be substituted in your -# Makefile; and $enable_valgrind which can be used in subsequent configure -# output. ENABLE_VALGRIND is defined and substituted, and corresponds to -# the value of the --enable-valgrind option, which defaults to being -# enabled if Valgrind is installed and disabled otherwise. -# -# If unit tests are written using a shell script and automake's -# LOG_COMPILER system, the $(VALGRIND) variable can be used within the -# shell scripts to enable Valgrind, as described here: -# -# https://www.gnu.org/software/gnulib/manual/html_node/Running-self_002dtests-under-valgrind.html -# -# Usage example: -# -# configure.ac: -# -# AX_VALGRIND_CHECK -# -# Makefile.am: -# -# @VALGRIND_CHECK_RULES@ -# VALGRIND_SUPPRESSIONS_FILES = my-project.supp -# EXTRA_DIST = my-project.supp -# -# This results in a "tests-valgrind" rule being added to any Makefile.am -# which includes "@VALGRIND_CHECK_RULES@" (assuming the module has been -# configured with --enable-valgrind). Running `make tests-valgrind` in -# that directory will run the module's test suite (`make check`) once for -# each of the available Valgrind tools (out of memcheck, helgrind, drd and -# sgcheck), and will output results to valgrind-suite-$toolname.log for each. -# The target will succeed if there are zero errors and fail otherwise. -# -# The macro supports running with and without libtool. -# -# LICENSE -# -# Copyright (c) 2014, 2015 Philip Withnall -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 4 - -dnl TODO: add custom valgrind installation and VALGRIND_LIB -AC_DEFUN([AX_VALGRIND_CHECK],[ - m4_pushdef([enable_valgrind],m4_default($1,[ENABLE_VALGRIND])) - - dnl Check for --enable-valgrind - AC_ARG_ENABLE([valgrind], - [AS_HELP_STRING([--enable-valgrind], - [Whether to enable Valgrind on the unit tests])], - [enable_valgrind=$enableval],[enable_valgrind="yes"]) - - AS_VAR_IF(enable_valgrind,[yes], [ - # check for valgrind program - AC_CHECK_PROG([VALGRIND],[valgrind],[valgrind]) - AS_IF([test "${VALGRIND}" = ""],[ - AC_MSG_WARN([Could not find valgrind; either install it or reconfigure with --disable-valgrind]) - AS_VAR_SET(enable_valgrind,[no]) - ]) - # Enable valgrind only in debug mode (WARNING $enable_debug must be used to selec debug mode) - AS_VAR_IF(enable_debug,[yes],[:],[ - AC_MSG_WARN([Valgrind works only in debug mode, either reconfigure with --enable-debug or --disable-valgrind]) - AS_VAR_SET(enable_valgrind,[no]) - ]) - ]) - - # Looking for Valgrind specific headers - AS_VAR_IF([enable_valgrind],[yes], - AC_CHECK_HEADER([valgrind/valgrind.h], - AS_VAR_SET([have_valgrind_h],[yes]), - AS_VAR_SET([have_valgrind_h],[no])) - AC_CHECK_HEADER([valgrind/memcheck.h], - AS_VAR_SET([have_valgrind_memcheck_h],[yes]), - AS_VAR_SET([have_valgrind_memcheck_h],[no]))) - AS_VAR_IF([have_valgrind_h],[yes], - AC_DEFINE(HAVE_VALGRIND_H, 1, - [Define to 1 if you have the header file.])) - AS_VAR_IF([have_valgrind_memcheck_h],[yes], - AC_DEFINE(HAVE_VALGRIND_MEMCHECK_H, 1, - [Define to 1 if you have the header file.])) - - # AM CONDITIONAL - AM_CONDITIONAL(enable_valgrind,[test "${enable_valgrind}" = "yes" ]) - AC_SUBST(enable_valgrind) - - AC_ARG_WITH([valgrind-lib], - [AS_HELP_STRING([--with-valgrind-lib], - [Set Valgrind lib directory])], - [valgrind_dir=$withval]) - AS_VAR_SET_IF([VALGRIND_LIB], AS_VAR_SET([valgrind_dir],[${VALGRIND_LIB}])) - AC_SUBST([VALGRIND_LIB],[${valgrind_dir}]) - AM_SUBST_NOTMAKE([VALGRIND_LIB]) - - AC_MSG_CHECKING([whether to enable Valgrind on the unit tests]) - AC_MSG_RESULT(${enable_valgrind}) - - - - - - # Check for Valgrind tools we care about. - m4_define([valgrind_tool_list],[[memcheck], [helgrind], [drd], [exp-sgcheck]]) - - # permits use of AM_TESTS_FD_REDIRECT to change suppressions redirections - m4_pattern_allow(AM_TESTS_FD_REDIRECT) - - AS_IF([test "$VALGRIND" != ""],[ - m4_foreach([vgtool],[valgrind_tool_list],[ - m4_define([vgtooln],AS_TR_SH(vgtool)) - m4_define([ax_cv_var],[ax_cv_valgrind_tool_]vgtooln) - AC_CACHE_CHECK([for Valgrind tool ]vgtool,ax_cv_var,[ - ax_cv_var= - AS_IF([`$VALGRIND --tool=vgtool --help >/dev/null 2>&1`],[ - ax_cv_var="vgtool" - ]) - ]) - - AC_SUBST([VALGRIND_HAVE_TOOL_]vgtooln,[$ax_cv_var]) - ]) - ]) - - - -dnl -dnl Parsed substitutions -dnl -AS_VAR_READ([VALGRIND_CHECK_RULES_PRE],[ -VALGRIND_LIB ?= ${VALGRIND_LIB} -]) - -dnl -dnl Not parsed substitutions -dnl -VALGRIND_CHECK_RULES=' -# //////////////////////////////////////////////////////////////////////////// # -# /// Valgrind check //////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # -# -# Optional: -# - VALGRIND_SUPPRESSIONS_FILES: Space-separated list of Valgrind suppressions -# files to load. (Default: empty) -# - VALGRIND_FLAGS: General flags to pass to all Valgrind tools. -# (Default: --num-callers=30) -# - VALGRIND_$toolname_FLAGS: Flags to pass to Valgrind $toolname (one of: -# memcheck, helgrind, drd, sgcheck). (Default: various) - -# Optional variables -VALGRIND_SUPPRESSIONS_FILES += $(top_srcdir)/conf/valgrind.supp/mdsplus.supp -VALGRIND_SUPPRESSIONS_FILES += $(wildcard $(top_srcdir)/conf/valgrind.supp/$(DISTNAME).supp) - -VALGRIND_FLAGS ?= -VALGRIND_FLAGS += --gen-suppressions=all \ - --num-callers=64 \ - --trace-children=yes \ - --child-silent-after-fork=yes \ - --trace-children-skip-by-arg='*SetMdsplusFileProtection*' - -VALGRIND_memcheck_FLAGS ?= -VALGRIND_memcheck_FLAGS += --leak-check=full --show-reachable=no - -VALGRIND_helgrind_FLAGS ?= -VALGRIND_helgrind_FLAGS += --history-level=full - -VALGRIND_drd_FLAGS ?= -VALGRIND_drd_FLAGS += - -VALGRIND_sgcheck_FLAGS ?= -VALGRIND_sgcheck_FLAGS += - -VALGRIND_SUPPRESSIONS ?= -VALGRIND_SUPPRESSIONS += $(addprefix --suppressions=,$(VALGRIND_SUPPRESSIONS_FILES)) - -VALGRIND_TOOLS ?= memcheck helgrind drd sgcheck - -VALGRIND_TESTS ?= ${TESTS} -valgrind__test_logs1 = $(VALGRIND_TESTS) -valgrind__test_logs2 = $(valgrind__test_logs1:=.log) -VALGRIND_LOGS ?= $(foreach ext,$(TEST_EXTENSIONS),$(valgrind__test_logs2:${ext}.log=.log)) - - -# Internal use -valgrind_log_files = $(addprefix valgrind-suite-,$(addsuffix .log,$(VALGRIND_TOOLS))) \ - $(TEST_LOGS:.log=-valgrind-*.log) \ - $(TEST_LOGS:.log=-valgrind-*.log.core.*) \ - $(TEST_LOGS:.log=-valgrind-*.xml) \ - $(TEST_LOGS:.log=-valgrind-*.supp) -dnl $(foreach tst,$(TESTS),$(addprefix $(tst)-valgrind-,$(addsuffix .xml,$(VALGRIND_TOOLS)))) - -valgrind_supp_files = $(addsuffix -valgrind.supp,$(TESTS)) - -valgrind_memcheck_flags = --tool=memcheck $(VALGRIND_memcheck_FLAGS) -valgrind_helgrind_flags = --tool=helgrind $(VALGRIND_helgrind_FLAGS) -valgrind_drd_flags = --tool=drd $(VALGRIND_drd_FLAGS) -valgrind_sgcheck_flags = --tool=exp-sgcheck $(VALGRIND_sgcheck_FLAGS) - -valgrind_quiet = $(valgrind_quiet_$(V)) -valgrind_quiet_ = $(valgrind_quiet_$(AM_DEFAULT_VERBOSITY)) -valgrind_quiet_0 = --quiet - -# Support running with and without libtool. -ifneq ($(LIBTOOL),) -valgrind_lt = $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=execute -else -valgrind_lt = -endif - -# -# Valgrind chain add ons -# -VALGRIND_TESTS_ENVIRONMENT ?= -VALGRIND_TESTS_ENVIRONMENT += \ - VALGRIND=$(VALGRIND) \ - $(if ${VALGRIND_LIB},VALGRIND_LIB=${VALGRIND_LIB}) \ - G_SLICE=always-malloc,debug-blocks \ - G_DEBUG=fatal-warnings,fatal-criticals,gc-friendly - -VALGRIND_LOG_COMPILER = \ - $(valgrind_lt) \ - $(VALGRIND) --error-exitcode=7 \ - $(VALGRIND_SUPPRESSIONS) \ - $(valgrind_$(VALGRIND_TOOL)_flags) \ - $(VALGRIND_FLAGS) - - - -.PHONY: tests-valgrind tests-valgrind-tool -.PHONY: tests-valgrind-suppressions tests-valgrind-suppressions-tool -ifeq ($(enable_valgrind),yes) - -_print_valgrind_hello = \ - echo ""; \ - echo "---------------------------------------------------------------------------"; \ - echo " [valgrind $(VALGRIND_TOOL)] "; \ - echo " active tool options : $(valgrind_$(VALGRIND_TOOL)_flags) "; \ - echo " active valgrind flags : $(VALGRIND_FLAGS) "; \ - echo " active suppressions : "; \ - for supp in $(VALGRIND_SUPPRESSIONS); do \ - echo " $${supp}"; \ - done - -$(VALGRIND_LOGS): - -tests-valgrind: ##@valgrind perform tests in valgrind with tools in $VALGRIND_TOOLS -tests-valgrind: - @ \ - $(if $(VALGRIND_LOGS),,exit 0;) \ - echo "--- VALGRIND TESTS --- enabled tools: $(foreach tool,$(VALGRIND_TOOLS), $(tool))"; \ - $(MAKE) -k $(BUILD_FLAGS) $(AM_MAKEFLAGS) all VALGRIND_BUILD="yes"; \ - $(foreach tool,$(VALGRIND_TOOLS), \ - $(if $(VALGRIND_HAVE_TOOL_$(tool))$(VALGRIND_HAVE_TOOL_exp_$(tool)), \ - $(MAKE) -k $(TEST_FLAGS) $(AM_MAKEFLAGS) tests-valgrind-tool VALGRIND_TOOL=$(tool); \ - ) \ - ) - -tests-valgrind-tool: - @list="$(VALGRIND_LOGS)"; test -z "$$list" || rm -f $$list - @list="$(VALGRIND_LOGS:.log=.trs)"; test -z "$$list" || rm -f $$list - @ $(_print_valgrind_hello); - @ \ - $(MAKE) -k $(AM_MAKEFLAGS) $(VALGRIND_LOGS) \ - TESTS_ENVIRONMENT="$(VALGRIND_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)" \ - LOG_COMPILER="$(VALGRIND_LOG_COMPILER) -q --log-file=\$$\$$b-valgrind-$(VALGRIND_TOOL)-%p.log --xml=yes --xml-file=\$$\$$b-valgrind-$(VALGRIND_TOOL)-%p.xml $(subst ",\",$(LOG_COMPILER))" \ - PY_LOG_COMPILER="$(VALGRIND_LOG_COMPILER) -q --log-file=\$$\$$b-valgrind-$(VALGRIND_TOOL)-%p.log --xml=yes --xml-file=\$$\$$b-valgrind-$(VALGRIND_TOOL)-%p.xml $(subst ",\",$(PY_LOG_COMPILER))" \ - TEST_SUITE_LOG=valgrind-suite-$(VALGRIND_TOOL).log - - -tests-valgrind-suppressions: ##@valgrind perform valgrind with suppression output redirected to file -tests-valgrind-suppressions: - @ \ - $(MAKE) VALGRIND_BUILD="yes"; \ - $(foreach tool,$(VALGRIND_TOOLS), \ - $(if $(VALGRIND_HAVE_TOOL_$(tool))$(VALGRIND_HAVE_TOOL_exp_$(tool)), \ - $(MAKE) $(AM_MAKEFLAGS) -k tests-valgrind-suppressions-tool VALGRIND_TOOL=$(tool); \ - ) \ - ) - -tests-valgrind-suppressions-tool: - @list="$(VALGRIND_LOGS)"; test -z "$$list" || rm -f $$list - @list="$(VALGRIND_LOGS:.log=.trs)"; test -z "$$list" || rm -f $$list - @ $(_print_valgrind_hello); - @ \ - $(MAKE) -k $(AM_MAKEFLAGS) $(VALGRIND_LOGS) \ - TESTS_ENVIRONMENT="$(VALGRIND_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)" \ - LOG_COMPILER="$(VALGRIND_LOG_COMPILER) --gen-suppressions=all --log-fd=11 $(subst ",\",$(LOG_COMPILER))" \ - PY_LOG_COMPILER="$(VALGRIND_LOG_COMPILER) --gen-suppressions=all --log-fd=11 $(subst ",\",$(PY_LOG_COMPILER))" \ - AM_TESTS_FD_REDIRECT=" 11>&1 | $(AWK) -f $(top_srcdir)/testing/parse_valgrind_suppressions.sh > \$$\$$b-valgrind-$(VALGRIND_TOOL).supp" \ - TEST_SUITE_LOG=valgrind-suite-$(VALGRIND_TOOL).log - -else - -tests-valgrind tests-valgrind-tool \ -tests-valgrind-suppressions tests-valgrind-suppressions-tool: - @ \ - echo " ------------------------------------------ "; \ - echo " Need to reconfigure with --enable-valgrind "; \ - echo " ------------------------------------------ "; -endif - - - -DISTCHECK_CONFIGURE_FLAGS ?= -DISTCHECK_CONFIGURE_FLAGS += --disable-valgrind - -MOSTLYCLEANFILES ?= -MOSTLYCLEANFILES += $(valgrind_log_files) -' - -dnl VALGRIND_CHECK_RULES subsituition -AC_SUBST([VALGRIND_CHECK_RULES],["${VALGRIND_CHECK_RULES_PRE} ${VALGRIND_CHECK_RULES}"]) -m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([VALGRIND_CHECK_RULES])]) - -m4_pushdef([enable_valgrind]) -]) - - - - -# internal utils -AC_DEFUN([AS_VAR_READ],[ -read -d '' $1 << _as_read_EOF -$2 -_as_read_EOF -]) - - - -dnl --- TEST CHAIN --- - -dnl LOG_DRIVER = $(SHELL) $(top_srcdir)/conf/test-driver -dnl LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS) -dnl PY_LOG_DRIVER = $(SHELL) $(top_srcdir)/conf/test-driver -dnl PY_LOG_COMPILE = $(PY_LOG_COMPILER) $(AM_PY_LOG_FLAGS) $(PY_LOG_FLAGS) - -dnl am__test_logs1 = $(TESTS:=.log) -dnl am__test_logs2 = $(am__test_logs1:.log=.log) -dnl TEST_LOGS = $(am__test_logs2:.test.log=.log) -dnl TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/conf/test-driver -dnl TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) $(TEST_LOG_FLAGS) -dnl DIST_SUBDIRS = $(SUBDIRS) - -dnl buildtest.log: buildtest$(EXEEXT) -dnl @p='buildtest$(EXEEXT)'; \ -dnl b='buildtest'; \ -dnl $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ -dnl --log-file $$b.log --trs-file $$b.trs \ -dnl $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ -dnl "$$tst" $(AM_TESTS_FD_REDIRECT) - -dnl .py.log: -dnl @p='$<'; \ -dnl $(am__set_b); \ -dnl $(am__check_pre) $(PY_LOG_DRIVER) --test-name "$$f" \ -dnl --log-file $$b.log --trs-file $$b.trs \ -dnl $(am__common_driver_flags) $(AM_PY_LOG_DRIVER_FLAGS) $(PY_LOG_DRIVER_FLAGS) -- $(PY_LOG_COMPILE) \ -dnl "$$tst" $(AM_TESTS_FD_REDIRECT) diff --git a/m4/pkg.m4 b/m4/pkg.m4 deleted file mode 100644 index c5b26b52e6..0000000000 --- a/m4/pkg.m4 +++ /dev/null @@ -1,214 +0,0 @@ -# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- -# serial 1 (pkg-config-0.24) -# -# Copyright © 2004 Scott James Remnant . -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# 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. - -# PKG_PROG_PKG_CONFIG([MIN-VERSION]) -# ---------------------------------- -AC_DEFUN([PKG_PROG_PKG_CONFIG], -[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) -m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$]) -m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$]) -AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) -AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) -AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) - -if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then - AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) -fi -if test -n "$PKG_CONFIG"; then - _pkg_min_version=m4_default([$1], [0.9.0]) - AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) - if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - PKG_CONFIG="" - fi -fi[]dnl -])# PKG_PROG_PKG_CONFIG - -# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) -# -# Check to see whether a particular set of modules exists. Similar -# to PKG_CHECK_MODULES(), but does not set variables or print errors. -# -# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) -# only at the first occurence in configure.ac, so if the first place -# it's called might be skipped (such as if it is within an "if", you -# have to call PKG_CHECK_EXISTS manually -# -------------------------------------------------------------- -AC_DEFUN([PKG_CHECK_EXISTS], -[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl -if test -n "$PKG_CONFIG" && \ - AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then - m4_default([$2], [:]) -m4_ifvaln([$3], [else - $3])dnl -fi]) - -# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) -# --------------------------------------------- -m4_define([_PKG_CONFIG], -[if test -n "$$1"; then - pkg_cv_[]$1="$$1" - elif test -n "$PKG_CONFIG"; then - PKG_CHECK_EXISTS([$3], - [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null` - test "x$?" != "x0" && pkg_failed=yes ], - [pkg_failed=yes]) - else - pkg_failed=untried -fi[]dnl -])# _PKG_CONFIG - -# _PKG_SHORT_ERRORS_SUPPORTED -# ----------------------------- -AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], -[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) -if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then - _pkg_short_errors_supported=yes -else - _pkg_short_errors_supported=no -fi[]dnl -])# _PKG_SHORT_ERRORS_SUPPORTED - - -# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], -# [ACTION-IF-NOT-FOUND]) -# -# -# Note that if there is a possibility the first call to -# PKG_CHECK_MODULES might not happen, you should be sure to include an -# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac -# -# -# -------------------------------------------------------------- -AC_DEFUN([PKG_CHECK_MODULES], -[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl -AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl -AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl - -pkg_failed=no -AC_MSG_CHECKING([for $1]) - -_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) -_PKG_CONFIG([$1][_LIBS], [libs], [$2]) - -m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS -and $1[]_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details.]) - -if test $pkg_failed = yes; then - AC_MSG_RESULT([no]) - _PKG_SHORT_ERRORS_SUPPORTED - if test $_pkg_short_errors_supported = yes; then - $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1` - else - $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1` - fi - # Put the nasty error message in config.log where it belongs - echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD - - m4_default([$4], [AC_MSG_ERROR( -[Package requirements ($2) were not met: - -$$1_PKG_ERRORS - -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. - -_PKG_TEXT])[]dnl - ]) -elif test $pkg_failed = untried; then - AC_MSG_RESULT([no]) - m4_default([$4], [AC_MSG_FAILURE( -[The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. - -_PKG_TEXT - -To get pkg-config, see .])[]dnl - ]) -else - $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS - $1[]_LIBS=$pkg_cv_[]$1[]_LIBS - AC_MSG_RESULT([yes]) - $3 -fi[]dnl -])# PKG_CHECK_MODULES - - -# PKG_INSTALLDIR(DIRECTORY) -# ------------------------- -# Substitutes the variable pkgconfigdir as the location where a module -# should install pkg-config .pc files. By default the directory is -# $libdir/pkgconfig, but the default can be changed by passing -# DIRECTORY. The user can override through the --with-pkgconfigdir -# parameter. -AC_DEFUN([PKG_INSTALLDIR], -[m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])]) -m4_pushdef([pkg_description], - [pkg-config installation directory @<:@]pkg_default[@:>@]) -AC_ARG_WITH([pkgconfigdir], - [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],, - [with_pkgconfigdir=]pkg_default) -AC_SUBST([pkgconfigdir], [$with_pkgconfigdir]) -m4_popdef([pkg_default]) -m4_popdef([pkg_description]) -]) dnl PKG_INSTALLDIR - - -# PKG_NOARCH_INSTALLDIR(DIRECTORY) -# ------------------------- -# Substitutes the variable noarch_pkgconfigdir as the location where a -# module should install arch-independent pkg-config .pc files. By -# default the directory is $datadir/pkgconfig, but the default can be -# changed by passing DIRECTORY. The user can override through the -# --with-noarch-pkgconfigdir parameter. -AC_DEFUN([PKG_NOARCH_INSTALLDIR], -[m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])]) -m4_pushdef([pkg_description], - [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@]) -AC_ARG_WITH([noarch-pkgconfigdir], - [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],, - [with_noarch_pkgconfigdir=]pkg_default) -AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir]) -m4_popdef([pkg_default]) -m4_popdef([pkg_description]) -]) dnl PKG_NOARCH_INSTALLDIR - - -# PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE, -# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) -# ------------------------------------------- -# Retrieves the value of the pkg-config variable for the given module. -AC_DEFUN([PKG_CHECK_VAR], -[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl -AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl - -_PKG_CONFIG([$1], [variable="][$3]["], [$2]) -AS_VAR_COPY([$1], [pkg_cv_][$1]) - -AS_VAR_IF([$1], [""], [$5], [$4])dnl -])# PKG_CHECK_VAR diff --git a/m4/visibility.m4 b/m4/visibility.m4 deleted file mode 100644 index 2ff6330aa4..0000000000 --- a/m4/visibility.m4 +++ /dev/null @@ -1,52 +0,0 @@ -# visibility.m4 serial 1 (gettext-0.15) -dnl Copyright (C) 2005 Free Software Foundation, Inc. -dnl This file is free software; the Free Software Foundation -dnl gives unlimited permission to copy and/or distribute it, -dnl with or without modifications, as long as this notice is preserved. - -dnl From Bruno Haible. - -dnl Tests whether the compiler supports the command-line option -dnl -fvisibility=hidden and the function and variable attributes -dnl __attribute__((__visibility__("hidden"))) and -dnl __attribute__((__visibility__("default"))). -dnl Does *not* test for __visibility__("protected") - which has tricky -dnl semantics (see the 'vismain' test in glibc) and does not exist e.g. on -dnl MacOS X. -dnl Does *not* test for __visibility__("internal") - which has processor -dnl dependent semantics. -dnl Does *not* test for #pragma GCC visibility push(hidden) - which is -dnl "really only recommended for legacy code". -dnl Set the variable CFLAG_VISIBILITY. -dnl Defines and sets the variable HAVE_VISIBILITY. - -AC_DEFUN([gl_VISIBILITY], -[ - AC_REQUIRE([AC_PROG_CC]) - CFLAG_VISIBILITY= - HAVE_VISIBILITY=0 - if test -n "$GCC"; then - AC_MSG_CHECKING([for simple visibility declarations]) - AC_CACHE_VAL(gl_cv_cc_visibility, [ - gl_save_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -fvisibility=hidden" - AC_TRY_COMPILE( - [extern __attribute__((__visibility__("hidden"))) int hiddenvar; - extern __attribute__((__visibility__("default"))) int exportedvar; - extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void); - extern __attribute__((__visibility__("default"))) int exportedfunc (void);], - [], - gl_cv_cc_visibility=yes, - gl_cv_cc_visibility=no) - CFLAGS="$gl_save_CFLAGS"]) - AC_MSG_RESULT([$gl_cv_cc_visibility]) - if test $gl_cv_cc_visibility = yes; then - CFLAG_VISIBILITY="-fvisibility=hidden" - HAVE_VISIBILITY=1 - fi - fi - AC_SUBST([CFLAG_VISIBILITY]) - AC_SUBST([HAVE_VISIBILITY]) - AC_DEFINE_UNQUOTED([HAVE_VISIBILITY], [$HAVE_VISIBILITY], - [Define to 1 or 0, depending whether the compiler supports simple visibility declarations.]) -]) diff --git a/macosx/Makefile.am b/macosx/Makefile.am deleted file mode 100755 index 877f2a31c4..0000000000 --- a/macosx/Makefile.am +++ /dev/null @@ -1,6 +0,0 @@ -dist_sysconf_DATA = mdsip.plist - -dist_bin_SCRIPTS = mdsplus_launchconfig - -scriptsdir = $(exec_prefix)/scripts -dist_scripts_SCRIPTS = scripts/preinstall scripts/postinstall scripts/postinstall.rtf diff --git a/manpages/Makefile.am b/manpages/Makefile.am deleted file mode 100644 index bc26a7e6dd..0000000000 --- a/manpages/Makefile.am +++ /dev/null @@ -1,2 +0,0 @@ -dist_man1_MANS = mdsplus.groff traverser.groff -dist_man5_MANS = mdsip.hosts.groff mdsplus.conf.groff \ No newline at end of file diff --git a/math/Makefile.in b/math/Makefile.in deleted file mode 100644 index b4353753a6..0000000000 --- a/math/Makefile.in +++ /dev/null @@ -1,88 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ -FFLAGS += $(FCFLAGS) -Wno-maybe-uninitialized -Wno-compare-reals - -LIBPREFIX=MdsMath - -BLAS = \ - caxpy.f\ - daxpy.f\ - saxpy.f\ - zaxpy.f\ - cgeco.f\ - dgeco.f\ - sgeco.f\ - zgeco.f\ - -@HAVE_BLAS_TRUE@SRCBLAS = -@HAVE_BLAS_TRUE@LIBBLAS = -lblas -@HAVE_BLAS_FALSE@SRCBLAS = $(BLAS) -@HAVE_BLAS_FALSE@LIBBLAS = - -SOURCES = $(SRCBLAS)\ - cmul.f\ - csint.f\ - csval.f\ - dcsint.f\ - dcsval.f\ - dmul.f\ - dpermu.f\ - dppval.f\ - dsrch.f\ - dsvrgn.f\ - gn.f\ - isrch.f\ - msceez.f\ - mskrv2.f\ - mstrms.f\ - mskrv1.f\ - msshch.f\ - permu.f\ - ppval.f\ - smul.f\ - srch.f\ - ssrch.f\ - svign.f\ - svrgn.f\ - toms510.f\ - umach.f\ - zmul.f - -@LIBPRE@MdsMath = @MAKESHLIBDIR@@LIBPRE@MdsMath@SHARETYPE@ -all: @MAKESHLIBDIR@ $(@LIBPRE@MdsMath) - -OBJECTS = $(SOURCES:.f=.o) boxsmooth.o - -## suppressing conversion error warning ## -umach.o : umach.f - $(COMPILE.f) $< $(OUTPUT_OPTION) $(FFLAGS) -Wno-error - -$(BLAS:.f=.o) : %.o : blas/%.f - $(COMPILE.f) $< $(OUTPUT_OPTION) $(FFLAGS) -Wno-error - -local@LIBPRE@MdsMath = @LIBPRE@MdsMath@SHARETYPE@ - -ifeq "@MACOSX@" "" -LIBRARIES = $(@LIBPRE@MdsMath) -else -LIBRARIES = $(local@LIBPRE@MdsMath) -$(@LIBPRE@MdsMath): @LIBPRE@MdsMath@SHARETYPE@ - lipo -create -o $@ $^ -endif - -$(LIBRARIES) : $(OBJECTS) - $(LINK.f) $(OUTPUT_OPTION) @FOR_LINKSHARED@ $^ -L@MAKESHLIBDIR@ -lMdsShr $(LIBBLAS) @FOR_LDFLAGS@ $(LIBM) - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 755 $(@LIBPRE@MdsMath) $(libdir) - -clean: - $(RM) $(OBJECTS) - $(RM) $(@LIBPRE@MdsMath) $(local@LIBPRE@MdsMath) diff --git a/math/testing/Makefile.am b/math/testing/Makefile.am deleted file mode 100644 index 09d3221785..0000000000 --- a/math/testing/Makefile.am +++ /dev/null @@ -1,35 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ -LDADD = @LIBS@ $(TEST_LIBS) -lMdsMath -lblas -lgfortran - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .out -AM_DEFAULT_SOURCE_EXT = .c - -TESTS = \ - csint\ - toms510 - -VALGRIND_SUPPRESSIONS_FILES = - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -all-local: $(TESTS) -clean-local: clean-local-tests - -check_PROGRAMS = $(TESTS) -check_SCRIPTS = diff --git a/mdsdcl/Makefile.in b/mdsdcl/Makefile.in deleted file mode 100644 index 3f67426b54..0000000000 --- a/mdsdcl/Makefile.in +++ /dev/null @@ -1,86 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX=Mdsdcl - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS += -I$(srcdir) - -@MINGW_TRUE@ IMPLIB=@MAKELIBDIR@Mdsdcl.dll.a -@MINGW_TRUE@CFLAGS += -DLIBXML_STATIC -@MINGW_TRUE@ XML_LIBS=-Wl,-Bstatic -lxml2 -lz @LIBLZMA@ -Wl,-Bdynamic -liconv @LIBDL@ $(LIBSOCKET) -@MINGW_FALSE@ XML_LIBS=@XML_LIBS@ @LIBDL@ - -SOURCES = \ -mdsdclThreadStatic.c \ -cmdExecute.c \ -cmdHelp.c \ -cmdParseLex.c \ -cmdParse.c \ -mdsdclDeltatimeToSeconds.c \ -mdsdcl_commands.c \ -mdsdclVersionInfo.c \ -mdsdcl_show_version.c - - -OBJECTS = $(SOURCES:.c=.o) - -all: @MAKELIBDIR@ @MAKEBINDIR@ @MAKELIBDIR@@LIBPRE@Mdsdcl.a @MAKESHLIBDIR@@LIBPRE@Mdsdcl@SHARETYPE@ $(IMPLIB) @MAKEBINDIR@mdsdcl$(EXE) - -clean: - $(RM) $(OBJECTS) - $(RM) @MAKELIBDIR@@LIBPRE@Mdsdcl.a @MAKESHLIBDIR@@LIBPRE@Mdsdcl@SHARETYPE@ @MAKEBINDIR@mdsdcl$(EXE) $(IMPLIB) - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) mdsdcl.c ocldToXml.c - -install: $(libdir) $(bindir) - $(INSTALL) -m 755 @MAKEBINDIR@mdsdcl$(EXE) $(bindir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@Mdsdcl@SHARETYPE@ $(IMPLIB) $(libdir) - -@MAKELIBDIR@@LIBPRE@Mdsdcl.a: $(OBJECTS) - $(AR) -cr $@ $^ - @RANLIB@ $@ - -mdsdclThreadSafe.o: mdsdclThreadSafe.c - $(COMPILE.c) $(CFLAGS) -c @XML_CPPFLAGS@ $^ - -cmdExecute.o: cmdExecute.c - $(COMPILE.c) $(CFLAGS) -c @XML_CPPFLAGS@ $^ - -cmdHelp.o: cmdHelp.c - $(COMPILE.c) $(CFLAGS) -c @XML_CPPFLAGS@ $^ - -cmdParseLex.o: cmdParseLex.c - $(COMPILE.c) $(CFLAGS) -Wno-sign-compare -Wno-unused-parameter -c $^ - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -@MAKESHLIBDIR@@LIBPRE@Mdsdcl@SHARETYPE@ $(IMPLIB): $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKESHLIBDIR@ -lMdsShr -lTreeShr $(LIBS) $(MAKE_IMPLIB) $(THREAD) $(XML_LIBS) @LIBREADLINE@ - -@MAKEBINDIR@mdsdcl$(EXE): mdsdcl.c @MAKESHLIBDIR@@LIBPRE@Mdsdcl@SHARETYPE@ $(IMPLIB) - $(LINK.c) $(OUTPUT_OPTION) $< -L@MAKESHLIBDIR@ -lMdsdcl -lMdsShr -lTreeShr $(LIBS) @LIBREADLINE@ - -mdsdclDeltatimeToSeconds.o : - $(COMPILE.c) $(OUTPUT_OPTION) $(srcdir)/mdsdclDeltatimeToSeconds.c -Wno-sign-compare - -#cmdParse.c: cmdParse.y -# bison cmdParse.y - -#cmdParseLex.c: cmdParse.l -# lex -P cmdParse_ cmdParse.l - -#ocldToXml: ocldToXml.c -# $(LINK.c) $(OUTPUT_OPTION) $< - -#ocldToXml.c: ocldToXml.l -# lex -P ocldToXml_ ocldToXml.l - -#mdsdcl_commands.xml: mdsdcl_tables.ocld -# ./ocldToXml mdsdcl_tables.ocld mdsdcl_commands - -#mdsdclDeltatimeToSeconds.c: mdsdclDeltatimeToSeconds.l -# lex -P mdsdclDelta_ mdsdclDeltatimeToSeconds.l diff --git a/mdslib/Makefile.in b/mdslib/Makefile.in deleted file mode 100644 index aba4286cc4..0000000000 --- a/mdslib/Makefile.in +++ /dev/null @@ -1,88 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX=MdsLib - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -MKDIR_P=@MKDIR_P@ -@AX_RECONFIGURE_TARGET@ - -@MINGW_TRUE@ IMPLIB_MdsLib=@MAKELIBDIR@MdsLib.dll.a -@MINGW_TRUE@ IMPLIB_MdsLib_client=@MAKELIBDIR@MdsLib_client.dll.a -@MINGW_TRUE@ IMPLIB_MdsLib_fortran=@MAKELIBDIR@MdsLib_fortran.dll.a - -LIBS = @LIBS@ @GLOBUS_LIBS@ $(LIBSOCKET) @LIBRESOLV@ @LIBM@ -MDSLIB_LIBS=-lTdiShr -lTreeShr -lMdsShr - -FFLAGS += $(FCFLAGS) - -SOURCES = MdsLib.c -OBJECTS = $(SOURCES:.c=.o) - -OBJECTS_CLIENT = MdsLib_client.o - -OBJECTS_FORTRAN = MdsLib_fortran.o - -all: \ - @MAKEBINDIR@ @MAKELIBDIR@\ - @MAKESHLIBDIR@@LIBPRE@MdsLib_client@SHARETYPE@ $(IMPLIB_MdsLib_Client)\ - @MAKESHLIBDIR@@LIBPRE@MdsLib@SHARETYPE@ $(IMPLIB_MdsLib)\ - @MAKESHLIBDIR@@LIBPRE@MdsLib_fortran@SHARETYPE@ $(IMPLIB_MdsLib_fortran)\ - @MAKELIBDIR@@LIBPRE@MdsLib_client.a\ - @MAKELIBDIR@@LIBPRE@MdsLib_fortran.a\ - @MAKELIBDIR@@LIBPRE@MdsLib.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean: - @ $(RM) $(OBJECTS) $(OBJECTS_CLIENT)\ - @MAKELIBDIR@@LIBPRE@MdsLib.a\ - @MAKELIBDIR@@LIBPRE@MdsLib_client.a\ - @MAKELIBDIR@@LIBPRE@MdsLib_fortran.a\ - @MAKESHLIBDIR@@LIBPRE@MdsLib@SHARETYPE@\ - @MAKESHLIBDIR@@LIBPRE@MdsLib_client@SHARETYPE@\ - @MAKESHLIBDIR@@LIBPRE@MdsLib_fortran@SHARETYPE@\ - $(IMPLIB_MdsLib) $(IMPLIB_MdsLib_client) $(IMPLIB_MdsLib_fortran) - -install: $(libdir) - $(MKDIR_P) $(libdir) - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@MdsLib.a @MAKELIBDIR@@LIBPRE@MdsLib_client.a @MAKELIBDIR@@LIBPRE@MdsLib_fortran.a $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MdsLib@SHARETYPE@ @MAKESHLIBDIR@@LIBPRE@MdsLib_client@SHARETYPE@ @MAKESHLIBDIR@@LIBPRE@MdsLib_fortran@SHARETYPE@ $(IMPLIB_MdsLib) $(IMPLIB_MdsLib_client) $(libdir) - -MdsLib = @MAKESHLIBDIR@@LIBPRE@MdsLib@SHARETYPE@ $(IMPLIB_MdsLib) - -@MINGW_TRUE@ MAKE_IMPLIB_MdsLib=-Wl,--out-implib,$(IMPLIB_MdsLib) -$(MdsLib): $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKELIBDIR@ -lMdsShr -lMdsIpShr -L@MAKESHLIBDIR@ $(MDSLIB_LIBS) $(LIBS) $(GLOBUS_LDFLAGS) $(MAKE_IMPLIB_MdsLib) - -@MAKELIBDIR@@LIBPRE@MdsLib.a: $(OBJECTS) - $(AR) -cr $@ $^ - @RANLIB@ $@ - -@MINGW_TRUE@ MAKE_IMPLIB_MdsLib_client=-Wl,--out-implib,$(IMPLIB_MdsLib_client) -@MAKESHLIBDIR@@LIBPRE@MdsLib_client@SHARETYPE@ : $(OBJECTS_CLIENT) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKELIBDIR@ -lMdsShr -lMdsIpShr $(LIBS) $(GLOBUS_LDFLAGS) $(MAKE_IMPLIB_MdsLib_client) - -@MAKELIBDIR@@LIBPRE@MdsLib_client.a : $(OBJECTS_CLIENT) - $(AR) -cr $@ $^ - @RANLIB@ $@ - -@MINGW_TRUE@ MAKE_IMPLIB_MdsLib_fortran=-Wl,--out-implib,$(IMPLIB_MdsLib_fortran) -@MAKESHLIBDIR@@LIBPRE@MdsLib_fortran@SHARETYPE@ : $(OBJECTS_FORTRAN) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKELIBDIR@ -lMdsShr -lMdsIpShr -L@MAKESHLIBDIR@ $(MDSLIB_LIBS) $(LIBS) $(GLOBUS_LDFLAGS) $(MAKE_IMPLIB_MdsLib_fortran) - -@MAKELIBDIR@@LIBPRE@MdsLib_fortran.a : $(OBJECTS_FORTRAN) - $(AR) -cr $@ $^ - @RANLIB@ $@ - -MdsLib.o: MdsLib.c - $(COMPILE.c) $< $(OUTPUT_OPTION) -DFILENAME=MdsLib.c - -MdsLib_client.o: MdsLib.c - $(COMPILE.c) $< $(OUTPUT_OPTION) -DFILENAME=MdsLib.c -D_CLIENT_ONLY - -MdsLib_fortran.o: MdsLib.c - $(COMPILE.c) $< $(OUTPUT_OPTION) -DFILENAME=MdsLib.c -DOLD_FORTRAN_API - diff --git a/mdslib/docs/Makefile.am b/mdslib/docs/Makefile.am deleted file mode 100644 index 8ca40ec35e..0000000000 --- a/mdslib/docs/Makefile.am +++ /dev/null @@ -1,33 +0,0 @@ - -include ../../docs/config/doxygen.am - - -# //////////////////////////////////////////////////////////////////////////// # -# DOXYGEN CONFIG # -DX_CONFIG = "${top_srcdir}/docs/config/doxygen.cfg" -DX_DOCDIR = mdslib/docs -DX_PACKAGE_NAME = mdslib -DX_TITLE = MDSlib -DX_BRIEF = "MDSplus library" - - -DX_PAGES = .. \ - index.md - - -DX_EXCLUDE_PAGES = - -DX_TAGFILES = docs.tag - - -MOSTLYCLEANFILES = $(DX_CLEANFILES) - -# //////////////////////////////////////////////////////////////////////////// # -# TARGETS # - -all: html - -html: doxygen-run -pdf: doxygen-pdf - -install-data-local: doxygen-install diff --git a/mdslib/testing/Makefile.am b/mdslib/testing/Makefile.am deleted file mode 100644 index 561ba769ad..0000000000 --- a/mdslib/testing/Makefile.am +++ /dev/null @@ -1,49 +0,0 @@ -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - - - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ @LIBS@ -LDADD = -lMdsLib -lTdiShr -lTreeShr -lMdsShr -lMdsIpShr $(TEST_LIBS) - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .out -AM_DEFAULT_SOURCE_EXT = .c - -TESTS = \ - dtype_test\ - mdslib_ctest\ - mdslib_ftest\ - mdslib_fremotetest - -VALGRIND_SUPPRESSIONS_FILES = - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = *.out test_*.tree test_*.characteristics test_*.datafile - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -print_shell: - @echo "SHELL = ${SHELL}" - -all-local: $(TESTS) -clean-local: clean-local-tests - -check_PROGRAMS = $(TESTS) -check_SCRIPTS = - -mdslib_ftest$(EXEEXT) : mdslib_ftest.f $(MdsLib) - $(LINK.F) $(OUTPUT_OPTION) $< @FEXECLIBDIR@@MAKESHLIBDIR@ $(FCFLAGS) $(LDADD) -Wno-error - -mdslib_fremotetest$(EXEEXT) : mdslib_fremotetest.f $(MdsLib) - $(LINK.F) $(OUTPUT_OPTION) $< @FEXECLIBDIR@@MAKESHLIBDIR@ $(FCFLAGS) $(LDADD) -Wno-error - diff --git a/mdslibidl/Makefile.in b/mdslibidl/Makefile.in deleted file mode 100644 index 83c8a8474c..0000000000 --- a/mdslibidl/Makefile.in +++ /dev/null @@ -1,24 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -SOURCES = MdsLibIdl.c -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@MdsLibIdl@SHARETYPEMOD@ - -@MAKESHLIBDIR@@LIBPRE@MdsLibIdl@SHARETYPEMOD@ : $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ $(LIBM) -L@MAKESHLIBDIR@ -lTdiShr -lTreeShr -lMdsShr $(LIBS) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsLibIdl@SHARETYPEMOD@ - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MdsLibIdl@SHARETYPEMOD@ $(libdir) diff --git a/mdsmisc/Makefile.in b/mdsmisc/Makefile.in deleted file mode 100644 index 184dcb0088..0000000000 --- a/mdsmisc/Makefile.in +++ /dev/null @@ -1,54 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX=MdsMisc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS+=@GLOBUS_CFLAGS@ -LIBS=@LIBS@ @LIBDL@ - -SOURCES = boxsmooth.c \ - bwfilter.c \ - getnidarray.c \ - getreferences.c \ - resample.c \ - step_resample.c \ - fformat.c \ - filter.c \ - complex.c \ - butterworth.c \ - bessel.c \ - fir.c \ - iir.c \ - MdsFilter.c \ - whoami.c \ - ScopeUtilities.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@MdsMisc@SHARETYPE@ @MAKELIBDIR@@LIBPRE@MdsMisc.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsMisc.a - @ $(RM) @MAKESHLIBDIR@@LIBPRE@MdsMisc@SHARETYPE@ - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MdsMisc@SHARETYPE@ @libdir@ - if (test @SHARETYPE@ != .a) then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@MdsMisc.a @libdir@; \ - fi; - -@MAKESHLIBDIR@@LIBPRE@MdsMisc@SHARETYPE@ : $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(OBJECTS) $(LIBM) $(LIBS) -L@MAKESHLIBDIR@ -lTdiShr -lTreeShr -lMdsShr -lXTreeShr - -@MAKELIBDIR@@LIBPRE@MdsMisc.a : $(OBJECTS) - $(AR) -cr $@ $^ - @RANLIB@ $@ - diff --git a/mdsobjects/cpp/Makefile.in b/mdsobjects/cpp/Makefile.in deleted file mode 100644 index 9af2b95903..0000000000 --- a/mdsobjects/cpp/Makefile.in +++ /dev/null @@ -1,65 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -@MINGW_TRUE@ IMPLIB=@MAKELIBDIR@MdsObjectsCppShr.dll.a - -CPPFLAGS += -CFLAGS += @SRBINCLUDE@ -CXXFLAGS += -Wno-deprecated $(CFLAGS) @CXXFLAGS@ -LIBS=-L@MAKESHLIBDIR@ @LIBS@ -lMdsShr -lTreeShr -lTdiShr -lMdsIpShr @SRBLIB@ - -CXXSOURCES = \ - mdsdataobjects.cpp mdstreeobjects.cpp mdsipobjects.cpp mdseventobjects.cpp mdsdatastreams.cpp - -SOURCES = mdsdata.c mdstree.c - -OBJECTS = $(CXXSOURCES:.cpp=.o) $(SOURCES:.c=.o) - -@VS_TRUE@ VSDLL=@MAKELIBDIR@MdsObjectsCppShr-VS.dll @MAKELIBDIR@MdsObjectsCppShr-VS.lib @MAKELIBDIR@MdsObjectsCppShr-VS.exp - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@MdsObjectsCppShr@SHARETYPE@ $(IMPLIB) @MAKELIBDIR@@LIBPRE@MdsObjectsCppShr.a $(VSDLL) - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) @MAKESHLIBDIR@@LIBPRE@MdsObjectsCppShr@SHARETYPE@ $(IMPLIB) $(VSDLL) - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsObjectsCppShr.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MdsObjectsCppShr@SHARETYPE@ $(IMPLIB) $(libdir) - @VS_TRUE@ $(INSTALL) -m 755 @MAKELIBDIR@MdsObjectsCppShr-VS.dll @MAKESHLIBDIR@*.lib $(libdir) - if test @SHARETYPE@ != .a ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@MdsObjectsCppShr.a $(libdir); \ - fi; - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -@MAKESHLIBDIR@@LIBPRE@MdsObjectsCppShr@SHARETYPE@ $(IMPLIB): $(OBJECTS) - $(CXX) $(TARGET_ARCH) $(OUTPUT_OPTION) $(LDFLAGS) @LINKSHARED@ $(OBJECTS) $(LIBS) -lTdiShr -lTreeShr -lMdsShr $(MAKE_IMPLIB) $(CXXFLAGS) - -@MAKELIBDIR@@LIBPRE@MdsObjectsCppShr.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -generate-libs-from-dlls: - @mkdir -p $(top_builddir)/defs - @for i in $$(find @MAKESHLIBDIR@ -follow -name '*.dll'); do \ - deffile=$(top_builddir)/defs/$$(basename $${i/.dll/.def}) ;\ - gendef -a - $$i > $$deffile ;\ - @DLLTOOL@ -d $$deffile -l @MAKESHLIBDIR@/$$(basename $${i/.dll/.lib}); \ - done - -.PHONY: generate-libs-from-dlls - -ifneq "$(VSDLL)" "" - -$(VSDLL) : $(CXXSOURCES) $(SOURCES) $(IMPLIB) generate-libs-from-dlls -@HAVE_WINE_TRUE@ wine cmd.exe /C vsbuild @VS_DIR@ @VS_ARCH@ @MAKESHLIBDIR@ -@HAVE_WINE_FALSE@ @echo VSDLL defined but no wine: at this point we would have built VSDLLs - -endif diff --git a/mdsobjects/cpp/docs/Makefile.am b/mdsobjects/cpp/docs/Makefile.am deleted file mode 100644 index b6e29393e6..0000000000 --- a/mdsobjects/cpp/docs/Makefile.am +++ /dev/null @@ -1,37 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../../docs/config/doxygen.am - -# //////////////////////////////////////////////////////////////////////////// # -# DOXYGEN CONFIG # - -# DX_DOCDIR = mdsobjects/cpp/docs -DX_CONFIG = ${top_srcdir}/docs/config/doxygen_cpp.cfg -DX_DOCDIR = mdsobjects/cpp/docs -DX_PACKAGE_NAME = mdsobjects_cpp -DX_TITLE = MDSplus C++ interface -DX_BRIEF = "MDSplus object oriented interface" - -DX_PAGES = .. \ - ${top_srcdir}/include/mdsobjects.h \ - ${top_srcdir}/include/usagedef.h \ - ${top_srcdir}/include/mdsplus/ \ - index.md \ - native_types.md \ - wrapped_types.md - -DX_EXCLUDE_PAGES = - -DX_TAGFILES = docs.tag - -MOSTLYCLEANFILES = $(DX_CLEANFILES) - -# //////////////////////////////////////////////////////////////////////////// # -# TARGETS # - -all: html - -html: doxygen-run -pdf: doxygen-pdf - -install-data-local: doxygen-install diff --git a/mdsobjects/cpp/testing/Makefile.am b/mdsobjects/cpp/testing/Makefile.am deleted file mode 100644 index c61977c13d..0000000000 --- a/mdsobjects/cpp/testing/Makefile.am +++ /dev/null @@ -1,82 +0,0 @@ -SUBDIRS = testutils . - -include @top_builddir@/Makefile.inc -include ../../../testing/testing.am - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_CXXFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -fsigned-char -Wno-deprecated @CXXFLAGS@ $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ -AM_LIBS = $(LIBS) $(TEST_LIBS) testutils/libMdsTestUtils.a -LDADD = $(AM_LIBS) -lMdsShr -lTreeShr -lTdiShr -lMdsIpShr -lMdsObjectsCppShr \ -@MINGW_TRUE@ -lws2_32 -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -AM_DEFAULT_SOURCE_EXT = .cpp - -BUILD_FLAGS = @MAKEFLAG_J@ -# no parallel execution as this currently breaks the MdsConnectionTest "Connection local" -TEST_FLAGS = - -# -# This is the list of tests to be compiled and executed -# -TESTS = \ - buildtest \ - MdsExpressionCompileTest \ - MdsExceptionTest \ - MdsDataTest \ - MdsTdiTest \ - MdsScalarTest_NumericConversion \ - MdsScalarTest_NumericLimits \ - MdsScalarTest_ScalarCast \ - MdsStringTest \ - MdsCompoundTest \ - MdsSignalTest \ - MdsDimensionTest \ - MdsWindowTest \ - MdsFunctionTest \ - MdsConglomTest \ - MdsRangeTest \ - MdsTreeSuppression \ - MdsTreeTest \ - MdsTreeNodeTest \ - MdsTreeSegments \ - MdsEventSuppression \ - MdsEventTest \ - MdsConnectionTest - -# MdsCallTest -# MdsActionTest -# MdsApdTest - -# set VALGRIND_TESTS to select a subset of tests performed under valgrind if -# the variable is unset all TESTS are added. -# -# VALGRIND_TESTS = - -VALGRIND_SUPPRESSIONS_FILES = \ - $(srcdir)/valgrind.supp \ - $(top_srcdir)/mdsshr/testing/valgrind.supp - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = *.out \ - testing.hosts \ - t_*.* - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -all-local: $(TESTS) - -clean-local: clean-local-tests - -check_PROGRAMS = $(TESTS) -check_SCRIPTS = - - diff --git a/mdsobjects/cpp/testing/testutils/CMakeLists.txt b/mdsobjects/cpp/testing/testutils/CMakeLists.txt new file mode 100644 index 0000000000..898d8b2248 --- /dev/null +++ b/mdsobjects/cpp/testing/testutils/CMakeLists.txt @@ -0,0 +1,30 @@ + +# TODO: Remove this library + +### +### MdsTestUtils +### + +add_library( + MdsTestUtils + CommaInit.h + FunctionTypes.h + Singleton.h + testutils.h + type_traits.h + unique_ptr.h + vector_test.h + MdsIpInstancer.h + testutils.cpp + mdsipmain.c +) + +target_link_libraries( + MdsTestUtils + PUBLIC + MdsObjectsCppShr +) + +mdsplus_add_static_copy(MdsTestUtils _static_target) + +# install(TARGETS MdsTestUtils ${_static_target}) diff --git a/mdsobjects/cpp/testing/testutils/Makefile.am b/mdsobjects/cpp/testing/testutils/Makefile.am deleted file mode 100644 index 50e04096f9..0000000000 --- a/mdsobjects/cpp/testing/testutils/Makefile.am +++ /dev/null @@ -1,55 +0,0 @@ - -include @top_builddir@/Makefile.inc - -AM_DEFAULT_SOURCE_EXT = .cpp - -# NOTE: please note that also ${top_srcdir} is added to be able to access the -# mdstcpip includes .. needed by mdsipmain.c -# -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -I${top_srcdir} -AM_CXXFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -Wno-deprecated @CXXFLAGS@ -I${top_srcdir} -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ - -AM_LIBS = $(LIBS) -lMdsShr -lTreeShr -lTdiShr -lMdsIpShr -lMdsObjectsCppShr -LDADD = $(AM_LIBS) - -library_includedir = $(includedir)/mdsplus/testutils -library_include_HEADERS = \ - CommaInit.h \ - FunctionTypes.h \ - Singleton.h \ - testutils.h \ - type_traits.h \ - unique_ptr.h \ - vector_test.h \ - MdsIpInstancer.h -_SOURCES = \ - testutils.cpp \ - mdsipmain.c - - -# -# libtool version: -# -# noinst_LTLIBRARIES = libMdsTestUtils.la -# libMdsTestUtils_la_SOURCES = ${_SOURCES} -# libMdsTestUtils_la_LIBADD = $(AM_LIBS) -# - - -# -# Static TestUtils library -# -noinst_LIBRARIES = libMdsTestUtils.a -libMdsTestUtils_a_SOURCES = $(_SOURCES) - - -# -# This library aims to provide the test symbols for the MdsCall object check -# -libMdsTestDummy.so: testutils.cpp - $(CC) $(CPPFLAGS) $(CFLAGS) $(AM_CXXFLAGS) -shared -o $@ $^ - -MOSTLYCLEANFILES = libMdsTestDummy.so - -all-local: libMdsTestDummy.so diff --git a/mdsobjects/labview/Makefile.in b/mdsobjects/labview/Makefile.in deleted file mode 100644 index be23c4189a..0000000000 --- a/mdsobjects/labview/Makefile.in +++ /dev/null @@ -1,80 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -MKDIR_P=@MKDIR_P@ -@AX_RECONFIGURE_TARGET@ - -LD=@CXX@ -CFLAGS+=-I@LV_CINTOOLS@ -fPIC @TARGET_ARCH@ -CXXFLAGS=-Wno-deprecated -fPIC @CFLAGS@ -I@LV_CINTOOLS@ @TARGET_ARCH@ @CXXFLAGS@ -CLIBS=-L@MAKESHLIBDIR@ @LIBS@ -lMdsShr -@MINGW_TRUE@ LV_LIB="@LV_CINTOOLS@/labview-$(host_cpu).lib" -@MINGW_FALSE@ LV_LIB=-lLV -CXXLIBS=-L@MAKESHLIBDIR@ @LIBS@ -lMdsShr -lTreeShr -lTdiShr -lMdsIpShr -lMdsObjectsCppShr $(LV_LIB) -@MINGW_FALSE@ LV_SHR=@MAKESHLIBDIR@@LIBPRE@LV@SHARETYPE@ @MAKELIBDIR@@LIBPRE@LV.a @MAKESHLIBDIR@MDSobjectsLVShr @MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr -CSOURCES = lv.c - -CXXSOURCES = \ - mdsdataobjectswrp.cpp mdseventobjectswrp.cpp mdsipobjectswrp.cpp mdstreeobjectswrp.cpp - -COBJECTS= $(CSOURCES:.c=.o) -OBJECTS = $(CXXSOURCES:.cpp=.o) - -all : primary - $(MAKE) secundary @MAKEFLAG_J@ @MAKEFLAG_O@ - -primary : \ - @MAKELIBDIR@ \ - @MAKESHLIBDIR@ \ - $(LV_SHR) - -secundary : primary \ - @MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr@SHARETYPE@ \ - @MAKELIBDIR@@LIBPRE@MDSobjectsLVShr.a - -clean: - @ $(RM) $(COBJECTS) - @ $(RM) $(OBJECTS) - @ $(RM) @MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr - @ $(RM) @MAKESHLIBDIR@MDSobjectsLVShr - @ $(RM) @MAKESHLIBDIR@@LIBPRE@LV@SHARETYPE@ - @ $(RM) @MAKELIBDIR@@LIBPRE@LV.a - @ $(RM) @MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr@SHARETYPE@ - @ $(RM) @MAKELIBDIR@@LIBPRE@MDSobjectsLVShr.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(MKDIR_P) $(exec_prefix)/LabView - tar -C ${top_srcdir}/mdsobjects/labview -cf - MDSplus | tar -C ${exec_prefix}/LabView -xf - - tar -C ${top_srcdir}/mdsobjects/labview -cf - MDSplus_LV2012 | tar -C ${exec_prefix}/LabView -xf - - tar -C ${top_srcdir}/mdsobjects/labview -cf - MDSplus_LV2015 | tar -C ${exec_prefix}/LabView -xf - - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr@SHARETYPE@ @libdir@ -@MINGW_FALSE@ $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr @libdir@ -@MINGW_FALSE@ $(INSTALL) -m 755 @MAKESHLIBDIR@MDSobjectsLVShr @libdir@ -@MINGW_FALSE@ $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@LV@SHARETYPE@ @libdir@ - -@MAKESHLIBDIR@@LIBPRE@LV@SHARETYPE@: $(COBJECTS) - $(LD) -o $@ $(CFLAGS) @LINKSHARED@ $(COBJECTS) $(CLIBS) $(LIBS) $(CXXFLAGS) - -@MAKELIBDIR@@LIBPRE@LV.a : $(COBJECTS) - $(AR) -cr $@ $(COBJECTS) - @RANLIB@ $@ - -@MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr@SHARETYPE@ : $(OBJECTS) - $(LD) -o $@ $(CXXFLAGS) @LINKSHARED@ $(OBJECTS) $(CXXLIBS) - -@MAKELIBDIR@@LIBPRE@MDSobjectsLVShr.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -ifneq "@LIBPRE@" "" -@MAKESHLIBDIR@@LIBPRE@MDSobjectsLVShr : - ln -sf @LIBPRE@MDSobjectsLVShr@SHARETYPE@ $@ -endif - -@MAKESHLIBDIR@MDSobjectsLVShr : - ln -sf @LIBPRE@MDSobjectsLVShr@SHARETYPE@ $@ diff --git a/mdsshr/Makefile.in b/mdsshr/Makefile.in deleted file mode 100644 index 46886951fc..0000000000 --- a/mdsshr/Makefile.in +++ /dev/null @@ -1,85 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX=Mds - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -MKDIR_P=@MKDIR_P@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS += $(THREAD) @GLOBUS_CFLAGS@ @XML_CPPFLAGS@ -LDFLAGS += $(THREAD) - -@MINGW_TRUE@IMPLIB = @MAKELIBDIR@MdsShr.dll.a -@MINGW_TRUE@CFLAGS += -DLIBXML_STATIC -@MINGW_TRUE@XML_LIBS = -Wl,-Bstatic -lxml2 -lz @LIBLZMA@ -Wl,-Bdynamic -liconv -@MINGW_FALSE@XML_LIBS = @XML_LIBS@ -LIBS=@LIBS@ @LIBDL@ $(XML_LIBS) @CLOCK_GETTIME_LIB@ $(LIBSOCKET) \ -@MINGW_TRUE@ -liphlpapi - - -lib_LIBRARIES = MdsShr -libStatic = $(addsuffix .a, $(addprefix @MAKELIBDIR@@LIBPRE@, $(lib_LIBRARIES))) -libShared = $(addsuffix @SHARETYPE@, $(addprefix @MAKESHLIBDIR@@LIBPRE@, $(lib_LIBRARIES))) -libs = $(libStatic) $(libShared) $(IMPLIB) - -SOURCES = \ - gzipcompress.c \ - librtl.c \ - mdsmsg.c \ - MDSprintf.c \ - MdsCmprs.c \ - MdsCompareXd.c \ - MdsCompress.c \ - MdsEvents.c \ - MdsGet1DxA.c \ - MdsGet1DxS.c \ - MdsGetSetShotId.c \ - MdsGetStdMsg.c \ - MdsPk.c \ - MdsSandbox.c \ - MdsSerialize.c \ - MdsThreadStatic.c \ - MdsXdRoutines.c \ - mds_dsc_string.c \ - UdpEvents.c \ - UdpEventSettings.c - -OBJECTS = $(SOURCES:.c=.o) - -## Version info for git needs to be checked for tag each time -.PHONY: MdsVersionInfo.o -MdsVersionInfo.o: CFLAGS := $(CFLAGS) -D_GIT_TAG=$(GIT_TAG) -MdsVersionInfo.o: MdsVersionInfo.c - $(COMPILE.c) $(OUTPUT_OPTION) $< - - -all: @MAKELIBDIR@ @MAKESHLIBDIR@ $(libs) - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) $(libs) - -install: $(libdir) - $(INSTALL) -m 755 $(libs) $(libdir) - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -@MAKELIBDIR@%.dll @MAKELIBDIR@%.dll.a: $(OBJECTS) - $(LINK.c) -o $@ @LINKSHARED@ $(OBJECTS) $(LIBS) $(MAKE_IMPLIB) - -#%.so %.dylib: $(OBJECTS) -# $(LINK.o) $(OUTPUT_OPTION) @LINKSHARED@ $^ $(LIBS) - -@MAKELIBDIR@libMdsShr.so @MAKELIBDIR@libMdsShr.dylib: $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ $(LIBS) - -%.a: $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -#MdsGetStdMsg.c : -# python gen_messages.py diff --git a/mdsshr/docs/Makefile.am b/mdsshr/docs/Makefile.am deleted file mode 100644 index a0c3ba6469..0000000000 --- a/mdsshr/docs/Makefile.am +++ /dev/null @@ -1,37 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../docs/config/doxygen.am - - -# //////////////////////////////////////////////////////////////////////////// # -# DOXYGEN CONFIG # -DX_CONFIG = "${top_srcdir}/docs/config/doxygen.cfg" -DX_DOCDIR = mdsshr/docs -DX_PACKAGE_NAME = mdsshr -DX_TITLE = MdsShr -DX_BRIEF = "MDSplus MdsShr kernel library" - - -DX_PAGES = .. \ - index.md \ - $(top_srcdir)/include/mdsshr.h \ - $(top_srcdir)/include/mdsshr_messages.h \ - $(top_srcdir)/include/mdsdescrip.h \ - $(top_srcdir)/include/mdstypes.h \ - $(top_srcdir)/include/libroutines.h \ - $(top_srcdir)/include/strroutines.h - -DX_TAGFILES = docs.tag - - -MOSTLYCLEANFILES = $(DX_CLEANFILES) - -# //////////////////////////////////////////////////////////////////////////// # -# TARGETS # - -all: html - -html: doxygen-run -pdf: doxygen-pdf - -install-data-local: doxygen-install diff --git a/mdsshr/testing/Makefile.am b/mdsshr/testing/Makefile.am deleted file mode 100644 index 14500f7656..0000000000 --- a/mdsshr/testing/Makefile.am +++ /dev/null @@ -1,39 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_CXXFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -Wno-deprecated @CXXFLAGS@ $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ -LDADD = @LIBS@ $(TEST_LIBS) -lMdsShr $(LIBSOCKET) - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .py .pl -AM_DEFAULT_SOURCE_EXT = .c - -TESTS = \ - UdpEventsTest \ - UdpEventsTestStatics - -UdpEventsTestStatics.o: ../UdpEvents.c - -VALGRIND_SUPPRESSIONS_FILES = \ - $(srcdir)/valgrind.supp - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = *.out - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -all-local: $(TESTS) -clean-local: clean-local-tests - -check_PROGRAMS = $(TESTS) -check_SCRIPTS = diff --git a/mdssql/Makefile.in b/mdssql/Makefile.in deleted file mode 100644 index 0177a84027..0000000000 --- a/mdssql/Makefile.in +++ /dev/null @@ -1,39 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS+=@SYBASE_INC@ @TARGET_ARCH@ -LD_FLAGS=$(LDFLAGS) @TARGET_ARCH@ -LIBS=@LIBS@ @SYBASE_LIB@ @DNET_STUB@ @LIBSOCKET@ - -SOURCES = \ -dynamic_syb.c \ -dbstubs.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKELIBDIR@@LIBPRE@MdsSql@SHARETYPE@ @MAKELIBDIR@@LIBPRE@MdsSql.a - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsSql@SHARETYPE@ - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsSql.a - - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@MdsSql.a @libdir@ - $(INSTALL) -m 755 @MAKELIBDIR@@LIBPRE@MdsSql@SHARETYPE@ @libdir@ - -@MAKELIBDIR@@LIBPRE@MdsSql@SHARETYPE@ : $(OBJECTS) - $(LINK.c) -o $@ @LINKSHARED@ $(OBJECTS) -L@MAKELIBDIR@ $(LDFLAGS) $(LIBS) - -@MAKELIBDIR@@LIBPRE@MdsSql.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - $(RANLIB) $@ diff --git a/mdstcpip/Makefile.in b/mdstcpip/Makefile.in deleted file mode 100644 index c232f61552..0000000000 --- a/mdstcpip/Makefile.in +++ /dev/null @@ -1,249 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX = MdsIp - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -MKDIR_P=@MKDIR_P@ -@AX_RECONFIGURE_TARGET@ - - -@MINGW_TRUE@ IMPLIB_MdsIpShr=@MAKELIBDIR@MdsIpShr.dll.a -@MINGW_TRUE@ WIN=.win - -COMPRESSION_SWITCH= -COMPRESSION_SOURCES = $(wildcard @srcdir@/zlib/*.c) -COMPRESSION_OBJECTS = $(COMPRESSION_SOURCES:@srcdir@/%.c=@builddir@/%.o) -$(COMPRESSION_OBJECTS): | --zlib-dir ---zlib-dir: - @$(MKDIR_P) zlib - -CFLAGS += $(THREAD) $(COMPRESSION_SWITCH) -I@srcdir@/udt4/src -I@srcdir@/udt4/udtc -LDFLAGS += $(THREAD) - -CXXFLAGS=-Wno-deprecated -fPIC -finline-functions -fno-strict-aliasing $(CFLAGS) @CXXFLAGS@ -LIBS=@LIBS@ @LIBRESOLV@ $(LIBSOCKET) - -MdsIpShr = @MAKESHLIBDIR@@LIBPRE@MdsIpShr@SHARETYPE@ $(IMPLIB_MdsIpShr) -MdsIpSrvShr = @MAKESHLIBDIR@@LIBPRE@MdsIpSrvShr@SHARETYPE@ $(IMPLIB_MdsIpSrvShr) -MdsIpTCP = @MAKESHLIBDIR@@LIBPRE@MdsIpTCP@SHARETYPE@ -MdsIpTCPV6 = @MAKESHLIBDIR@@LIBPRE@MdsIpTCPV6@SHARETYPE@ -MdsIpUDT = @MAKESHLIBDIR@@LIBPRE@MdsIpUDT@SHARETYPE@ -MdsIpUDTV6 = @MAKESHLIBDIR@@LIBPRE@MdsIpUDTV6@SHARETYPE@ - -# fix this -@MINGW_FALSE@ IPV6_UDT = $(MdsIpTCPV6) $(MdsIpUDT) $(MdsIpUDTV6) -@MINGW_TRUE@ MDSIP_SERVICE = @MAKEBINDIR@mdsip_service.exe - -ifeq "@SHARETYPEMOD@" "@SHARETYPE@" - modules = -else #SHARETYPE - modules = @MAKESHLIBDIR@@LIBPRE@MdsIpShr@SHARETYPEMOD@ -endif #SHARETYPE - - -## MdsIpShr sources ## -shr_srcdir = $(srcdir)/mdsipshr ---mdsipshr-dir: - @$(MKDIR_P) mdsipshr -LIB_SOURCES = $(wildcard $(shr_srcdir)/*.c) -LIB_OBJECTS = $(LIB_SOURCES:$(srcdir)/%.c=%.o) -LIB_HEADERS = $(srcdir)/mdsip_connections.h -$(LIB_OBJECTS): $(LIB_HEADERS) | --mdsipshr-dir - -SERVER_SOURCES = mdsip.c -SERVER_OBJECTS = $(SERVER_SOURCES:.c=.o) - -io_srcdir = $(srcdir)/io_routines ---io_routines-dir: - @$(MKDIR_P) io_routines -ETH_HEADERS = $(addprefix $(io_srcdir)/,ioroutines.h ioroutinesx.h) -ETHV6_HEADERS = $(addprefix $(io_srcdir)/,ioroutinesV6.h ioroutinesx.h) -TCP_HEADERS = $(ETH_HEADERS) $(io_srcdir)/ioroutinestcp.h -UDT_HEADERS = $(ETH_HEADERS) $(io_srcdir)/ioroutinesudt.h - -TCP_SOURCES = $(io_srcdir)/IoRoutinesTcp.c -TCP_OBJECTS = $(TCP_SOURCES:$(srcdir)/%.c=%.o) -TCPV6_SOURCES = $(io_srcdir)/IoRoutinesTcpV6.c -TCPV6_OBJECTS = $(TCPV6_SOURCES:$(srcdir)/%.c=%.o) - -UDT_SOURCES = $(io_srcdir)/IoRoutinesUdt.c -UDT_OBJECTS = $(UDT_SOURCES:$(srcdir)/%.c=%.o) -UDTV6_SOURCES = $(io_srcdir)/IoRoutinesUdtV6.c -UDTV6_OBJECTS = $(UDTV6_SOURCES:$(srcdir)/%.c=%.o) - -$(TCP_OBJECTS) $(TCPV6_OBJECTS): $(TCP_HEADERS) | --io_routines-dir -$(UDT_OBJECTS) $(UDTV6_OBJECTS): $(UDT_HEADERS) $(UDT4_OBJECTS) | --io_routines-dir - -PIPE_SOURCES = $(addprefix $(io_srcdir)/,IoRoutinesTunnel.c IoRoutinesThread.c) -PIPE_OBJECTS = $(PIPE_SOURCES:$(srcdir)/%.c=%.o) -PIPE_HEADERS = $(io_srcdir)/ioroutines_pipes.h -$(PIPE_OBJECTS): $(PIPE_HEADERS) | --io_routines-dir -LIB_SOURCES += $(PIPE_SOURCES) -LIB_OBJECTS += $(PIPE_OBJECTS) - - ---udt4-dirs: - @$(MKDIR_P) udt4/src udt4/udtc -UDT4_SOURCES = $(wildcard @srcdir@/udt4/src/*.cpp) $(wildcard @srcdir@/udt4/udtc/*.cpp) -UDT4_OBJECTS = $(UDT4_SOURCES:@srcdir@/%.cpp=%.o) -$(UDT4_OBJECTS): | --udt4-dirs - - -CLEAN_OBJECTS = $(COMPRESSION_OBJECTS) $(LIB_OBJECTS) $(UDT4_OBJECTS)\ - $(TCP_OBJECTS) $(UDT_OBJECTS) $(TCPV6_OBJECTS) $(UDTV6_OBJECTS) -ALL_SOURCES = $(LIB_SOURCES) $(TCP_SOURCES) $(TCPV6_SOURCES) $(UDT_SOURCES) $(UDTV6_SOURCES) - -bin_SCRIPTS = -@MINGW_TRUE@bin_SCRIPTS += @MAKEBINDIR@mdsip_service.exe.manifest -@MINGW_TRUE@bin_SCRIPTS += @MAKEBINDIR@mdsip-client-ssh.bat -@MINGW_TRUE@bin_SCRIPTS += @MAKEBINDIR@mdsip-client-sshp.bat -@MINGW_TRUE@bin_SCRIPTS += @MAKEBINDIR@mdsip-client-local.bat - - -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsipd -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsip_server -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsip-client-ssh -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsip-client-sshp -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsip-client-http -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsip-client-local -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsip-server-ssh -@MINGW_FALSE@bin_SCRIPTS += @MAKEBINDIR@mdsip-server-http - - -ifneq "@GLOBUS_FLAVOR@" "" - -MdsIpGSI = @MAKESHLIBDIR@@LIBPRE@MdsIpGSI@SHARETYPE@ -GSI_SOURCES = @srcdir@/io_routines/IoRoutinesGsi.c -GSI_OBJECTS = $(GSI_SOURCES:@srcdir@/%.c=%.o) -ALL_SOURCES += $(GSI_SOURCES) -CLEAN_OBJECTS += $(GSI_OBJECTS) -MDSIPSD = @MAKEBINDIR@mdsipsd - -endif #GLOBUS_FLAVOR - -PROGRAMS = $(bin_SCRIPTS) $(MDSIPSD) @MAKEBINDIR@mdsip$(EXE) $(MDSIP_SERVICE) - -all : primary - $(MAKE) secundary @MAKEFLAG_J@ @MAKEFLAG_O@ - -primary : \ - $(MAKEFILE_HEADER) \ - @MAKEBINDIR@ @MAKELIBDIR@ @MAKEETCDIR@ \ - $(PROGRAMS) \ - $(MdsIpShr) \ - $(UDT4_DIRS) - -secundary : primary \ - $(modules) \ - $(MdsIpTCP) \ - $(MdsIpTCPV6) \ - $(IPV6_UDT) \ - $(MdsIpGSI) \ - $(MDSIPSD) \ - @MAKEETCDIR@mdsip.hosts \ - @MAKEETCDIR@multi.hosts \ - @MAKELIBDIR@@LIBPRE@MdsIpShr.a - -depend: - @makedepend -- $(CFLAGS) -- $(ALL_SOURCES) - -clean : - @ $(RM) $(CLEAN_OBJECTS) - @ $(RM) $(MdsIpShr) - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsIpShr.a - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsIpUtil.a - @ $(RM) $(PROGRAMS) - @ $(RM) @MAKEETCDIR@mdsip.hosts - @ $(RM) @MAKEETCDIR@multi.hosts - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsIpTCP@SHARETYPE@ - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsIpTCPV6@SHARETYPE@ - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsIpUDT@SHARETYPE@ - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsIpUDTV6@SHARETYPE@ -ifdef MdsIpGSI - @ $(RM) $(MdsIpGSI) - @ $(RM) $(MDSIPSD) -endif - -install: $(bindir) $(libdir) $(sysconfdir) - $(INSTALL) -m 755 $(PROGRAMS) @bindir@ - $(INSTALL) -m 755 $(MdsIpShr) @libdir@ -ifdef modules - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MdsIpShr@SHARETYPEMOD@ @libdir@ -endif - if test "@SHARETYPE@" != ".a" ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@MdsIpShr.a @libdir@; \ - fi; - $(INSTALL) -m 755 @MAKEETCDIR@mdsip.hosts $(sysconfdir) - $(INSTALL) -m 755 @MAKEETCDIR@multi.hosts $(sysconfdir) - $(INSTALL) -m 755 $(MdsIpTCP) @libdir@ - $(INSTALL) -m 755 $(MdsIpTCPV6) @libdir@ -@MINGW_FALSE@ $(INSTALL) -m 755 $(IPV6_UDT) @libdir@ -ifdef MdsIpGSI - $(INSTALL) -m 755 $(MdsIpGSI) @libdir@ -endif - -.PHONY: docs -docs: - doxygen docs/doxy.conf - -EXTRALIBS = -L@MAKESHLIBDIR@ -lMdsShr -lTdiShr -lTreeShr - -@MAKEBINDIR@mdsip_service.exe: mdsip_service.c $(MdsIpShr) - $(LINK.c) $< $(OUTPUT_OPTION) $(EXTRALIBS) -lMdsIpShr $(LIBS) - -@MAKEBINDIR@mdsip$(EXE): $(MdsIpShr) -@MAKEBINDIR@mdsip$(EXE): $(SERVER_OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) $(SERVER_OBJECTS) $(EXTRALIBS) -lMdsIpShr $(LIBS) - -@MAKELIBDIR@@LIBPRE@MdsIpShr.a : $(LIB_OBJECTS) $(COMPRESSION_OBJECTS) - $(AR) -cr $@ $^ - $(RANLIB) $@ - -$(modules): $(LIB_OBJECTS) $(COMPRESSION_OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKMODULE@ $(OBJECTS) $(LIBS) - -$(MDSIP_UTIL) : mdsiputil.o mdsip_socket_io.o mdsip_parallel.o $(COMPRESSION_OBJECTS) - $(AR) -cr $@ $^ - $(RANLIB) $@ - -@MINGW_TRUE@ MAKE_IMPLIB_MdsIpShr=-Wl,--out-implib,$(IMPLIB_MdsIpShr) -$(MdsIpShr): $(LIB_OBJECTS) $(COMPRESSION_OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) $^ @LINKSHARED@ $(EXTRALIBS) $(LIBS) -lMdsShr -lTreeShr -lTdiShr $(MAKE_IMPLIB_MdsIpShr) -LINK_MDSIPSHR = -L@MAKESHLIBDIR@ -lMdsIpShr -lMdsShr - -$(MdsIpTCP): $(TCP_OBJECTS) $(MdsIpShr) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(TCP_OBJECTS) $(LINK_MDSIPSHR) $(LIBS) - -$(MdsIpTCPV6): $(TCPV6_OBJECTS) $(MdsIpShr) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(TCPV6_OBJECTS) $(LINK_MDSIPSHR) $(LIBS) - -$(MdsIpUDT): $(UDT_OBJECTS) $(UDT4_OBJECTS) $(MdsIpShr) - $(CXX) $(TARGET_ARCH) $(OUTPUT_OPTION) @LINKSHARED@ $(LDFLAGS) $(UDT_OBJECTS) $(UDT4_OBJECTS) $(CXXFLAGS) $(LINK_MDSIPSHR) $(LIBS) - -$(MdsIpUDTV6): $(UDTV6_OBJECTS) $(UDT4_OBJECTS) $(MdsIpShr) - $(CXX) $(TARGET_ARCH) $(OUTPUT_OPTION) @LINKSHARED@ $(LDFLAGS) $(UDTV6_OBJECTS) $(UDT4_OBJECTS) $(CXXFLAGS) $(LINK_MDSIPSHR) $(LIBS) - -@MAKEETCDIR@mdsip.hosts : mdsip.hosts$(WIN) - cp $< $@ -@MAKEETCDIR@multi.hosts : multi.hosts$(WIN) - cp $< $@ - -$(bin_SCRIPTS): @MAKEBINDIR@%: % - cp $< $@ - - -ifdef MdsIpGSI - -#makefile-header: -# GLOBUS_LOCATION=@GLOBUS_LOCATION@; $$GLOBUS_LOCATION/bin/globus-makefile-header --flavor=@GLOBUS_FLAVOR@pthr globus_xio globus_xio_gsi_driver > makefile-eader - -#include makefile-header - -$(MdsIpGSI): io_routines/IoRoutinesGsi.c | --io_routines-dir - $(LINK.c) $(OUTPUT_OPTION) $< $$(pkg-config --cflags globus-xio) @LINKSHARED@ $(LIBS) $(LINK_MDSIPSHR) $$(pkg-config --libs globus-xio globus-xio-gsi-driver globus-gssapi-gsi globus-gss-assist globus-common) - -@MAKEBINDIR@mdsipsd : mdsipsd - cp $< $@ -endif diff --git a/mdstcpip/docs/Makefile.am b/mdstcpip/docs/Makefile.am deleted file mode 100644 index b867ad112d..0000000000 --- a/mdstcpip/docs/Makefile.am +++ /dev/null @@ -1,44 +0,0 @@ -SUBDIRS = img . - -include @top_builddir@/Makefile.inc -include ../../docs/config/doxygen.am - - -# //////////////////////////////////////////////////////////////////////////// # -# DOXYGEN CONFIG # -DX_CONFIG = "${top_srcdir}/docs/config/doxygen.cfg" -DX_DOCDIR = mdstcpip/docs -DX_PACKAGE_NAME = mdsip -DX_TITLE = MDSip -DX_BRIEF = "MDSplus remote data access library" - - -DX_PAGES = .. \ - index.md \ - Clients_connection.md \ - Objects_bindings.md \ - Protocols_plugins.md - - -DX_EXCLUDE_PAGES = \ - ../io_routines/* \ - ../udt4/* \ - ../zlib/* \ - ../mdsip.c \ - ../mdsip.h \ - ../mdsip_service.c - -DX_TAGFILES = docs.tag - - -MOSTLYCLEANFILES = $(DX_CLEANFILES) - -# //////////////////////////////////////////////////////////////////////////// # -# TARGETS # - -all: html - -html: doxygen-run -pdf: doxygen-pdf - -install-data-local: doxygen-install diff --git a/mdstcpip/docs/img/Makefile.am b/mdstcpip/docs/img/Makefile.am deleted file mode 100644 index 6ba2f66ddb..0000000000 --- a/mdstcpip/docs/img/Makefile.am +++ /dev/null @@ -1,40 +0,0 @@ - -CLEANFILES = *.log *.idx *.out *.toc *.aux - - - -SUFFIXES = .pdf .png -.PRECIOUS: %.tex %.pdf %.png - - -# //////////////////////////////////////////////////////////////////////////// # -# // GENERATE IMAGES // - -IMAGES = \ - mdsip_login.png \ - tc_open.png \ - tc_value.png - -#### implicit rules #### - - -.tex.pdf: - pdflatex $< - -.pdf.png: - convert $< $@ - - - -PHONY: images -images: ${IMAGES} - - -if DX_COND_pdf -all: images -endif DX_COND_pdf - - -# //////////////////////////////////////////////////////////////////////////// # - - diff --git a/mdstcpip/testing/Makefile.am b/mdstcpip/testing/Makefile.am deleted file mode 100644 index 45064608c7..0000000000 --- a/mdstcpip/testing/Makefile.am +++ /dev/null @@ -1,41 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_CXXFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -Wno-deprecated @CXXFLAGS@ $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ -LDADD = @LIBS@ $(TEST_LIBS) -lMdsShr -lMdsIpShr - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .py .pl -AM_DEFAULT_SOURCE_EXT = .c - -TESTS = MdsIpTest - -VALGRIND_TESTS = $(TESTS) - -VALGRIND_SUPPRESSIONS_FILES = - - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - - -all-local: $(TESTS) -clean-local: clean-local-tests - -check_PROGRAMS = $(TESTS) -check_SCRIPTS = diff --git a/mdsvme/Makefile.in b/mdsvme/Makefile.in deleted file mode 100644 index d85fa5fee2..0000000000 --- a/mdsvme/Makefile.in +++ /dev/null @@ -1,40 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -LIBS=@LIBS@ @LIBDL@ - -SOURCES = \ - mdsvme.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@libMdsVme@SHARETYPE@ @MAKELIBDIR@libMdsVme.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKELIBDIR@libMdsVme.a - @ $(RM) @MAKESHLIBDIR@libMdsVme@SHARETYPE@ - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@libMdsVme@SHARETYPE@ @libdir@ - if (test @SHARETYPE@ != .a) then \ - $(INSTALL) -m 644 @MAKELIBDIR@libMdsVme.a @libdir@; \ - fi; - -@MAKESHLIBDIR@libMdsVme@SHARETYPE@ : $(OBJECTS) - $(LD) -o $@ @LINKSHARED@ $(OBJECTS) $(LIBS) - -@MAKELIBDIR@libMdsVme.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -MdsVme.exports: MdsVme.def - sed -e /LIBRARY/\;/\;/d MdsVme.def > $@ diff --git a/mitdevices/Makefile.in b/mitdevices/Makefile.in deleted file mode 100644 index 0241d264dd..0000000000 --- a/mitdevices/Makefile.in +++ /dev/null @@ -1,336 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -SHELL=/bin/bash -X_CFLAGS=@X_CFLAGS@ -CFLAGS+=$(X_CFLAGS) $(TARGET_ARCH) -LD_FLAGS=$(LDFLAGS) $(TARGET_ARCH) -LIBS=@LIBS@ @LIBM@ -X_LIBS=@X_LIBS@ -X_EXTRA_LIBS=@X_EXTRA_LIBS@ -X_PRE_LIBS=@X_PRE_LIBS@ -MOTIF_LIBS = @MOTIF_LD_LDARC@ @XM_LIBS@ @MOTIF_LD_LDSHARE@ @LIBXP@ @LIBXEXT@ -UIL=@UIL@ -I$(top_srcdir)/include -MATH_LIBS=-L@MAKESHLIBDIR@ -lMdsMath -LIBDC1394_LIBS=-ldc1394 -lraw1394 $(THREAD) -LIBDC1394_INCS=-I$(top_srcdir)/include -I/usr/include/dc1394 -I/usr/include/libraw1394a $(THREAD) -export @LIBPATH@=@MAKESHLIBDIR@ -DTACQ_FILESYSTEM := $(shell find ${srcdir}/acq_root_filesystem -print) -DC := $(shell date) - -UIDS = \ -@MAKEUIDDIR@A12.uid \ -@MAKEUIDDIR@A14.uid \ -@MAKEUIDDIR@A3204.uid \ -@MAKEUIDDIR@B2408.uid \ -@MAKEUIDDIR@B3224.uid \ -@MAKEUIDDIR@B5910A.uid \ -@MAKEUIDDIR@CHS_A14.uid \ -@MAKEUIDDIR@DC1394.uid \ -@MAKEUIDDIR@DC1394A.uid \ -@MAKEUIDDIR@DT101.uid \ -@MAKEUIDDIR@DT196.uid \ -@MAKEUIDDIR@DT196A.uid \ -@MAKEUIDDIR@DT200.uid \ -@MAKEUIDDIR@DT_ACQ16.uid \ -@MAKEUIDDIR@DT200DA.uid \ -@MAKEUIDDIR@DT216.uid \ -@MAKEUIDDIR@DT216A.uid \ -@MAKEUIDDIR@DSP2904.uid \ -@MAKEUIDDIR@EC727.uid \ -@MAKEUIDDIR@FERA.uid \ -@MAKEUIDDIR@H908.uid \ -@MAKEUIDDIR@H911.uid \ -@MAKEUIDDIR@H912.uid \ -@MAKEUIDDIR@HM650.uid \ -@MAKEUIDDIR@HV1440.uid \ -@MAKEUIDDIR@HV1443.uid \ -@MAKEUIDDIR@HV4032.uid \ -@MAKEUIDDIR@HV4032A1.uid \ -@MAKEUIDDIR@IDL.uid \ -@MAKEUIDDIR@INCAA16.uid \ -@MAKEUIDDIR@INCAA4.uid \ -@MAKEUIDDIR@INCAA6.uid \ -@MAKEUIDDIR@INCAA_TR10.uid \ -@MAKEUIDDIR@J1819.uid \ -@MAKEUIDDIR@J221.uid \ -@MAKEUIDDIR@J412.uid \ -@MAKEUIDDIR@JOERGER_ADCP.uid \ -@MAKEUIDDIR@JOERGER_CG.uid \ -@MAKEUIDDIR@JOERGER_DAC16.uid \ -@MAKEUIDDIR@JOERGER_TR16.uid \ -@MAKEUIDDIR@JOERGER_TR612.uid \ -@MAKEUIDDIR@JOERGER_TR812.uid \ -@MAKEUIDDIR@JRG_TR1612.uid \ -@MAKEUIDDIR@L2232.uid \ -@MAKEUIDDIR@L2256.uid \ -@MAKEUIDDIR@L2415.uid \ -@MAKEUIDDIR@L3512.uid \ -@MAKEUIDDIR@L4202.uid \ -@MAKEUIDDIR@L6810.uid \ -@MAKEUIDDIR@L6810A.uid \ -@MAKEUIDDIR@L6810B.uid \ -@MAKEUIDDIR@L6810C.uid \ -@MAKEUIDDIR@L8100.uid \ -@MAKEUIDDIR@L8201.uid \ -@MAKEUIDDIR@L8206.uid \ -@MAKEUIDDIR@L8210.uid \ -@MAKEUIDDIR@L8210_HEADERS.uid \ -@MAKEUIDDIR@L8212.uid \ -@MAKEUIDDIR@L8212_HEADERS.uid \ -@MAKEUIDDIR@L8501.uid \ -@MAKEUIDDIR@L8590.uid \ -@MAKEUIDDIR@L8590_MEM.uid \ -@MAKEUIDDIR@L8590_SCLR.uid \ -@MAKEUIDDIR@L8818.uid \ -@MAKEUIDDIR@L8828.uid \ -@MAKEUIDDIR@MDSDCL.uid \ -@MAKEUIDDIR@MIT_CLOCK.uid \ -@MAKEUIDDIR@MIT_DCLOCK.uid \ -@MAKEUIDDIR@MIT_DECODER.uid \ -@MAKEUIDDIR@MIT_ENCODER.uid \ -@MAKEUIDDIR@MIT_GATE.uid \ -@MAKEUIDDIR@MIT_PULSE.uid \ -@MAKEUIDDIR@MIT__CLOCK.uid \ -@MAKEUIDDIR@MIT__DCLOCK.uid \ -@MAKEUIDDIR@MIT__GATE.uid \ -@MAKEUIDDIR@MPB__DECODER.uid \ -@MAKEUIDDIR@PARAGON_HIST.uid \ -@MAKEUIDDIR@PARAGON_RPT.uid \ -@MAKEUIDDIR@PREAMP.uid \ -@MAKEUIDDIR@RETICON120.uid \ -@MAKEUIDDIR@T4012.uid \ -@MAKEUIDDIR@UMCCD.uid \ -@MAKEUIDDIR@U_OF_M_SPECT.uid - -gen_device_sources = \ -GenDeviceCallData.c \ -GenDeviceCvtFloatCode.c \ -GenDeviceCvtIntCode.c \ -GenDeviceCvtStringCode.c \ -GenDeviceFree.c \ -GenDeviceHeadNid.c \ -GenDeviceSignal.c \ -gen_device_msg.c - - -SOURCES = \ -$(gen_device_sources) \ -dt200.c \ -dt_acq16.c \ -DevRoutines.c \ -a12_gen.c a12.c \ -a14_gen.c a14.c \ -a3204_gen.c a3204.c \ -b2408_gen.c b2408.c \ -b3224_gen.c b3224.c \ -b5910a_gen.c b5910a.c \ -dsp2904_gen.c dsp2904.c \ -ec727_gen.c ec727.c \ -fera_gen.c fera.c \ -h908_gen.c h908.c \ -h911_gen.c h911.c\ -h912_gen.c h912.c \ -hm650_gen.c hm650.c \ -hv1440_gen.c hv1440.c \ -hv1443_gen.c hv1443.c \ -hv4032a1_gen.c hv4032a1.c \ -hv4032_gen.c hv4032.c \ -idl_gen.c idl.c \ -incaa16_gen.c incaa16.c \ -incaa4_gen.c incaa4.c \ -incaa6_gen.c incaa6.c \ -j1819_gen.c j1819.c \ -j221_gen.c j221.c \ -j412_gen.c j412.c \ -joerger_adc_gen.c joerger_adc.c \ -joerger_adcp_gen.c joerger_adcp.c \ -joerger_cg_gen.c joerger_cg.c \ -joerger_dac16_gen.c joerger_dac16.c \ -joerger_tr16_gen.c joerger_tr16.c \ -joerger_tr612_gen.c joerger_tr612.c \ -joerger_tr812_gen.c joerger_tr812.c \ -l2232_gen.c l2232.c \ -l2256_gen.c l2256.c \ -l2415_gen.c l2415.c \ -l3512a_gen.c l3512a.c \ -l3512_gen.c l3512.c \ -l4202_gen.c l4202.c \ -l6810a_gen.c l6810a.c \ -l6810b_gen.c l6810b.c \ -l6810c_gen.c l6810c.c \ -l6810_gen.c l6810.c \ -l8100_gen.c l8100.c \ -l8201_gen.c l8201.c \ -l8206_gen.c l8206.c \ -l8210_gen.c l8210.c \ -l8212_04_gen.c l8212.c \ -l8212_08_gen.c \ -l8212_16_gen.c \ -l8212_32_gen.c \ -l8501_gen.c l8501.c \ -l8590_gen.c l8590.c \ -l8590_mem_gen.c l8590_mem.c \ -l8590_sclr_gen.c \ -l8818_gen.c l8818.c \ -l8828_gen.c l8828.c \ -mdsdcl_gen.c mdsdcl.c \ -mit__clock_gen.c mit__clock.c \ -mit_clock_gen.c mit_clock.c \ -mit__dclock_gen.c mit__dclock.c \ -mit_dclock_gen.c mit_dclock.c \ -mit_decoder_gen.c mit_decoder.c \ -mit_encoder_gen.c mit_encoder.c \ -mit__gate_gen.c mit__gate.c \ -mit_gate_gen.c \ -mit_gclock_gen.c mit_gclock.c\ -mit_pulse_gen.c mit_pulse-gate.c \ -mpb__decoder_gen.c mpb__decoder.c \ -paragon_hist_gen.c paragon_hist.c \ -paragon_rpt_gen.c paragon_rpt.c \ -preamp_gen.c preamp.c \ -reticon120_gen.c reticon120.c \ -t2812_gen.c \ -t2814_gen.c \ -t2824_gen.c \ -t2825_gen.c \ -t2860_gen.c \ -t4012_gen.c t4012.c \ -umccd_gen.c \ -u_of_m_spect_gen.c u_of_m_spect.c - - -IO_SOURCES = \ -io.c\ -curvefit.c - -OBJECTS = $(SOURCES:.c=.o) - -IO_OBJECTS = $(IO_SOURCES:.c=.o) - - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKEBINDIR@ \ - @MAKESHLIBDIR@libMitDevices@SHARETYPE@ \ - @MAKESHLIBDIR@libMitDevicesMsg@SHARETYPE@ \ - @MAKELIBDIR@libMitDevices.a \ - @MITDEVICESIO_TARGETS@ $(UIDS) \ - @MAKEBINDIR@reboot_dtaq_satelite \ - @DC1394_SUPPORT@ @DC1394_SUPPORT2@ \ - @MAKESHLIBDIR@acq_root_filesystem.tgz \ - @MAKESHLIBDIR@acq_root_filesystem.tgz_ffs \ - @MAKEBINDIR@dtaq_update_board.sh - - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) $(IO_SOURCES) mitdevices_msg.c - -clean: - @ $(RM) $(UIDS) - @ $(RM) *.o - @ $(RM) so_locations - @ $(RM) @MAKELIBDIR@libMitDevices.a - @ $(RM) @MAKESHLIBDIR@libMitDevices@SHARETYPE@ - @ $(RM) @MAKESHLIBDIR@libMitDevicesIO@SHARETYPE@ - @ $(RM) @MAKESHLIBDIR@libMIT\$$DEVICES@SHARETYPE@ - @ $(RM) @MAKESHLIBDIR@libMitDevicesMsg@SHARETYPE@ - @ $(RM) @MAKEBINDIR@reboot_dtaq_satelite - @ $(RM) @MAKEBINDIR@dtaq_update_board.sh - @ $(RM) @MAKESHLIBDIR@acq_root_filesystem.tgz - @ $(RM) @MAKESHLIBDIR@acq_root_filesystem.tgz_ffs - @ $(RM) @DC1394_SUPPORT@ @DC1394_SUPPORT2@ - - -install: $(bindir) $(libdir) - $(INSTALL) -m 644 $(UIDS) @uiddir@ - $(INSTALL) -m 755 @MAKESHLIBDIR@libMitDevices@SHARETYPE@ @libdir@ - if [ -x @MAKESHLIBDIR@libMitDevicesIO@SHARETYPE@ ] ; then \ - $(INSTALL) -m 755 @MAKESHLIBDIR@libMitDevicesIO@SHARETYPE@ @libdir@ ;\ - fi; - $(INSTALL) -m 755 @MAKESHLIBDIR@libMitDevicesMsg@SHARETYPE@ @libdir@ - ln -sf libMitDevices@SHARETYPE@ @libdir@/libMIT\$$DEVICES@SHARETYPE@ - if (test @SHARETYPE@ != .a) then \ - $(INSTALL) -m 644 @MAKELIBDIR@libMitDevices.a @libdir@; \ - fi; - $(INSTALL) -m 755 @MAKEBINDIR@reboot_dtaq_satelite @bindir@ - $(INSTALL) -m 755 @MAKEBINDIR@dtaq_update_board.sh @bindir@ - $(INSTALL) -m 755 @MAKESHLIBDIR@acq_root_filesystem.tgz @libdir@ - $(INSTALL) -m 755 @MAKESHLIBDIR@acq_root_filesystem.tgz_ffs @libdir@ -ifneq "@DC1394_SUPPORT@" "" - $(INSTALL) -m 755 @DC1394_SUPPORT@ @libdir@ -endif -ifneq "@DC1394_SUPPORT2@" "" - $(INSTALL) -m 755 @DC1394_SUPPORT2@ @libdir@ -endif - -l8590_mem.c: l8590_sclr_gen.c -%_gen.c: %.gen - @MAKEBINDIR@/gen_device $< sx _gen - $(SED) -i.tmp $$'1s/^/#include "mitdevices_msg.h"\\\n/' $@; $(RM) $@.tmp - -@MAKEBINDIR@daq_server : daq_server - cp ${srcdir}/daq_server @MAKEBINDIR@daq_server - -@MAKEBINDIR@reboot_dtaq_satelite : reboot_dtaq_satelite - cp ${srcdir}/reboot_dtaq_satelite @MAKEBINDIR@reboot_dtaq_satelite - -@MAKESHLIBDIR@libMitDevices@SHARETYPE@ : $(OBJECTS) - $(LINK.c) -o $@ @LINKSHARED@ $(OBJECTS) -L@MAKESHLIBDIR@ -lCamShr -lXmdsShr -lMdsdcl -lTdiShr -lTreeShr -lMdsShr $(LIBS) $(X_LIBS) $(MOTIF_LIBS) $(X_PRE_LIBS) -lXt -lX11 $(X_EXTRA_LIBS) $(LIBS) $(MATH_LIBS) $(LD_FLAGS) - ln -sf libMitDevices@SHARETYPE@ @MAKESHLIBDIR@libMIT\$$DEVICES@SHARETYPE@ - -@MAKESHLIBDIR@libMitDevicesMsg@SHARETYPE@ : mitdevices_msg.o - $(LINK.c) -o $@ @LINKSHARED@ mitdevices_msg.o $(LIBS) $(LD_FLAGS) - -@MAKELIBDIR@libMitDevices.a: $(OBJECTS) - $(AR) -cr $@ $^ - $(RANLIB) $@ - -@MAKESHLIBDIR@libMitDevicesIO@SHARETYPE@ : $(IO_OBJECTS) - $(LINK.c) -o $@ @LINKSHARED@ $(IO_OBJECTS) $(LIBS) $(MATH_LIBS) $(LD_FLAGS) - -@MAKELIBDIR@libMitDevicesIO.a : $(IO_OBJECTS) - $(AR) -cr $@ $(IO_OBJECTS) - $(RANLIB) $@ - -@MAKEUIDDIR@%.uid: %.uil - $(UIL) -o $@ $< - -# This build must be done on a glibc 2.2.2 system (RedHat 7.x) or idl will have undefined references -@MAKESHLIBDIR@libIdl@SHARETYPE@ : callidl.c - cc -o $@ $< -shared \ - @IDL_INC@ \ - @IDL_LIB@ \ - -L/usr/X11R6/lib -lXm -lXp -lXpm -lXext -lXt -lSM -lICE -lX11 \ - -ldl -ltermcap -lrt -lm -lpthread -lXinerama -lgcc_s -# -# Support for libdc1394 connected cameras -# -@DC1394_SUPPORT@ : dc1394_support.o - $(LINK.c) -o $@ @LINKSHARED@ dc1394_support.o $(LIBDC1394_LIBS) $(LIBS) $(LD_FLAGS) - -dc1394_support.o : dc1394_support.c - $(CC) -c -o $@ $(CPPFLAGS) $(CFLAGS) $< $(LIBDC1394_INCS) - -@DC1394_SUPPORT2@ : dc1394_support2.o - $(LINK.c) -o $@ @LINKSHARED@ dc1394_support2.o $(LIBDC1394_LIBS) $(LIBS) $(LD_FLAGS) - - -dc1394_support2.o : dc1394_support2.c - $(CC) -c -o $@ $(CPPFLAGS) $(CFLAGS) $< $(LIBDC1394_INCS) - - -@MAKESHLIBDIR@acq_root_filesystem.tgz : $(DTACQ_FILESYSTEM) - ( tar -C ${srcdir}/acq_root_filesystem --exclude=ffs -czf $@ . ; \ - tar -C ${srcdir}/acq_root_filesystem -czf $@_ffs ffs/user ) - -@MAKESHLIBDIR@acq_root_filesystem.tgz_ffs : $(DTACQ_FILESYSTEM) -# echo $(DC) > ${srcdir}/acq_root_filesystem/ffs/user/MitFilesDate - ( tar -C ${srcdir}/acq_root_filesystem -czf $@ ffs/user ) - -@MAKEBINDIR@dtaq_update_board.sh : dtaq_update_board.sh - cp $< $@ - -.NOTPARALLEL: diff --git a/ntwdblib.dll b/ntwdblib.dll deleted file mode 100644 index 031d1f6318..0000000000 Binary files a/ntwdblib.dll and /dev/null differ diff --git a/ntwdblib.lib b/ntwdblib.lib deleted file mode 100644 index d8ba312283..0000000000 Binary files a/ntwdblib.lib and /dev/null differ diff --git a/php/config.m4 b/php/config.m4 deleted file mode 100644 index 1b73c93509..0000000000 --- a/php/config.m4 +++ /dev/null @@ -1,61 +0,0 @@ -dnl $Id$ -dnl config.m4 for extension mdsplus - -dnl Comments in this file start with the string 'dnl'. -dnl Remove where necessary. This file will not work -dnl without editing. - -dnl If your extension references something external, use with: - -PHP_ARG_WITH(mdsplus, for mdsplus support, -[ --with-mdsplus Include mdsplus support]) - -dnl Otherwise use enable: - -dnl PHP_ARG_ENABLE(mdsplus, whether to enable mdsplus support, -dnl Make sure that the comment is aligned: -dnl [ --enable-mdsplus Enable mdsplus support]) - -if test "$PHP_MDSPLUS" != "no"; then - - dnl # --with-mdsplus -> check with-path - SEARCH_PATH="/usr/local/mdsplus" - SEARCH_FOR="/include/mdsdescrip.h" - if test -r $PHP_MDSPLUS/; then # path given as parameter - MDSPLUS_DIR=$PHP_MDSPLUS - else # search default path list - AC_MSG_CHECKING([for mdsplus files in default path]) - for i in $SEARCH_PATH ; do - if test -r $i/$SEARCH_FOR; then - MDSPLUS_DIR=$i - AC_MSG_RESULT(found in $i) - fi - done - fi - - if test -z "$MDSPLUS_DIR"; then - AC_MSG_RESULT([not found]) - AC_MSG_ERROR([Please reinstall the mdsplus distribution]) - fi - - dnl # --with-mdsplus -> add include path - PHP_ADD_INCLUDE($MDSPLUS_DIR/include) - - dnl # --with-mdsplus -> check for lib and symbol presence - LIBNAME=MdsIpShr # you may want to change this - LIBSYMBOL=ConnectToMds # you most likely want to change this - - PHP_CHECK_LIBRARY($LIBNAME,$LIBSYMBOL, - [ - PHP_ADD_LIBRARY_WITH_PATH($LIBNAME, $MDSPLUS_DIR/lib, MDSPLUS_SHARED_LIBADD) - AC_DEFINE(HAVE_MDSPLUSLIB,1,[ ]) - ],[ - AC_MSG_ERROR([wrong mdsplus lib version or lib not found]) - ],[ - -L$MDSPLUS_DIR/lib -lm -ldl - ]) - dnl - PHP_SUBST(MDSPLUS_SHARED_LIBADD) - - PHP_NEW_EXTENSION(mdsplus, mdsplus.c, $ext_shared) -fi diff --git a/python/MDSplus/docs/Makefile.am b/python/MDSplus/docs/Makefile.am deleted file mode 100644 index 590d3bbb87..0000000000 --- a/python/MDSplus/docs/Makefile.am +++ /dev/null @@ -1,34 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../../docs/config/doxygen.am - -# //////////////////////////////////////////////////////////////////////////// # -# DOXYGEN CONFIG # - -DX_CONFIG = ${top_srcdir}/docs/config/doxygen_cpp.cfg -DX_DOCDIR = python/MDSplus/docs -DX_PACKAGE_NAME = mdsobjects_py -DX_TITLE = MDSplus Python interface -DX_BRIEF = "MDSplus object oriented interface" - -DX_PAGES = .. \ - index.md - -DX_EXCLUDE_PAGES = \ - ../mdsExceptions.py \ - ../setup.py \ - ../__init__.py - -DX_TAGFILES = docs.tag - -MOSTLYCLEANFILES = $(DX_CLEANFILES) - -# //////////////////////////////////////////////////////////////////////////// # -# TARGETS # - -all: html - -html: doxygen-run -pdf: doxygen-pdf - -install-data-local: doxygen-install diff --git a/python/MDSplus/tests/Makefile.am b/python/MDSplus/tests/Makefile.am deleted file mode 100644 index 6f3663264a..0000000000 --- a/python/MDSplus/tests/Makefile.am +++ /dev/null @@ -1,84 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../../testing/testing.am - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .py - -TEST_FLAGS = @MAKEFLAG_J@ - -TESTS = \ -data_data_test.py \ -data_scalars_test.py \ -data_arrays_test.py \ -data_vms_test.py \ -data_tdi_test.py \ -data_decompile_test.py \ -data_casts_test.py \ -data_tdipy_test.py \ -devices_mit_test.py \ -devices_rfx_test.py \ -devices_w7x_test.py \ -exception_default_test.py \ -exception_custom_test.py \ -exception_tcl_test.py \ -exception_segfault_test.py \ -segment_dim_order_test.py \ -segment_block_rows_test.py \ -segment_write_test.py \ -segment_opaque_test.py \ -segment_update_test.py \ -segment_time_context_test.py \ -segment_scaled_test.py \ -segment_dimless_test.py \ -segment_compress_test.py \ -segment_compress_ts_test.py \ -task_do_test.py \ -tree_attr_test.py \ -tree_open_test.py \ -tree_node_test.py \ -tree_find_test.py \ -tree_default_test.py \ -tree_linkage_test.py \ -tree_nci_test.py \ -tree_data_test.py \ -tree_xysignal_test.py \ -tree_compression_test.py \ -tree_records_test.py \ -connection_io_test.py \ -connection_thick_test.py \ -connection_thread_test.py \ -connection_tunnel_test.py \ -connection_tcp_test.py \ -connection_write_test.py \ -dcl_interface_test.py -if !MINGW -TESTS += dcl_dispatcher_test.py -endif - -# connection_write_test.py causes valgrind to hang? -VALGRIND_TESTS = $(filter-out connection_write_test.py,$(TESTS)) - -VALGRIND_SUPPRESSIONS_FILES = - -# Skipping child programs that are launched inside python classes -# -VALGRIND_FLAGS = --trace-children-skip=*/ld,*/collect2,*/ldconfig,*/sh - -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = *.log *.trs - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -clean-local: clean-local-tests - -check_PROGRAMS = -check_SCRIPTS = $(TESTS) diff --git a/remcam/Makefile.in b/remcam/Makefile.in deleted file mode 100644 index 60e6669257..0000000000 --- a/remcam/Makefile.in +++ /dev/null @@ -1,26 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -LIBS=@LIBS@ - -SOURCES = CamIosb.c CamMulti.c CamSingle.c -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@@REMCAMLIB@@SHARETYPE@ - -@MAKESHLIBDIR@@LIBPRE@@REMCAMLIB@@SHARETYPE@ : $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKESHLIBDIR@ -lMdsIpShr $(LIBS) - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) @MAKESHLIBDIR@@LIBPRE@@REMCAMLIB@@SHARETYPE@ - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@@REMCAMLIB@@SHARETYPE@ @libdir@ diff --git a/roam/Makefile.in b/roam/Makefile.in deleted file mode 100644 index def022a2ac..0000000000 --- a/roam/Makefile.in +++ /dev/null @@ -1,73 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS+=$$(pkg-config --cflags globus-xio globus-gridmap-callout-error) -LDFLAGS = @LDFLAGS@ $$(pkg-config --libs globus-xio globus-gridmap-callout-error globus-gssapi-gsi globus-gss-assist globus-gssapi-error globus-common) -L@MAKESHLIBDIR@ -lMdsShr -lTdiShr -lcurl - -ifeq "@SHARETYPEMOD@" "@SHARETYPE@" - modules = -else - modules = @MAKESHLIBDIR@libRoam_@GLOBUS_FLAVOR@@SHARETYPEMOD@ -endif - -SOURCES = \ - roam_check_access.c \ - roam_gridmap_callout.c - -OBJECTS = $(SOURCES:.c=.o) - -all : \ - @MAKESHLIBDIR@libRoam_@GLOBUS_FLAVOR@@SHARETYPE@ \ - @MAKESHLIBDIR@libRoam@SHARETYPE@ \ - $(modules) \ - @MAKELIBDIR@ \ - @MAKELIBDIR@libRoam_@GLOBUS_FLAVOR@.a \ - @MAKEBINDIR@roam_check_access - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) @MAKESHLIBDIR@libRoam_@GLOBUS_FLAVOR@@SHARETYPE@ - @ $(RM) @MAKESHLIBDIR@libRoam@SHARETYPE@ - @ $(RM) makefile-header - @ $(RM) @MAKELIBDIR@libRoam_@GLOBUS_FLAVOR@.a - @ $(RM) @MAKEBINDIR@roam_check_access - - -install: $(bindir) $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@libRoam_@GLOBUS_FLAVOR@@SHARETYPE@ $(libdir) - ln -sf libRoam_@GLOBUS_FLAVOR@@SHARETYPE@ $(libdir)/libRoam@SHARETYPE@ - chmod 755 $(libdir)/libRoam@SHARETYPE@ - $(INSTALL) -m 755 @MAKEBINDIR@roam_check_access $(bindir) - ifdef modules - $(INSTALL) -m 755 @MAKESHLIBDIR@libRoam_@GLOBUS_FLAVOR@@SHARETYPEMOD@ $(libdir) - endif - if test "@SHARETYPE@" != ".a" ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@libRoam_@GLOBUS_FLAVOR@.a $(libdir); \ - fi; - - -@MAKESHLIBDIR@libRoam_@GLOBUS_FLAVOR@@SHARETYPE@ : $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ $(LIBS) - -@MAKESHLIBDIR@libRoam@SHARETYPE@ : - ln -sf libRoam_@GLOBUS_FLAVOR@@SHARETYPE@ @MAKESHLIBDIR@libRoam@SHARETYPE@ - -@MAKELIBDIR@libRoam_@GLOBUS_FLAVOR@.a : $(OBJECTS) - $(AR) -cr $@ $^ - @RANLIB@ $@ - -@MAKEBINDIR@roam_check_access : roam_check_access.sh - cp $< $@ - -ifdef modules -@MAKESHLIBDIR@libRoam_@GLOBUS_FLAVOR@@SHARETYPEMOD@ : $(OBJECTS) - $(LINK.c) $(TARGET_ARCH) @LINKMODULE@ $^ $(LIBS) -endif - diff --git a/rpm/Makefile.am b/rpm/Makefile.am deleted file mode 100644 index 92b6b5c994..0000000000 --- a/rpm/Makefile.am +++ /dev/null @@ -1,13 +0,0 @@ -etcdir = $(exec_prefix)/etc -etc_DATA = envsyms -dist_etc_DATA = mdsplus.conf.template - -rpmdir = $(exec_prefix)/rpm -rpm_SCRIPTS = post_uninstall_script -dist_rpm_SCRIPTS = post_install_script python_module_install.sh python_module_remove.sh - -if GLOBUSLICENSE -dist_rpm_DATA = fusiongrid-mdsip.xinetd fusiongrid-mdsips.xinetd globus-gatekeeper.xinetd globus-gridftp.xinetd -else -dist_rpm_DATA = mdsipd.xinetd mdsipsd.xinetd mdsip.socket mdsip@.service -endif diff --git a/scripts/Makefile.am b/scripts/Makefile.am deleted file mode 100644 index ad1ef7e606..0000000000 --- a/scripts/Makefile.am +++ /dev/null @@ -1,13 +0,0 @@ -if !MINGW -dist_bin_SCRIPTS = job_finish -dist_bin_SCRIPTS += job_functions -dist_bin_SCRIPTS += job_output -dist_bin_SCRIPTS += job_que -dist_bin_SCRIPTS += job_start -dist_bin_SCRIPTS += job_wait -dist_bin_SCRIPTS += MonitorCpciData.py -dist_bin_SCRIPTS += remote_submit -dist_bin_SCRIPTS += SetMdsplusFileProtection -dist_bin_SCRIPTS += synchronize_unix -dist_bin_SCRIPTS += unix_submit -endif diff --git a/servershr/Makefile.in b/servershr/Makefile.in deleted file mode 100644 index f161e7de48..0000000000 --- a/servershr/Makefile.in +++ /dev/null @@ -1,38 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -@MINGW_TRUE@ IMPLIB=@MAKELIBDIR@MdsServerShr.dll.a - -SOURCES = $(wildcard @srcdir@/Server*.c) -OBJECTS = $(SOURCES:@srcdir@/%.c=%.o) - -all: @MAKELIBDIR@ @MAKESHLIBDIR@@LIBPRE@MdsServerShr@SHARETYPE@ @MAKELIBDIR@@LIBPRE@MdsServerShr.a - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKESHLIBDIR@@LIBPRE@MdsServerShr@SHARETYPE@ $(IMPLIB) - @ $(RM) @MAKELIBDIR@@LIBPRE@MdsServerShr.a - -$(OBJECTS): servershrp.h -ServerSendMessage.o: Job.h Client.h -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@MdsServerShr@SHARETYPE@ $(IMPLIB) $(libdir) - if test "@SHARETYPE@" != ".a" ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@MdsServerShr.a $(libdir); \ - fi; - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -@MAKESHLIBDIR@@LIBPRE@MdsServerShr@SHARETYPE@: $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKESHLIBDIR@ -lMdsdcl -lTdiShr -lTreeShr -lMdsShr -lMdsIpShr $(LIBS) $(LIBSOCKET) $(THREAD) $(MAKE_IMPLIB) - -@MAKELIBDIR@@LIBPRE@MdsServerShr.a: $(OBJECTS) - $(AR) -cr $@ $^ - @RANLIB@ $@ diff --git a/setevent/Makefile.am b/setevent/Makefile.am deleted file mode 100644 index c29f4c282f..0000000000 --- a/setevent/Makefile.am +++ /dev/null @@ -1,19 +0,0 @@ -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) - -#FIXME: Use rpath-link until build system is flattened -libdir=@MAKESHLIBDIR@ -if RPATHLINK -RPATHFLAGS = $(RPATHLINK)=$(libdir) -else -RPATHFLAGS = -endif - -AM_LDFLAGS = $(RPATHFLAGS) -LDADD = -L$(libdir) -lMdsShr - -bin_PROGRAMS = setevent -setevent_SOURCES = setevent.c - -#FIXME: Clean up LIBS in top level configure -#LIBS= - diff --git a/tcl/Makefile.in b/tcl/Makefile.in deleted file mode 100644 index 1fa310402d..0000000000 --- a/tcl/Makefile.in +++ /dev/null @@ -1,45 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS += $(THREAD) -LDFLAGS += $(THREAD) - -@MINGW_TRUE@ MDSTCL=mdstcl.bat -@MINGW_FALSE@ MDSTCL=mdstcl - -SOURCES = $(wildcard @srcdir@/tcl_*.c) -@MINGW_TRUE@SOURCES += icon.o -OBJECTS = $(SOURCES:@srcdir@/%.c=%.o) -EXPORTS = tcl_commands.export - -all: @MAKEBINDIR@$(MDSTCL) @MAKESHLIBDIR@@LIBPRE@tcl_commands@SHARETYPE@ - -depend: - - @makedepend -- $(CFLAGS) -- $(SOURCES) 2>/dev/null - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) @MAKEBINDIR@$(MDSTCL) - @ $(RM) @MAKESHLIBDIR@@LIBPRE@tcl_commands@SHARETYPE@ - -install: $(libdir) $(bindir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@tcl_commands@SHARETYPE@ $(libdir) - $(INSTALL) -m 755 @MAKEBINDIR@$(MDSTCL) $(bindir) - -@MAKEBINDIR@$(MDSTCL): $(MDSTCL) - $(INSTALL) -m 755 $< $@ - -cdudir = $(top_builddir)/cdu -CDU = $(cdudir)/cdu - -tcl_commands.c-disabled: tcl_commands.ocld - if [ "@LIBPATH@" == "PATH" ]; then env PATH="@MAKESHLIBDIR@:$$(dirname $$(which gcc))" $(CDU) < tcl_commands.ocld;\ - else env @LIBPATH@=@MAKESHLIBDIR@ $(CDU) < tcl_commands.ocld; fi - $(MAKE) depend - -@MAKESHLIBDIR@@LIBPRE@tcl_commands@SHARETYPE@: $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKESHLIBDIR@ -lMdsdcl -lMdsServerShr -lMdsShr -lTreeShr -lTdiShr -lMdsIpShr $(LIBS) @LIBREADLINE@ diff --git a/tdic/Makefile.in b/tdic/Makefile.in deleted file mode 100644 index cb7cc1e101..0000000000 --- a/tdic/Makefile.in +++ /dev/null @@ -1,43 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -LIBS=@LIBS@ -L@MAKESHLIBDIR@ -lMdsIpShr -lTdiShr -lMdsShr -lTreeShr -TDIC_LIBS= $(LIBS) @LIBREADLINE@ - -SOURCES = \ - TdiShrExt.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKEBINDIR@ @MAKESHLIBDIR@@LIBPRE@TdiShrExt@SHARETYPE@ @MAKELIBDIR@@LIBPRE@TdiShrExt.a @MAKEBINDIR@tdic$(EXE) - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) @MAKELIBDIR@@LIBPRE@TdiShrExt.a - @ $(RM) @MAKESHLIBDIR@@LIBPRE@TdiShrExt@SHARETYPE@ - @ $(RM) @MAKEBINDIR@tdic - -install: $(libdir) $(bindir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@TdiShrExt@SHARETYPE@ $(libdir) - if (test @SHARETYPE@ != .a) then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@TdiShrExt.a $(libdir); \ - fi; - $(INSTALL) -m 755 @MAKEBINDIR@tdic$(EXE) $(bindir) - -@MAKESHLIBDIR@@LIBPRE@TdiShrExt@SHARETYPE@ : $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(OBJECTS) $(LIBS) - -@MAKELIBDIR@@LIBPRE@TdiShrExt.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -@MINGW_TRUE@@MAKEBINDIR@tdic$(EXE): tdic.c icon.o -@MINGW_FALSE@@MAKEBINDIR@tdic$(EXE): tdic.c - $(LINK.c) $(OUTPUT_OPTION) $^ $(TDIC_LIBS) diff --git a/tdishr/Makefile.in b/tdishr/Makefile.in deleted file mode 100644 index 3e5330cfb2..0000000000 --- a/tdishr/Makefile.in +++ /dev/null @@ -1,134 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX=Tdi - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -@MINGW_TRUE@ IMPLIB=@MAKELIBDIR@TdiShr.dll.a - -LIBS=-L@MAKESHLIBDIR@ @LIBS@ -lTreeShr -lMdsShr @LIBM@ $(THREAD) @LIBDL@ $(LIBSOCKET) -SYBASE_INC=@SYBASE_INC@ - -SOURCES = \ -CvtConvertFloat.c \ -DummyRoutines.c \ -IsRoprand.c \ -TdiAbs.c \ -TdiAdd.c \ -TdiAnd.c \ -TdiApd.c \ -TdiArray.c \ -TdiBinary.c \ -TdiBound.c \ -TdiBuild.c \ -TdiCall.c \ -TdiChar.c \ -TdiCompileDependency.c \ -TdiCompile.c \ -TdiConstant.c \ -TdiConvert.c \ -TdiCull.c \ -TdiCvtArgs.c \ -TdiCvtDxDx.c \ -TdiDecompileDependency.c \ -TdiDecompileR.c \ -TdiDecompile.c \ -TdiDecompress.c \ -TdiDefCat.c \ -TdiDefFunction.c \ -TdiDim.c \ -TdiDivide.c \ -TdiDoTask.c \ -TdiDtypeRange.c \ -TdiEq.c \ -TdiEvaluate.c \ -TdiExponent.c \ -TdiExpt.c \ -TdiExtFunction.c \ -TdiExtPython.c \ -TdiFaultHandler.c \ -TdiGetArgs.c \ -TdiGetData.c \ -TdiGetDbi.c \ -TdiGetNci.c \ -TdiGetShape.c \ -TdiGetSlope.c \ -TdiHash.c \ -TdiIand.c \ -TdiIntrinsic.c \ -TdiIo.c \ -TdiItoX.c \ -TdiLex.c \ -TdiMakeFunctionTable.c \ -TdiMasterData.c \ -TdiMath1.c \ -TdiMath2.c \ -TdiMatrix.c \ -TdiMaxVal.c \ -TdiMinMax.c \ -TdiOpcDef.c \ -TdiPack.c \ -TdiPower.c \ -TdiReshape.c \ -TdiSame.c \ -TdiScalar.c \ -TdiSetRange.c \ -TdiShowVm.c \ -TdiSort.c \ -TdiSql.c \ -TdiSquare.c \ -TdiStatement.c \ -TdiSubscript.c \ -TdiThreadStatic.c \ -TdiTrans.c \ -TdiTrim.c \ -TdiUnary.c \ -TdiUndef.c \ -TdiVar.c \ -TdiVector.c \ -TdiXxxOf.c \ -TdiXxx.c \ -TdiYaccSubs.c \ -TdiYacc.c - -all: @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@TdiShr@SHARETYPE@ $(IMPLIB) @MAKELIBDIR@@LIBPRE@TdiShr.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - @mv Makefile Makefile.tmp - @grep -v '\.y' Makefile.tmp > Makefile - @rm Makefile.tmp - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKESHLIBDIR@@LIBPRE@TdiShr@SHARETYPE@ $(IMPLIB) - @ $(RM) @MAKELIBDIR@@LIBPRE@TdiShr.a - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@TdiShr@SHARETYPE@ $(IMPLIB) @libdir@ - if test "@SHARETYPE@" != ".a" ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@TdiShr.a @libdir@; \ - fi; - -OBJECTS = $(SOURCES:.c=.o) - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -@MAKESHLIBDIR@@LIBPRE@TdiShr@SHARETYPE@ $(IMPLIB): $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(OBJECTS) $(LIBS) $(MAKE_IMPLIB) - -@MAKELIBDIR@@LIBPRE@TdiShr.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -TdiSql.o : TdiSql.c - $(COMPILE.c) $(OUTPUT_OPTION) $< $(SYBASE_INC) - -TdiYacc.o : - $(COMPILE.c) $(OUTPUT_OPTION) $(srcdir)/TdiYacc.c -Wno-array-bounds - -TdiLex.o : - $(COMPILE.c) $(OUTPUT_OPTION) $(srcdir)/TdiLex.c -Wno-sign-compare -Wno-unused-parameter diff --git a/tdishr/testing/Makefile.am b/tdishr/testing/Makefile.am deleted file mode 100644 index ef0ad0cf5b..0000000000 --- a/tdishr/testing/Makefile.am +++ /dev/null @@ -1,41 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_CXXFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -Wno-deprecated @CXXFLAGS@ $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ - -LDADD = @LIBS@ $(TEST_LIBS) -lMdsLib -lTdiShr -lTreeShr -lMdsShr - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .py .pl -AM_DEFAULT_SOURCE_EXT = .c - -TESTS = \ - build_test - - - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = *.out - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -all-local: $(TESTS) -clean-local: clean-local-tests - -check_PROGRAMS = $(TESTS) -check_SCRIPTS = - - diff --git a/tditest/Makefile.in b/tditest/Makefile.in deleted file mode 100644 index fcbaa1a4f8..0000000000 --- a/tditest/Makefile.in +++ /dev/null @@ -1,24 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -MKDIR_P=@MKDIR_P@ -@AX_RECONFIGURE_TARGET@ - -SOURCES = tditest.c -@MINGW_TRUE@ SOURCES += icon.o - -all : @MAKEBINDIR@ @MAKEBINDIR@tditest$(EXE) - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(bindir) - $(INSTALL) -m 755 @MAKEBINDIR@tditest$(EXE) $(bindir) - -clean : - @ $(RM) @MAKEBINDIR@tditest$(EXE) - -@MAKEBINDIR@tditest$(EXE) : $(SOURCES) - $(LINK.c) $(OUTPUT_OPTION) $^ -L@MAKESHLIBDIR@ -lTdiShr -lTreeShr -lMdsShr $(LIBS) $(LIBSOCKET) @LIBREADLINE@ diff --git a/tditest/testing/Makefile.am b/tditest/testing/Makefile.am deleted file mode 100644 index dfeeae685c..0000000000 --- a/tditest/testing/Makefile.am +++ /dev/null @@ -1,58 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .tdi -TDI_LOG_COMPILER= $(abs_top_srcdir)/tditest/testing/do_tditests.sh - -TEST_FLAGS = @MAKEFLAG_J@ - -TESTS = \ - test-tcl.tdi \ - test-tdishr.tdi \ - test-treeshr.tdi \ - test-mdsip.tdi \ - test-mdsip0.tdi \ - test-mdsmisc.tdi \ - test-dev-py.tdi \ - test-tab.tdi - -# DISABLE PYTHON LEAK DETECTION: This suppression file shall be removed when -# python will finally introduce the patch to detect if valgrind is running .. -# take a look at the file for details. You can also disable this if you are -# using a Python compiled with --without-pymalloc (only for valgrind as it is 5 -# times slower to run) -# -#VALGRIND_SUPPRESSIONS_FILES_PY = \ -# $(top_srcdir)/conf/valgrind-mdsplus.supp \ -# ${top_srcdir}/conf/valgrind-python.supp \ -# ${top_srcdir}/conf/valgrind-python-disableleak.supp - - - - -# Skipping child programs that are launched inside python classes -# -VALGRIND_FLAGS = \ - --trace-children-skip=*/diff - -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = \ - ./*.log ./*.tap \ - tditst.tmp shotid.sys \ - *_*.characteristics* *_*.datafile* *_*.tree* -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -#clean-local: clean-local-tests - -check_PROGRAMS = -check_SCRIPTS = $(TESTS) diff --git a/testing/Makefile.am b/testing/Makefile.am deleted file mode 100644 index 62c3688f80..0000000000 --- a/testing/Makefile.am +++ /dev/null @@ -1,110 +0,0 @@ -SUBDIRS = backends/check . - -include @top_builddir@/Makefile.inc - -AM_CFLAGS = -I${top_srcdir}/include $(TARGET_ARCH) $(WARNFLAGS) -AM_CXXFLAGS = -I${top_srcdir}/include @CXXFLAGS@ $(TARGET_ARCH) $(WARNFLAGS) - -# -# Static Base library -# -noinst_LIBRARIES = libMdsTest.a -libMdsTest_a_CFLAGS = -D_TESTING -libMdsTest_a_SOURCES = base_backend.c - -# -# only check backend for now -# -noinst_LIBRARIES += libMdsTestBackend.a -libMdsTestBackend_a_CFLAGS = -D_TESTING -I${srcdir}/backends/check $(AM_CFLAGS) -libMdsTestBackend_a_SOURCES = check_backend.c - -# -# Shared library -# -# @MINGW_TRUE@ DEF=${srcdir}/MdsTestShr.def -@MINGW_TRUE@ MAKE_IMPLIB_MdsTestShr=-Wl,--out-implib,@MAKELIBDIR@MdsTestShr.dll.a -MdsTestShr = @MAKESHLIBDIR@@LIBPRE@MdsTestShr@SHARETYPE@ -$(MdsTestShr): backends/check/libCheck.a libMdsTestBackend.a - $(CXX) $(TARGET_ARCH) $(CXXFLAGS) $(OUTPUT_OPTION) @LINKSHARED@ -Wl,-whole-archive $^ -Wl,-no-whole-archive $(LDFLAGS) $(LIBS) $(MAKE_IMPLIB_MdsTestShr) - -all-local: $(MdsTestShr) - -clean-local: - -$(RM) $(MdsTestShr) - - - - - - -# //////////////////////////////////////////////////////////////////////////// # -# // COLLECT TESTS IN SUBDIRECTORIES /////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -if ENABLE_JAVA -JAVA_TEST_DIRS = \ - java/mdsplus-api/tests \ - java/mdsobjects/tests -else -JAVA_TEST_DIRS = -endif - -PYTHON_TEST_DIRS = \ - python/MDSplus/tests - -C_TEST_DIRS =\ - mdsshr/testing\ - treeshr/testing\ - mdslib/testing\ - mdstcpip/testing\ - tditest/testing\ - mdsobjects/cpp/testing\ - actions/testing\ - wfevent/testing -# testing/selftest - -TEST_DIRS ?=\ - $(C_TEST_DIRS)\ - $(PYTHON_TEST_DIRS)\ - $(JAVA_TEST_DIRS) - -TEST_OUTDIR ?= ${top_builddir}/testing - -print: - @echo $(tests_DIRS) - @echo "$(MAKE) $(AM_MAKEFLAGS)" - -.PHONY: $(tests_DIRS) $(clean_DIRS) $(tests_valgrind_DIRS) $(tests_valgrind_suppressions_DIRS) -tests_DIRS = $(addprefix tests__$(top_builddir)/, $(TEST_DIRS)) -rebuild_tests_DIRS = $(addprefix rebuild_tests__$(top_builddir)/, $(TEST_DIRS)) -clean_DIRS = $(addprefix clean__$(top_builddir)/, $(TEST_DIRS)) -tests_valgrind_DIRS = $(addprefix tests_valgrind__$(top_builddir)/, $(TEST_DIRS)) -tests_valgrind_suppressions_DIRS = $(addprefix tests_valgrind_suppressions__$(top_builddir)/, $(TEST_DIRS)) -$(tests_DIRS): - @ $(MAKE) $(AM_MAKEFLAGS) -C $(@:tests__%=%) tests - -$(rebuild_tests_DIRS): - @ $(MAKE) $(AM_MAKEFLAGS) -C $(@:rebuild_tests__%=%) rebuild-tests - -$(clean_DIRS): - @-$(MAKE) $(AM_MAKEFLAGS) -C $(@:clean__%=%) clean - -$(tests_valgrind_DIRS): - @ $(MAKE) $(AM_MAKEFLAGS) -C $(@:tests_valgrind__%=%) tests-valgrind - -$(tests_valgrind_suppressions_DIRS): - @-$(MAKE) $(AM_MAKEFLAGS) -C $(@:tests_valgrind_suppressions__%=%) tests-valgrind-suppressions - - - -.PHONY: tests tests-valgrind tests-valgrind-suppressions tests-clean -tests: $(tests_DIRS) - -rebuild-tests: $(rebuild_tests_DIRS) - -tests-valgrind: $(tests_valgrind_DIRS) - -tests-valgrind-suppressions: $(tests_valgrind_suppressions_DIRS) - -tests-clean: $(clean_DIRS) diff --git a/testing/backends/check/Makefile.am b/testing/backends/check/Makefile.am deleted file mode 100644 index d8d5b78c52..0000000000 --- a/testing/backends/check/Makefile.am +++ /dev/null @@ -1,37 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBS = -L@MAKESHLIBDIR@ @LIBS@ @LIBM@ @LIBDL@ $(LIBSOCKET) - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -AM_CXXFLAGS = $(TARGET_ARCH) -AM_LDFLAGS = $(LIBS) - - -AM_DEFAULT_SOURCE_EXT = .c -_SOURCES = \ - check_error.c \ - check_list.c \ - check_log.c \ - check_msg.c \ - check_pack.c \ - check_print.c \ - check_run.c \ - check_str.c \ - check.c - -#\ -# test_backend.c - - -# -# Static Test library -# -noinst_LIBRARIES = libCheck.a -libCheck_a_SOURCES = $(_SOURCES) -libCheck_a_CFLAGS = $(AM_CFLAGS) $(CFLAGS) - - - -bin_PROGRAMS = build_test -build_test_CFLAGS = $(AM_CFLAGS) $(CFLAGS) -build_test_LDADD = libCheck.a -lm -lpthread diff --git a/testing/collate_tap.pl b/testing/collate_tap.pl deleted file mode 100644 index b9b0a54e9b..0000000000 --- a/testing/collate_tap.pl +++ /dev/null @@ -1,33 +0,0 @@ -use strict; -use POSIX qw/strftime/; -use TAP::Parser qw/all/; -use TAP::Parser::Aggregator qw/all/; - - -my @files = @ARGV; -my $aggregate = TAP::Parser::Aggregator->new; -my $test_count = 0; - -foreach my $file (@files) { - if( -f $file ) { - my $parser = TAP::Parser->new( { - source => $file, - sources => { File => { extensions => [ '.tap', '.log', '.t' ] } } - }); - - while ( my $result = $parser->next ) { - if( $result->is_test ) { - $test_count += 1; - if( $result->has_skip || $result->has_todo ) { - printf "%s %d %s # %s %s \n", $result->ok, $test_count, $result->description, - $result->directive, $result->explanation; } - else { - printf "%s %d %s \n", $result->ok, $test_count, $result->description; } - } - } - $aggregate->add($file, $parser); - } -} - -printf "1..%d\n", $aggregate->total; -exit($aggregate->failed); diff --git a/testing/helgrind b/testing/helgrind deleted file mode 100755 index 3964bd4ded..0000000000 --- a/testing/helgrind +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -repo=$(dirname $(dirname $(realpath $0))) -supp=$repo/conf/valgrind.supp -suppressions="--suppressions=$supp/mdsplus.supp" -if test -f "$supp/${DISTNAME}.supp" -then suppressions="${suppressions} --suppressions=$supp/${DISTNAME}.supp" -fi -exec valgrind --tool=helgrind --history-level=full\ - --xml=yes --xml-file=$(basename $1)-helgrind-%p.xml\ - --gen-suppressions=all --num-callers=64\ - --trace-children-skip='*/ld,*/collect2,*/ldconfig,*/sh'\ - --trace-children=yes --child-silent-after-fork=yes\ - --trace-children-skip-by-arg='*SetMdsplusFileProtection*'\ - $suppressions\ - "$@" diff --git a/testing/memcheck b/testing/memcheck deleted file mode 100755 index a22c731000..0000000000 --- a/testing/memcheck +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -repo=$(dirname $(dirname $(realpath $0))) -supp=$repo/conf/valgrind.supp -suppressions="--suppressions=$supp/mdsplus.supp" -if test -f "$supp/${DISTNAME}.supp" -then suppressions="${suppressions} --suppressions=$supp/${DISTNAME}.supp" -fi -exec valgrind --tool=memcheck --leak-check=full --show-reachable=no\ - --xml=yes --xml-file=$(basename $1)-memcheck-%p.xml\ - --gen-suppressions=all --num-callers=64\ - --trace-children-skip='*/ld,*/collect2,*/ldconfig,*/sh'\ - --trace-children=yes --child-silent-after-fork=yes\ - --trace-children-skip-by-arg='*SetMdsplusFileProtection*'\ - $suppressions\ - "$@" diff --git a/testing/selftest/Makefile.am b/testing/selftest/Makefile.am deleted file mode 100644 index 2e182a7d5f..0000000000 --- a/testing/selftest/Makefile.am +++ /dev/null @@ -1,115 +0,0 @@ -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_CXXFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -Wno-deprecated @CXXFLAGS@ $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ -LDADD = ${LIBS} $(TEST_LIBS) - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .py .pl -AM_DEFAULT_SOURCE_EXT = .c - - -C_TESTS = \ - leak_test \ - test_options \ - example2 \ - example3 \ - example4 \ - example_assert \ - skip_test \ - error_test \ - fork_success \ - fork_fail \ - timeout_success \ - timeout_fail - - -PY_TESTS = \ - pyex1.py \ - py_fail.py - -PL_TESTS = - -## // LIST OF ALL TESTS //////////////////////// -TESTS = $(C_TESTS) $(PY_TESTS) $(PL_TESTS) - -## // LIST OF TESTS EXPECTED TO FAIL /////////// -XFAIL_TESTS = error_test \ - example4 \ - example_assert \ - fork_fail \ - timeout_fail \ - py_fail.py - -if ENABLE_VALGRIND -XFAIL_TESTS += leak_test -endif - - -bin_PROGRAMS = example3 -example3_SOURCES = example3.cpp - -bin_PROGRAMS += example_assert -example_assert_LDADD = ${TEST_LIBS} $(builddir)/libMdsTestDummy.so - - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = \ - *.out \ - libMdsTestDummy.so - - -# DISABLE PYTHON LEAK DETECTION: This suppression file shall be removed when -# python will finally introduce the patch to detect if valgrind is running .. -# take a look at the file for details. You can also disable this if you are -# using a Python compiled with --without-pymalloc (only for valgrind as it is 5 -# times slower to run) -# -VALGRIND_SUPPRESSIONS_FILES_PY = \ - ${top_srcdir}/conf/valgrind-python-disableleak.supp - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -libMdsTestDummy.so: mdstestdummy.cpp - $(CC) $(CFLAGS) $(AM_CXXFLAGS) -shared -o $@ $^ - -.ONESHELL: -print: - @ - echo "--------------------------------------------------------------"; - echo "host = ${host}"; - echo "TESTS_ENVIRONMENT"; \ - for _i in ${TESTS_ENVIRONMENT}; do echo " $${_i}"; done - echo "LOG_COMPILER = ${LOG_COMPILER}"; - echo "LOG_DRIVER = ${LOG_DRIVER}"; - echo "%PATH% = $(shell ${TESTS_ENVIRONMENT} wine cmd /c 'echo %PATH%' )" - echo "--------------------------------------------------------------"; - - - -test_arch: - @echo " Testing py arch " - $(TESTS_ENVIRONMENT) $(PYTHON) $(top_srcdir)/testing/testing.py @MAKESHLIBDIR@@LIBPRE@MdsShr@SHARETYPE@ || echo FAIL; - $(TESTS_ENVIRONMENT) $(PYTHON) $(top_srcdir)/testing/testing.py @MAKESHLIBDIR@@LIBPRE@MdsTestShr@SHARETYPE@ || echo FAIL; - - - - -all-local: $(TESTS) libMdsTestDummy.so - -clean-local: clean-local-tests - -check_PROGRAMS = $(C_TESTS) -check_SCRIPTS = $(PY_TESTS) $(PL_TESTS) - diff --git a/testing/testing.am b/testing/testing.am deleted file mode 100644 index e91fb16b99..0000000000 --- a/testing/testing.am +++ /dev/null @@ -1,270 +0,0 @@ - - -# //////////////////////////////////////////////////////////////////////////// # -# /// TESTS SECTION /////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -TEST_CFLAGS = -I${top_srcdir}/testing -TEST_LIBS = -lMdsTestShr @LIBM@ @THREAD@ @LIBRT@ -TESTS_ENVIRONMENT += MDSPLUS_VERSION_CHECK=off - -# /// select test form env variable //////////////////////////////////////// # - -TEST_BUILDTYPE = local -TEST_FORMAT ?= log,tap -AM_MAKEFLAGS ?= V=0 - - -.PHONY: tap xml log -tap: ##@@tests-targets perform all TAP test targets -tap: $(TEST_SUITE_TAP) -xml: ##@@tests-targets perform all XML test targets -xml: $(TEST_SUITE_XML) -log: ##@@tests-targets perform all LOG test targets -log: $(TEST_SUITE_LOG) - - -SUFFIXES = .log .tap .xml -.PRECIUS = %.log %.tap %.xml - -## HELP ## -tests: ##@tests perform tests in this directory -rebuild-tests: ##@tests rebuild tests in this directory - - -.PHONY: tests -tests: rebuild-tests - @ \ - echo "//// Performing tests /////"; \ - export TEST_FORMAT=${TEST_FORMAT}; \ - status=0; \ - $(MAKE) -k $(TEST_FLAGS) $(AM_MAKEFLAGS) $${TEST_FORMAT//,/ } || status=$$?; \ - exit $$status - - -.PHONY: rebuild-tests -rebuild-tests: - @ \ - if [ -n "$(check_PROGRAMS)" ]; then \ - if [ -n "$${VALGRIND_BUILD}" ]; then \ - if [ -f testing ]; then $(MAKE) clean; fi; \ - $(MAKE) -k $(AM_MAKEFLAGS) $(BUILD_FLAGS) all; \ - else \ - if [ ! -f testing ]; then $(MAKE) clean; fi; \ - $(MAKE) -k $(AM_MAKEFLAGS) $(BUILD_FLAGS) all \ - CFLAGS="${CFLAGS} -D_TESTING" CPPFLAGS="${CPPFLAGS} -D_TESTING" && touch testing; \ - fi;\ - fi - - -# //////////////////////////////////////////////////////////////////////////// # -# /// VALGRIND RULES /////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -## Valgrind rules are provided by autoconf macro m4_ax_valgrind_check.m4 where -## targets tests-valgrind and test-valgrind-suppressions are provided. - -@VALGRIND_CHECK_RULES@ - - -# //////////////////////////////////////////////////////////////////////////// # -# /// SANITIZE RULES /////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -if ENABLE_SANITIZE - # // sanitizer options specific (overload this in your Makefile.am) // - LSAN_OPTIONS ?= - ASAN_OPTIONS ?= use_sigaltstack=0 - TSAN_OPTIONS ?= second_deadlock_stack=1 - UBSAN_OPTIONS ?= - - # // suppressions files (overload this in your Makefile.am) // - LSAN_OPTIONS_SUPP ?= suppressions=$(top_srcdir)/conf/sanitizer.supp/leak.supp - ASAN_OPTIONS_SUPP ?= suppressions=$(top_srcdir)/conf/sanitizer.supp/address.supp - TSAN_OPTIONS_SUPP ?= suppressions=$(top_srcdir)/conf/sanitizer.supp/thread.supp - UBSAN_OPTIONS_SUPP ?= suppressions=$(top_srcdir)/conf/sanitizer.supp/undefined.supp - - # Preloaded libraries to be exported within the test-driver script. This was - # done to avoid having libraries for 32bit preloaded when we trigger the - # shell executable to run script. NOTE: This could harm a possible preload - # order that we would add in the future ... maybe an AM_LD_PRELOAD should be - # foreseen. - # - TEST_LD_PRELOAD ?= ${ENABLE_SANITIZE_LIBPATH} - - TESTS_ENVIRONMENT += ${ENABLE_SANITIZE_OPTIONS}=${${ENABLE_SANITIZE_OPTIONS}_SUPP}:${SAN_OPTIONS}:${${ENABLE_SANITIZE_OPTIONS}}:start_deactivated=1:exitcode=1 - TESTS_ENVIRONMENT += LSAN_OPTIONS=${LSAN_OPTIONS_SUPP}:${LSAN_OPTIONS}:G_SLICE=always-malloc - TESTS_ENVIRONMENT += TEST_LD_PRELOAD=${TEST_LD_PRELOAD} - TESTS_ENVIRONMENT += TEST_TIMEUNIT=$$(($${TEST_TIMEUNIT:-1} * 5)) -endif - -# // check if libpath is correct or skip python tests -if ENABLE_SANITIZE - _check_sanitize_ldd = \ - ( test "${ENABLE_SANITIZE}" != "no" -a -n "${ENABLE_SANITIZE_LIBPATH}" && \ - ldd ${MAKESHLIBDIR}/libMdsTestShr.so | grep ${ENABLE_SANITIZE_LIBPATH} > /dev/null; ) - PY_LOG_FLAGS += $(shell ${_check_sanitize_ldd} || echo --skip;) - - # // NOTE: - # somtimes thread sanitizer does not work with python... probably because of - # the -fpie flag for now we will disable it at all. - # - PY_LOG_FLAGS += $(shell test x"${ENABLE_SANITIZE}" != x"thread" || echo --skip;) -endif - - -# //////////////////////////////////////////////////////////////////////////// # -# /// TAP TARGET ////////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -# .PHONY: $(TEST_SUITE_TAP) - -TEST_BUILD_TAP = test-build.tap -TEST_SUITE_TAP = test-suite.tap - - -# Single tap output -# ^^^^^^^^^^^^^^^^^ -# Tap target to generate single tap result beside the normal log file. This -# should make use of the TEST_TAPFILE env that generate multiple logger -# instances. - -$(TEST_LOGS:.log=.tap): - @ \ - f=$(@:.tap=.log); rm -f $$f; \ - $(MAKE) $(AM_MAKEFLAGS) $$f TEST_TAPFILE=$@ ||: - - - - -# Tap Test Build Suite -# ^^^^^^^^^^^^^^^^^^^^ -# Collects the tap result of possible test build failures prior to make the -# actual tests - -$(TEST_BUILD_TAP): - @ \ - if [ -n "$(check_PROGRAMS)" ]; then \ - echo "Try to build targets one by one"; \ - echo "TAP version 13" > $@; \ - count=0; \ - for i in $(check_PROGRAMS); do \ - if ! $(MAKE) -s -q $$i; then \ - $(MAKE) -k $(AM_MAKEFLAGS) $$i || \ - { ((count++)); \ - echo "not ok $${count} - Build of $${i} failed." >> $@; \ - }; \ - fi; \ - done; \ - fi; \ - echo "1..$${count}" >> $@; - - - -# Tap Test Suite -# ^^^^^^^^^^^^^^ -# The results are collected here using a perl script collate_tap.pl that is -# using the perl tap parser from cpan. If it is not actually available -# configure should have diabled HAVE_PL_TAP_PARSER. -# -# TODO: fix this in the case the only tap is provided as TEST_FORMAT and the -# test taps are streamed into the .log file directly ... for now a workaround -# was added: both TEST_LOGS and TEST_LOGS.tap are added to ${suite} so in both -# cases it is able to collect results. remember to add $(TEST_LOGS:.log=.tap) -# to prerequisites in the future when fix will be done. -# - -$(TEST_SUITE_TAP): $(TEST_BUILD_TAP) -if HAVE_PL_TAP_PARSER - @ ## collate test-build.tap \ - if [ -n "$(VALGRIND_TOOL)" ]; then suite="$@.$(VALGRIND_TOOL)"; \ - else suite="$@"; \ - fi; \ - perl $(top_srcdir)/testing/collate_tap.pl $(TEST_BUILD_TAP) \ - $(TEST_LOGS) $(TEST_LOGS:.log=.tap) > $${suite} \ - || exit 1 -else - @ ## test parser not available \ - echo "Can not collate tap results" >2; -endif - - -## ////////////////////////////////////////////////////////////////////////// ## -## // LOG ///////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -## test suite log is already provided by automake -## $(TEST_SUITE_LOG): - - -## ////////////////////////////////////////////////////////////////////////// ## -## // XML ///////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -## TODO: add xml output -$(TEST_SUITE_XML): - -$(TEST_LOGS:.log=.xml): - @ \ - f=$(@:.xml=.log); rm -f $$f; \ - $(MAKE) $(AM_MAKEFLAGS) $$f TEST_XMLFILE=$@ ||:s - - -# //////////////////////////////////////////////////////////////////////////// # -# /// clean //////////////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - - - -.PHONY: clean-local-tests -clean-local-tests: - -$(RM) -f testing - -$(RM) -rf $(TEST_BUILD_TAP) - -$(RM) -rf $(TEST_SUITE_TAP) - -$(RM) -rf $(TEST_LOGS:.log=.tap) - -$(RM) -rf $(TEST_SUITE_XML) - -$(RM) -rf $(TEST_LOGS:.log=.xml) - - - -# //////////////////////////////////////////////////////////////////////////// # -# /// utils //////////////////////////////////////////////////////////////// # -# //////////////////////////////////////////////////////////////////////////// # - -.PHONY: tests-envdump -tests-envdump: ##@tests enter a new shell with all tests enviroment set -tests-envdump: - @echo; \ - echo ----------------------------------------------------------------; \ - echo TESTS_ENVIRONMENT = ;\ - for _i in ${TESTS_ENVIRONMENT}; do \ - echo " $${_i}"; \ - done; - - -tests-env: ##@tests enter a new shell with all tests enviroment set -tests-env: - @ echo; echo " [ RUNNING A TESTS ENV BASH ]"; \ - echo ----------------------------------------------------------------; \ - for _i in ${TESTS_ENVIRONMENT}; do \ - echo $${_i}; \ - export $${_i}; \ - done; \ - echo srcdir=$(srcdir); \ - export srcdir=$(srcdir); \ - echo ----------------------------------------------------------------; \ - echo ""; \ - bash --rcfile $(top_srcdir)/testing/bashrc -i - - - -if HAVE_WINE -wineconsole: ##@tests enter a new WINE console with tests environment set -wineconsole: - @ \ - echo "--------------------------------------------------------------"; \ - echo "%PATH% = $(shell $${TESTS_ENVIRONMENT} wine cmd /c 'echo %PATH%' 2>/dev/null)"; \ - echo "--------------------------------------------------------------"; \ - ${TESTS_ENVIRONMENT} wineconsole -endif diff --git a/testing/windowslinks.bat b/testing/windowslinks.bat deleted file mode 100644 index 2709415a0e..0000000000 --- a/testing/windowslinks.bat +++ /dev/null @@ -1,14 +0,0 @@ -@ECHO OFF -CALL :makewinlink MDSplus -CALL :makewinlink MitDevices -CALL :makewinlink RfxDevices -CALL :makewinlink W7xDevices -GOTO EOF -:makewinlink -IF NOT EXIST "%1~" ( - IF NOT EXIST "%1" GOTO:EOF - RENAME "%1" "%1~" -) -SET /P link=<"%1~" -MKLINK /D "%1" "%link:/=\%" -:EOF \ No newline at end of file diff --git a/testing/winpython b/testing/winpython deleted file mode 100755 index 9a74dfdc8d..0000000000 --- a/testing/winpython +++ /dev/null @@ -1 +0,0 @@ -exec wine $1 $2 $(winepath -w $3) $(winepath -w $4) diff --git a/traverser/Makefile.in b/traverser/Makefile.in deleted file mode 100644 index 7fa1a92fe7..0000000000 --- a/traverser/Makefile.in +++ /dev/null @@ -1,53 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -X_CFLAGS=@X_CFLAGS@ -CFLAGS+=$(X_CFLAGS) @TARGET_ARCH@ -UIL=@UIL@ -X_LIBS=@X_LIBS@ -X_EXTRA_LIBS=@X_EXTRA_LIBS@ -X_PRE_LIBS=@X_PRE_LIBS@ -MOTIF_LIBS = @MOTIF_LDARC@ @XM_LIBS@ @MOTIF_LDSHARE@ @LIBXP@ @LIBXEXT@ -MLIBS = $(X_LIBS) $(MOTIF_LIBS) $(X_PRE_LIBS) -lXt -lX11 $(X_EXTRA_LIBS) $(LIBS) - -SOURCES = \ - main-uil.c \ - bxutils-uil.c \ - CallbacksUil.c \ - ReadInt.c \ - ReadString.c \ - GetNciString.c \ - GetSupportedDevices.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKEBINDIR@ \ -@MAKEBINDIR@traverser \ -@MAKEUIDDIR@ \ -@MAKEUIDDIR@traverser.uid - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) @MAKEBINDIR@traverser - @ $(RM) @MAKEUIDDIR@traverser.uid - - -install: $(bindir) @uiddir@ - $(INSTALL) -m 644 @MAKEUIDDIR@traverser.uid @uiddir@ - $(INSTALL) -m 755 @MAKEBINDIR@traverser @bindir@ - - -@MAKEBINDIR@traverser : $(OBJECTS) - $(CC) -o $@ $(CFLAGS) $(OBJECTS) -L@MAKESHLIBDIR@ -lMdsdcl -lTdiShr -lTreeShr -lMdsShr -lXmdsShr $(MLIBS) $(LIBS) - - -.SUFFIXES: .uid .uil -@MAKEUIDDIR@traverser.uid : ${srcdir}/traverser.uil - $(UIL) -o $@ ${srcdir}/traverser.uil diff --git a/treeshr/Makefile.in b/treeshr/Makefile.in deleted file mode 100644 index 03b01b9f89..0000000000 --- a/treeshr/Makefile.in +++ /dev/null @@ -1,49 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX=Tree - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -CFLAGS+=@SRBINCLUDE@ $(THREAD) -LIBS=-L@MAKESHLIBDIR@ @LIBS@ -lMdsShr @SRBLIB@ $(LIBSOCKET) $(THREAD) - -@MINGW_TRUE@ IMPLIB=@MAKELIBDIR@TreeShr.dll.a -@MINGW_TRUE@ DEF=${srcdir}/TreeShr.def - -SOURCES = $(wildcard @srcdir@/*.c) -OBJECTS = $(SOURCES:@srcdir@/%.c=%.o) - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@TreeShr@SHARETYPE@ $(IMPLIB) @MAKELIBDIR@@LIBPRE@TreeShr.a - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKESHLIBDIR@@LIBPRE@TreeShr@SHARETYPE@ $(IMPLIB) - @ $(RM) @MAKELIBDIR@@LIBPRE@TreeShr.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@TreeShr@SHARETYPE@ $(IMPLIB) @libdir@ - if test @SHARETYPE@ != .a ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@TreeShr.a @libdir@; \ - fi; - - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -@MAKESHLIBDIR@@LIBPRE@TreeShr@SHARETYPE@ $(IMPLIB): $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(OBJECTS) $(LIBS) $(MAKE_IMPLIB) - -@MAKELIBDIR@@LIBPRE@TreeShr.a : $(OBJECTS) - $(AR) -cr $@ $(OBJECTS) - @RANLIB@ $@ - -lex.yytreepath.o: lex.yytreepath.c - $(COMPILE.c) $(CFLAGS) -Wno-sign-compare -Wno-unused-parameter -c $^ - -#lex.yytreepath.c: TreeFindNodeWild.l -# flex $^ diff --git a/treeshr/testing/Makefile.am b/treeshr/testing/Makefile.am deleted file mode 100644 index 61f367aeb7..0000000000 --- a/treeshr/testing/Makefile.am +++ /dev/null @@ -1,48 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - - -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) $(TEST_CFLAGS) -AM_CXXFLAGS = $(TARGET_ARCH) $(WARNFLAGS) -Wno-deprecated @CXXFLAGS@ $(TEST_CFLAGS) -AM_LDFLAGS = -L@MAKESHLIBDIR@ $(RPATHLINK),@MAKESHLIBDIR@ -LDADD = @LIBS@ $(TEST_LIBS) -lMdsShr -lTreeShr - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .py .pl -AM_DEFAULT_SOURCE_EXT = .c - -TESTS = \ - TreeDeleteNodeTest\ - TreeSegmentTest - -VALGRIND_TESTS = \ - TreeDeleteNodeTest - -VALGRIND_SUPPRESSIONS_FILES = - - -# -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = \ - tree_test_*.characteristics \ - tree_test_*.datafile \ - tree_test_*.tree - - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - - -all-local: $(TESTS) -clean-local: clean-local-tests - -check_PROGRAMS = $(TESTS) -check_SCRIPTS = diff --git a/wfevent/Makefile.am b/wfevent/Makefile.am deleted file mode 100644 index 0f50bcbc55..0000000000 --- a/wfevent/Makefile.am +++ /dev/null @@ -1,19 +0,0 @@ -AM_CFLAGS = $(TARGET_ARCH) $(WARNFLAGS) - -#FIXME: Use rpath-link until build system is flattened -libdir=@MAKESHLIBDIR@ -if RPATHLINK -RPATHFLAGS = $(RPATHLINK)=$(libdir) -else -RPATHFLAGS = -endif - -AM_LDFLAGS = $(RPATHFLAGS) -LDADD = -L$(libdir) -lTdiShr -lMdsShr - -bin_PROGRAMS = wfevent -wfevent_SOURCES = wfevent.c - -#FIXME: Clean up LIBS in top level configure -#LIBS= - diff --git a/wfevent/testing/Makefile.am b/wfevent/testing/Makefile.am deleted file mode 100644 index 4fef5746c1..0000000000 --- a/wfevent/testing/Makefile.am +++ /dev/null @@ -1,30 +0,0 @@ - -include @top_builddir@/Makefile.inc -include ../../testing/testing.am - - -## ////////////////////////////////////////////////////////////////////////// ## -## // TESTS //////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - -TEST_EXTENSIONS = .sh - -# Temporarily disable tests -#TESTS = \ -# LocalEventTest.sh\ -# RemoteEventTest.sh - -# Files produced by tests that must be purged -# -MOSTLYCLEANFILES = \ - ./*.log ./*.err - -## ////////////////////////////////////////////////////////////////////////// ## -## // TARGETS ////////////////////////////////////////////////////////////// ## -## ////////////////////////////////////////////////////////////////////////// ## - - -#clean-local: clean-local-tests - -check_PROGRAMS = -check_SCRIPTS = $(TESTS) diff --git a/xmdsshr/Makefile.in b/xmdsshr/Makefile.in deleted file mode 100644 index f79c7324a4..0000000000 --- a/xmdsshr/Makefile.in +++ /dev/null @@ -1,111 +0,0 @@ -include @top_builddir@/Makefile.inc - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -MKDIR_P=@MKDIR_P@ -@AX_RECONFIGURE_TARGET@ - -X_CFLAGS=@X_CFLAGS@ -CFLAGS+=$(X_CFLAGS) -CFLAGS+=-Wno-unused-parameter -UIL=@UIL@ -X_LIBS=@X_LIBS@ -X_EXTRA_LIBS=@X_EXTRA_LIBS@ -X_PRE_LIBS=@X_PRE_LIBS@ -MOTIF_LIBS = @MOTIF_LD_LDARC@ @XM_LIBS@ @MOTIF_LD_LDSHARE@ @LIBXP@ @LIBXEXT@ - -SOURCES = \ -ListTree.c \ -XmdsBells.c \ -XmdsComplain.c \ -XmdsDeviceSetup.c \ -XmdsDigChans.c \ -XmdsDisplay.c \ -XmdsExpr.c \ -XmdsGetPutNid.c \ -XmdsGetSetOptionIdx.c \ -XmdsInitialize.c \ -XmdsInput.c \ -XmdsInputs.c \ -XmdsNidOptionMenu.c \ -XmdsOkButtons.c \ -XmdsOnOffToggleButton.c \ -XmdsPath.c \ -XmdsPopupMenuPosition.c \ -XmdsSetSubvalues.c \ -XmdsSupport.c \ -XmdsUsageIcons.c \ -XmdsWavedraw.c \ -XmdsWaveform.c \ -XmdsWidgetCallbacks.c \ -XmdsXdBox.c \ -XmdsXdBoxDialog.c \ -XmdsXdBoxDialogButton.c \ -XmdsXdBoxOnOffButton.c - -OBJECTS = $(SOURCES:.c=.o) -EXPORTS = XmdsShr.exports - -all: @MAKEUIDDIR@ \ - @MAKEUIDDIR@xmds_usage_icons.uid \ - @MAKEUIDDIR@XmdsDigChans.uid \ - @MAKEUIDDIR@XmdsInput.uid \ - @MAKEUIDDIR@XmdsXdBox.uid \ - @MAKELIBDIR@ \ - @MAKELIBDIR@libXmdsShr.a \ - @MAKESHLIBDIR@libXmdsShr@SHARETYPE@ - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -clean : - @ $(RM) $(OBJECTS) - @ $(RM) so_locations - @ $(RM) @MAKELIBDIR@libXmdsShr.a - @ $(RM) @MAKESHLIBDIR@libXmdsShr@SHARETYPE@ - @ $(RM) @MAKEUIDDIR@xmdsuil.wmd - @ $(RM) @MAKEUIDDIR@xmds_usage_icons.uid - @ $(RM) @MAKEUIDDIR@XmdsDigChans.uid - @ $(RM) @MAKEUIDDIR@XmdsInput.uid - @ $(RM) @MAKEUIDDIR@XmdsXdBox.uid - - -install: $(libdir) @uiddir@ - $(INSTALL) -m 644 @MAKEUIDDIR@xmds_usage_icons.uid @uiddir@ - $(INSTALL) -m 644 @MAKEUIDDIR@XmdsDigChans.uid @uiddir@ - $(INSTALL) -m 644 @MAKEUIDDIR@XmdsInput.uid @uiddir@ - $(INSTALL) -m 644 @MAKEUIDDIR@XmdsXdBox.uid @uiddir@ - $(INSTALL) -m 755 @MAKESHLIBDIR@libXmdsShr@SHARETYPE@ @libdir@ - if test "@SHARETYPE@" != ".a" ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@libXmdsShr.a @libdir@; \ - fi; - - -@MAKEUIDDIR@xmds_usage_icons.uid: ${srcdir}/xmds_usage_icons.uil - $(UIL) -o $@ ${srcdir}/xmds_usage_icons.uil - -@MAKEUIDDIR@XmdsDigChans.uid : ${srcdir}/XmdsDigChans.uil - $(UIL) -o $@ ${srcdir}/XmdsDigChans.uil - -@MAKEUIDDIR@XmdsInput.uid : ${srcdir}/XmdsInput.uil - $(UIL) -o $@ ${srcdir}/XmdsInput.uil - -@MAKEUIDDIR@XmdsXdBox.uid : ${srcdir}/XmdsXdBox.uil - $(UIL) -o $@ ${srcdir}/XmdsXdBox.uil - -@MAKESHLIBDIR@libXmdsShr@SHARETYPE@: $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $^ -L@MAKESHLIBDIR@ -lMdsShr -lTdiShr -lTreeShr $(LIBS) $(X_LIBS) $(MOTIF_LIBS) $(X_PRE_LIBS) -lXt -lX11 $(X_EXTRA_LIBS) $(LIBM) - -@MAKELIBDIR@libXmdsShr.a : $(OBJECTS) - $(AR) -cr $@ $^ - @RANLIB@ $@ - -@MAKELIBDIR@xmdsuil.wmd : $(WMD_RULE) - -@MAKEBINDIR@wmdcreate: wmldbcreate-xmdsshr.c UilConst.h - $(LINK.c) $(OUTPUT_OPTION) $< -DMDS_EXTENSION $(LIBS) $(MOTIF_LIBS) $(X_PRE_LIBS) -lX11 $(X_EXTRA_LIBS) - -UilConst.h : xmdsuil.wml - $(WML) - diff --git a/xtreeshr/Makefile.in b/xtreeshr/Makefile.in deleted file mode 100644 index d8f3ad6718..0000000000 --- a/xtreeshr/Makefile.in +++ /dev/null @@ -1,45 +0,0 @@ -include @top_builddir@/Makefile.inc - -LIBPREFIX=XTree - -srcdir=@srcdir@ -builddir=@builddir@ -VPATH=@srcdir@ -@AX_RECONFIGURE_TARGET@ - -@MINGW_TRUE@IMPLIB = @MAKELIBDIR@XTreeShr.dll.a - -CPPFLAGS+=@SRBINCLUDE@ - -SOURCES = \ - XTreeConvertToLongTime.c\ - XTreeDefaultSquish.c \ - XTreeDefaultResample.c \ - XTreeGetTimedRecord.c \ - XTreeGetSegmentList.c - -OBJECTS = $(SOURCES:.c=.o) - -all : @MAKELIBDIR@ @MAKESHLIBDIR@ @MAKESHLIBDIR@@LIBPRE@XTreeShr@SHARETYPE@ $(IMPLIB) @MAKELIBDIR@@LIBPRE@XTreeShr.a $(IMPLIB) - -clean: - @ $(RM) $(OBJECTS) - @ $(RM) @MAKESHLIBDIR@@LIBPRE@XTreeShr@SHARETYPE@ $(IMPLIB) - @ $(RM) @MAKELIBDIR@@LIBPRE@XTreeShr.a - -depend: - @makedepend -- $(CFLAGS) -- $(SOURCES) - -install: $(libdir) - $(INSTALL) -m 755 @MAKESHLIBDIR@@LIBPRE@XTreeShr@SHARETYPE@ $(IMPLIB) $(libdir) - if test @SHARETYPE@ != .a ; then \ - $(INSTALL) -m 644 @MAKELIBDIR@@LIBPRE@XTreeShr.a $(libdir); \ - fi; - -@MINGW_TRUE@ MAKE_IMPLIB=-Wl,--out-implib,$(IMPLIB) -@MAKESHLIBDIR@@LIBPRE@XTreeShr@SHARETYPE@ $(IMPLIB): $(OBJECTS) - $(LINK.c) $(OUTPUT_OPTION) @LINKSHARED@ $(OBJECTS) $(LIBS) -L@MAKESHLIBDIR@ -lTdiShr -lTreeShr -lMdsShr @SRBLIB@ $(MAKE_IMPLIB) - -@MAKELIBDIR@@LIBPRE@XTreeShr.a: $(OBJECTS) - $(AR) -cr $@ $^ - @RANLIB@ $@