[12844] | 1 | ###########################################################################
|
---|
| 2 | #
|
---|
[18224] | 3 | # Makefile -- common-src/src/gdbmedit/gdbmset
|
---|
[12844] | 4 | # A component of the Greenstone digital library software
|
---|
| 5 | # from the New Zealand Digital Library Project at the
|
---|
| 6 | # University of Waikato, New Zealand.
|
---|
| 7 | #
|
---|
[15932] | 8 | # Copyright (C) 1999-2008 The New Zealand Digital Library Project
|
---|
[12844] | 9 | #
|
---|
| 10 | #
|
---|
| 11 | # This program is free software; you can redistribute it and/or modify
|
---|
| 12 | # it under the terms of the GNU General Public License as published by
|
---|
| 13 | # the Free Software Foundation; either version 2 of the License, or
|
---|
| 14 | # (at your option) any later version.
|
---|
| 15 | #
|
---|
| 16 | # This program is distributed in the hope that it will be useful,
|
---|
| 17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
| 19 | # GNU General Public License for more details.
|
---|
| 20 | #
|
---|
| 21 | # You should have received a copy of the GNU General Public License
|
---|
| 22 | # along with this program; if not, write to the Free Software
|
---|
| 23 | # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
---|
| 24 | #
|
---|
| 25 | ###########################################################################
|
---|
| 26 |
|
---|
[16603] | 27 | GSDL_DIR = ../../../..
|
---|
[16605] | 28 | COMMON_DIR = $(GSDL_DIR)/common-src
|
---|
[15932] | 29 |
|
---|
[18224] | 30 | COMMON_PACKAGES_DIR = $(COMMON_DIR)/packages
|
---|
| 31 |
|
---|
[15551] | 32 | CXX = @CXX@
|
---|
[25149] | 33 | CXXFLAGS = @CXXFLAGS@ @ARCH_DEP_FLAGS@
|
---|
[22058] | 34 | DEFS = @DEFS@ $(GDBM_DEFINES) $(JDBM_DEFINES) $(SQLITE_DEFINES)
|
---|
[15932] | 35 | GSDLOS = @gsdlos@
|
---|
[18224] | 36 | INCLUDES = -I$(COMMON_PACKAGES_DIR)/gdbm/include -I$(COMMON_DIR)/src/lib
|
---|
[26821] | 37 | STRIP = @STRIP@
|
---|
[15932] | 38 | INSTALL = @INSTALL@
|
---|
[25149] | 39 | LDFLAGS = @LDFLAGS@ @ARCH_DEP_FLAGS@
|
---|
[18224] | 40 | LIBS = @LIBS@ $(COMMON_PACKAGES_DIR)/gdbm/lib/libgdbm.a
|
---|
[15932] | 41 |
|
---|
| 42 |
|
---|
| 43 | CXXCOMPILE = $(CXX) -c $(CXXFLAGS) $(DEFS) $(INCLUDES)
|
---|
[15551] | 44 | CXXLINK = $(CXX) $(LDFLAGS) -o $@
|
---|
[15932] | 45 |
|
---|
| 46 |
|
---|
[12844] | 47 | .SUFFIXES:
|
---|
| 48 | .SUFFIXES: .cpp .o
|
---|
| 49 | .cpp.o:
|
---|
[15551] | 50 | $(CXXCOMPILE) $<
|
---|
[12844] | 51 |
|
---|
| 52 |
|
---|
[15932] | 53 | SOURCES = \
|
---|
| 54 | gdbmset.cpp
|
---|
[12844] | 55 |
|
---|
[15932] | 56 | OBJECTS = \
|
---|
[15936] | 57 | gdbmset.o
|
---|
[12844] | 58 |
|
---|
[15932] | 59 | EXECUTABLE_OBJECTS = \
|
---|
| 60 | $(OBJECTS)
|
---|
[12844] | 61 |
|
---|
[15932] | 62 | EXECUTABLE = gdbmset
|
---|
[12844] | 63 |
|
---|
| 64 |
|
---|
[15932] | 65 | # Default target: make the gdbmset executable
|
---|
| 66 | all: $(EXECUTABLE)
|
---|
[12844] | 67 |
|
---|
[15932] | 68 | gdbmset: $(EXECUTABLE_OBJECTS)
|
---|
| 69 | $(CXXLINK) $(EXECUTABLE_OBJECTS) $(LIBS)
|
---|
[12844] | 70 |
|
---|
[15932] | 71 | install: $(EXECUTABLE)
|
---|
| 72 | $(INSTALL) -d $(GSDL_DIR)/bin/$(GSDLOS)
|
---|
[26821] | 73 | $(STRIP) $(EXECUTABLE)
|
---|
| 74 | $(INSTALL) -m 755 $(EXECUTABLE) $(GSDL_DIR)/bin/$(GSDLOS)
|
---|
[12844] | 75 |
|
---|
[15932] | 76 | clean:
|
---|
| 77 | rm -f $(OBJECTS) $(EXECUTABLE)
|
---|
[12844] | 78 |
|
---|
[15932] | 79 | distclean:
|
---|
| 80 | rm -f $(OBJECTS) $(EXECUTABLE) Makefile
|
---|
| 81 |
|
---|
| 82 | depend:
|
---|
| 83 | makedepend -Y -- $(DEFS) $(INCLUDES) $(CXXFLAGS) -- $(SOURCES)
|
---|