# Makefile template 
# you may edit the original in
#	~/config/settings/Eddie/TemplateMakefile

# (To edit the template now, place the cursor inside the path and press Alt-D)
# This template works with the generic makefile in
#	/boot/develop/etc/makefile-engine
# and is a subset of
#	/boot/develop/etc/makefile

# you may add stuff here 


# name of your binary
NAME= Gim-ICQ

# type of binary (one of APP, SHARED, STATIC, DRIVER)
TYPE= APP

# @src->@ 

ORIGIN := /boot/home/linus/sources/Gim-ICQ_beta_23_ickle/ 

common_src := \
	src/common/Globals.cpp \
#

general_src := \
	src/general/Date.cpp \
	src/general/Gim-ICQ.cpp \
	src/general/GManager.cpp \
	src/general/History.cpp \
	src/general/HistoryIO.cpp \
	src/general/Locale.cpp \
	src/general/MiscStuff.cpp \
	src/general/PeopleData.cpp \
	src/general/Prefs.cpp \
	src/general/ProtocolManager.cpp \
	src/general/Timezone.cpp \
	src/general/WindowManager.cpp \
#

interface_src := \
	src/interface/AboutBox.cpp \
	src/interface/AuthorizationWindow.cpp \
	src/interface/BitmapView.cpp \
	src/interface/BuddyList.cpp \
	src/interface/ChatWindow.cpp \
	src/interface/FancyView.cpp \
	src/interface/GButton.cpp \
	src/interface/HTMLView.cpp \
	src/interface/HistoryWindow.cpp \
	src/interface/InfoWindow.cpp \
	src/interface/LoginBox.cpp \
	src/interface/NotesEditor.cpp \
	src/interface/PasswordChanger.cpp \
	src/interface/PrefsViewInterface.cpp \
	src/interface/PrefsWindow.cpp \
	src/interface/ResultsWindow.cpp \
	src/interface/SearchForUser.cpp \
	src/interface/SendURL.cpp \
	src/interface/TrayIcon.cpp \
	src/interface/UpdateInfo.cpp \
#

misc_src := \
	src/misc/DataContainer.cpp \
	src/misc/HTMLStuff.cpp \
	src/misc/KDeskbar.cpp \
	src/misc/TextElement.cpp \
	src/misc/classSound.cpp \
	src/misc/classSoundMaster.cpp \
#

misc-lib_src := \
	src/misc-lib/BarberPole.cpp \
	src/misc-lib/BetterScrollView.cpp \
	src/misc-lib/CLVColumn.cpp \
	src/misc-lib/CLVColumnLabelView.cpp \
	src/misc-lib/CLVEasyItem.cpp \
	src/misc-lib/CLVListItem.cpp \
	src/misc-lib/ColumnListView.cpp \
	src/misc-lib/MouseWatcher.cpp \
	src/misc-lib/PrefilledBitmap.cpp \
	src/misc-lib/ScrollViewCorner.cpp \
#

protocol_src := \
	src/protocol/Gicq.cpp \
#

SRCS := \
	$(common_src) \
	$(general_src) \
	$(interface_src) \
	$(misc_src) \
	$(misc-lib_src) \
	$(protocol_src) \
#

# @<-src@ 


# list the libraries your binary needs to link against
# (lbe, ltracker, etc.)

#LIBS= be root stdc++.r4 media textencoding sigc socket bind
LIBS= be root stdc++.r4 media textencoding icq2000 sigc

LIBPATHS=./libicq2000/lib ./libsigc++-1.0.4/sigc++/.libs

# you may add stuff here 

RSRCS= ./resources/Gim-ICQ.rsrc ./resources/Pix.rsrc

SYSTEM_INCLUDE_PATHS = ./ ./src/common/ ./libicq2000 ./libsigc++-1.0.4 ./libsigc++-1.0.4/sigc++/config

DEFINES= DEBUG

#	additional paths to look for local headers
#	thes use the form: #include "header"
#	source file directories are automatically included
#LOCAL_INCLUDE_PATHS = ./libicq2k/

#	NONE = supress all warnings
#	ALL = enable all warnings
WARNINGS = ALL

#	specify whether image symbols will be created
#	so that stack crawls in the debugger are meaningful
#	if TRUE symbols will be created
SYMBOLS = TRUE

#	if TRUE will allow application to be run from a source-level
#	debugger.  Note that this will disable all optimzation.
DEBUGGER = 

#	specify the level of optimization that you desire
#	NONE, SOME, FULL
OPTIMIZE= FULL

#	specify additional compiler flags for all files
COMPILER_FLAGS =

#	specify additional linker flags
LINKER_FLAGS =

#BONE vs net_server
ifeq ($(wildcard /boot/develop/headers/be/bone/arpa/inet.h),)
DEFINES += BEOS_NETSERVER
LIBS += net
else
LIBS += socket bind
endif


include ./makefile-engine

dist: $(TARGET)
ifeq ($(wildcard ./dist/),)
	mkdir dist
	mkdir dist/lib
	mkdir dist/Sounds
	mkdir dist/Docs
endif
	copyattr --data $(TARGET) dist/
	copyattr --data Language dist/
	copyattr --data README dist/
	copyattr --data english dist/
	copyattr --data ./Docs/HowToTranslate dist/Docs
	copyattr --data ./Sounds/* dist/Sounds
	copyattr --data ./libicq2000/lib/libicq2000.so dist/lib
	copyattr --data ./libsigc++-1.0.4/sigc++/.libs/libsigc.so dist/lib


	
