Magellan Linux

Contents of /branches/R11-unstable/extras/libproxy/libproxy-0.4.15-r2.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 29998 - (show annotations) (download)
Fri Oct 20 06:46:50 2017 UTC (6 years, 6 months ago) by niro
Original Path: trunk/extras/libproxy/libproxy-0.4.15-r2.smage2
File size: 4697 byte(s)
auto added: ver bump to 0.4.15-r2
1 # $Id$
2
3 PNAME="libproxy"
4 PVER="0.4.15"
5 PBUILD="r2"
6
7 # disabled: libproxy-kde4
8 SPLIT_PACKAGES="libproxy libproxy-networkmanager libproxy-gnome3 perl-libproxy python2-libproxy python3-libproxy"
9 PCAT="net-libs"
10
11 HOMEPAGE="http://libproxy.github.io/libproxy/"
12
13 COMMON_DEPEND=">= dev-libs/glib2-2.54
14 >= sys-libs/libstdc++-6.3"
15 NN_DEPEND=">= net-libs/libnm-1.8"
16 #KDE_DEPEND=">= kde-base/kdelibs-4.14"
17 PERL_DEPEND=">= dev-lang/perl-5.26.1"
18 PYTHON2_DEPEND=">= dev-lang/python-2.7"
19 PYTHON3_DEPEND=">= dev-lang/python3-3.6"
20
21 SDEPEND="${COMMON_DEPEND}
22 ${NN_DEPEND}
23 ${KDE_DEPEND}
24 ${PERL_DEPEND}
25 ${PYTHON2_DEPEND}
26 ${PYTHON3_DEPEND}"
27
28 SRCFILE="${PVER}.tar.gz"
29 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
30
31 #sminclude multilib kde4 cmake mtools cleanutils rpath
32 sminclude multilib cmake mtools cleanutils rpath
33 msetfeature "!check"
34
35 SRC_URI=(
36 https://github.com/${PNAME}/${PNAME}/archive/${SRCFILE}
37 mirror://${PNAME}/${SRCFILE}
38 )
39
40 UP2DATE="updatecmd ${HOMEPAGE}downloads/list | firsttarball gz"
41
42 split_info_libproxy()
43 {
44 DESCRIPTION="A library that provides automatic proxy configuration management."
45 DEPEND="${COMMON_DEPEND}"
46 }
47
48 split_info_libproxy-networkmanager()
49 {
50 DESCRIPTION="NetworkManager plugin for libproxy."
51 DEPEND="== net-libs/libproxy-${PVER}
52 ${NM_DEPEND}"
53 }
54
55 split_info_libproxy-gnome3()
56 {
57 DESCRIPTION="GNOME3 plugin for libproxy."
58 DEPEND="== net-libs/libproxy-${PVER}"
59 }
60
61 split_info_libproxy-kde4()
62 {
63 DESCRIPTION="KDE4 plugin for libproxy."
64 DEPEND="== net-libs/libproxy-${PVER}
65 ${KDE_DEPEND}"
66 }
67
68 split_info_perl-libproxy()
69 {
70 DESCRIPTION="Perl bindings for libproxy."
71 DEPEND="== net-libs/libproxy-${PVER}
72 ${PERL_DEPEND}"
73 }
74
75 split_info_python2-libproxy()
76 {
77 DESCRIPTION="Python2 bindings for libproxy."
78 DEPEND="== net-libs/libproxy-${PVER}
79 ${PYTHON2_DEPEND}"
80 }
81
82 split_info_python3-libproxy()
83 {
84 DESCRIPTION="Python3 bindings for libproxy."
85 DEPEND="== net-libs/libproxy-${PVER}
86 ${PYTHON3_DEPEND}"
87 }
88
89 src_prepare()
90 {
91 munpack ${SRCFILE} || die
92 }
93
94 src_compile()
95 {
96 # $(cmake_with KDE4)
97 cmake_configure \
98 -DLIBEXEC_INSTALL_DIR=/usr/'$(mlibdir)'/libproxy \
99 -DPYTHON2_EXECUTABLE:FILEPATH=/usr/bin/python2 \
100 -DPYTHON3_EXECUTABLE:FILEPATH=/usr/bin/python3 \
101 $(cmake_opt PERL_VENDORINSTALL ON) \
102 $(cmake_with GNOME3) \
103 $(cmake_with NM) \
104 $(cmake_with PERL) \
105 $(cmake_with VALA) \
106 $(cmake_without DOTNET) \
107 $(cmake_without WEBKIT) \
108 $(cmake_without WEBKIT3) \
109 $(cmake_without MOZJS) \
110 || die
111
112 mmake || die
113 }
114
115 src_install_libproxy()
116 {
117 mmake -C libproxy DESTDIR=${BINDIR} install || die
118 mmake -C utils DESTDIR=${BINDIR} install || die
119 minstalldir /usr/share/vala/vapi || die
120 minstallfile bindings/vala/\*.vapi /usr/share/vala/vapi/ || die
121 minstalldocs AUTHORS COPYING ChangeLog NEWS README || die
122
123 # remove unwanted plugins and helpers
124 if [[ -d ${BINDIR}/usr/$(mlibdir)/libproxy/${PVER}/modules ]]
125 then
126 mdelete -r /usr/$(mlibdir)/libproxy/${PVER}/modules || die
127 fi
128 if [[ -f ${BINDIR}/usr/$(mlibdir)/libproxy/pxgsettings ]]
129 then
130 mdelete /usr/$(mlibdir)/libproxy/pxgsettings || die
131 fi
132 if [[ $(mlibdir) != lib ]]
133 then
134 if [[ -d ${BINDIR}/usr/lib/libproxy/${PVER}/modules ]]
135 then
136 mdelete -r /usr/lib/libproxy/${PVER}/modules || die
137 fi
138 if [[ -f ${BINDIR}/usr/lib/libproxy/pxgsettings ]]
139 then
140 mdelete /usr/lib/libproxy/pxgsettings || die
141 fi
142 fi
143 }
144
145 src_install_libproxy-networkmanager()
146 {
147 all-abis minstalldir /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
148 all-abis minstallexec libproxy/network_networkmanager.so /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
149 all-abis minstallexec libproxy/pxgsettings /usr/'$(mlibdir)'/libproxy/ || die
150
151 # remove insecure rpath
152 mdeleterpath || die
153 }
154
155 src_install_libproxy-gnome3()
156 {
157 all-abis minstalldir /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
158 all-abis minstallexec libproxy/config_gnome3.so /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
159
160 # remove insecure rpath
161 mdeleterpath || die
162 }
163
164 #src_install_libproxy-kde4()
165 #{
166 # # no multilib!
167 # if [[ ${ARCH} = x86_64 ]]
168 # then
169 # only-m64 minstalldir /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
170 # only-m64 minstallexec lib/config_kde4.so /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
171 # else
172 # all-abis minstalldir /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
173 # all-abis minstallexec lib/config_kde4.so /usr/'$(mlibdir)'/libproxy/${PVER}/modules || die
174 # fi
175 #
176 # # remove insecure rpath
177 # mdeleterpath || die
178 #}
179
180 src_install_perl-libproxy()
181 {
182 mmake -C bindings/perl DESTDIR=${BINDIR} install || die
183 }
184
185 src_install_python2-libproxy()
186 {
187 mmake -C bindings/python/python2 DESTDIR=${BINDIR} install || die
188 }
189
190 src_install_python3-libproxy()
191 {
192 mmake -C bindings/python/python3 DESTDIR=${BINDIR} install || die
193 }