Skip to content

Commit 087afde

Browse files
committed
local build on workstation quite similar to build in pipeline now! clean up AI slop a touch and add the right conditional for executing an echo that a command completed successfully. add options as commented out to ponder for quick conda build testing. tweak the make check configuration step in the testing section.
1 parent 208cdae commit 087afde

File tree

2 files changed

+64
-26
lines changed

2 files changed

+64
-26
lines changed

build.sh

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,27 @@
11
echo 'builindg FRE-NCtools conda package...'
2-
echo "Build directory:" && pwd
3-
echo "Contents of Build directory:" && ls
2+
echo "SRC_DIR / Build directory is:"
3+
pwd
4+
echo "Contents of SRC_DIR / Build directory are:"
5+
ls
6+
7+
## this is sufficient
48
autoreconf -i
5-
./configure --prefix=$PREFIX
9+
./configure --prefix=$PREFIX || cat config.log
10+
#./configure --prefix=$PREFIX --with-mpi || cat config.log
11+
#./configure --prefix=$PREFIX --enable-quad-precision || cat config.log
12+
#./configure --prefix=$PREFIX --enable-quad-precision --with-mpi || cat config.log
13+
echo "compiling/building"
614
make
15+
echo "installing into $PREFIX"
716
make install
8-
#cp configure.ac $SRC_DIR
9-
#make check RUN_EXPENSIVE_TESTS=no
17+
18+
### to test, build-dir option, ala README
19+
#autoreconf -i
20+
#mkdir build && cd build
21+
#../configure --prefix=$PREFIX || cat config.log
22+
##../configure --prefix=$PREFIX --with-mpi || cat config.log
23+
##../configure --prefix=$PREFIX --enable-quad-precision || cat config.log
24+
##../configure --prefix=$PREFIX --enable-quad-precision --with-mpi || cat config.logecho "compiling/building"
25+
#make
26+
#echo "installing into $PREFIX"
27+
#make install

meta.yaml

Lines changed: 41 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package:
22
name: fre-nctools
3-
version: alpha
3+
version: 2025.05.02
44

55
source:
66
path: .
@@ -75,7 +75,7 @@ requirements:
7575
- conda-forge::hdf5=1.14.*=mpi*
7676
- conda-forge::openmp
7777
- conda-forge::tcsh
78-
- conda-forge::which
78+
- conda-forge::which
7979

8080
test:
8181
source_files:
@@ -87,31 +87,51 @@ test:
8787
- m4/**
8888
- configure.ac
8989
- Makefile.am
90+
# # if using build-dir option? needed?
91+
# - build**
9092
commands:
9193
- echo 'Testing FRE-NCtools conda package installation...'
92-
- echo "Installation directory:" && pwd
93-
- echo "Contents of Installation directory:" && ls
94-
94+
- echo "Installation directory:"
95+
- pwd
96+
- echo "Contents of Installation directory:"
97+
- ls
98+
9599
# Test key installed programs with help flags (allow help commands to exit with any status)
96-
- echo "Testing timavg script..." && which timavg && (timavg -h || echo "timavg help command completed")
97-
- echo "Testing ncexists program..." && which ncexists && (ncexists --help || echo "ncexists help command completed")
98-
- echo "Testing combine-ncc program..." && which combine-ncc && (combine-ncc --help || echo "combine-ncc help command completed")
99-
- echo "Testing fregrid program..." && which fregrid && (fregrid --help || echo "fregrid help command completed")
100-
- echo "Testing make_hgrid program..." && which make_hgrid && (make_hgrid --help || echo "make_hgrid help command completed")
101-
- echo "Testing check_mask program..." && which check_mask && (check_mask 2>&1 | grep -q "check_mask --grid_file" && echo "check_mask usage displayed correctly" || echo "check_mask found")
102-
100+
- echo "Testing timavg script..."
101+
- which timavg && timavg -h && echo "timavg help command completed"
102+
- echo "Testing ncexists program..."
103+
- which ncexists && ncexists --help && echo "ncexists help command completed"
104+
- echo "Testing combine-ncc program..."
105+
- which combine-ncc && combine-ncc --help && echo "combine-ncc help command completed"
106+
- echo "Testing fregrid program..."
107+
- which fregrid && fregrid --help && echo "fregrid help command completed"
108+
- echo "Testing make_hgrid program..."
109+
- which make_hgrid && make_hgrid --help && echo "make_hgrid help command completed"
110+
- echo "Testing check_mask program..."
111+
- which check_mask && check_mask 2>&1 | grep -q "check_mask --grid_file" && echo "found check_mask, usage displayed correctly"
112+
103113
# Test some key script utilities exist
104-
- echo "Testing list_ncvars.sh script..." && which list_ncvars.sh && echo "list_ncvars.sh found"
105-
- echo "Testing split_ncvars.pl script..." && which split_ncvars.pl && echo "split_ncvars.pl found"
106-
114+
- echo "Testing list_ncvars.sh script..."
115+
- which list_ncvars.sh && echo "list_ncvars.sh found"
116+
- echo "Testing split_ncvars.pl script..."
117+
- which split_ncvars.pl && echo "split_ncvars.pl found"
118+
107119
# Test version reporting for programs that support it (allow version commands to exit with any status)
108-
- echo "Testing version reporting..." && (ncexists --version || echo "ncexists version command completed")
109-
- echo "Testing combine-ncc version..." && (combine-ncc --version || echo "combine-ncc version command completed")
110-
- echo "Testing timavg version..." && (timavg -V || echo "timavg version command completed")
111-
120+
- echo "Testing version reporting..."
121+
- ncexists --version && echo "ncexists version command completed"
122+
- echo "Testing combine-ncc version..."
123+
- combine-ncc --version && echo "combine-ncc version command completed"
124+
- echo "Testing timavg version..."
125+
- timavg -V && echo "timavg version command completed"
126+
112127
# Run actual tests using the repository's test infrastructure
113-
- echo "Setting up test environment..." && autoreconf -i . && ./configure && make check RUN_EXPENSIVE_TESTS=no
114-
128+
# vanilla
129+
- echo "Setting up test environment..."
130+
- autoreconf -i && ./configure --prefix=$PREFIX && make check RUN_EXPENSIVE_TESTS=no
131+
# # --with-mpi --enable-quad-precision
132+
# - echo "Setting up test environment..."
133+
# - autoreconf -i && ./configure --with-mpi --enable-quad-precision && make check RUN_EXPENSIVE_TESTS=no
134+
115135
- echo 'All tests completed - FRE-NCtools installation verified!'
116136

117137
about:

0 commit comments

Comments
 (0)