DCL 3.7.4
Loading...
Searching...
No Matches
src/SQLInterBase/Makefile.dso
Go to the documentation of this file.
1
2OBJS := IBField.o IBParam.o IBQuery.o IBConnection.o IBModuleMain.o
3
4INSTALL := $(OUTPUT_ROOT)/lib
5
6ifdef __DCL_DEBUG
7 LDFLAGS += -lDCLCoreD
8 NAME := DCLInterBaseD
9else
10 LDFLAGS += -lDCLCore
11 NAME := DCLInterBase
12endif
13
14XFLAGS_ := -I$(INTERBASE)/include
15LFLAGS_ := -L$(INTERBASE)/lib -lgds
16
17ifneq ($(findstring MINGW, $(UNAME)),)
18 XFLAGS_ := -I$(INTERBASE)/SDK/include
19 LFLAGS_ := -libclient64
20 TARGET := $(NAME).dll
21else ifneq ($(findstring AIX, $(UNAME)),)
22 SONAME := $(NAME).so
23 TARGET := $(SONAME).$(VERSION)
24 LDFLAGS := -Wl,-G,-brtl $(LDFLAGS)
25else ifneq ($(findstring Darwin, $(UNAME)),)
26 SONAME := $(NAME).dylib
27 TARGET := $(SONAME).$(VERSION)
28 LDFLAGS := -dynamiclib $(LDFLAGS)
29else
30 SONAME := $(NAME).so
31 TARGET := $(SONAME).$(VERSION)
32 LDFLAGS := -Wl,-soname,$(SONAME) $(LDFLAGS)
33endif
34
35CXFLAGS += $(XFLAGS_)
36LDFLAGS += $(LFLAGS_)
37
38all: $(TARGET) install
39
40$(TARGET): $(OBJS)
41 $(LD) $(OBJS) -shared $(LDFLAGS) -o $(TARGET)
42
43install:
44 $(CP) $(TARGET) $(INSTALL)/$(TARGET)
45ifdef SONAME
46 cd $(INSTALL); $(LN) -sf $(TARGET) $(SONAME)
47endif
48
49clean:
50 $(RM) -f $(OBJS) $(TARGET)