generating shared library stuff

master
Rachel Fae Fox (foxiepaws) 2020-03-10 00:26:32 -04:00
parent f4c40b254b
commit 966746932d
2 changed files with 30 additions and 5 deletions

View File

@ -22,7 +22,7 @@ OBJ = ${SRC:${SRCDIR}/%.cpp=${OBJDIR}/%.o}
BINS = $(wildcard ${SRCDIR}/*.cpp)
ALLOBJ = ${SRC:${SRCDIR}/%.cpp=${OBJDIR}/%.o} ${BINS:${SRCDIR}/%.cpp=${OBJDIR}/%.o}
all: fmtest wavtest
all: fmtest wavtest amalgam
${ALLOBJ}: $(OBJDIR)/%.o : $(SRCDIR)/%.cpp
@mkdir -p $(dir $@)
@ -37,10 +37,17 @@ wavtest: ${ALLOBJ}
@mkdir -p ${BINDIR}
${CXX} ${INCDIR} -o ${BINDIR}/wavtest ${OBJDIR}/wavtest.o ${OBJ} ${LDFLAGS} ${CFLAGS} ${DEFINES}
${TARGET}: ${OBJ}
@echo CXX -o ${BINDIR}/${TARGET}
@mkdir -p ${BINDIR}
${CXX} ${INCDIR} -o ${BINDIR}/${TARGET} ${OBJ} ${LDFLAGS} ${CFLAGS} ${DEFINES}
amalgam.so: ${OBJ}
${CXX} ${INCDIR} -o ${BINDIR}/${TARGET}.so ${OBJ} --shared -fPIC ${LDFLAGS} ${CFLAGS} ${DEFINES}
amalgam.dylib: ${OBJ}
${CXX} ${INCDIR} -o ${BINDIR}/${TARGET}.dylib ${OBJ} -dynamiclib ${LDFLAGS} ${CFLAGS} ${DEFINES}
ifeq (${UNAME},Darwin)
amalgam: amalgam.dylib
else
amalgam: amalgam.so
endif
clean:
@echo cleaning

18
src/FM/Engine.cpp Normal file
View File

@ -0,0 +1,18 @@
/*
* Filename: Engine.cpp
*
* Description:
*
*
* Version:
* Created: Mon Mar 9 23:53:38 2020
* Revision: None
* Author: Rachel Fae Fox (foxiepaws),fox@foxiepa.ws
*
*/
#include "Engine.h"
template class FM::Engine<2>;
template class FM::Engine<4>;
template class FM::Engine<6>;
template class FM::Engine<8>;