Skip to content

Commit

Permalink
revert files modification
Browse files Browse the repository at this point in the history
add sudo to MacOS actions (install)
add python to Windows
  • Loading branch information
sgarnotel committed Dec 8, 2023
1 parent 8791364 commit c14672c
Show file tree
Hide file tree
Showing 12 changed files with 17 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/job1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ jobs:

- name: Check
continue-on-error: true
run: make check
run: sudo make check #TODO should work without sudo

- name: Install
run: make install
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/job2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ jobs:
run: make check

- name: Install
run: make install
run: sudo make check #TODO should work without sudo

windows:
name: Job2 - Windows
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/job3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ jobs:
run: make check

- name: Install
run: make install
run: sudo make check #TODO should work without sudo

windows:
name: Job3 - Windows
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/job4-mpich.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,4 +97,4 @@ jobs:
run: make check

- name: Install
run: make install
run: sudo make check #TODO should work without sudo
2 changes: 2 additions & 0 deletions .github/workflows/job4-msmpi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ jobs:
tar
mingw-w64-x86_64-cmake
mingw-w64-x86_64-msmpi
python
mingw-w64-x86_64-python
- uses: actions/checkout@v4

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/job4-openmpi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,4 +98,4 @@ jobs:
run: make check

- name: Install
run: make install
run: sudo make check #TODO should work without sudo
2 changes: 1 addition & 1 deletion .github/workflows/job5-mpich.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,4 +97,4 @@ jobs:
run: make check

- name: Install
run: make install
run: sudo make check #TODO should work without sudo
2 changes: 2 additions & 0 deletions .github/workflows/job5-msmpi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ jobs:
tar
mingw-w64-x86_64-cmake
mingw-w64-x86_64-msmpi
python
mingw-w64-x86_64-python
- uses: actions/checkout@v4

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/job5-openmpi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,4 +98,4 @@ jobs:
run: make check

- name: Install
run: make install
run: sudo make check #TODO should work without sudo
2 changes: 1 addition & 1 deletion Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ install-exec-local:: bin/script/PostInstall.sh FreeFEM-documentation.pdf
if [ -f $$i ]; then $(INSTALL) -m 555 $$i "$(DESTDIR)$(ff_prefix_dir)/idp"; fi; done

bin/script/PostInstall.sh:./Makefile bin/script/PostInstall.m4
m4 "-DFF__FVER=$(PACKAGE_VERSION)" "-DFF_BINDIR=$(bindir)" "-DFF__DATADIR=$(pkgdatadir)" "-DFF__DESTDIR=$(DESTDIR)" bin/script/PostInstall.m4 > bin/script/PostInstall.sh
m4 "-DFF__FVER=$(PACKAGE_VERSION)" "-DFF_BINDIR=$(bindir)" "-DFF__DATADIR=$(pkgdatadir)" bin/script/PostInstall.m4 > bin/script/PostInstall.sh
chmod a+x bin/script/PostInstall.sh

FreeFEM-documentation.pdf:Makefile
Expand Down
9 changes: 4 additions & 5 deletions bin/script/PostInstall.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,17 @@
# "-DFF__FVER=$(PACKAGE_VERSION)"
# "-DFF_BINDIR=$(bindir)"
# "-DFF__DATADIR=$(pkgdatadir)
# "-DFF__DESTDIR=$(DESTDIR)"
# "FFBIN="@prefix@"/bin

if [ "$(uname)" = "Darwin" ]; then
ff_desktop="$HOME/Desktop/FreeFem++-""FF__FVER"
mkdir -p -m 0755 "FF__DESTDIR"/etc/paths.d
mkdir -p -m 0755 /etc/paths.d
ln -sf "FF__DATADIR"/"FreeFEM-documentation.pdf" "$HOME/Desktop"
test -e "$ff_desktop" || ln -sf "FF__DATADIR"/"FF__FVER" "$ff_desktop"
echo Install "FF__DESTDIR"/etc/paths.d/FreeFem++ file: "FF_BINDIR"
echo Install /etc/paths.d/FreeFem++ file: "FF_BINDIR"

echo "FF_BINDIR" > "FF__DESTDIR"/etc/paths.d/FreeFem++
chmod a+r "FF__DESTDIR"/etc/paths.d/FreeFem++
echo "FF_BINDIR" > /etc/paths.d/FreeFem++
chmod a+r /etc/paths.d/FreeFem++
fi

echo " Try to Clean old file version "
Expand Down
2 changes: 1 addition & 1 deletion etc/config/FreeFem++.scrpt-txt.in
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ on freefem(edpfile)
if not (exists window 1) then reopen
activate
try
do shell script "/usr/bin/env bash -c 'export PATH=\"$PATH:$(cat "$(DESTDIR)/etc/paths.d/FreeFem++")\";cd \"" & edpdir & "\";FreeFem++-CoCoa \"" & edppath & "\"'"
do shell script "/usr/bin/env bash -c 'export PATH=\"$PATH:$(cat /etc/paths.d/FreeFem++)\";cd \"" & edpdir & "\";FreeFem++-CoCoa \"" & edppath & "\"'"
end try
end tell
end freefem
Expand Down

0 comments on commit c14672c

Please sign in to comment.