From 013060a06fd5bc93ee392347d0e5805aa5c6206d Mon Sep 17 00:00:00 2001 From: Yuichi Nishiwaki Date: Tue, 29 Oct 2013 15:53:04 +0900 Subject: [PATCH] fix the order of gcc command line args; -lfoo must be later than src/*.c --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index a50c5cbc..a279c7f0 100644 --- a/Makefile +++ b/Makefile @@ -5,13 +5,13 @@ all: build run build: build-lib build-main build-main: - $(CC) -Wall -g -o bin/picrin -I./include -L./lib -lpicrin -lreadline tools/main.c + $(CC) -Wall -g tools/main.c -o bin/picrin -I./include -L./lib -lpicrin -lreadline build-lib: cd src; \ yacc -d parse.y; \ lex scan.l - $(CC) -Wall -g -shared -o lib/libpicrin.so -I./include -I./extlib src/*.c + $(CC) -Wall -g -shared src/*.c -o lib/libpicrin.so -I./include -I./extlib clean: rm -f src/y.tab.c src/y.tab.h src/lex.yy.c