More tweaking of build for static FLTK.

This commit is contained in:
Jonathan Moore Liles 2012-03-06 20:01:37 -08:00
parent 5336880bd4
commit 2e80994cf5
6 changed files with 12 additions and 15 deletions

View File

@ -12,11 +12,11 @@ SRCS:=$(SRCS:.fl=.C)
SRCS:=$(sort $(SRCS)) SRCS:=$(sort $(SRCS))
OBJS:=$(SRCS:.C=.o) OBJS:=$(SRCS:.C=.o)
LIBS += $(FLTK_LIBS) $(JACK_LIBS) $(LASH_LIBS) $(LRDF_LIBS) $(LIBLO_LIBS) $(SIGCPP_LIBS) $(XPM_LIBS) LIBS += $(FLTK_LDFLAGS) $(JACK_LIBS) $(LASH_LIBS) $(LRDF_LIBS) $(LIBLO_LIBS) $(SIGCPP_LIBS) $(XPM_LIBS)
CFLAGS += $(FLTK_CFLAGS) $(JACK_CFLAGS) $(LIBLO_CFLAGS) $(SIGCPP_CFLAGS) $(XPM_CFLAGS) CFLAGS += $(FLTK_CFLAGS) $(JACK_CFLAGS) $(LIBLO_CFLAGS) $(SIGCPP_CFLAGS) $(XPM_CFLAGS)
src/mixer: $(OBJS) FL/libfl_widgets.a nonlib/libnonlib.a $(STATIC_LIBS) src/mixer: $(OBJS) FL/libfl_widgets.a nonlib/libnonlib.a $(FLTK_LIBS)
@ echo -n Linking mixer... @ echo -n Linking mixer...
@ $(CXX) $(CXXFLAGS) $(LIBS) $^ -o $@ -LFL -lfl_widgets -Lnonlib -lnonlib -ldl && echo $(DONE) @ $(CXX) $(CXXFLAGS) $(LIBS) $^ -o $@ -LFL -lfl_widgets -Lnonlib -lnonlib -ldl && echo $(DONE)

View File

@ -55,11 +55,7 @@ else
CXXFLAGS := -fno-rtti -fno-exceptions CXXFLAGS := -fno-rtti -fno-exceptions
endif endif
# LIBS := "$(FLTK_LIBS) $(LIBS)"
STATIC_LIBS := lib/fltk/lib/libfltk.a lib/fltk/lib/libfltk_images.a
# FLTK_LIBS := -lfltk -fltk_images -lfltk_gl -lfltk_forms -lfltk_cairo
LIBS += $(FLTK_LIBS)
LIBS += -lpng -lcairo -ljpeg
INCLUDES := -I. -Iutil -IFL -Inonlib INCLUDES := -I. -Iutil -IFL -Inonlib
INCLUDES += $(FLTK_CFLAGS) INCLUDES += $(FLTK_CFLAGS)

View File

@ -259,7 +259,7 @@ require_command ()
if [ -x "$2" ] if [ -x "$2" ]
then then
name="$2" name="$PWD/$2"
ok ok
elif [ -x "`which "$2"`" ] elif [ -x "`which "$2"`" ]
then then
@ -270,7 +270,7 @@ require_command ()
fatal "Command $1 not found." fatal "Command $1 not found."
fi fi
append "$1=$2" append "$1=$name"
} }
require_package () require_package ()
@ -383,6 +383,7 @@ require_FLTK ()
use="$use --use-$1" use="$use --use-$1"
done done
append "FLTK_LIBS=`lib/fltk/fltk-config $use --ldflags | sed 's/,\\?--as-needed//g'`" append "FLTK_LIBS=`lib/fltk/fltk-config $use --libs | sed 's/,\\?--as-needed//g'`"
append "FLTK_LDFLAGS=`lib/fltk/fltk-config $use --ldflags | sed 's/,\\?--as-needed//g'`"
append "FLTK_CFLAGS=`lib/fltk/fltk-config $use --cflags`" append "FLTK_CFLAGS=`lib/fltk/fltk-config $use --cflags`"
} }

View File

@ -16,7 +16,7 @@ begin_tests
require_command ar ar require_command ar ar
require_command makedepend makedepend require_command makedepend makedepend
require_FLTK 1.3.0 images cairo require_FLTK 1.3.0 images
suggest_package JACK 0.103.0 jack suggest_package JACK 0.103.0 jack
require_package liblo 0.23 liblo require_package liblo 0.23 liblo
require_package sigcpp 2.0.0 sigc++-2.0 require_package sigcpp 2.0.0 sigc++-2.0

View File

@ -20,9 +20,9 @@ src/nsmd: src/nsmd.o nonlib/libnonlib.a
@ echo -n Linking session handler. @ echo -n Linking session handler.
@ $(CXX) $(CXXFLAGS) $(LIBS) $^ -o $@ -Lnonlib -lnonlib && echo $(DONE) @ $(CXX) $(CXXFLAGS) $(LIBS) $^ -o $@ -Lnonlib -lnonlib && echo $(DONE)
src/session-manager: src/session-manager.o nonlib/libnonlib.a $(STATIC_LIBS) src/session-manager: src/session-manager.o nonlib/libnonlib.a $(FLTK_LIBS)
@ echo -n Linking session handler. @ echo -n Linking session handler.
@ $(CXX) $(CXXFLAGS) $(FLTK_LIBS) $(XPM_LIBS) $(LIBS) $^ -o $@ -LFL -lfl_widgets -Lnonlib -lnonlib && echo $(DONE) @ $(CXX) $(CXXFLAGS) $(FLTK_LDFLAGS) $(XPM_LIBS) $(LIBS) $^ -o $@ -LFL -lfl_widgets -Lnonlib -lnonlib && echo $(DONE)
src/send_osc: src/send_osc.o nonlib/libnonlib.a src/send_osc: src/send_osc.o nonlib/libnonlib.a
@ $(CXX) $(CXXFLAGS) $(LIBS) $^ -o $@ -Lnonlib -lnonlib && echo $(DONE) @ $(CXX) $(CXXFLAGS) $(LIBS) $^ -o $@ -Lnonlib -lnonlib && echo $(DONE)

View File

@ -12,7 +12,7 @@ SRCS:=$(SRCS:.fl=.C)
SRCS:=$(sort $(SRCS)) SRCS:=$(sort $(SRCS))
OBJS:=$(SRCS:.C=.o) OBJS:=$(SRCS:.C=.o)
LIBS += $(JACK_LIBS) $(SNDFILE_LIBS) $(LIBLO_LIBS) $(SIGCPP_LIBS) $(XPM_LIBS) LIBS += $(FLTK_LDFLAGS) $(JACK_LIBS) $(SNDFILE_LIBS) $(LIBLO_LIBS) $(SIGCPP_LIBS) $(XPM_LIBS)
CFLAGS += $(SNDFILE_CFLAGS) $(FLTK_CFLAGS) $(JACK_CFLAGS) $(SIGCPP_CFLAGS) $(XPM_CFLAGS) CFLAGS += $(SNDFILE_CFLAGS) $(FLTK_CFLAGS) $(JACK_CFLAGS) $(SIGCPP_CFLAGS) $(XPM_CFLAGS)
@ -29,7 +29,7 @@ ifeq ($(USE_WIDGET_FOR_TIMELINE),yes)
endif endif
src/timeline: $(OBJS) FL/libfl_widgets.a nonlib/libnonlib.a $(STATIC_LIBS) src/timeline: $(OBJS) FL/libfl_widgets.a nonlib/libnonlib.a $(FLTK_LIBS)
@ echo -n Linking timeline... @ echo -n Linking timeline...
@ $(CXX) $(CXXFLAGS) $(INCLUDES) $(LIBS) $^ -o $@ -LFL -lfl_widgets -Lnonlib -lnonlib && echo $(DONE) @ $(CXX) $(CXXFLAGS) $(INCLUDES) $(LIBS) $^ -o $@ -LFL -lfl_widgets -Lnonlib -lnonlib && echo $(DONE)