Cleanup build.
This commit is contained in:
parent
2695f9eed5
commit
5cd2475609
2
Makefile
2
Makefile
|
@ -22,7 +22,7 @@ else
|
||||||
CXXFLAGS := -pipe -O3 -fno-rtti -fno-exceptions -DNDEBUG
|
CXXFLAGS := -pipe -O3 -fno-rtti -fno-exceptions -DNDEBUG
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CXXFLAGS += $(LASH_CFLAGS) -DINSTALL_PREFIX=\"$(prefix)\" -DVERSION=\"$(VERSION)\"
|
CXXFLAGS += $(LASH_CFLAGS) $(FLTK_CFLAGS) -DINSTALL_PREFIX=\"$(prefix)\" -DVERSION=\"$(VERSION)\"
|
||||||
|
|
||||||
include scripts/colors
|
include scripts/colors
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
#include "Audio_Sequence.H"
|
#include "Audio_Sequence.H"
|
||||||
#include "Control_Sequence.H"
|
#include "Control_Sequence.H"
|
||||||
#include <FL/Fl_Scrollbar.H>
|
#include <FL/Fl_Scrollbar.H>
|
||||||
|
#include "Scalebar.H"
|
||||||
#include "Annotation_Sequence.H"
|
#include "Annotation_Sequence.H"
|
||||||
|
|
||||||
// #include <FL/Fl_Image.H>
|
// #include <FL/Fl_Image.H>
|
||||||
|
|
|
@ -5,11 +5,6 @@
|
||||||
|
|
||||||
. scripts/colors
|
. scripts/colors
|
||||||
|
|
||||||
if [ $# -gt 0 ]
|
|
||||||
then
|
|
||||||
echo This is not an autoconf script. Run it without any options and you will be prompted.
|
|
||||||
exit 255
|
|
||||||
fi
|
|
||||||
|
|
||||||
fatal ()
|
fatal ()
|
||||||
{
|
{
|
||||||
|
@ -26,14 +21,17 @@ ask ()
|
||||||
|
|
||||||
ok ()
|
ok ()
|
||||||
{
|
{
|
||||||
echo "$BOLD${GREEN}ok$SGR0."
|
echo "$BOLD${GREEN}ok${SGR0}."
|
||||||
}
|
}
|
||||||
|
|
||||||
failed ()
|
failed ()
|
||||||
{
|
{
|
||||||
echo "$BOLD${RED}failed!$SGR0"
|
echo "$BOLD${RED}failed!${SGR0}"
|
||||||
|
rm -f make.conf
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[ $# -gt 0 ] && fatal "This is not an autoconf script. Run it without any options and you will be prompted."
|
||||||
|
|
||||||
echo "-- Configuration:"
|
echo "-- Configuration:"
|
||||||
|
|
||||||
# get the old values
|
# get the old values
|
||||||
|
@ -65,7 +63,7 @@ FLTK_VERSION_MAJOR=`echo $FLTK_VERSION | cut -d'.' -f1`
|
||||||
FLTK_VERSION_MINOR=`echo $FLTK_VERSION | cut -d'.' -f2`
|
FLTK_VERSION_MINOR=`echo $FLTK_VERSION | cut -d'.' -f2`
|
||||||
FLTK_VERSION_PATCH=`echo $FLTK_VERSION | cut -d'.' -f3`
|
FLTK_VERSION_PATCH=`echo $FLTK_VERSION | cut -d'.' -f3`
|
||||||
|
|
||||||
if ! ( [ $FLTK_VERSION_MAJOR -ge 1 ] && [ $FLTK_VERSION_MINOR -ge 1 ] && [ $FLTK_VERSION_PATCH -ge 8 ] )
|
if ! ( [ $FLTK_VERSION_MAJOR -ge 1 ] && [ $FLTK_VERSION_MINOR -ge 1 ] && [ $FLTK_VERSION_PATCH -ge 7 ] )
|
||||||
then
|
then
|
||||||
failed
|
failed
|
||||||
fatal "The installed FLTK version ($FLTK_VERSION) is too old."
|
fatal "The installed FLTK version ($FLTK_VERSION) is too old."
|
||||||
|
@ -74,16 +72,36 @@ else
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "FLTK_LIBS=`fltk-config --use-images --ldflags`" >> make.conf
|
echo "FLTK_LIBS=`fltk-config --use-images --ldflags`" >> make.conf
|
||||||
|
echo "FLTK_CFLAGS=`fltk-config --cflags`" >> make.conf
|
||||||
|
|
||||||
|
check_command ()
|
||||||
|
{
|
||||||
|
echo -n "Checking for ${BOLD}$1${SGR0}..."
|
||||||
|
|
||||||
|
if ! [ -x "`which $2`" ]
|
||||||
|
then
|
||||||
|
failed
|
||||||
|
fatal "Command $1 not found."
|
||||||
|
else
|
||||||
|
ok
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
check_command FLUID fluid
|
||||||
|
|
||||||
#
|
#
|
||||||
|
|
||||||
check ()
|
check ()
|
||||||
{
|
{
|
||||||
echo -n "Checking for $BOLD$1$SGR0..."
|
echo -n "Checking for $BOLD$1$SGR0..."
|
||||||
if ! pkg-config --atleast-version $2 $3
|
if ! pkg-config --exists $3
|
||||||
then
|
then
|
||||||
failed
|
failed
|
||||||
fatal "$1 not installed or too old."
|
fatal "Required package $1 doesn't appear to be installed."
|
||||||
|
elif ! pkg-config --atleast-version $2 $3
|
||||||
|
then
|
||||||
|
failed
|
||||||
|
fatal "The installed version of $1 (`pkg-config --mod-version $3`) is too old."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ok
|
ok
|
||||||
|
|
Loading…
Reference in New Issue