Ticket #48862: patch-Makefile.diff
File patch-Makefile.diff, 2.8 KB (added by ryandesign (Ryan Carsten Schmidt), 9 years ago) |
---|
-
Makefile
old new 33 33 # define macros 34 34 dylib = dylib 35 35 dynamiclib = -dynamiclib 36 installname = -install_name ${prefix}/lib/ 36 37 bindir = bin 37 38 objdir = obj 38 39 ipath=$(prefix)/bin 39 40 CBASEFLAGS = -W -Wall -fno-rtti -fno-exceptions 40 UNIVFLAGS = -arch i386 -arch x86_6441 41 JAVAINCS = -I/System/Library/Frameworks/JavaVM.framework/Headers 42 42 CXX = clang++ 43 INSTALL=install -o $(USER) -g wheel43 INSTALL=install 44 44 # INSTALL=install -o 0 -g 0 45 45 46 46 # set debug directories for DEBUG=1 on the command line … … 53 53 ifdef linux 54 54 dylib = so 55 55 dynamiclib = -shared 56 installname = -Wl,-soname, 56 57 JAVAINCS = -I$(JAVA_HOME)/include 57 58 endif 58 59 … … 125 126 shared: libastyle-2.05.1.$(dylib) 126 127 libastyle-2.05.1.$(dylib): $(OBJs) 127 128 @ mkdir -p $(bindir) 128 $(CXX) $(dynamiclib) $( LDFLAGSr) $(UNIVFLAGS) -o $(bindir)/$@ $^129 $(CXX) $(dynamiclib) $(installname)libastyle-2.05.1.$(dylib) $(LDFLAGSr) $(UNIVFLAGS) -o $(bindir)/$@ $^ 129 130 @ echo 130 131 131 132 static: libastyle.a … … 137 138 java: libastyle-2.05.1j.$(dylib) 138 139 libastyle-2.05.1j.$(dylib): $(OBJsj) 139 140 @ mkdir -p $(bindir) 140 $(CXX) $(dynamiclib) $( LDFLAGSr) $(UNIVFLAGS) -o $(bindir)/$@ $^141 $(CXX) $(dynamiclib) $(installname)libastyle-2.05.1j.$(dylib) $(LDFLAGSr) $(UNIVFLAGS) -o $(bindir)/$@ $^ 141 142 @ echo 142 143 143 144 all: release static shared … … 148 149 cleanobj: 149 150 rm -f $(objdir)/*.o 150 151 151 install: 152 $(INSTALL) -m 755 -d $( ipath)153 @$(INSTALL) -m 755 $(bindir)/astyle$(ipath)152 install: release 153 $(INSTALL) -m 755 -d $(DESTDIR)$(ipath) 154 $(INSTALL) -m 755 $(bindir)/astyle $(DESTDIR)$(ipath) 154 155 155 @if [ -d $( SYSCONF_PATH)/html ]; then \156 rm -rf $( SYSCONF_PATH)/html; \156 @if [ -d $(DESTDIR)$(SYSCONF_PATH)/html ]; then \ 157 rm -rf $(DESTDIR)$(SYSCONF_PATH)/html; \ 157 158 fi 158 159 159 $(INSTALL) -m 755 -d $( SYSCONF_PATH)160 @mkdir -p $( SYSCONF_PATH)/html;160 $(INSTALL) -m 755 -d $(DESTDIR)$(SYSCONF_PATH) 161 @mkdir -p $(DESTDIR)$(SYSCONF_PATH)/html; 161 162 @for files in ../../doc/*.html ../../doc/*.css; \ 162 163 do \ 163 $(INSTALL) -m 644 $$files $( SYSCONF_PATH)/html; \164 $(INSTALL) -m 644 $$files $(DESTDIR)$(SYSCONF_PATH)/html; \ 164 165 done 165 166 166 @if [ -d $( SYSCONF_PATH_OLD) ]; then \167 rm -rf $( SYSCONF_PATH_OLD); \167 @if [ -d $(DESTDIR)$(SYSCONF_PATH_OLD) ]; then \ 168 rm -rf $(DESTDIR)$(SYSCONF_PATH_OLD); \ 168 169 fi 169 170 171 install-lib: static shared 172 $(INSTALL) -m 755 -d $(DESTDIR)$(prefix)/lib 173 $(INSTALL) $(bindir)/libastyle.a $(bindir)/libastyle-2.05.1.$(dylib) $(DESTDIR)$(prefix)/lib 174 ln -s libastyle-2.05.1.$(dylib) $(DESTDIR)$(prefix)/lib/libastyle.$(dylib) 175 176 install-jnilib: java 177 $(INSTALL) -m 755 -d $(DESTDIR)$(prefix)/lib 178 $(INSTALL) $(bindir)/libastyle-2.05.1j.$(dylib) $(DESTDIR)$(prefix)/lib 179 ln -s libastyle-2.05.1j.$(dylib) $(DESTDIR)$(prefix)/lib/libastylej.$(dylib) 180 170 181 uninstall: 171 182 rm -f $(ipath)/astyle 172 183 rm -rf $(SYSCONF_PATH)