View | Details | Raw Unified | Return to bug 142748
Collapse All | Expand All

(-)p5-Tk/Makefile (-4 / +10 lines)
Lines 16-21 Link Here
16
16
17
MAKE_JOBS_UNSAFE=	yes
17
MAKE_JOBS_UNSAFE=	yes
18
18
19
LIB_DEPENDS=	jpeg.10:${PORTSDIR}/graphics/jpeg \
20
		png.5:${PORTSDIR}/graphics/png
19
PERL_CONFIGURE=	5.8.0+
21
PERL_CONFIGURE=	5.8.0+
20
USE_XORG=	x11
22
USE_XORG=	x11
21
CONFIGURE_ARGS=	X11LIB=${LOCALBASE}/lib X11INC=${LOCALBASE}/include
23
CONFIGURE_ARGS=	X11LIB=${LOCALBASE}/lib X11INC=${LOCALBASE}/include
Lines 146-152 Link Here
146
148
147
.if defined(WITH_XFT)
149
.if defined(WITH_XFT)
148
CONFIGURE_ARGS=	XFT=1
150
CONFIGURE_ARGS=	XFT=1
149
LIB_DEPENDS+=	Xft.2:${PORTSDIR}/x11-fonts/libXft
151
USE_XORG+=	xft
150
.endif
152
.endif
151
153
152
.if !defined(WITH_XFT)
154
.if !defined(WITH_XFT)
Lines 159-171 Link Here
159
.endif
161
.endif
160
162
161
post-patch:
163
post-patch:
162
	@${PERL} -i -p -e 's|%%LOCALBASE%%|${LOCALBASE}|' \
164
	@${PERL} -i -p -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
163
		${WRKSRC}/pTk/Makefile.PL
165
		${WRKSRC}/pTk/Makefile.PL \
166
		${WRKSRC}/JPEG/Makefile.PL \
167
		${WRKSRC}/PNG/Makefile.PL
164
168
165
post-configure:
169
post-configure:
166
	@${PERL} -i -p \
170
	@${PERL} -i -p \
167
		-e 's|^(CC = ).*|$$1 ${CC}|;' \
171
		-e 's|^(CC = ).*|$$1 ${CC}|;' \
168
		-e 's|^(CCFLAGS = ).*|$$1 ${CFLAGS}|' \
172
		-e 's|^(CCFLAGS = ).*|$$1 ${CFLAGS}|;' \
173
		-e 's|^(LD = ).*|$$1 ${CC} ${CFLAGS} ${LDFLAGS}|;' \
174
		-e 's|^(FULL_AR = ).*|$$1 ${AR}|' \
169
		`${FIND} ${WRKSRC} -name Makefile`
175
		`${FIND} ${WRKSRC} -name Makefile`
170
176
171
.include <bsd.port.post.mk>
177
.include <bsd.port.post.mk>
(-)p5-Tk/files/patch-JPEG_Makefile.PL (+16 lines)
Line 0 Link Here
1
--- JPEG/Makefile.PL.orig	2010-01-12 08:28:55.000000000 -0500
2
+++ JPEG/Makefile.PL	2010-01-12 08:32:23.000000000 -0500
3
@@ -13,10 +13,10 @@
4
 
5
 use Tk::MMtry;
6
 
7
-if ($Tk::MMtry::VERSION ge '4.007' && try_run("jpeg/has_jpeg.c",['-I/usr/local/include'],['-ljpeg']))
8
+if ($Tk::MMtry::VERSION ge '4.007' && try_run("jpeg/has_jpeg.c",['-I%%LOCALBASE%%/include'],['-L%%LOCALBASE%%/lib -ljpeg']))
9
  {
10
-  push(@args, LIBS => ['-ljpeg'],
11
-              INC  => '-I/usr/local/include',
12
+  push(@args, LIBS => ['-L%%LOCALBASE%%/lib -ljpeg'],
13
+              INC  => '-I%%LOCALBASE%%/include',
14
               DEFINE => '-DHAVE_JPEGLIB_H',
15
       );
16
   warn "Using system's -ljpeg\n";
(-)p5-Tk/files/patch-PNG_Makefile.PL (+22 lines)
Line 0 Link Here
1
--- PNG/Makefile.PL.orig	2010-01-12 08:23:36.000000000 -0500
2
+++ PNG/Makefile.PL	2010-01-12 08:26:18.000000000 -0500
3
@@ -16,7 +16,7 @@
4
  }
5
 
6
 if ($Tk::MMtry::VERSION ge '4.007' &&
7
-    try_run("config/has_png.c",['-I/usr/local/include'],['-lpng -lz -lm']))
8
+    try_run("config/has_png.c",['-I%%LOCALBASE%%/include'],['-L%%LOCALBASE%%/lib -lpng -lz -lm']))
9
  {
10
   Tk::MMutil::TkExtMakefile(
11
        NAME         => 'Tk::PNG',
12
@@ -24,8 +24,8 @@
13
        XS_VERSION   => $Tk::Config::VERSION,
14
        dist         => { COMPRESS => 'gzip -f9', SUFFIX => '.gz' },
15
        OBJECT       => '$(O_FILES)',
16
-       INC          => '-I/usr/local/include',
17
-       LIBS         => ['-lpng -lz -lm'],
18
+       INC          => '-I%%LOCALBASE%%/include',
19
+       LIBS         => ['-L%%LOCALBASE%%/lib -lpng -lz -lm'],
20
      );
21
  }
22
 else

Return to bug 142748