diff options
author | Mohammad Akhlaghi <mohammad@akhlaghi.org> | 2020-12-01 16:36:04 +0000 |
---|---|---|
committer | Mohammad Akhlaghi <mohammad@akhlaghi.org> | 2020-12-01 16:38:08 +0000 |
commit | a9786200d5ed5bde30cb29b445e2a6af06694b2e (patch) | |
tree | ca1f3277f6ee724b43e458a5df25795a665827fe /reproduce | |
parent | 8fbf384f7ca3d3cba566194c21da23ee6c9374be (diff) | |
parent | ac8eee90b1580fb566ee5b84fef9acb4ed437c01 (diff) |
Imported recent work in Maneage, minor conflicts fixed
Some minor conflicts that came up during the merge were fixed.
Diffstat (limited to 'reproduce')
-rw-r--r-- | reproduce/analysis/config/gnuastro/astbuildprog.conf | 16 | ||||
-rw-r--r-- | reproduce/analysis/config/gnuastro/astconvertt.conf | 33 | ||||
-rw-r--r-- | reproduce/analysis/config/gnuastro/aststatistics.conf | 36 | ||||
-rw-r--r-- | reproduce/analysis/config/gnuastro/gnuastro.conf | 43 | ||||
-rw-r--r-- | reproduce/analysis/config/pdf-build.conf | 10 | ||||
-rw-r--r-- | reproduce/analysis/make/initialize.mk | 24 | ||||
-rw-r--r-- | reproduce/analysis/make/paper.mk | 16 | ||||
-rw-r--r-- | reproduce/analysis/make/top-make.mk | 4 | ||||
-rw-r--r-- | reproduce/analysis/make/verify.mk | 8 | ||||
-rwxr-xr-x | reproduce/software/shell/configure.sh | 62 |
10 files changed, 92 insertions, 160 deletions
diff --git a/reproduce/analysis/config/gnuastro/astbuildprog.conf b/reproduce/analysis/config/gnuastro/astbuildprog.conf deleted file mode 100644 index 7adb4d1..0000000 --- a/reproduce/analysis/config/gnuastro/astbuildprog.conf +++ /dev/null @@ -1,16 +0,0 @@ -# BuildProgram's configuration file depends on the build and is installed -# along with the rest of Gnuastro. So we'll set any specific configuration -# we want here, then import those. -# -# Copyright (C) 2018-2020 Mohammad Akhlaghi <mohammad@akhlaghi.org> -# -# 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. - -# To keep the program's compiled excutable file, comment this line. -deletecompiled 1 - -# Import the built configuration file -config .local/etc/astbuildprog.conf
\ No newline at end of file diff --git a/reproduce/analysis/config/gnuastro/astconvertt.conf b/reproduce/analysis/config/gnuastro/astconvertt.conf deleted file mode 100644 index 770ac39..0000000 --- a/reproduce/analysis/config/gnuastro/astconvertt.conf +++ /dev/null @@ -1,33 +0,0 @@ -# Default parameters (System) for ConvertType. -# ConvertType is part of GNU Astronomy Utitlies. -# -# Use the long option name of each parameter followed by a value. The name -# and value should be separated by atleast one white-space character (for -# example ` '[space], or tab). Lines starting with `#' are ignored. -# -# For more information, please run these commands: -# -# $ astconvertt --help # Full list of options, short doc. -# $ astconvertt -P # Print all options and used values. -# $ info astconvertt # All options and input/output. -# $ info gnuastro "Configuration files" # How to use configuration files. -# -# Copyright (C) 2018-2020 Mohammad Akhlaghi <mohammad@akhlaghi.org> -# -# 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. - -# Input: - -# Output: - quality 100 - widthincm 10.0 - borderwidth 1 - output jpg - -# Flux: - invert 0 - -# Common options diff --git a/reproduce/analysis/config/gnuastro/aststatistics.conf b/reproduce/analysis/config/gnuastro/aststatistics.conf deleted file mode 100644 index 90f985d..0000000 --- a/reproduce/analysis/config/gnuastro/aststatistics.conf +++ /dev/null @@ -1,36 +0,0 @@ -# Default parameters (System) for Statistics. -# Statistics is part of GNU Astronomy Utitlies. -# -# Use the long option name of each parameter followed by a value. The name -# and value should be separated by atleast one white-space character (for -# example ` '[space], or tab). Lines starting with `#' are ignored. -# -# For more information, please run these commands: -# -# $ aststatistics --help # Full list of options, short doc. -# $ aststatistics -P # Print all options and used values. -# $ info aststatistics # All options and input/output. -# $ info gnuastro "Configuration files" # How to use configuration files. -# -# Copyright (C) 2018-2020 Mohammad Akhlaghi <mohammad@akhlaghi.org> -# -# 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. - -# Input image: - -# Sky and its STD settings - khdu 1 - meanmedqdiff 0.005 - outliersigma 10 - outliersclip 3,0.2 - smoothwidth 3 - sclipparams 3,0.1 - -# Histogram and CFP settings - numasciibins 70 - asciiheight 10 - numbins 100 - mirrordist 1.5 diff --git a/reproduce/analysis/config/gnuastro/gnuastro.conf b/reproduce/analysis/config/gnuastro/gnuastro.conf deleted file mode 100644 index 82cb100..0000000 --- a/reproduce/analysis/config/gnuastro/gnuastro.conf +++ /dev/null @@ -1,43 +0,0 @@ -# Default values for the common options to all the programs in GNU -# Astronomy Utitlies. -# -# IMPORTANT NOTE: The `lastconfig' option is very important in a -# reproducible environment. Because we don't want any of Gnuastro's -# programs to go into an un-controlled environment (user or system wide -# configuration files). -# -# The rest of this configuration file is taken from the default Gnuastro -# configuration from its source (`bin/gnuastro.conf'). -# -# Copyright (C) 2018-2020 Mohammad Akhlaghi <mohammad@akhlaghi.org> -# -# 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. - -# Local project settings (`config' has to be before `lastconfig'). - config .gnuastro/gnuastro-local.conf - lastconfig 1 - -# Input: - hdu 1 - ignorecase 1 - searchin name - stdintimeout 100000 - -# Tessellation - tilesize 30,30 - numchannels 1,1 - remainderfrac 0.1 - workoverch 0 - interpmetric radial - interpnumngb 9 - interponlyblank 0 - -# Output: - tableformat fits-binary - -# Operating mode - quietmmap 0 - minmapsize 2000000000 diff --git a/reproduce/analysis/config/pdf-build.conf b/reproduce/analysis/config/pdf-build.conf index e2d59cc..48585b4 100644 --- a/reproduce/analysis/config/pdf-build.conf +++ b/reproduce/analysis/config/pdf-build.conf @@ -3,13 +3,13 @@ # # During the project's early phases, it is usually not necessary to build # the PDF file (which makes a lot of output lines on the command-line and -# can make it hard to find the commands and possible errors (and their -# outputs). Also, in some cases, only the produced results may be of +# can make it hard to find the analysis commands and possible errors (and +# their outputs). Also, in some cases, only the produced results may be of # interest and not the final PDF, so LaTeX (and its necessary packages) may -# not be installed. +# not be installed at all. # -# If this variable is given any string, a PDF will be made with -# LaTeX. Otherwise, a notice will just printed that for now, no PDF will be +# If 'pdf-build-final' is given the value 'yes', a PDF will be made with +# LaTeX. Otherwise, a notice will just printed that, no PDF will be # created. # # Copyright (C) 2018-2020 Mohammad Akhlaghi <mohammad@akhlaghi.org> diff --git a/reproduce/analysis/make/initialize.mk b/reproduce/analysis/make/initialize.mk index 6431863..75f87ee 100644 --- a/reproduce/analysis/make/initialize.mk +++ b/reproduce/analysis/make/initialize.mk @@ -38,9 +38,6 @@ mtexdir = $(texdir)/macros bashdir = reproduce/analysis/bash pconfdir = reproduce/analysis/config installdir = $(BDIR)/software/installed -# --------- Delete for no Gnuastro --------- -gconfdir = reproduce/analysis/config/gnuastro -# ------------------------------------------ @@ -240,7 +237,7 @@ clean: clean-mmap # features like ignoring the listing of a file with `!()' that we # are using afterwards. shopt -s extglob - rm -rf $(BDIR)/tex/macros/!(dependencies.tex|dependencies-bib.tex) + rm -rf $(BDIR)/tex/macros/!(dependencies.tex|dependencies-bib.tex|hardware-parameters.tex) rm -rf $(BDIR)/!(software|tex) $(BDIR)/tex/!(macros|$(texbtopdir)) rm -rf $(BDIR)/tex/build/!(tikz) $(BDIR)/tex/build/tikz/* rm -rf $(BDIR)/software/preparation-done.mk @@ -255,8 +252,8 @@ distclean: clean # `rm' program. So for this recipe, we'll use the host system's # `rm', not our own. $$sys_rm -rf $(BDIR) + $$sys_rm -f $(pconfdir)/LOCAL.conf $$sys_rm -f Makefile .gnuastro .local .build - $$sys_rm -f $(pconfdir)/LOCAL.conf $(gconfdir)/gnuastro-local.conf @@ -487,8 +484,13 @@ print-copyright = \ # actually exists, it is also aded as a `.PHONY' target above. $(mtexdir)/initialize.tex: | $(mtexdir) - # Version and title of project. - @echo "\newcommand{\projecttitle}{$(metadata-title)}" > $@ + # Version and title of project. About the starting '@': since these + # commands are run every time with './project make', it is annoying + # to print them on the standard output every time. With the '@', + # make will not print the commands that it runs in this recipe. + @d=$$(git show -s --format=%aD HEAD | awk '{print $$2, $$3, $$4}') + echo "\newcommand{\projectdate}{$$d}" > $@ + echo "\newcommand{\projecttitle}{$(metadata-title)}" >> $@ echo "\newcommand{\projectversion}{$(project-commit-hash)}" >> $@ # arXiv/Zenodo identifier (necessary for download link): @@ -505,10 +507,6 @@ $(mtexdir)/initialize.tex: | $(mtexdir) # after cloning from a fork that didn't include it!). In this # case, we'll just return the string a clear string. v=$$(git describe --always --long maneage) || v=maneage-ref-missing + d=$$(git show -s --format=%aD $$v | awk '{print $$2, $$3, $$4}') + echo "\newcommand{\maneagedate}{$$d}" >> $@ echo "\newcommand{\maneageversion}{$$v}" >> $@ - - # Get the date of the most recent commit from the Maneage - # branch. Note that with '%aD', the format looks like this: - # Wed, 9 Sep 2020 10:08:20 +0200 - v=$$(git show -s --format=%aD $$v | awk '{print $$2, $$3, $$4}') - echo "\newcommand{\maneagedate}{$$v}" >> $@ diff --git a/reproduce/analysis/make/paper.mk b/reproduce/analysis/make/paper.mk index 6a974d9..d8f18b3 100644 --- a/reproduce/analysis/make/paper.mk +++ b/reproduce/analysis/make/paper.mk @@ -37,14 +37,14 @@ # completed. # # Note that if you don't want the final PDF and just want the processing -# and file outputs, you can remove the value of `pdf-build-final' in -# `reproduce/analysis/config/pdf-build.conf'. +# and file outputs, you can give any value other than 'yes' to +# 'pdf-build-final' in `reproduce/analysis/config/pdf-build.conf'. $(mtexdir)/project.tex: $(mtexdir)/verify.tex # If no PDF is requested, or if LaTeX isn't available, don't # continue to building the final PDF. Otherwise, merge all the TeX # macros into one for building the PDF. - @if [ -f .local/bin/latex ] && [ x"$(pdf-build-final)" != x ]; then + @if [ -f .local/bin/latex ] && [ x"$(pdf-build-final)" = xyes ]; then # Put a LaTeX input command for all the necessary macro files. # 'hardware-parameters.tex' is created in 'configure.sh'. @@ -77,11 +77,11 @@ $(mtexdir)/project.tex: $(mtexdir)/verify.tex echo "LaTeX-built PDF paper will not be built." echo if [ x$(more-on-building-pdf) = x1 ]; then - echo "To do so, make sure you have LaTeX within the project (you" - echo "can check by running './.local/bin/latex --version'), _AND_" - echo "make sure that the 'pdf-build-final' variable has a value." - echo "'pdf-build-final' is defined in: " - echo "'reproduce/analysis/config/pdf-build.conf'." + echo "To build the PDF, make sure you have LaTeX within the " + echo "project (you can check by running " + echo "'./.local/bin/latex --version'), _AND_ make sure that " + echo "the 'pdf-build-final' variable has a value of 'yes', it " + echo "is defined in: 'reproduce/analysis/config/pdf-build.conf'." echo echo "If you don't have LaTeX within the project, please re-run" echo "'./project configure -e' when you have internet access." diff --git a/reproduce/analysis/make/top-make.mk b/reproduce/analysis/make/top-make.mk index 55b1f43..18d54b1 100644 --- a/reproduce/analysis/make/top-make.mk +++ b/reproduce/analysis/make/top-make.mk @@ -62,8 +62,8 @@ include reproduce/software/config/LOCAL.conf # ----------------------------- # # If you are just interested in the processing and don't want to build the -# PDF, you can skip the creation of the final PDF by removing the value -# of `pdf-build-final' in `reproduce/analysis/config/pdf-build.conf'. +# PDF, you can skip the creation of the final PDF by giving a value of +# `yes' to `pdf-build-final' in `reproduce/analysis/config/pdf-build.conf'. ifeq (x$(reproducible_paper_group_name),x$(GROUP-NAME)) all: paper.pdf else diff --git a/reproduce/analysis/make/verify.mk b/reproduce/analysis/make/verify.mk index fe828dd..35f49db 100644 --- a/reproduce/analysis/make/verify.mk +++ b/reproduce/analysis/make/verify.mk @@ -114,8 +114,12 @@ verify-dep = $(subst verify,,$(subst paper,,$(makesrc))) verify-check = $(subst initialize,,$(verify-dep)) $(mtexdir)/verify.tex: $(foreach s, $(verify-dep), $(mtexdir)/$(s).tex) - # Make sure that verification is actually requested. - if [ x"$(verify-outputs)" = xyes ]; then + # Make sure that verification is actually requested, the '@' at the + # start of the recipe is added so Make doesn't print the commands + # on the standard output because this recipe is run on every call + # to the project and can be annoying (get mixed in the middle of + # the analysis outputs or the LaTeX outputs). + @if [ x"$(verify-outputs)" = xyes ]; then # Make sure the temporary output doesn't exist (because we want # to append to it). We are making a temporary output target so if diff --git a/reproduce/software/shell/configure.sh b/reproduce/software/shell/configure.sh index d9a1b46..0b0daea 100755 --- a/reproduce/software/shell/configure.sh +++ b/reproduce/software/shell/configure.sh @@ -212,13 +212,31 @@ if [ x$kernelname = xLinux ]; then # Don't forget to add the respective C++ compiler below (leave 'cc' in # the end). c_compiler_list="gcc clang cc" -else +elif [ x$kernelname = xDarwin ]; then host_cc=1 on_mac_os=yes # Don't forget to add the respective C++ compiler below (leave 'cc' in # the end). c_compiler_list="clang gcc cc" +else + on_mac_os=no + cat <<EOF +______________________________________________________ +!!!!!!! WARNING !!!!!!! + +Maneage has been tested on GNU/Linux and Darwin (macOS) systems. But, it +seems that the current system is not GNU/Linux or Darwin (macOS). If you +notice any problem during the configure phase, please contact us with this +web-form: + + https://savannah.nongnu.org/support/?func=additem&group=reproduce + +The configuration will continue in 10 seconds... +!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +EOF + sleep 10 fi @@ -281,6 +299,47 @@ fi +# Check for Xcode in macOS systems +# -------------------------------- +# +# When trying to build Maneage on macOS systems, there are some problems +# related with the Xcode and Command Line Tools. As a consequnce, in order to +# avoid these error it is highly recommended to install Xcode in the host +# system. Here, it is checked that this is the case, and if not, warn the user +# about not having Xcode already installed. +if [ x$on_mac_os = xyes ]; then + xcode=$(which xcodebuild) + if [ x$xcode != x ]; then + xcode_version=$(xcodebuild -version | grep Xcode) + echo " " + echo "$xcode_version already installed in the system" + echo " " + else + cat <<EOF +______________________________________________________ +!!!!!!! WARNING !!!!!!! + +Maneage has been tested Darwin (macOS) systems with host Xcode +installation. However, Xcode cannot be found in this system. As a +consequence, the configure step may fail at some point. If this is the +case, please install Xcode and try to run again the configure step. If the +problem still persist after installing Xcode, please contact us with this +web-form: + + https://savannah.nongnu.org/support/?func=additem&group=reproduce + +The configuration will continue in 5 seconds ... +!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +EOF + sleep 5 + fi +fi + + + + + # Check for C/C++ compilers # ------------------------- # @@ -1211,7 +1270,6 @@ ln -s "$tikzdir" tex/tikz # --------- Delete for no Gnuastro --------- rm -f .gnuastro -ln -s "$topdir"/reproduce/analysis/config/gnuastro .gnuastro # ------------------------------------------ |