File: fhs.make

package info (click to toggle)
sope 3.2.6-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 16,408 kB
  • ctags: 2,779
  • sloc: objc: 167,855; sh: 3,646; ansic: 3,399; python: 318; makefile: 181
file content (41 lines) | stat: -rw-r--r-- 1,188 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# postprocessing

# FHS support (this is a hack and is going to be done by gstep-make!)

ifneq ($(FHS_INSTALL_ROOT),)

FHS_INCLUDE_DIR=$(FHS_INSTALL_ROOT)/include/
FHS_BIN_DIR=$(FHS_INSTALL_ROOT)/bin/

ifeq ($(findstring _64, $(GNUSTEP_TARGET_CPU)), _64)
FHS_LIB_DIR=$(FHS_INSTALL_ROOT)/lib64/
else
FHS_LIB_DIR=$(FHS_INSTALL_ROOT)/lib/
endif

NONFHS_LIBDIR="$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR)/"
NONFHS_LIBNAME="$(LIBRARY_NAME)$(LIBRARY_NAME_SUFFIX)$(SHARED_LIBEXT)"


fhs-header-dirs ::
	$(MKDIRS) $(FHS_INCLUDE_DIR)$(libNGMime_HEADER_FILES_INSTALL_DIR)
	$(MKDIRS) $(FHS_INCLUDE_DIR)/NGImap4
	$(MKDIRS) $(FHS_INCLUDE_DIR)/NGMail


move-headers-to-fhs :: fhs-header-dirs
	@echo "moving headers to $(FHS_INCLUDE_DIR) .."
	mv $(GNUSTEP_HEADERS)$(libNGMime_HEADER_FILES_INSTALL_DIR)/*.h \
	  $(FHS_INCLUDE_DIR)$(libNGMime_HEADER_FILES_INSTALL_DIR)/
	mv $(GNUSTEP_HEADERS)/NGImap4/*.h $(FHS_INCLUDE_DIR)/NGImap4/
	mv $(GNUSTEP_HEADERS)/NGMail/*.h $(FHS_INCLUDE_DIR)/NGMail/

move-libs-to-fhs :: 
	@echo "moving libs to $(FHS_LIB_DIR) .."
	mv $(NONFHS_LIBDIR)/$(NONFHS_LIBNAME)* $(FHS_LIB_DIR)/

move-to-fhs :: move-headers-to-fhs move-libs-to-fhs

after-install :: move-to-fhs

endif