summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2009-07-21 15:07:02 (GMT)
committerRemko Tronçon <git@el-tramo.be>2009-07-21 15:07:02 (GMT)
commit3c6895ea29dad8a93d7d3ee43bb70e2bf5d8717e (patch)
treea7dc7c6fb153e68cdbce8c479482117c69c4704c /Slimber
parent0c0df47a4667a0cd5b0005b70c1beda376678d09 (diff)
downloadswift-contrib-3c6895ea29dad8a93d7d3ee43bb70e2bf5d8717e.zip
swift-contrib-3c6895ea29dad8a93d7d3ee43bb70e2bf5d8717e.tar.bz2
Create a Slimber/CLI module.
Diffstat (limited to 'Slimber')
-rw-r--r--Slimber/CLI/Makefile.inc16
-rw-r--r--Slimber/CLI/main.cpp (renamed from Slimber/main.cpp)0
-rw-r--r--Slimber/Cocoa/Makefile.inc2
-rw-r--r--Slimber/Makefile.inc25
4 files changed, 32 insertions, 11 deletions
diff --git a/Slimber/CLI/Makefile.inc b/Slimber/CLI/Makefile.inc
new file mode 100644
index 0000000..601929c
--- /dev/null
+++ b/Slimber/CLI/Makefile.inc
@@ -0,0 +1,16 @@
+SLIMBER_CLI_TARGET = Slimber/CLI/slimber
+SLIMBER_CLI_SOURCES = \
+ Slimber/CLI/main.cpp
+SLIMBER_CLI_OBJECTS = \
+ $(SLIMBER_CLI_SOURCES:.cpp=.o)
+
+$(SLIMBER_CLI_TARGET): $(SWIFTEN_TARGET) $(SLIMBER_TARGET) $(SLIMBER_CLI_OBJECTS)
+ $(QUIET_LINK)$(CXX) -o $(SLIMBER_CLI_TARGET) $(SLIMBER_CLI_OBJECTS) $(LDFLAGS) $(SLIMBER_TARGET) $(SWIFTEN_TARGET) $(LIBS)
+
+TARGETS += $(SLIMBER_CLI_TARGET)
+SLIMBER_TARGETS += $(SLIMBER_CLI_TARGET)
+CLEANFILES += \
+ $(SLIMBER_CLI_OBJECTS) \
+ $(SLIMBER_CLI_TARGET)
+DEPS += \
+ $(SLIMBER_CLI_SOURCES:.cpp=.dep) \
diff --git a/Slimber/main.cpp b/Slimber/CLI/main.cpp
index 40f41c8..40f41c8 100644
--- a/Slimber/main.cpp
+++ b/Slimber/CLI/main.cpp
diff --git a/Slimber/Cocoa/Makefile.inc b/Slimber/Cocoa/Makefile.inc
index e4a9c67..73b0f5d 100644
--- a/Slimber/Cocoa/Makefile.inc
+++ b/Slimber/Cocoa/Makefile.inc
@@ -17,6 +17,8 @@ SLIMBER_COCOA_RESOURCES = \
Slimber/Resources/UsersOnline.png \
Slimber/Resources/UsersOffline.png
+TARGETS += $(SLIMBER_COCOA_TARGET)
+SLIMBER_TARGETS += $(SLIMBER_COCOA_TARGET)
SLIMBER_COCOA_NIBS = \
$(SLIMBER_COCOA_XIBS:.xib=.nib)
SLIMBER_COCOA_OBJECTS = \
diff --git a/Slimber/Makefile.inc b/Slimber/Makefile.inc
index 6d52f0f..539646c 100644
--- a/Slimber/Makefile.inc
+++ b/Slimber/Makefile.inc
@@ -1,21 +1,24 @@
-SLIMBER_TARGET = Slimber/slimber
+SLIMBER_TARGET = Slimber/Slimber.a
SLIMBER_SOURCES = \
Slimber/FileVCardCollection.cpp \
Slimber/VCardCollection.cpp \
- Slimber/Server.cpp \
- Slimber/main.cpp
+ Slimber/Server.cpp
SLIMBER_OBJECTS = \
$(SLIMBER_SOURCES:.cpp=.o)
-.PHONY: slimber
-slimber: $(SLIMBER_TARGET)
-
-$(SLIMBER_TARGET): $(SWIFTEN_TARGET) $(SLIMBER_OBJECTS)
- $(QUIET_LINK)$(CXX) -o $(SLIMBER_TARGET) $(SLIMBER_OBJECTS) $(LDFLAGS) $(SWIFTEN_TARGET) $(LIBS)
-
-#TARGETS += $(SLIMBER_TARGET)
-CLEANFILES += $(SLIMBER_OBJECTS)
+CLEANFILES += \
+ $(SLIMBER_OBJECTS) \
+ $(SLIMBER_TARGET)
DEPS += \
$(SLIMBER_SOURCES:.cpp=.dep) \
+include Slimber/CLI/Makefile.inc
+ifeq ($(MACOSX),1)
include Slimber/Cocoa/Makefile.inc
+endif
+
+.PHONY: slimber
+slimber: $(SLIMBER_TARGETS)
+
+$(SLIMBER_TARGET): $(SLIMBER_OBJECTS)
+ $(QUIET_AR)$(AR) $(ARFLAGS) $@ $(SLIMBER_OBJECTS)