Commit e3c0e7ebde664b38049cd57ad50edfedca829c55
1 parent
74a194f2
Exists in
master
and in
5 other branches
Finalizando classe de apoio
Showing
2 changed files
with
29 additions
and
1 deletions
Show diff stats
Makefile.in
| @@ -286,6 +286,9 @@ install-plugins: $(foreach PLUGIN, $(PLUGINS), $(BINDIR)/Release/plugins/$(PLUGI | @@ -286,6 +286,9 @@ install-plugins: $(foreach PLUGIN, $(PLUGINS), $(BINDIR)/Release/plugins/$(PLUGI | ||
| 286 | install-lib: $(BINDIR)/Release@DLLDIR@/lib3270@DLLEXT@ | 286 | install-lib: $(BINDIR)/Release@DLLDIR@/lib3270@DLLEXT@ |
| 287 | @$(MAKE) BINRLS="../../.bin/Release@DLLDIR@" -C src/lib3270 install | 287 | @$(MAKE) BINRLS="../../.bin/Release@DLLDIR@" -C src/lib3270 install |
| 288 | 288 | ||
| 289 | +install-classlib: | ||
| 290 | + @$(MAKE) BINRLS="../../.bin/Release" -C src/classlib install | ||
| 291 | + | ||
| 289 | locale: $(foreach MO, $(basename $(LANG_FILES)), $(BINDIR)/Release/$(localedir)/$(notdir $(MO))/LC_MESSAGES/$(PACKAGE_NAME).mo) | 292 | locale: $(foreach MO, $(basename $(LANG_FILES)), $(BINDIR)/Release/$(localedir)/$(notdir $(MO))/LC_MESSAGES/$(PACKAGE_NAME).mo) |
| 290 | 293 | ||
| 291 | install-locale: $(foreach MO, $(basename $(LANG_FILES)), $(BINDIR)/Release/$(localedir)/$(notdir $(MO))/LC_MESSAGES/$(PACKAGE_NAME).mo) | 294 | install-locale: $(foreach MO, $(basename $(LANG_FILES)), $(BINDIR)/Release/$(localedir)/$(notdir $(MO))/LC_MESSAGES/$(PACKAGE_NAME).mo) |
src/classlib/Makefile.in
| @@ -24,7 +24,8 @@ | @@ -24,7 +24,8 @@ | ||
| 24 | # erico.mendonca@gmail.com (Erico Mascarenhas de Mendonça) | 24 | # erico.mendonca@gmail.com (Erico Mascarenhas de Mendonça) |
| 25 | # | 25 | # |
| 26 | 26 | ||
| 27 | -LIBNAME=pw3270cxx.a | 27 | +PACKAGE=@PACKAGE_NAME@ |
| 28 | +LIBNAME=$(PACKAGE)cxx.a | ||
| 28 | 29 | ||
| 29 | #---[ Sources ]---------------------------------------------------------------- | 30 | #---[ Sources ]---------------------------------------------------------------- |
| 30 | 31 | ||
| @@ -32,6 +33,9 @@ SOURCES=main.cc session.cc exception.cc local.cc remote.cc | @@ -32,6 +33,9 @@ SOURCES=main.cc session.cc exception.cc local.cc remote.cc | ||
| 32 | 33 | ||
| 33 | #---[ Paths ]------------------------------------------------------------------ | 34 | #---[ Paths ]------------------------------------------------------------------ |
| 34 | 35 | ||
| 36 | +prefix=@prefix@ | ||
| 37 | +datarootdir=@datarootdir@ | ||
| 38 | + | ||
| 35 | ROOTDIR ?= . | 39 | ROOTDIR ?= . |
| 36 | OBJDIR ?= $(ROOTDIR)/.obj | 40 | OBJDIR ?= $(ROOTDIR)/.obj |
| 37 | BINDIR ?= $(ROOTDIR)/.bin | 41 | BINDIR ?= $(ROOTDIR)/.bin |
| @@ -45,6 +49,8 @@ OBJRLS = $(OBJDIR)/Release | @@ -45,6 +49,8 @@ OBJRLS = $(OBJDIR)/Release | ||
| 45 | 49 | ||
| 46 | MKDIR=@MKDIR_P@ | 50 | MKDIR=@MKDIR_P@ |
| 47 | LN_S=@LN_S@ | 51 | LN_S=@LN_S@ |
| 52 | +INSTALL=@INSTALL@ | ||
| 53 | +INSTALL_DATA=$(INSTALL) -m 644 | ||
| 48 | 54 | ||
| 49 | #---[ Flags ]------------------------------------------------------------------ | 55 | #---[ Flags ]------------------------------------------------------------------ |
| 50 | 56 | ||
| @@ -60,11 +66,30 @@ LD=@CXX@ | @@ -60,11 +66,30 @@ LD=@CXX@ | ||
| 60 | 66 | ||
| 61 | DEPENDS=../include/*.h ../include/lib3270/*.h ../include/pw3270/*.h Makefile | 67 | DEPENDS=../include/*.h ../include/lib3270/*.h ../include/pw3270/*.h Makefile |
| 62 | 68 | ||
| 69 | +#---[ Rules ]------------------------------------------------------------------ | ||
| 70 | + | ||
| 63 | $(OBJDBG)/%.o: %.cc $(DEPENDS) | 71 | $(OBJDBG)/%.o: %.cc $(DEPENDS) |
| 64 | @echo " CC `basename $@`" | 72 | @echo " CC `basename $@`" |
| 65 | @$(MKDIR) `dirname $@` | 73 | @$(MKDIR) `dirname $@` |
| 66 | @$(CXX) $(CFLAGS) $(DEBUG_CFLAGS) -o $@ -c $< | 74 | @$(CXX) $(CFLAGS) $(DEBUG_CFLAGS) -o $@ -c $< |
| 67 | 75 | ||
| 76 | +$(OBJRLS)/%.o: %.cc $(DEPENDS) | ||
| 77 | + @echo " CC `basename $@`" | ||
| 78 | + @$(MKDIR) `dirname $@` | ||
| 79 | + @$(CXX) $(CFLAGS) -o $@ -c $< | ||
| 80 | + | ||
| 81 | +#---[ Release targets ]-------------------------------------------------------- | ||
| 82 | + | ||
| 83 | +Release: $(BINRLS)/$(LIBNAME) | ||
| 84 | + | ||
| 85 | +$(BINRLS)/$(LIBNAME): $(foreach SRC, $(basename $(SOURCES)), $(OBJRLS)/$(SRC).o) | ||
| 86 | + @echo " CCLD `basename $@`" | ||
| 87 | + @$(MKDIR) `dirname $@` | ||
| 88 | + @ar rs $@ $^ | ||
| 89 | + | ||
| 90 | +install: Release | ||
| 91 | + @$(MKDIR) $(DESTDIR)$(datarootdir)/$(PACKAGE) | ||
| 92 | + @$(INSTALL_DATA) $(BINRLS)/$(LIBNAME) $(DESTDIR)$(datarootdir)/$(PACKAGE) | ||
| 68 | 93 | ||
| 69 | #---[ Debug targets ]---------------------------------------------------------- | 94 | #---[ Debug targets ]---------------------------------------------------------- |
| 70 | 95 |