Skip to content

Commit

Permalink
Change unix/prebuild.sh to allow running it from the main directory.
Browse files Browse the repository at this point in the history
  • Loading branch information
c-lipka committed Jan 5, 2018
1 parent 8f4ba8a commit d418768
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 14 deletions.
4 changes: 1 addition & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@ addons:
- zlib1g-dev

install:
- cd unix
- ./prebuild.sh
- cd ..
- unix/prebuild.sh
- ./configure COMPILED_BY="Travis CI" --prefix="$(pwd)/build"
- make check
- make install
Expand Down
6 changes: 4 additions & 2 deletions changes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ Reported via GitHub:
spline types & lathe uses.")
- #292 ("Port of FS227 - Fixed Vector Limitations")
- #317 ("Boost 1.65.0 incompatibility")
- #341 ("macOS build failure for 3.7.0.5", configure script failing to use
-lboost_system with Boost 1.66)

Reported via the Newsgroups:

Expand All @@ -59,8 +61,6 @@ Miscellaneous:
- Fix `interior_texture` for text objects (as mentioned in GitHub issue #65)
- Eliminated use of deprecated C++ `register` keyword (except in 3rd party
libraries bundled with the POV-Ray source code).
- Fix configure script failing to use -lboost_system with Boost 1.66
(reported for v3.7.0.5 as GitHub issue #341).

Changed Behaviour
-----------------
Expand Down Expand Up @@ -89,6 +89,8 @@ Other Noteworthy
from the repository. To retrieve version information from the source
package, use one of the new `get-source-version.*` scripts provided in
`tools/unix/` and `tools/windows/`, respectively.
- The `unix/prebuild.sh` script can now be run from the main directory; it is
no longer necessary to change to the unix directory first.


Changes between 3.7.1-beta.9 and 3.7.1-rc.1
Expand Down
23 changes: 14 additions & 9 deletions unix/prebuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@
#
###############################################################################

# Change to the directory this script resides in
scriptname=`basename $0`
olddir=`pwd`
cd `dirname $0`

umask 022

# Extract version information from `source/base/version.h`
Expand All @@ -65,16 +70,10 @@ required_automake="1.9"
# Setup
###############################################################################

# Prevents running from another directory.
if test x"`dirname $0`" != x"."; then
echo "$0: must ran from POV-Ray's unix/ directory"
exit 1
fi

# Check optional argument.
case "$1" in
""|clean|doc|docs|docclean|docsclean) ;;
*) echo "$0: error: unrecognized option '$1'"; exit ;;
*) echo "$scriptname: error: unrecognized option '$1'"; cd "$olddir" ; exit ;;
esac

# Check whether 'cp -u' is supported.
Expand All @@ -94,7 +93,8 @@ if test x"$1" = x""; then
expr $autoconf \>= $required > /dev/null || autoconf=""
fi
if test x"$autoconf" = x""; then
echo "$0: error: requires autoconf $required_autoconf or above"
echo "$scriptname: error: requires autoconf $required_autoconf or above"
cd "$olddir"
exit 1
fi

Expand All @@ -106,7 +106,8 @@ if test x"$1" = x""; then
expr $automake \>= $required > /dev/null || automake=""
fi
if test x"$automake" = x""; then
echo "$0: error: requires automake $required_automake or above"
echo "$scriptname: error: requires automake $required_automake or above"
cd "$olddir"
exit 1
fi
fi
Expand Down Expand Up @@ -346,6 +347,7 @@ echo "make maintainer-clean" 1>&2 && make maintainer-clean 1>&2 ; \
chmod u+rw docs_internal_$timestamp.log
rm -f $log_file

cd "$olddir"
exit
;;

Expand Down Expand Up @@ -1526,3 +1528,6 @@ case "$1" in
done
;;
esac # boost


cd "$olddir"

0 comments on commit d418768

Please sign in to comment.