File: rules

package info (click to toggle)
swt4-gtk 4.10.0-3
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 40,680 kB
  • sloc: java: 375,638; ansic: 80,301; cpp: 4,793; xml: 2,646; sh: 658; makefile: 64; python: 43
file content (53 lines) | stat: -rwxr-xr-x 2,342 bytes parent folder | download
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
42
43
44
45
46
47
48
49
50
51
52
53
#!/usr/bin/make -f

export DEB_CFLAGS_MAINT_APPEND=-fPIC
DEB_BUILD_MAINT_OPTIONS=hardening=+all
include /usr/share/dpkg/buildflags.mk
CFLAGS+=$(CPPFLAGS)
export DEB_LDFLAGS  := $(LDFLAGS)

include /usr/share/javahelper/java-vars.mk

DEB_DH_MAKESHLIBS_ARGS_ALL := -Xjni

AWT_LIB_DIR := $(JAVA_ARCH)

export AWT_LIB_PATH=/usr/lib/jvm/default-java/jre/lib/$(AWT_LIB_DIR)

MAKE_ARGS=-C bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library -I../../../Eclipse\ SWT/common/library/ -f make_linux.mak

ifeq ($(shell dpkg-architecture -qDEB_HOST_ARCH_BITS), 64)
  IS64=true
  export SWT_PTR_CFLAGS=-DJNI64
else
  IS64=false
endif


%:
	dh $@ --buildsystem=makefile --with maven-repo-helper --with javahelper

override_dh_auto_build:
	cd bundles/org.eclipse.swt && ant -f buildFragment.xml build.jars -Dswt.ws=gtk -Dplugindir=. -Dis64=$(IS64)
	cp bundles/org.eclipse.swt/swt.jar swt-gtk-4.6.0.jar

	cp bundles/org.eclipse.swt/Eclipse\ SWT/common/library/*         bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/
	cp bundles/org.eclipse.swt/Eclipse\ SWT\ AWT/gtk/library/*.c     bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/
	cp bundles/org.eclipse.swt/Eclipse\ SWT\ PI/cairo/library/*      bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/
	cp bundles/org.eclipse.swt/Eclipse\ SWT\ OpenGL/glx/library/*    bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/
	cp bundles/org.eclipse.swt/Eclipse\ SWT\ PI/common/library/*     bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/
	cp bundles/org.eclipse.swt/Eclipse\ SWT\ WebKit/gtk/library/*    bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/

	GTK_VERSION=3.0 dh_auto_build -- $(MAKE_ARGS) make_atk make_awt make_cairo make_glx make_swt make_webkit make_swtpi

	cp bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/*.so .

override_dh_auto_clean:
	dh_auto_clean -- $(MAKE_ARGS) make_linux.mak clean
	rm -f bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/callback*
	rm -f bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/make_common.mak
	rm -f bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/swt*
	rm -f bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/cairo*
	rm -f bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/glx*
	rm -f bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/c*
	rm -f bundles/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library/webkit*