Mercurial > dwindows
view Makefile.in @ 1313:9f12bc79924b
Autorelease fixes for Mac allowing the objects to dealloc when destroyed.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Fri, 04 Nov 2011 12:30:23 +0000 |
parents | 924c8087a755 |
children | 751f127439f7 |
line wrap: on
line source
srcdir=@srcdir@ mandir=@mandir@ CC = @CC@ PLATCCFLAGS = @PLATCCFLAGS@ MLFLAGS = -L. # # Uncomment DEPRECATED line to force use of GTK 3.x support # #DEPRECATED = -DG_DISABLE_DEPRECATED -DG_DISABLE_SINGLE_INCLUDES -DGTK_DISABLE_DEPRECATED -DGTK_DISABLE_SINGLE_INCLUDES -DGDK_DISABLE_DEPRECATED -DGDK_DISABLE_SINGLE_INCLUDES CCFLAGS = $(DEPRECATED) @CFLAGS@ $(PLATCCFLAGS) @ARCH@ -D@DW_DEFINE@ -DBUILD_DLL -DDW_RESOURCES -DVER_REV=$(VER_REV) LFLAGS = @LIBS@ @ARCH@ ARFLAGS = @ARFLAGS@ INSTALL = @INSTALL@ DW_SRC = @DW_SRC@ DW_DIR = @DW_DIR@ INCPATH = -I.. -I. -I$(srcdir) TARGET = @TARGET@ SRCS = $(srcdir)/$(DW_DIR)/$(DW_SRC) BROWSER_OBJECT=@BROWSER_OBJECT@ COMPAT_OBJECT=@COMPAT_OBJECT@ INSTALL_COMPAT=@INSTALL_COMPAT@ OBJECTS = dw.o $(BROWSER_OBJECT) SRCS2 = $(srcdir)compat.c OBJECTS2= $(COMPAT_OBJECT) TARGET2= @TARGET2@ TARGETS = @TARGETS@ VER_MAJ = @DW_MAJOR_VERSION@ VER_MIN = @DW_MINOR_VERSION@ VER_REV = @SVNVERSION@ SOSUFFIX= @SOSUFFIX@ SONAME= @SONAME@ LIBPREFIX = @LIBPREFIX@ LIBSUFFIX = @LIBSUFFIX@ prefix = $(DESTDIR)@prefix@ SRCDIR=dwindows-$(VER_MAJ).$(VER_MIN) #.SUFFIXES: .c .h #.c.o: # $(CC) -c $(CCFLAGS) $(INCPATH) -o $@ $< # Link flags shared objects SYSCONF_LFLAGS_SHOBJ = @SHAREDFLAG@ # Linking shared libraries # - Build the $(TARGET) library, eg. lib$(TARGET).so.0.0 # - Usually needs to incorporate $(VER_MAJ) and $(VER_MIN) # SYSCONF_LINK_SHLIB = gcc SYSCONF_LINK_TARGET_SHARED = @SYSCONF_LINK_TARGET_SHARED@ SYSCONF_LINK_LIB_SHARED = $(SYSCONF_LINK_SHLIB) $(SYSCONF_LFLAGS_SHOBJ) \ -o $(SYSCONF_LINK_TARGET_SHARED) \ $(OBJECTS) $(LFLAGS) $(SONAME); \ rm -f lib$(TARGET).$(SOSUFFIX) lib$(TARGET).$(SOSUFFIX).$(VER_MAJ); \ ln -s $(SYSCONF_LINK_TARGET_SHARED) lib$(TARGET).$(SOSUFFIX); \ ln -s $(SYSCONF_LINK_TARGET_SHARED) lib$(TARGET).$(SOSUFFIX).$(VER_MAJ) SYSCONF_LINK_TARGET_SHARED2 = @SYSCONF_LINK_TARGET_SHARED2@ SYSCONF_LINK_LIB_SHARED2 = $(SYSCONF_LINK_SHLIB) $(SYSCONF_LFLAGS_SHOBJ) \ -o $(SYSCONF_LINK_TARGET_SHARED2) \ $(OBJECTS2) $(LFLAGS); \ rm -f lib$(TARGET2).$(SOSUFFIX) lib$(TARGET2).$(SOSUFFIX).$(VER_MAJ); \ ln -s $(SYSCONF_LINK_TARGET_SHARED2) lib$(TARGET2).$(SOSUFFIX); \ ln -s $(SYSCONF_LINK_TARGET_SHARED2) lib$(TARGET2).$(SOSUFFIX).$(VER_MAJ) # Linking static libraries # - Build the $(TARGET) library, eg. lib$(TARGET).a # SYSCONF_AR = ar $(ARFLAGS) SYSCONF_LINK_TARGET_STATIC = @SYSCONF_LINK_TARGET_STATIC@ SYSCONF_LINK_LIB_STATIC = rm -f $(SYSCONF_LINK_TARGET_STATIC) ; \ $(SYSCONF_AR) $(SYSCONF_LINK_TARGET_STATIC) $(OBJECTS) ####### Build rules SYSCONF_LINK_TARGET = $(SYSCONF_LINK_TARGET_SHARED) SYSCONF_LINK_LIB = $(SYSCONF_LINK_LIB_SHARED) SYSCONF_LINK_TARGET2 = $(SYSCONF_LINK_TARGET_SHARED2) SYSCONF_LINK_LIB2 = $(SYSCONF_LINK_LIB_SHARED2) all: $(TARGETS) dwtest install: installbase $(INSTALL_COMPAT) installbase: $(SYSCONF_LINK_TARGET) $(INSTALL) -d $(prefix)/include; \ $(INSTALL) -d $(prefix)/lib; \ $(INSTALL) -d $(prefix)/bin; \ $(INSTALL) -d $(prefix)/share/man/man1; \ $(INSTALL) $(srcdir)/dw.h $(prefix)/include; \ $(INSTALL) dwindows-config $(prefix)/bin; \ $(INSTALL) $(srcdir)/dwindows-config.1 $(prefix)/share/man/man1; \ cd $(prefix)/share/man/man1; gzip -f -9 dwindows-config.1 $(INSTALL) $(SYSCONF_LINK_TARGET) $(prefix)/lib; \ cd $(prefix)/lib; \ rm -f lib$(TARGET).so lib$(TARGET).so.$(VER_MAJ); \ ln -sf $(SYSCONF_LINK_TARGET_SHARED) lib$(TARGET).$(SOSUFFIX); \ ln -sf $(SYSCONF_LINK_TARGET_SHARED) lib$(TARGET).$(SOSUFFIX).$(VER_MAJ) installcompat: $(SYSCONF_LINK_TARGET2) $(INSTALL) -d $(prefix)/lib; \ $(INSTALL) $(SYSCONF_LINK_TARGET2) $(prefix)/lib; \ $(INSTALL) $(srcdir)/compat.h $(prefix)/include; \ cd $(prefix)/lib; \ rm -f lib$(TARGET2).$(SOSUFFIX) lib$(TARGET2).$(SOSUFFIX).$(VER_MAJ); \ ln -sf $(SYSCONF_LINK_TARGET_SHARED2) lib$(TARGET2).$(SOSUFFIX); \ ln -sf $(SYSCONF_LINK_TARGET_SHARED2) lib$(TARGET2).$(SOSUFFIX).$(VER_MAJ) deb: dist -rm -fr tmp -mkdir tmp (cd tmp;tar zxvf ../../$(srcdir)/$(SRCDIR).tar.gz;cd $(SRCDIR);dpkg-buildpackage -rfakeroot;cd ..;ls -l) distclean: clean rm -f config.status clean: rm -f *.$(SOSUFFIX) rm -f *.$(SOSUFFIX).* rm -f *.o rm -f *~ rm -f *.a rm -f $(DW_DIR)/*.o rm -f dwtest $(SYSCONF_LINK_TARGET2): $(OBJECTS2) $(SYSCONF_LINK_LIB2) $(SYSCONF_LINK_TARGET): $(OBJECTS) $(SYSCONF_LINK_LIB) $(SYSCONF_LINK_TARGET_STATIC): $(OBJECTS) $(SYSCONF_LINK_LIB_STATIC) dw.o: $(srcdir)/$(DW_DIR)/$(DW_SRC) $(srcdir)/dw.h $(CC) -c $(INCPATH) $(CCFLAGS) -o $@ $(srcdir)/$(DW_DIR)/$(DW_SRC) browser.o: $(srcdir)/$(DW_DIR)/browser.cpp $(srcdir)/dw.h $(CXX) -c $(INCPATH) $(CCFLAGS) -o $@ $(srcdir)/$(DW_DIR)/browser.cpp compat.o: $(srcdir)/compat.c $(CC) -c $(INCPATH) $(CCFLAGS) -o $@ $(srcdir)/compat.c dwtest.o: $(srcdir)/dwtest.c $(srcdir)/dw.h $(CC) -c $(INCPATH) $(CCFLAGS) -o $@ $(srcdir)/dwtest.c dwtest: dwtest.o $(CC) -o dwtest dwtest.o $(MLFLAGS) -l$(TARGET) $(LFLAGS) -chmod +x $(srcdir)/mac/finishup.sh -$(srcdir)/mac/finishup.sh $(srcdir) zip: zip dwindows$(VER_MAJ)$(VER_MIN).zip $(srcdir)/license.txt $(srcdir)/makefile.* $(srcdir)/readme $(srcdir)/*.c $(srcdir)/dw.h $(srcdir)/compat.h \ $(srcdir)/*.def $(srcdir)/install.sh $(srcdir)/*.in $(srcdir)/configure \ $(srcdir)/ac*.m4 $(srcdir)/dwindows-config.1 \ $(srcdir)/gtk/*.c $(srcdir)/gtk/*.cpp $(srcdir)/win/*.c $(srcdir)/os2/*.c $(srcdir)/win/*.txt $(srcdir)/os2/*.txt \ $(srcdir)/gtk/*.xpm $(srcdir)/win/*.ico $(srcdir)/os2/*.ico \ $(srcdir)/mac/Info.plist $(srcdir)/mac/PkgInfo $(srcdir)/mac/*.c $(srcdir)/mac/*.m $(srcdir)/mac/dwtest.r $(srcdir)/mac/finishup.sh \ $(srcdir)/platform/*.h \ $(srcdir)/debian/control $(srcdir)/debian/rules $(srcdir)/debian/copyright $(srcdir)/debian/compat $(srcdir)/debian/changelog dist: (cd $(srcdir)/..;ln -sf dwindows $(SRCDIR)) (cd $(srcdir)/..;tar -cvf - $(SRCDIR)/license.txt $(SRCDIR)/makefile.* $(SRCDIR)/readme $(SRCDIR)/*.c $(SRCDIR)/dw.h $(SRCDIR)/compat.h \ $(SRCDIR)/*.def $(SRCDIR)/install.sh $(SRCDIR)/*.in $(SRCDIR)/configure \ $(SRCDIR)/ac*.m4 $(SRCDIR)/dwindows-config.1 $(SRCDIR)/config.sub $(SRCDIR)/config.guess \ $(SRCDIR)/gtk/*.c $(SRCDIR)/gtk/*.cpp $(SRCDIR)/win/*.c $(SRCDIR)/win/*.cpp $(SRCDIR)/os2/*.c $(SRCDIR)/win/*.txt $(SRCDIR)/os2/*.txt \ $(SRCDIR)/gtk/*.xpm $(SRCDIR)/gtk3/*.c $(SRCDIR)/image/test.* $(SRCDIR)/win/*.ico $(SRCDIR)/os2/*.ico \ $(SRCDIR)/mac/Info.plist $(SRCDIR)/mac/PkgInfo $(SRCDIR)/mac/*.m $(SRCDIR)/mac/finishup.sh $(SRCDIR)/mac/*.png \ $(SRCDIR)/debian/control $(SRCDIR)/debian/rules $(SRCDIR)/debian/copyright $(SRCDIR)/debian/compat $(SRCDIR)/debian/changelog \ $(SRCDIR)/platform/*.h | gzip > $(SRCDIR).tar.gz ) (cd $(srcdir)/..;rm -f $(SRCDIR))