forked from zerothi/fdict
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
doc+check: added documentation and checks
- Cleaned up readme.md for easier reference. - enabled checks using make check/test - Added license header in the .inc and .F90 files - Added travis build system - I had created filter.sed, but forgotten to add it - The tests for memory where using towards 2 Gb of memory I have cut it down to 1 Gb to limit the requiremente of the hardware. - added default .arch.make file - add quick_test.sh which runs the make check using the .arch.make file.
- Loading branch information
Showing
16 changed files
with
201 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
FC=gfortran | ||
FFLAGS = -g | ||
|
||
.F90.o: | ||
$(FC) -c $(INC) $(FFLAGS) $< | ||
|
||
.f90.o: | ||
$(FC) -c $(INC) $(FFLAGS) $< | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
language: fortran | ||
|
||
notifications: | ||
email: | ||
recipients: | ||
- [email protected] | ||
on_failure: always | ||
on_success: change | ||
|
||
before_install: | ||
- ln -s .arch.make arch.make | ||
- sudo apt-get install -qq gfortran | ||
|
||
install: | ||
- make | ||
|
||
script: | ||
- make check |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,6 +34,8 @@ $(LIB): $(OBJS) | |
$(RANLIB) $(LIB) | ||
|
||
.PHONY: test | ||
.PHONY: check | ||
check: test | ||
test: lib | ||
$(MAKE) -C test | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Replace the marker NEWLINE by a '\n' character. | ||
# This will work in Linux and OSX. *Keep it in two lines!* | ||
s/NEWLINE/\ | ||
/g | ||
# Basically the following commands translates | ||
# pre-processors within another preprocessor | ||
# which isn't allowed. | ||
# Hence a small workaround is needed. | ||
# | ||
# This is for removing empty and comment lines | ||
/^$$/d;/^\!.*&/d | ||
# | ||
# This is for removing double hash and too much space | ||
# Strictly not needed | ||
s/[[:space:]]*\#\#[[:space:]]*\([^[:space:]]*\)/\1/g | ||
# | ||
# This is for changing the include statements | ||
# to direct include statements, certain platforms | ||
# requires you to do this kind of trick :( | ||
s/[[:space:]]*\#\([^i][^[:space:]]*\)/"\1"/g | ||
# | ||
# This is for translating direct endif statements to | ||
# preprocessor statements | ||
#s/"endif"/\n\#endif/g | ||
s/"endif"/\ | ||
\#endif/g | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/bin/bash | ||
|
||
# Create link from .arch.make to | ||
# arch.make | ||
|
||
_old_arch= | ||
if [ -L arch.make ]; then | ||
# We assume the arch.make is | ||
# a link to .arch.make | ||
# Simply delete it, we will re-instantiate it | ||
rm arch.make | ||
elif [ -e arch.make ]; then | ||
_old_arch=.temporary_arch.make | ||
mv arch.make $_old_arch | ||
fi | ||
|
||
# Create link to arch.make | ||
ln -s .arch.make arch.make | ||
|
||
# call make... | ||
make clean | ||
make | ||
make check | ||
|
||
if [ -z "$_old_arch" ]; then | ||
# the link should sustain, | ||
# it still links to .arch.make | ||
echo "do nothing" > /dev/null | ||
else | ||
rm arch.make | ||
mv $_old_arch arch.make | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ program tests | |
|
||
integer :: i, N, step | ||
|
||
N = 1000 | ||
N = 500 | ||
step = 25 | ||
|
||
write(*,*)'Delete and deallocation' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ program tests | |
|
||
integer :: i, N, step | ||
|
||
N = 1000 | ||
N = 500 | ||
step = 25 | ||
|
||
write(*,*)'Remove and delete var' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ program tests | |
|
||
integer :: i, N, step | ||
|
||
N = 1000 | ||
N = 500 | ||
step = 25 | ||
|
||
write(*,*)'Pop and delete var' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,7 @@ program tests | |
|
||
integer :: i, N, step | ||
|
||
N = 1000 | ||
N = 500 | ||
step = 25 | ||
|
||
write(*,*)'Running with deallocation' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters