]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blob - lfs/foomatic
suricata: Change midstream policy to "pass-flow"
[people/pmueller/ipfire-2.x.git] / lfs / foomatic
1 ###############################################################################
2 # #
3 # IPFire.org - A linux based firewall #
4 # Copyright (C) 2007-2019 IPFire Team <info@ipfire.org> #
5 # #
6 # This program is free software: you can redistribute it and/or modify #
7 # it under the terms of the GNU General Public License as published by #
8 # the Free Software Foundation, either version 3 of the License, or #
9 # (at your option) any later version. #
10 # #
11 # This program is distributed in the hope that it will be useful, #
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of #
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
14 # GNU General Public License for more details. #
15 # #
16 # You should have received a copy of the GNU General Public License #
17 # along with this program. If not, see <http://www.gnu.org/licenses/>. #
18 # #
19 ###############################################################################
20
21 ###############################################################################
22 # Definitions
23 ###############################################################################
24
25 include Config
26
27 VER = 4.0.9
28 VER_DB = 4.0-$(DATE)
29 VER_FILTERS = 4.0.17
30 DATE = 20131023
31
32 THISAPP = foomatic-$(VER)
33 DL_FILE = foomatic-filters-$(VER_FILTERS).tar.gz
34 DL_FROM = $(URL_IPFIRE)
35 DIR_APP = $(DIR_SRC)/foomatic-filters-$(VER_FILTERS)
36 TARGET = $(DIR_INFO)/$(THISAPP)
37 PROG = foomatic
38 PAK_VER = 6
39
40 DEPS = cups ghostscript libtiff hplip
41
42 CFLAGS += -fcommon
43
44 export LIB_CUPS=/usr/lib/cups
45 export CUPS_BACKENDS=/usr/lib/cups/backends
46 export CUPS_FILTERS=/usr/lib/cups/filters
47 export CUPS_PPDS=/usr/share/cups/model
48
49 ###############################################################################
50 # Top-level Rules
51 ###############################################################################
52
53 objects = $(DL_FILE) \
54 foomatic-db-$(VER_DB).tar.gz \
55 foomatic-db-engine-$(VER).tar.gz
56
57 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
58 foomatic-db-$(VER_DB).tar.gz = $(DL_FROM)/foomatic-db-$(VER_DB).tar.gz
59 foomatic-db-engine-$(VER).tar.gz = $(DL_FROM)/foomatic-db-engine-$(VER).tar.gz
60
61 $(DL_FILE)_MD5 = b05f5dcbfe359f198eef3df5b283d896
62 foomatic-db-$(VER_DB).tar.gz_MD5 = ffe38b354cb06a1f3d5e3b01b7e58b0e
63 foomatic-db-engine-$(VER).tar.gz_MD5 = 5b33c1adb21e7b6f3652e9a18d0e6f4e
64
65 install : $(TARGET)
66
67 check : $(patsubst %,$(DIR_CHK)/%,$(objects))
68
69 download :$(patsubst %,$(DIR_DL)/%,$(objects))
70
71 md5 : $(subst %,%_MD5,$(objects))
72
73 dist:
74 $(PAK)
75
76 ###############################################################################
77 # Downloading, checking, md5sum
78 ###############################################################################
79
80 $(patsubst %,$(DIR_CHK)/%,$(objects)) :
81 @$(CHECK)
82
83 $(patsubst %,$(DIR_DL)/%,$(objects)) :
84 @$(LOAD)
85
86 $(subst %,%_MD5,$(objects)) :
87 @$(MD5)
88
89 ###############################################################################
90 # Installation Details
91 ###############################################################################
92
93 $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
94 @$(PREBUILD)
95 @rm -rf $(DIR_SRC)/foomatic-* && cd $(DIR_SRC) && \
96 tar zxf $(DIR_DL)/$(DL_FILE) && \
97 tar zxf $(DIR_DL)/foomatic-db-$(VER_DB).tar.gz && \
98 tar zxf $(DIR_DL)/foomatic-db-engine-$(VER).tar.gz
99 cd $(DIR_APP) && ./configure --prefix=/usr --sysconfdir=/etc
100 cd $(DIR_APP) && make $(MAKETUNING)
101 cd $(DIR_APP) && make install
102 cd $(DIR_SRC)/foomatic-db-$(DATE) && ./configure --prefix=/usr --sysconfdir=/etc
103 cd $(DIR_SRC)/foomatic-db-$(DATE) && make $(MAKETUNING)
104 cd $(DIR_SRC)/foomatic-db-$(DATE) && make install
105 cd $(DIR_SRC)/foomatic-db-engine-$(VER) && ./configure --prefix=/usr --sysconfdir=/etc
106 cd $(DIR_SRC)/foomatic-db-engine-$(VER) && make $(MAKETUNING)
107 cd $(DIR_SRC)/foomatic-db-engine-$(VER) && make install
108
109 # Remove unwanted files
110 rm -rfv /usr/lib/ppr \
111 /etc/foomatic/filter.conf.sample \
112 /usr/share/foomatic/templates
113
114 -mkdir -pv /var/cache/foomatic
115
116 -mkdir -pv /etc/foomatic
117 echo "cups" > /etc/foomatic/defaultspooler
118
119 @rm -rf $(DIR_SRC)/foomatic-*
120 @$(POSTBUILD)