Skip to content

Commit

Permalink
Merge pull request #6 from jrincayc/ci_creation
Browse files Browse the repository at this point in the history
Creation of CI scripts
  • Loading branch information
jrincayc authored Apr 12, 2024
2 parents 62e0bf9 + 383bf68 commit 9c5713e
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 3 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: build

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: install
run: sudo apt-get install libmotif-dev libxpm-dev gfortran xutils-dev libglx-dev libgl-dev libxmu-dev libglu1-mesa-dev libxi-dev
- name: build
run: cd sera1 && ./fullbuild
- name: make_all
run: cd sera1 && make all
2 changes: 1 addition & 1 deletion sera1/Imakefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ Shared Sera3d SeraCalc SeraDose SeraImage \
SeraMC SeraMenu SeraModel SeraPlan SeraPlot \
Util

MakeSubdirs($(SUBDIRS))
MakeSubdirsOrExit($(SUBDIRS))
DependSubdirs($(SUBDIRS))
15 changes: 15 additions & 0 deletions sera1/config/Imake.rules
Original file line number Diff line number Diff line change
Expand Up @@ -1836,6 +1836,21 @@ name:: @@\
done
#endif

/*
* MakeSubdirsOrExit - recursively make a series of steps and exit if one
* fails.
*/
#ifndef MakeSubdirsOrExit
#define MakeSubdirsOrExit(dirs) @@\
all:: @@\
@MakeFlagsToShellFlags(ik,set +e); \ @@\
for i in dirs ;\ @@\
do \ @@\
echo "making all in $(CURRENT_DIR)/$$i..."; \ @@\
(cd $$i && $(MAKE) $(MFLAGS) PassCDebugFlags all) || exit -1; \ @@\
done
#endif


/*
* NamedMakeSubdirs - generate rules to do makes in the given subdirectories.
Expand Down
2 changes: 1 addition & 1 deletion sera1/config/linux.cf
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ EXTRA_X_LIBS = -lXmu -lXt -lSM -lICE -lXext -lXintl -lXi -lX11
#else
#define StandardIncludes -I/usr/X11R6/include -I$(TOP)/Shared/include
#define ExtraLibraries -L/usr/X11R6/lib -L$(TOP)/Shared/lib
EXTRA_X_LIBS = -lXmu -lXt -lSM -lICE -lXext -lXp -lXi -lX11
EXTRA_X_LIBS = -lXmu -lXt -lSM -lICE -lXext -lXi -lX11
#endif

XCOMM Location for libraries built withing the project.
Expand Down
5 changes: 4 additions & 1 deletion sera1/fullbuild
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/bin/sh

SERA_HOME=`dirname $0`
cd $SERA_HOME
export SERA_HOME=`pwd`
echo SERA_HOME=$SERA_HOME
touch $SERA_HOME/config/Local.def
imake -I./config
make Makefile
Expand Down

0 comments on commit 9c5713e

Please sign in to comment.