4b047a51f3
WWW: https://code.google.com/p/ghostplusplus/ PR: ports/154764 Submitted by: ports@c0decafe.net
39 lines
969 B
Text
39 lines
969 B
Text
--- Makefile
|
|
+++ Makefile
|
|
@@ -1,17 +1,15 @@
|
|
SHELL = /bin/sh
|
|
SYSTEM = $(shell uname)
|
|
-CXX = g++
|
|
-CXXFLAGS = -Wall -O3 -I ../ -Wno-multichar -fPIC
|
|
+CXXFLAGS = $(CFLAGS) -I ../ -Wno-multichar -fPIC
|
|
CXXOBJ = bsha1.o cdkeydecoder.o checkrevision.o decodekey.o file.o libinfo.o oldauth.o
|
|
-CC = gcc
|
|
-CCFLAGS = -Wall -O3 -I ../ -Wno-multichar -fPIC
|
|
+CCFLAGS = $(CFLAGS) -I ../ -Wno-multichar -fPIC
|
|
CCOBJ = nls.o pe.o sha1.o stack.o
|
|
|
|
ifeq ($(SYSTEM),Darwin)
|
|
LDFLAGS = -dynamiclib -lgmp -L/opt/local/lib
|
|
TARGET = libbncsutil.dylib
|
|
else
|
|
-LDFLAGS = -shared -lgmp
|
|
+LDFLAGS += -shared -lgmp -L/usr/local/lib
|
|
TARGET = libbncsutil.so
|
|
endif
|
|
|
|
@@ -26,11 +24,9 @@
|
|
|
|
clean:
|
|
rm -f $(CCOBJ) $(CXXOBJ) $(TARGET) *~
|
|
-all:
|
|
- make $(TARGET)
|
|
+all: $(TARGET)
|
|
|
|
install: $(TARGET)
|
|
- mkdir -p /usr/include/bncsutil
|
|
- cp *.h /usr/include/bncsutil
|
|
- cp $(TARGET) /usr/lib
|
|
- ldconfig
|
|
+ mkdir -p $(PREFIX)/include/bncsutil
|
|
+ cp *.h $(PREFIX)/include/bncsutil
|
|
+ cp $(TARGET) $(PREFIX)/lib
|