Copy library instead of building it directly
This commit is contained in:
parent
83b2cb465e
commit
b872a8db15
|
@ -79,11 +79,6 @@ $(OUTPUT_DIR)/%.o: $$(subst !super,..,%.s)
|
||||||
@mkdir -p $(dir $@)
|
@mkdir -p $(dir $@)
|
||||||
$(CC) $(ARCHFLAGS) -I$(PCSX_REDUX) -g -c -o $@ $<
|
$(CC) $(ARCHFLAGS) -I$(PCSX_REDUX) -g -c -o $@ $<
|
||||||
|
|
||||||
#Linking rule
|
|
||||||
$(TARGET).a: $(OBJS)
|
|
||||||
@mkdir -p $(dir $@)
|
|
||||||
$(AR) rcs $(TARGET).a $(OBJS)
|
|
||||||
|
|
||||||
$(TARGET).elf: $(OBJS)
|
$(TARGET).elf: $(OBJS)
|
||||||
$(LD) -o $(TARGET).elf $(LDFLAGS_all) $(LDFLAGS) $(OBJS) $(LIBS_all) $(LIBS)
|
$(LD) -o $(TARGET).elf $(LDFLAGS_all) $(LDFLAGS) $(OBJS) $(LIBS_all) $(LIBS)
|
||||||
|
|
||||||
|
|
|
@ -1,13 +1,24 @@
|
||||||
ARTIFACT = libJabyEngine
|
ARTIFACT = libJabyEngine
|
||||||
BUILD_DIR = ../../lib
|
BUILD_DIR = bin
|
||||||
|
|
||||||
include ../../lib/Wildcard.mk
|
include ../../lib/Wildcard.mk
|
||||||
SRCS = $(call rwildcard, src, c cpp)
|
SRCS = $(call rwildcard, src, c cpp)
|
||||||
|
|
||||||
include ../../lib/Makefile
|
include ../../lib/Makefile
|
||||||
|
LIB_DIR = ../../lib/$(CONFIG_NAME)
|
||||||
|
|
||||||
|
#Linking rule
|
||||||
|
$(TARGET).a: $(OBJS)
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
$(AR) rcs $(TARGET).a $(OBJS)
|
||||||
|
|
||||||
|
$(LIB_DIR)/$(ARTIFACT).a: $(TARGET).a
|
||||||
|
@mkdir -p $(LIB_DIR)
|
||||||
|
cp $(TARGET).a $(LIB_DIR)/$(ARTIFACT).a
|
||||||
|
|
||||||
#Rules section for default compilation and linking
|
#Rules section for default compilation and linking
|
||||||
all: $(TARGET).a
|
all: $(LIB_DIR)/$(ARTIFACT).a
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -fr $(OUTPUT_DIR)
|
rm -fr $(OUTPUT_DIR)
|
||||||
|
rm -fr $(LIB_DIR)/$(ARTIFACT).a
|
Loading…
Reference in New Issue