Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrant Gayed2004-11-17 16:56:48 +0000
committerGrant Gayed2004-11-17 16:56:48 +0000
commit2d331ca15e28a0236589397a2813e9329f0593a2 (patch)
treeabb8ee7ec65e95365b869f2d22c18e6476025c53
parent6c0fe7b1f3c9db0b22a43c2871bb0e1e12bdc313 (diff)
downloadeclipse.platform.swt-2d331ca15e28a0236589397a2813e9329f0593a2.tar.gz
eclipse.platform.swt-2d331ca15e28a0236589397a2813e9329f0593a2.tar.xz
eclipse.platform.swt-2d331ca15e28a0236589397a2813e9329f0593a2.zip
*** empty log message ***
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build.sh74
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build64.sh14
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.mak187
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.xml45
4 files changed, 72 insertions, 248 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build.sh b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build.sh
index 2db3bc5f2e..ddd7312c01 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build.sh
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
#*******************************************************************************
# Copyright (c) 2000, 2004 IBM Corporation and others.
# All rights reserved. This program and the accompanying materials
@@ -11,6 +12,75 @@
# Tom Tromey (Red Hat, Inc.)
#*******************************************************************************
-#!/bin/sh
+cd `dirname $0`
+
+if [ "${OS}" = "" ]; then
+ OS=`uname -s`
+fi
+if [ "${MODEL}" = "" ]; then
+ MODEL=`uname -m`
+fi
+QT_HOME=$QTDIR
+
+case $OS in
+ "Linux")
+ case $MODEL in
+ "x86_64")
+ CC=gcc
+ LD=gcc
+ if [ "${JAVA_HOME}" = "" ]; then
+ JAVA_HOME=/bluebird/teamswt/swt-builddir/jdk1.5.0
+ fi
+ AWT_LIB_PATH=$JAVA_HOME/jre/lib/amd64
+ XTEST_LIB_PATH=/usr/X11R6/lib64
+ SWT_PTR_CFLAGS=-DSWT_PTR_SIZE_64
+ OUTPUT_DIR=../../../org.eclipse.swt.gtk64/os/linux/amd64
+ makefile="make_linux.mak"
+ echo "Building Linux GTK AMD64 version of SWT"
+ ;;
+ i?86)
+ CC=gcc
+ LD=gcc
+ if [ "${JAVA_HOME}" = "" ]; then
+ JAVA_HOME=/bluebird/teamswt/swt-builddir/IBMJava2-141
+ fi
+ AWT_LIB_PATH=$JAVA_HOME/jre/bin
+ XTEST_LIB_PATH=/usr/X11R6/lib
+ if [ "${GECKO_SDK}" = "" ]; then
+ GECKO_SDK=/mozilla/mozilla/1.4/linux_gtk2/mozilla/dist/sdk
+ fi
+ OUTPUT_DIR=../../../org.eclipse.swt.gtk/os/linux/x86
+ makefile="make_linux.mak"
+ echo "Building Linux GTK x86 version of SWT"
+ ;;
+ *)
+ echo "*** Unknown MODEL <${MODEL}>"
+ ;;
+ esac
+ ;;
+ "SunOS")
+ CC=gcc
+ LD=gcc
+ if [ "${JAVA_HOME}" = "" ]; then
+ JAVA_HOME=/usr/j2se
+ fi
+ AWT_LIB_PATH=$JAVA_HOME/jre/lib/sparc
+ PATH=/usr/ccs/bin:/usr/local/bin:$PATH
+ export PATH
+ XTEST_LIB_PATH=/usr/openwin/lib/
+# if [ "${GECKO_SDK}" = "" ]; then
+# GECKO_SDK=/mozilla/mozilla/1.4/linux_gtk2/mozilla/dist/sdk
+# fi
+ OUTPUT_DIR=../../../org.eclipse.swt.gtk/os/solaris/sparc
+ makefile="make_solaris.mak"
+ echo "Building Solaris GTK version of SWT"
+ ;;
+ *)
+
+ echo "*** Unknown OS <${OS}>"
+ ;;
+esac
+
+export CC LD JAVA_HOME QT_HOME AWT_LIB_PATH XTEST_LIB_PATH GECKO_SDK SWT_PTR_CFLAGS OUTPUT_DIR
-make -f make_gtk.mak ${1} ${2} ${3} ${4}
+make -f $makefile ${1} ${2} ${3} ${4}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build64.sh b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build64.sh
deleted file mode 100644
index 4eb13b86df..0000000000
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build64.sh
+++ /dev/null
@@ -1,14 +0,0 @@
-#*******************************************************************************
-# Copyright (c) 2000, 2004 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-#*******************************************************************************
-
-#!/bin/sh
-
-make -f make_gtk.mak SWT_PTR_CFLAGS=-DSWT_PTR_SIZE_64 ${1} ${2} ${3} ${4}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.mak b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.mak
deleted file mode 100644
index 7bebf9dd26..0000000000
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.mak
+++ /dev/null
@@ -1,187 +0,0 @@
-#*******************************************************************************
-# Copyright (c) 2000, 2004 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-#*******************************************************************************
-
-# Makefile for creating SWT libraries for Linux GTK
-
-include make_common.mak
-
-CC=gcc
-LD=gcc
-
-SWT_VERSION=$(maj_ver)$(min_ver)
-
-# Define the installation directories for various products.
-# Your system may have these in a different place.
-# JAVA_HOME - IBM's version of Java
-
-ifeq ($(SWT_PTR_CFLAGS),-DSWT_PTR_SIZE_64)
-# 64 bit path
-JAVA_HOME = /bluebird/teamswt/swt-builddir/jdk1.5.0
-AWT_LIB_PATH = $(JAVA_HOME)/jre/lib/amd64
-XTEST_LIB_PATH = /usr/X11R6/lib64
-else
-# 32 bit path
-JAVA_HOME = /bluebird/teamswt/swt-builddir/IBMJava2-141
-AWT_LIB_PATH = $(JAVA_HOME)/jre/bin
-XTEST_LIB_PATH = /usr/X11R6/lib
-endif
-
-# mozilla source distribution folder
-MOZILLA_HOME = /mozilla/mozilla/1.6/linux_gtk2/mozilla/dist
-
-# Define the various shared libraries to be build.
-WS_PREFIX = gtk
-SWT_PREFIX = swt
-AWT_PREFIX = swt-awt
-SWTPI_PREFIX = swt-pi
-ATK_PREFIX = swt-atk
-GNOME_PREFIX = swt-gnome
-MOZILLA_PREFIX = swt-mozilla
-SWT_LIB = lib$(SWT_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).so
-AWT_LIB = lib$(AWT_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).so
-SWTPI_LIB = lib$(SWTPI_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).so
-ATK_LIB = lib$(ATK_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).so
-GNOME_LIB = lib$(GNOME_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).so
-MOZILLA_LIB = lib$(MOZILLA_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).so
-
-GTKCFLAGS = `pkg-config --cflags gtk+-2.0`
-GTKLIBS = `pkg-config --libs gtk+-2.0 gthread-2.0` -L$(XTEST_LIB_PATH) -lXtst
-
-AWT_LIBS = -L$(AWT_LIB_PATH) -ljawt -shared
-
-ATKCFLAGS = `pkg-config --cflags atk gtk+-2.0`
-ATKLIBS = `pkg-config --libs atk gtk+-2.0`
-
-GNOMECFLAGS = `pkg-config --cflags gnome-vfs-module-2.0 libgnome-2.0 libgnomeui-2.0`
-GNOMELIBS = `pkg-config --libs gnome-vfs-module-2.0 libgnome-2.0 libgnomeui-2.0`
-
-MOZILLACFLAGS = -O \
- -fno-rtti \
- -Wall \
- -I./ \
- -I$(JAVA_HOME) \
- -include $(MOZILLA_HOME)/include/mozilla-config.h \
- -I$(MOZILLA_HOME)/include \
- -I$(MOZILLA_HOME)/include/xpcom \
- -I$(MOZILLA_HOME)/include/string \
- -I$(MOZILLA_HOME)/include/nspr \
- -I$(MOZILLA_HOME)/include/embed_base \
- -I$(MOZILLA_HOME)/include/gfx
-MOZILLALIBS = -L$(MOZILLA_HOME)/lib -lembed_base_s -lxpcom
-MOZILLALDFLAGS = -s
-
-SWT_OBJECTS = swt.o callback.o
-AWT_OBJECTS = swt_awt.o
-SWTPI_OBJECTS = swt.o os.o os_structs.o os_custom.o os_stats.o
-ATK_OBJECTS = swt.o atk.o atk_structs.o atk_custom.o atk_stats.o
-GNOME_OBJECTS = swt.o gnome.o gnome_structs.o gnome_stats.o
-MOZILLA_OBJECTS = xpcom.o
-
-CFLAGS = -O -Wall \
- -DSWT_VERSION=$(SWT_VERSION) \
- -DLINUX -DGTK \
- -I$(JAVA_HOME)/include \
- -fpic \
- ${SWT_PTR_CFLAGS}
-
-LIBS = -shared -fpic
-
-#
-# Target Rules
-#
-
-all: make_swt make_atk make_gnome make_awt make_mozilla
-
-all64: make_swt make_atk make_gnome make_awt
-
-#
-# SWT libs
-#
-make_swt: $(SWT_LIB) $(SWTPI_LIB)
-
-$(SWT_LIB): $(SWT_OBJECTS)
- $(LD) $(LIBS) -o $(SWT_LIB) $(SWT_OBJECTS)
-
-callback.o: callback.c callback.h
- $(CC) $(CFLAGS) -c callback.c
-
-$(SWTPI_LIB): $(SWTPI_OBJECTS)
- $(LD) $(LIBS) $(GTKLIBS) -o $(SWTPI_LIB) $(SWTPI_OBJECTS)
-
-swt.o: swt.c swt.h
- $(CC) $(CFLAGS) -c swt.c
-os.o: os.c os.h swt.h os_custom.h
- $(CC) $(CFLAGS) $(GTKCFLAGS) -c os.c
-os_structs.o: os_structs.c os_structs.h os.h swt.h
- $(CC) $(CFLAGS) $(GTKCFLAGS) -c os_structs.c
-os_custom.o: os_custom.c os_structs.h os.h swt.h
- $(CC) $(CFLAGS) $(GTKCFLAGS) -c os_custom.c
-os_stats.o: os_stats.c os_structs.h os.h os_stats.h swt.h
- $(CC) $(CFLAGS) $(GTKCFLAGS) -c os_stats.c
-
-#
-# AWT lib
-#
-make_awt:$(AWT_LIB)
-
-$(AWT_LIB): $(AWT_OBJECTS)
- $(LD) $(AWT_LIBS) -o $(AWT_LIB) $(AWT_OBJECTS)
-
-#
-# Atk lib
-#
-make_atk: $(ATK_LIB)
-
-$(ATK_LIB): $(ATK_OBJECTS)
- $(LD) $(LIBS) $(ATKLIBS) -o $(ATK_LIB) $(ATK_OBJECTS)
-
-atk.o: atk.c atk.h
- $(CC) $(CFLAGS) $(ATKCFLAGS) -c atk.c
-atk_structs.o: atk_structs.c atk_structs.h atk.h
- $(CC) $(CFLAGS) $(ATKCFLAGS) -c atk_structs.c
-atk_custom.o: atk_custom.c atk_structs.h atk.h
- $(CC) $(CFLAGS) $(ATKCFLAGS) -c atk_custom.c
-atk_stats.o: atk_stats.c atk_structs.h atk_stats.h atk.h
- $(CC) $(CFLAGS) $(ATKCFLAGS) -c atk_stats.c
-
-#
-# Gnome lib
-#
-make_gnome: $(GNOME_LIB)
-
-$(GNOME_LIB): $(GNOME_OBJECTS)
- $(LD) $(LIBS) $(GNOMELIBS) -o $(GNOME_LIB) $(GNOME_OBJECTS)
-
-gnome.o: gnome.c
- $(CC) $(CFLAGS) $(GNOMECFLAGS) -c gnome.c
-
-gnome_structs.o: gnome_structs.c
- $(CC) $(CFLAGS) $(GNOMECFLAGS) -c gnome_structs.c
-
-gnome_stats.o: gnome_stats.c gnome_stats.h
- $(CC) $(CFLAGS) $(GNOMECFLAGS) -c gnome_stats.c
-
-#
-# Mozilla lib
-#
-make_mozilla:$(MOZILLA_LIB)
-
-$(MOZILLA_LIB): $(MOZILLA_OBJECTS)
- $(CXX) $(LIBS) $(MOZILLALDFLAGS) -o $(MOZILLA_LIB) $(MOZILLA_OBJECTS) $(MOZILLALIBS)
-
-xpcom.o: xpcom.cpp
- $(CXX) $(MOZILLACFLAGS) -c xpcom.cpp
-
-#
-# Clean
-#
-clean:
- rm -f *.o *.so
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.xml b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.xml
deleted file mode 100644
index ffb0f68e52..0000000000
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_gtk.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<project default="build_gtk_linux_lib" basedir="../../..">
-
-<target name="init">
- <tstamp/>
- <property name="lib_destdir" value="${basedir}/../org.eclipse.swt.gtk/os/linux/x86" />
- <property name="lib_destdir64" value="${basedir}/../org.eclipse.swt.gtk64/os/linux/amd64" />
-</target>
-
-<!-- Build swt.so for GTK -->
-<!-- Output .so for this platform into the org.eclipse.swt.gtk/os directory -->
-<target name="build_gtk_linux_lib" depends="init">
- <mkdir dir="${lib_destdir}" />
- <exec dir="./bin/library" executable="sh">
- <arg line="${basedir}/bin/library/build.sh"/>
- </exec>
- <copy todir="${lib_destdir}">
- <fileset dir="${basedir}/bin/library/" includes="*.so"/>
- </copy>
- <eclipse.refreshLocal resource="org.eclipse.swt.gtk" depth="infinite" />
-</target>
-
-<!-- Output .so for this platform into the org.eclipse.swt.gtk64/os directory -->
-<target name="build_gtk_64_linux_lib" depends="init">
- <mkdir dir="${lib_destdir64}" />
- <exec dir="./bin/library" executable="sh">
- <arg line="${basedir}/bin/library/build64.sh"/>
- <arg line="all64"/>
- </exec>
- <copy todir="${lib_destdir64}">
- <fileset dir="${basedir}/bin/library/" includes="*.so"/>
- </copy>
- <eclipse.refreshLocal resource="org.eclipse.swt.gtk64" depth="infinite" />
-</target>
-
-<target name="clean" depends="init">
- <tstamp/>
- <exec dir="./bin/library" executable="sh">
- <arg line="${basedir}/bin/library/build.sh"/>
- <arg line="clean"/>
- </exec>
-</target>
-
-</project> \ No newline at end of file

Back to the top