From c6a4aaad62a90af9a72f9bc58650696419474239 Mon Sep 17 00:00:00 2001 From: Mohammadreza Khellat Date: Wed, 26 Aug 2020 14:53:10 +0400 Subject: Machine architecture and byte-order available as LaTeX macro Until now, no machine-related specifications were being documented in the workflow. This information can become helpful when observing differences in the outcome of both software and analysis segments of the workflow by others (some software may behave differently based on host machine). With this commit, the host machine's 'hardware class' and 'byte-order' are collected and now available as LaTeX macros for the authors to use in the paper. Currently it is placed in the acknowledgments, right after mentioning the Maneage commit. Furthermore, the project and configuration scripts are now capable of dealing with input directory names that have SPACE (and other special characters) by putting them inside double-quotes. However, having spaces and metacharacters in the address of the build directory could cause build/install failure for some software source files which are beyond the control of Maneage. So we now check the user's given build directory string, and if the string has any '@', '#', '$', '%', '^', '&', '*', '(', ')', '+', ';', and ' ' (SPACE), it will ask the user to provide a different directory. --- project | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) (limited to 'project') diff --git a/project b/project index 7368151..29d633d 100755 --- a/project +++ b/project @@ -167,27 +167,27 @@ do # Configure options: - -b|--builddir) build_dir="$2"; check_v "$1" "$build_dir"; shift;shift;; - -b=*|--build-dir=*) build_dir="${1#*=}"; check_v "$1" "$build_dir"; shift;; - -b*) build_dir=$(echo "$1" | sed -e's/-b//'); check_v "$1" "$build_dir"; shift;; - -e|--existing-conf) existing_conf=1; shift;; + -b|--build-dir) IFS='"' build_dir="$2"; check_v "$1" "$build_dir"; shift;shift;; + -b=*|--build-dir=*) IFS='"' build_dir="${1#*=}"; check_v "$1" "$build_dir"; shift;; + -b*) IFS='"' build_dir=$(echo "$1" | sed -e's/-b//'); check_v "$1" "$build_dir"; shift;; + -e|--existing-conf) existing_conf=1; shift;; -e*|--existing-conf=*) on_off_option_error --existing-conf -e;; - --host-cc) host_cc=1; shift;; + --host-cc) host_cc=1; shift;; --host-cc=*) on_off_option_error --host-cc;; - -i|--input-dir) input_dir="$2"; check_v "$1" "$input_dir"; shift;shift;; - -i=*|--input-dir=*) input_dir="${1#*=}"; check_v "$1" "$input_dir"; shift;; - -i*) input_dir=$(echo "$1" | sed -e's/-i//'); check_v "$1" "$input_dir"; shift;; - -m|--minmapsize) minmapsize="$2"; check_v "$1" "$minmapsize"; shift;shift;; - -m=*|--minmapsize=*) minmapsize="${1#*=}"; check_v "$1" "$minmapsize"; shift;; - -m*) minmapsize=$(echo "$1" | sed -e's/-m//'); check_v "$1" "$minmapsize"; shift;; - -s|--software-dir) software_dir="$2"; check_v "$1" "$software_dir"; shift;shift;; - -s=*|--software-dir=*) software_dir="${1#*=}"; check_v "$1" "$software_dir"; shift;; - -s*) software_dir=$(echo "$1" | sed -e's/-s//'); check_v "$1" "$software_dir"; shift;; - --check-config) check_config=1; shift;; + -i|--input-dir) IFS='"' input_dir="$2"; check_v "$1" "$input_dir"; shift;shift;; + -i=*|--input-dir=*) IFS='"' input_dir="${1#*=}"; check_v "$1" "$input_dir"; shift;; + -i*) input_dir=$(echo "$1" | sed -e's/-i//'); check_v "$1" "$input_dir"; shift;; + -m|--minmapsize) minmapsize="$2"; check_v "$1" "$minmapsize"; shift;shift;; + -m=*|--minmapsize=*) minmapsize="${1#*=}"; check_v "$1" "$minmapsize"; shift;; + -m*) minmapsize=$(echo "$1" | sed -e's/-m//'); check_v "$1" "$minmapsize"; shift;; + -s|--software-dir) IFS='"' software_dir="$2"; check_v "$1" "$software_dir"; shift;shift;; + -s=*|--software-dir=*) IFS='"' software_dir="${1#*=}"; check_v "$1" "$software_dir"; shift;; + -s*) IFS='"' software_dir=$(echo "$1" | sed -e's/-s//'); check_v "$1" "$software_dir"; shift;; + --check-config) check_config=1; shift;; --check-config=*) on_off_option_error --check-config;; - --clean-texdir) clean_texdir=1; shift;; + --clean-texdir) clean_texdir=1; shift;; --clean-texdir=*) on_off_option_error --clean-texdir;; - --all-highlevel) all_highlevel=1; shift;; + --all-highlevel) all_highlevel=1; shift;; --all-highlevel=*) on_off_option_error --all-highlevel;; # Configure and Make options: @@ -279,7 +279,7 @@ EOF check=$(ls .local/version-info/proglib/) if ! [ "x$check" = x ]; then printresults=1 - ln -s $(pwd)/.local/version-info/proglib/* $checkdir/ + ln -s "$(pwd)"/.local/version-info/proglib/* $checkdir/ fi # If something was actually found, then print them. @@ -304,7 +304,7 @@ EOF echo "========================" # Wait for the next round of checks. - sleep 1; + sleep 1 done exit 0 fi -- cgit v1.2.1 From 87948105390c035a0f0ad409db622b3850988ddb Mon Sep 17 00:00:00 2001 From: Mohammad Akhlaghi Date: Thu, 27 Aug 2020 16:47:26 +0100 Subject: Plain text editors: nano in basic, emacs and vim in high-level While a project is under development, the raw analysis software are not the only necessary software in a project. We also need tools to all the edit plain-text files within the Maneaged project. Usually people use their operating system's plain-text editor. However, when working on the project on a new computer, or in a container, the plain-text editors will have different versions, or may not be present at all! This can be very annoying and frustrating! With this commit, Maneage now installs GNU Nano as part of the basic tools. GNU Nano is a very simple and small plain text editor (the installed size is only ~3.5MB, and it is friendly to new users). Therefore, any Maneaged project can assume atleast Nano will be present (in particular when no editor is available on the running system!). GNU Emacs and VIM (both without extra dependencies, in particular without GUI support) are also optionally available in 'high-level.mk' (by adding them to 'TARGETS.conf'). The basic idea for the more advanced editors (Emacs and VIM) is that project authors can add their favorite editor while they are working on the project, but upon publication they can remove them from 'TARGETS.conf'. A few other minor things came up during this work and are now also fixed: - The 'file' program and its libraries like 'libmagic' were linking to system's 'libseccomp'! This dependency then leaked into Nano (which depends on 'libmagic'). But this is just an extra feature of 'file', only for the Linux kernel. Also, we have no dependency on it so far. So 'file' is not configured to not build with 'libseccomp'. - A typo was fixed in the line where the physical core information is being read on macOS. - The top-level directories when running './project shell' are now quoted (in case they have special characters). --- project | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) (limited to 'project') diff --git a/project b/project index 29d633d..d6ad891 100755 --- a/project +++ b/project @@ -494,22 +494,24 @@ case $operation in fi # Run the project's own shell without inheriting any environment - # from the host. + # from the host. The 'TERM' environment variable is necessary for + # tools like some text editors. bdir=`.local/bin/realpath .build` - instdir=$bdir/software/installed + instdir="$bdir"/software/installed .local/bin/env -i \ - HOME=$bdir \ + HOME="$bdir" \ + TERM="$TERM" \ CCACHE_DISABLE=1 \ - PATH=$instdir/bin \ - LDFLAGS=-L$instdir/lib \ - SHELL=$instdir/bin/bash \ - CPPFLAGS=-I$instdir/include \ - LD_LIBRARY_PATH=$instdir/lib \ + PATH="$instdir"/bin \ + LDFLAGS=-L"$instdir"/lib \ + SHELL="$instdir"/bin/bash \ + CPPFLAGS=-I"$instdir"/include \ + LD_LIBRARY_PATH="$instdir"/lib \ OMPI_MCA_plm_rsh_agent=/bin/false \ - PYTHONPATH=$instdir/lib/python/site-packages \ - PYTHONPATH3=$instdir/lib/python/site-packages \ + PYTHONPATH="$instdir"/lib/python/site-packages \ + PYTHONPATH3="$instdir"/lib/python/site-packages \ PS1="[\[\033[32m\](maneage)\[\033[00m\] \u@\h \W]$ " \ - $instdir/bin/bash + "$instdir"/bin/bash ;; -- cgit v1.2.1