Skip to content

HotFixes_10

William Henney edited this page Oct 17, 2019 · 2 revisions

_Format:_ The procedure for creating a hot fix is described on the HotFixToDo page and should be strictly followed at all times. Every hot fix should include a UNIX-style patch file that needs to be attached to this page. If the bug affects any predictions this should be noted. The date that the hot fix was posted should be listed, along with an acknowledgment to the person who identified the problem.

To apply the hot fix, you can either use a UNIX-style patch file, or a zip archive as outlined below. Generally the zip archive will have a larger size since it contains a full copy of every file that was changed.

Using a patch file to install a hot fix

To download a patch to your computer, first click on the "patch" link, and then right-click on the "Unified Diff" link at the bottom of the page and select "Save link as".

To install the patch you need the UNIX patch program. First go to the root of the Cloudy directory tree, then type the command:

patch -p3 < /path/to/patch-file

where /path/to/patch-file should be the location of the file you just downloaded. You can remove the patch file when you are finished.

Using a zip archive to install a hot fix

To download a zip archive to your computer, first click on the "patch" link, and then right-click on the "Zip Archive" link at the bottom of the page and select "Save link as".

To install the corrected files you need the unzip utility. Use this to explode the zip archive in a temporary location. This will create a directory tree containing only the modified files. Move these to replace the obsolete files in your Cloudy distribution. You can remove the zip file when you are finished.


Hot fixes to version C10.00

The _save line emissivity_ command may not work correctly because the emissivities are not reset properly from one iteration to the next. In order to fix this problem, edit the file iter_startend.cpp as follows after line 625:

 	for( i=0; i < LineSave.nsum; i++ )
 	{
		LineSv[i].SumLine[0] = 0.;
		LineSv[i].SumLine[1] = 0.;
		LineSv[i].emslin[0] = 0.;
		LineSv[i].emslin[1] = 0.;
 	}

The last two lines in the loop should be added. This bug will only affect the output of the save command, nothing else.


Users who have subversion 1.7.x installed, but are trying to compile Cloudy in an unversioned directory using the make facility will experience a failure during compilation. This will be the message:

Updating dependency file, this may take a little while
g++ -ansi -O3 -ftrapping-math -fno-math-errno -ftree-vectorize -Wall -W -g -DSVN_REVISION=\"Unversioned directory\" -DSYS_CONFIG=\"/home/pelleg/bin/cloudy/c10.00/source/cloudyconfig.h\"  -o cddefines.h.gch cddefines.h
g++: error: directory": No such file or directory
make: *** [cddefines.h.gch] Error 1

In order to fix this problem you need to edit the Makefile in the source directory. Change the following lines:

SVNVER := ${shell which svnversion 2> /dev/null}
ifneq ($(SVNVER),)
  REVISION := ${shell $(SVNVER) $(SRCDIR)}
else
  REVISION = exported
endif
CXXFLAGS += -DSVN_REVISION=\"$(REVISION)\"

to

SVNVER := ${shell which svnversion 2> /dev/null}
SED := ${shell which sed 2> /dev/null}
REVISION := exported
ifneq ($(SVNVER),)
  ifneq ($(SED),)
    REVISION := ${shell $(SVNVER) $(SRCDIR) | $(SED) 's/ /_/g'}
  endif
endif
CXXFLAGS += -DSVN_REVISION=\"$(REVISION)\"

and then the compilation should work fine.


Return to HotFixes main page

Return to the StepByStep instructions

Return to main [WikiStart wiki] page


Clone this wiki locally