Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 104064 | Differences between
and this patch

Collapse All | Expand All

(-)/usr/portage/net-libs/openh323/openh323-1.15.3.ebuild (-27 / +32 lines)
Lines 13-19 Link Here
13
IUSE="ssl novideo noaudio debug"
13
IUSE="ssl novideo noaudio debug"
14
SLOT="0"
14
SLOT="0"
15
LICENSE="MPL-1.1"
15
LICENSE="MPL-1.1"
16
KEYWORDS="~alpha ~amd64 ppc ~sparc ~x86"
16
KEYWORDS="~alpha ~amd64 ppc ~sparc ~x86 ~hppa"
17
17
18
DEPEND=">=sys-apps/sed-4
18
DEPEND=">=sys-apps/sed-4
19
	>=dev-libs/pwlib-1.8.4
19
	>=dev-libs/pwlib-1.8.4
Lines 39-45 Link Here
39
	export PTLIB_CONFIG=/usr/bin/ptlib-config
39
	export PTLIB_CONFIG=/usr/bin/ptlib-config
40
	export OPENH323DIR=${S}
40
	export OPENH323DIR=${S}
41
41
42
	makeopts="${makeopts} ASNPARSER=/usr/bin/asnparser LDFLAGS=-L${S}/lib"
42
	makeopts="ASNPARSER=/usr/bin/asnparser LDFLAGS=-L${S}/lib"
43
43
44
	# NOTRACE avoid compilation problems, we disable PTRACING using NOTRACE=1
44
	# NOTRACE avoid compilation problems, we disable PTRACING using NOTRACE=1
45
	# compile with PTRACING if the user wants to debug stuff
45
	# compile with PTRACING if the user wants to debug stuff
Lines 65-71 Link Here
65
65
66
src_install() {
66
src_install() {
67
	local OPENH323_ARCH ALT_ARCH OPENH323_SUFFIX
67
	local OPENH323_ARCH ALT_ARCH OPENH323_SUFFIX
68
	local makeopts
68
	local makeopts libdir
69
69
	# make NOTRACE=1 opt ==> linux_$ARCH_n
70
	# make NOTRACE=1 opt ==> linux_$ARCH_n
70
	# make opt           ==> linux_$ARCH_r
71
	# make opt           ==> linux_$ARCH_r
71
	if ! use debug; then
72
	if ! use debug; then
Lines 75-86 Link Here
75
		OPENH323_SUFFIX="r"
76
		OPENH323_SUFFIX="r"
76
	fi
77
	fi
77
78
78
	# amd64 needs special treatment
79
	# use ptlib-config to get the right values here (for hppa, amd64 ...)
79
	if use amd64; then
80
	OPENH323_ARCH="$(ptlib-config --ostype)_$(ptlib-config --machtype)_${OPENH323_SUFFIX}"
80
		OPENH323_ARCH="linux_x86_64_${OPENH323_SUFFIX}"
81
	else
82
		OPENH323_ARCH="linux_${ARCH}_${OPENH323_SUFFIX}"
83
	fi
84
81
85
	# set ALT_ARCH
82
	# set ALT_ARCH
86
	if use debug; then
83
	if use debug; then
Lines 96-115 Link Here
96
		OH323_FILE="libh323_${OPENH323_ARCH}.so.${PV}" \
93
		OH323_FILE="libh323_${OPENH323_ARCH}.so.${PV}" \
97
		${makeopts} install || die "install failed"
94
		${makeopts} install || die "install failed"
98
95
99
	# workaround: don't install libh323*.so and libh323.so.${PV}
96
	libdir=$(get_libdir)
100
	if [[ -f ${D}/usr/$(get_libdir)/libh323_${OPENH323_ARCH}.so ]]; then
101
		# libh323*.so is a file... replace it w/ a symlink
102
		rm -f ${D}/usr/$(get_libdir)/libh323_${OPENH323_ARCH}.so
103
97
104
		dosym  /usr/$(get_libdir)/libh323_${OPENH323_ARCH}.so.${PV} \
98
	# fix openh323's bogus symlinks
105
			/usr/$(get_libdir)/libh323_${OPENH323_ARCH}.so
99
	for pv in ${PV%.[0-9]} ${PV%.[0-9]*.[0-9]}; do
106
	fi
100
		rm -f ${D}/usr/${libdir}/libh323_${OPENH323_ARCH}.so.${pv}
101
102
		dosym /usr/${libdir}/libh323_${OPENH323_ARCH}.so.${PV} \
103
			/usr/${libdir}/libh323_${OPENH323_ARCH}.so.${pv}
104
	done
105
	rm -f ${D}/usr/${libdir}/libh323_${OPENH323_ARCH}.so
106
	dosym /usr/${libdir}/libh323_${OPENH323_ARCH}.so.${PV} \
107
		/usr/${libdir}/libh323_${OPENH323_ARCH}.so
108
109
	# create backwards compatibility with _r versioned libraries
110
	for pv in ${PV} ${PV%.[0-9]} ${PV%.[0-9]*.[0-9]}; do
111
		# compat symlink
112
		dosym /usr/${libdir}/libh323_${OPENH323_ARCH}.so.${PV} \
113
			/usr/${libdir}/libh323_${ALT_ARCH}.so.${pv}
114
	done
115
	dosym /usr/${libdir}/libh323_${OPENH323_ARCH}.so.${PV} \
116
		/usr/${libdir}/libh323_${ALT_ARCH}.so
107
117
108
	###
118
	###
109
	# Compatibility "hacks"
119
	# Compatibility "hacks"
110
	#
120
	#
111
121
112
	# mod to keep gnugk happy
122
	# mod to keep gnugk happy (still needed?)
113
	insinto /usr/share/openh323/src
123
	insinto /usr/share/openh323/src
114
	newins ${FILESDIR}/openh323-1.11.7-emptyMakefile Makefile
124
	newins ${FILESDIR}/openh323-1.11.7-emptyMakefile Makefile
115
125
Lines 117-138 Link Here
117
	insinto /usr/share/openh323
127
	insinto /usr/share/openh323
118
	doins version.h
128
	doins version.h
119
129
120
	rm ${D}/usr/$(get_libdir)/libopenh323.so
130
	# should try to get rid of this one
121
	dosym /usr/$(get_libdir)/libh323_${OPENH323_ARCH}.so.${PV} /usr/$(get_libdir)/libopenh323.so
131
	rm -f ${D}/usr/${libdir}/libopenh323.so
122
132
	dosym /usr/${libdir}/libh323_${OPENH323_ARCH}.so.${PV} /usr/${libdir}/libopenh323.so
123
	# for backwards compatibility with _r versioned libraries
124
	for pv in ${PV} ${PV%.[0-9]} ${PV%.[0-9]*.[0-9]}; do
125
		einfo "creating /usr/$(get_libdir)/libh323_${ALT_ARCH}.so.${pv} symlink"
126
		dosym /usr/$(get_libdir)/libh323_${OPENH323_ARCH}.so.${PV} /usr/$(get_libdir)/libh323_${ALT_ARCH}.so.${pv}
127
	done
128
	dosym /usr/$(get_libdir)/libh323_${OPENH323_ARCH}.so.${PV} /usr/$(get_libdir)/libh323_${ALT_ARCH}.so
129
133
130
	# these should point to the right directories,
134
	# these should point to the right directories,
131
	# openh323.org apps and others need this
135
	# openh323.org apps and others need this
132
	dosed "s:^OH323_LIBDIR = \$(OPENH323DIR).*:OH323_LIBDIR = /usr/$(get_libdir):" \
136
	dosed "s:^OH323_LIBDIR = \$(OPENH323DIR).*:OH323_LIBDIR = /usr/${libdir}:" \
133
		/usr/share/openh323/openh323u.mak
137
		/usr/share/openh323/openh323u.mak
134
	dosed "s:^OH323_INCDIR = \$(OPENH323DIR).*:OH323_INCDIR = /usr/include/openh323:" \
138
	dosed "s:^OH323_INCDIR = \$(OPENH323DIR).*:OH323_INCDIR = /usr/include/openh323:" \
135
		/usr/share/openh323/openh323u.mak
139
		/usr/share/openh323/openh323u.mak
140
136
	# this is hardcoded now?
141
	# this is hardcoded now?
137
	dosed "s:^\(OPENH323DIR[ \t]\+=\) ${S}:\1 /usr/share/openh323:" \
142
	dosed "s:^\(OPENH323DIR[ \t]\+=\) ${S}:\1 /usr/share/openh323:" \
138
		/usr/share/openh323/openh323u.mak
143
		/usr/share/openh323/openh323u.mak

Return to bug 104064