Rules.make 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. # $Id: Rules.make 532 2008-04-07 11:57:01Z pkun $
  2. TITLE := repoforge
  3. MAJOR := 0
  4. MINOR := 6
  5. BUGFIX := 0
  6. VERSION := $(MAJOR).$(MINOR).$(BUGFIX)
  7. SCRIPTS_DIR := scripts
  8. CONF_DIR := conf
  9. TARGET_PREFIX_DIR := /usr
  10. TARGET_DATA_DIR := $(TARGET_PREFIX_DIR)/share
  11. TARGET_BIN_DIR := $(TARGET_PREFIX_DIR)/bin
  12. TARGET_SBIN_DIR := $(TARGET_PREFIX_DIR)/sbin
  13. TARGET_PC_DIR := $(TARGET_DATA_DIR)/pkgconfig
  14. TARGET_CONF_DIR := /etc/repoforge
  15. DESTDIR := /
  16. INSTALL_FAKE_ROOT := $(DESTDIR)
  17. INSTALL_PREFIX_DIR := $(INSTALL_FAKE_ROOT)$(TARGET_PREFIX_DIR)
  18. INSTALL_DATA_DIR := $(INSTALL_FAKE_ROOT)$(TARGET_DATA_DIR)
  19. INSTALL_BIN_DIR := $(INSTALL_FAKE_ROOT)$(TARGET_BIN_DIR)
  20. INSTALL_SBIN_DIR := $(INSTALL_FAKE_ROOT)$(TARGET_SBIN_DIR)
  21. INSTALL_PC_DIR := $(INSTALL_FAKE_ROOT)$(TARGET_PC_DIR)
  22. INSTALL_CONF_DIR := $(INSTALL_FAKE_ROOT)$(TARGET_CONF_DIR)
  23. ifdef DEBUG
  24. DEBUG_FLAGS = -DDEBUG -ggdb -gdwarf-2 -g3
  25. OPT_FLAGS =
  26. else
  27. OPT_FLAGS = -O2
  28. endif
  29. CC := gcc
  30. ARFLAGS := rcs
  31. CFLAGS += $(OPT_FLAGS) \
  32. -std=c99 -fno-common \
  33. -Wstrict-prototypes -Wmissing-prototypes -Wsign-compare -Wmissing-declarations \
  34. -Wshadow -Wpointer-arith -Wcast-align -Wpacked -Wall -Werror $(DEBUG_FLAGS)
  35. CXXFLAGS += $(OPT_FLAGS) \
  36. -fno-common -Wsign-compare \
  37. -Wshadow -Wpointer-arith -Wcast-align -Wpacked -Wall -Werror $(DEBUG_FLAGS)
  38. CPPFLAGS += -MD -D_GNU_SOURCE
  39. LDFLAGS += -z defs
  40. # Shared libraries specific CFLAGS
  41. CFLAGS_SO := -fpic