source: trunk/Makefile @ 155

Last change on this file since 155 was 147, checked in by tim, 16 years ago

added talloc library

incorporated talloc into winsec and lru_cache modules

introduced talloc into SK caching system

  • Property svn:keywords set to Id
File size: 1.5 KB
RevLine 
[13]1# $Id: Makefile 147 2009-02-22 19:31:52Z tim $
[5]2
[13]3# Installation prefixes.  Change to install elsewhere.
[5]4
5PREFIX=/usr/local
[13]6BIN_PREFIX=$(PREFIX)/bin
7DOC_PREFIX=$(PREFIX)/share/doc/reglookup
8MAN_PREFIX=$(PREFIX)/man
[5]9
10################################################################################
11
12CC=gcc
[145]13OPTS=-std=gnu89 -pedantic -Wall -ggdb
14#OPTS=-std=gnu89 -pedantic -Wall
[147]15INC:=-I$(PWD)/include -I/usr/local/include
[98]16LIB=-L/usr/local/lib -lm
[143]17BIN_EXT=
18EXTRA_OBJ=
[5]19
[73]20UNAME := $(shell uname)
[88]21ifneq ($(UNAME),Linux) 
[74]22  LIB:=$(LIB) -liconv
[73]23endif
24
[144]25
26################################################################################
27# MinGW cross-compiling build settings
[143]28ifdef BUILD_MINGW
[144]29
30## These may need to be changed
[143]31CC=i586-mingw32msvc-cc
[144]32LIBICONV_PATH=/usr/local/src/libiconv-1.9.2-1-lib
33
34## These probably do not need to be changed
[143]35BIN_EXT=.exe
36INC:=$(INC) -I$(LIBICONV_PATH)/include
37EXTRA_OBJ=$(LIBICONV_PATH)/lib/libiconv.dll.a
[144]38
[143]39endif
[144]40################################################################################
[143]41
[144]42
[5]43BUILD=$(CURDIR)/build
44BUILD_BIN=$(BUILD)/bin
[9]45BUILD_DOC=$(BUILD)/doc
[5]46
[21]47BUILD_TREE=$(BUILD_BIN) $(BUILD_DOC)
[65]48SUB_DIRS=lib src doc bin
[5]49
50FILES=$(REGLOOKUP)
51.PHONY: $(SUB_DIRS) clean
52export
53
54
55all: $(BUILD_TREE) $(SUB_DIRS)
56
[20]57#XXX: This should be more generalized.
[11]58install: all
[13]59        mkdir -p $(BIN_PREFIX)
60        mkdir -p $(DOC_PREFIX)
[20]61        mkdir -p $(MAN_PREFIX)/man1
[67]62        $(MAKE) -C bin install
[26]63        $(MAKE) -C src install
[25]64        $(MAKE) -C doc install
[11]65
[13]66
[5]67$(SUB_DIRS):
68        $(MAKE) -C $@
69
70$(BUILD_TREE):
71        mkdir -p $@
72
73clean:
[39]74        $(MAKE) -C src clean
75        $(MAKE) -C lib clean
[5]76        rm -rf $(BUILD)/*
Note: See TracBrowser for help on using the repository browser.