1#**********************************************************************
2# Copyright (c) 2008, 2018 Oakland Software Incorporated and others.
3#
4# This program and the accompanying materials
5# are made available under the terms of the Eclipse Public License 2.0
6# which accompanies this distribution, and is available at
7# https://www.eclipse.org/legal/epl-2.0/
8#
9# SPDX-License-Identifier: EPL-2.0
10#
11# Contributors:
12#	Oakland Software Incorporated - initial submission
13#	IBM Corporation - refactoring, bug 245849
14#   Red Hat - GSettings implementation and code clean up (bug 394087)
15#
16#**********************************************************************
17#
18# makefile for libgnomeproxy-1.0.0.so
19
20GNOMEPROXY.C = ../gnomeproxy.c
21GNOMEPROXY.O = gnomeproxy.o
22LIB_NAME = gnomeproxy.so
23LIB_NAME_FULL = libgnomeproxy-1.0.0.so
24
25OS_TYPE = freebsd
26JDK_INCLUDE = -I${JAVA_HOME}/include -I${JAVA_HOME}/include/${OS_TYPE}
27INCLUDE = `pkg-config --cflags gio-2.0`
28COMPILER_FLAGS = -O0 -fPIC -g3 -Wall -c -fmessage-length=0 ${TARGET_ENVIRONMENT}
29
30LIBS := `pkg-config --libs gio-2.0`
31LINKER_FLAGS= ${TARGET_ENVIRONMENT}
32
33all: link
34
35compile:
36	@echo "Building file: $(GNOMEPROXY.O)"
37	$(CC) $(INCLUDE) $(JDK_INCLUDE) $(COMPILER_FLAGS) -o $(GNOMEPROXY.O) $(GNOMEPROXY.C)
38	@echo "Finished building: $(GNOMEPROXY.O)"
39	@echo " "
40
41link: compile
42	@echo "Building target: $(LIB_NAME_FULL)"
43	$(CC) $(LINKER_FLAGS) -shared -Wl,-soname,$(LIB_NAME) -o $(LIB_NAME_FULL) $(LIBS) $(GNOMEPROXY.O)
44	@echo "Finished building target: $(LIB_NAME_FULL)"
45	@echo " "
46
47clean:
48	-$(RM) $(GNOMEPROXY.O) $(LIB_NAME_FULL)
49	-@echo " "
50