diff options
author | William Pitcock <nenolod@dereferenced.org> | 2017-06-14 18:36:10 +0000 |
---|---|---|
committer | William Pitcock <nenolod@dereferenced.org> | 2017-06-14 18:36:10 +0000 |
commit | 918682c02bce090b0a8bd224883b38783ff0f8b0 (patch) | |
tree | 93e583ba2779b191cf453f62e19d76175618c25d /Makefile | |
parent | d059c61022230a89467e3aaf6475a53d5f2bbdf5 (diff) | |
download | gcompat-918682c02bce090b0a8bd224883b38783ff0f8b0.tar.gz gcompat-918682c02bce090b0a8bd224883b38783ff0f8b0.tar.bz2 gcompat-918682c02bce090b0a8bd224883b38783ff0f8b0.tar.xz gcompat-918682c02bce090b0a8bd224883b38783ff0f8b0.zip |
build system: add install target, fix loader build rules
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -28,11 +28,15 @@ all: ${LIBGCOMPAT_NAME} ${LOADER_NAME} ${LIBGCOMPAT_NAME}: ${LIBGCOMPAT_OBJ} gcc -o ${LIBGCOMPAT_NAME} -Wl,-soname,${LIBGCOMPAT_NAME} -shared ${LIBGCOMPAT_OBJ} -${LIBGCOMPAT_NAME}: ${LIBGCOMPAT_OBJ} - gcc -o ${LIBGCOMPAT_NAME} -Wl,-soname,${LIBGCOMPAT_NAME} -shared ${LIBGCOMPAT_OBJ} +${LOADER_NAME}: ${LOADER_OBJ} + gcc -o ${LOADER_NAME} -fPIE -static ${LOADER_OBJ} .c.o: gcc -fPIC -DPIC -DLINKER=\"${LINKER_PATH}\" -DLIBGCOMPAT=\"${LIBGCOMPAT_PATH}\" ${CFLAGS} ${CPPFLAGS} -c -o $@ $< clean: rm -f libgcompat/*.o loader/*.o ${LIBGCOMPAT_NAME} ${LOADER_NAME} + +install: all + install -D -m755 ${LIBGCOMPAT_NAME} ${DESTDIR}/${LIBGCOMPAT_PATH} + install -D -m755 ${LOADER_NAME} ${DESTDIR}/${LOADER_PATH} |