1#**************************************************************
2#
3#  Licensed to the Apache Software Foundation (ASF) under one
4#  or more contributor license agreements.  See the NOTICE file
5#  distributed with this work for additional information
6#  regarding copyright ownership.  The ASF licenses this file
7#  to you under the Apache License, Version 2.0 (the
8#  "License"); you may not use this file except in compliance
9#  with the License.  You may obtain a copy of the License at
10#
11#    http://www.apache.org/licenses/LICENSE-2.0
12#
13#  Unless required by applicable law or agreed to in writing,
14#  software distributed under the License is distributed on an
15#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16#  KIND, either express or implied.  See the License for the
17#  specific language governing permissions and limitations
18#  under the License.
19#
20#**************************************************************
21
22
23
24PRJ=..
25
26PRJNAME=setup_native
27TARGET=install
28
29# --- Settings -----------------------------------------------------
30
31.INCLUDE :	settings.mk
32.IF "$(L10N_framework)"==""
33# --- Files --------------------------------------------------------
34
35UNIXTEXT= \
36	$(BIN)$/langpackscript.sh \
37	$(BIN)$/linuxpatchscript.sh \
38	$(BIN)$/javaloader.sh \
39	$(BIN)$/register_extensions \
40	$(BIN)$/deregister_extensions \
41	$(BIN)$/unpack_update.sh \
42	$(BIN)$/update.sh \
43	$(BIN)$/downloadscript.sh
44
45.IF "$(OS)" == "SOLARIS" || "$(OS)" == "LINUX"
46UNIXTEXT+= $(BIN)$/stclient_wrapper.sh
47.ENDIF
48
49NOARCH=$(BIN)$/noarch
50FAKEDB=$(NOARCH)/fake-db-1.0-0.noarch.rpm
51FAKEDBROOT=$(COMMONMISC)/$(TARGET)/fake-db-root
52
53# --- Targets ------------------------------------------------------
54
55.ENDIF # L10N_framework
56.INCLUDE :	target.mk
57.IF "$(L10N_framework)"==""
58.IF "$(OS)" == "SOLARIS" || ( "$(OS)" == "LINUX" && "$(PKGFORMAT)"!="$(PKGFORMAT:s/rpm//)" )
59
60ALLTAR: $(BIN)$/install $(BIN)$/uninstall
61
62$(BIN)$/install: install_$(OS:l).sh
63	$(PERL) install_create.pl $& $@
64	-chmod 775 $@
65
66.ENDIF
67
68.IF "$(OS)" == "LINUX"
69.IF "$(PKGFORMAT)"!="$(PKGFORMAT:s/rpm//)"
70
71$(FAKEDB) : fake-db.spec
72	$(MKDIRHIER) $(FAKEDBROOT)
73	$(RPM) --define "_builddir $(shell @cd $(FAKEDBROOT) && pwd)" --define "_rpmdir $(shell @cd $(BIN) && pwd)" -bb $<
74    chmod g+w $(NOARCH)
75
76$(BIN)$/install: $(FAKEDB)
77.ENDIF          # "$(PKGFORMAT)"!="$(PKGFORMAT:s/rpm//)"
78
79$(BIN)$/uninstall: uninstall_linux.sh
80	$(TYPE) $< | tr -d "\015" > $@
81	-chmod 775 $@
82
83.ENDIF          # "$(OS)" == "LINUX"
84
85.IF "$(OS)" == "SOLARIS"
86
87$(BIN)$/install: $(LB)$/getuid.so.stripped
88
89$(BIN)$/uninstall: uninstall_solaris.sh $(LB)$/getuid.so.stripped
90	$(PERL) install_create.pl $<  $@
91    -chmod 775 $@
92
93$(LB)$/getuid.so.stripped: $(LB)$/getuid.so
94	@$(COPY) $< $@
95	@/usr/ccs/bin/strip $@
96
97.ENDIF
98
99.ENDIF # L10N_framework
100