1
arch_binaries := $(arch_binaries) gdc
3
ifeq ($(with_libphobos),yes)
4
arch_binaries += libphobos-dev
7
p_gdc = gdc$(pkg_ver)$(cross_bin_arch)
8
p_libphobos = libphobos$(pkg_ver)-dev
10
d_gdc = debian/$(p_gdc)
11
d_libphobos = debian/$(p_libphobos)
13
gdc_include_dir := $(PF)/include/d
17
$(PF)/share/man/man1 \
18
$(gdc_include_dir)/$(BASE_VERSION) \
22
$(PF)/bin/$(cmd_prefix)gdc$(pkg_ver) \
24
ifneq ($(GFDL_INVARIANT_FREE),yes-now-pure-gfdl)
26
$(PF)/share/man/man1/$(cmd_prefix)gdc$(pkg_ver).1
32
$(gdc_include_dir)/$(BASE_VERSION) \
36
$(PF)/$(libdir)/libgphobos2.a \
37
$(gdc_include_dir)/$(BASE_VERSION)
40
/$(gdc_include_dir)/$(BASE_VERSION) \
41
/$(gdc_include_dir)/$(GCC_VERSION) \
42
/$(docdir)/$(p_gcc)/README.Bugs \
43
/$(docdir)/$(p_gdc)/README.Bugs
46
$(binary_stamp)-gdc: $(install_stamp)
49
mv $(install_stamp) $(install_stamp)-tmp
52
dh_installdirs -p$(p_gdc) $(dirs_gdc)
54
dh_installdocs -p$(p_gdc) src/gcc/d/README
55
dh_installchangelogs -p$(p_gdc) src/gcc/d/ChangeLog
57
DH_COMPAT=2 dh_movefiles -p$(p_gdc) -X/zlib/ $(files_gdc)
59
ifneq ($(DEB_CROSS),yes)
60
ln -sf gdc$(pkg_ver) \
61
$(d_gdc)/$(PF)/bin/$(DEB_TARGET_GNU_TYPE)-gdc$(pkg_ver)
62
ln -sf gdc$(pkg_ver) \
63
$(d_gdc)/$(PF)/bin/$(TARGET_ALIAS)-gdc$(pkg_ver)
64
ifneq ($(GFDL_INVARIANT_FREE),yes)
65
ln -sf gdc$(pkg_ver).1 \
66
$(d_gdc)/$(PF)/share/man/man1/$(DEB_TARGET_GNU_TYPE)-gdc$(pkg_ver).1
67
ln -sf gdc$(pkg_ver).1 \
68
$(d_gdc)/$(PF)/share/man/man1/$(TARGET_ALIAS)-gdc$(pkg_ver).1
72
# Always needed by gdc.
73
cp $(srcdir)/libphobos/libdruntime/object.di \
74
$(d_gdc)/$(gdc_include_dir)/$(BASE_VERSION)/
76
dh_link -p$(p_gdc) $(links_gdc)
79
dh_compress -p$(p_gdc)
80
dh_fixperms -p$(p_gdc)
81
dh_shlibdeps -p$(p_gdc)
82
dh_gencontrol -p$(p_gdc) -- -v$(DEB_GDC_VERSION) $(common_substvars)
83
dh_installdeb -p$(p_gdc)
85
dh_builddeb -p$(p_gdc)
87
find $(d_gdc) -type d -empty -delete
89
trap '' 1 2 3 15; touch $@; mv $(install_stamp)-tmp $(install_stamp)
91
$(binary_stamp)-libphobos: $(install_stamp)
94
mv $(install_stamp) $(install_stamp)-tmp
97
dh_installdirs -p$(p_libphobos) $(dirs_libphobos)
99
DH_COMPAT=2 dh_movefiles -p$(p_libphobos) $(files_libphobos)
101
# better to have it there, avoid conflicts
102
mv $(d_libphobos)/$(PF)/$(libdir)/libgphobos2.a \
103
$(d_libphobos)/$(gcc_lib_dir)
105
# included in gdc package
106
rm -f $(d_libphobos)/$(gdc_include_dir)/$(BASE_VERSION)/object.di
108
ifeq ($(with_separate_gdc),yes)
109
debian/dh_doclink -p$(p_libphobos) $(p_gdc)
111
debian/dh_doclink -p$(p_libphobos) $(p_base)
114
dh_strip -p$(p_libphobos)
115
dh_compress -p$(p_libphobos)
116
dh_fixperms -p$(p_libphobos)
117
dh_shlibdeps -p$(p_libphobos)
118
dh_gencontrol -p$(p_libphobos) -- -v$(DEB_GDC_VERSION) $(common_substvars)
119
dh_installdeb -p$(p_libphobos)
120
dh_md5sums -p$(p_libphobos)
121
dh_builddeb -p$(p_libphobos)
123
find $(d_libphobos) -type d -empty -delete
125
trap '' 1 2 3 15; touch $@; mv $(install_stamp)-tmp $(install_stamp)
127
define __do_libphobos_dev
130
mv $(install_stamp) $(install_stamp)-tmp
133
dh_installdirs -p$(p_l) \
135
DH_COMPAT=2 dh_movefiles -p$(p_l) \
138
: # better to have it there, avoid conflicts
139
mv $(d_l)/$(PF)/$(libdir)/libgphobos2.a \
140
$(d_l)/$(gcc_lib_dir)
142
: # included in gdc package
143
rm -f $(d_l)/$(gdc_include_dir)/$(BASE_VERSION)/object.di
145
debian/dh_doclink -p$(p_l) \
146
$(if $(filter yes,$(with_separate_gdc)),$(p_gdc),$(p_base))
148
# $(call install_gcc_lib,libphobos,$(PHOBOS_SONAME),$(2),$(p_l))
150
# debian/dh_doclink -p$(p_l) $(p_base)
154
$(cross_gencontrol) dh_gencontrol -p$(p_l) \
155
-- -v$(DEB_VERSION) $(common_substvars)
156
$(call cross_mangle_control,$(p_l))
157
dh_installdeb -p$(p_l)
161
trap '' 1 2 3 15; touch $@; mv $(install_stamp)-tmp $(install_stamp)
164
do_libphobos_dev = $(call __do_libphobos_dev,lib$(1)phobos-$(BASE_VERSION)-dev,$(1))
166
$(binary_stamp)-libphobos-dev: $(install_stamp)
167
$(call do_libphobos_dev,)