Files
znc/Makefile.in
psychon 9c4a5a1d90 Some tweaking and cleaning up to configure.in
- Make it clear to autoconf that we are C++ only. It now no longer checks for a
  C compiler which might save time on some boxes.
- Honour CPPFLAGS.
- Remove some unused vars from AC_SUBST.
- Add includes to CXXFLAGS instead of using $INCLUDES for this.
- Use autoconf macros instead of 'echo' for the 'checking for perl' message.
- Fix all warnings from 'autoconf -W all'.
- Use AC_CONFIG_SRCDIR for helping configure find the source dir.


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1251 726aef4b-f618-498e-8847-2d620e286838
2008-10-15 18:36:08 +00:00

67 lines
1.7 KiB
Makefile

prefix := @prefix@
exec_prefix := @exec_prefix@
datarootdir := @datarootdir@
bindir := @bindir@
datadir := @datadir@
sysconfdir := @sysconfdir@
libdir := @libdir@
sbindir := @sbindir@
localstatedir := @localstatedir@
CXX := @CXX@
CXXFLAGS := @CPPFLAGS@ @CXXFLAGS@
LDFLAGS := @LDFLAGS@
LIBS := @LIBS@
SRCS := ZNCString.cpp Csocket.cpp main.cpp znc.cpp User.cpp IRCSock.cpp Client.cpp DCCBounce.cpp \
DCCSock.cpp Chan.cpp Nick.cpp Server.cpp Modules.cpp MD5.cpp Buffer.cpp Utils.cpp \
FileUtils.cpp HTTPSock.cpp Template.cpp ClientCommand.cpp
OBJS := $(patsubst %cpp,%o,$(SRCS))
CLEAN := znc *.o core core.*
DISTCLEAN := Makefile config.log config.status znc-config znc-buildmod .depend \
modules/.depend modules/Makefile man/Makefile
.PHONY: all man modules clean distclean install
all: znc man @MODTARGET@
znc: $(OBJS)
$(CXX) $(LDFLAGS) -o $@ $(OBJS) $(LIBS)
man:
@$(MAKE) -C man
modules:
@if test -n "@MODTARGET@"; then \
$(MAKE) -C modules; \
else \
echo "Modules are not enabled"; \
fi
clean:
rm -rf $(CLEAN)
@if test -n "@MODTARGET@"; then \
$(MAKE) -C modules clean; \
fi
@$(MAKE) -C man clean
distclean: clean
rm -rf $(DISTCLEAN)
%.o: %.cpp Makefile
@mkdir -p .depend
$(CXX) $(CXXFLAGS) -c -o $@ $< -MMD -MF .depend/$<.dep
install: znc
mkdir -p $(DESTDIR)$(bindir)
mkdir -p $(DESTDIR)$(prefix)/include/znc
install -m 0755 znc $(DESTDIR)$(bindir)
install -m 0755 znc-config $(DESTDIR)$(bindir)
install -m 0755 znc-buildmod $(DESTDIR)$(bindir)
install -m 0644 *.h $(DESTDIR)$(prefix)/include/znc
@if test -n "@MODTARGET@"; then \
$(MAKE) -C modules install DESTDIR=$(DESTDIR); \
fi
@$(MAKE) -C man install DESTDIR=$(DESTDIR)
-include $(wildcard .depend/*.dep)