ports/69453: [MAINTAINER] multimedia/y4mscaler: [fix with gcc 3.4]

Michael Johnson ahze at ahze.net
Fri Jul 23 01:20:18 UTC 2004


>Number:         69453
>Category:       ports
>Synopsis:       [MAINTAINER] multimedia/y4mscaler: [fix with gcc 3.4]
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul 23 01:20:17 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Michael Johnson
>Release:        FreeBSD 5.2-CURRENT i386
>Organization:
>Environment:
System: FreeBSD gentoo.ahze.net 5.2-CURRENT FreeBSD 5.2-CURRENT #57: Fri Jul 16 00:36:31 EDT 2004
>Description:
- Fix build with gcc 3.4

Generated with FreeBSD Port Tools 0.50
>How-To-Repeat:
>Fix:

--- y4mscaler-0.6.1.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/multimedia/y4mscaler.orig/files/patch-gcc34 /usr/ports/multimedia/y4mscaler/files/patch-gcc34
--- /usr/ports/multimedia/y4mscaler.orig/files/patch-gcc34	Wed Dec 31 19:00:00 1969
+++ /usr/ports/multimedia/y4mscaler/files/patch-gcc34	Thu Jul 22 21:10:33 2004
@@ -0,0 +1,158 @@
+--- graphics.H.orig	Thu Jul 22 20:50:55 2004
++++ graphics.H	Thu Jul 22 21:00:44 2004
+@@ -338,7 +338,7 @@
+   ysRatioPoint effective_sample_offset(Field field, Plane plane) const;
+ 
+   const char *mode_to_string() const;
+-  void log_info(enum log_level_t level, const char *prefix) const;
++  void log_info(const log_level_t level, const char *prefix) const;
+ 
+   int parse_mode(const char *s);
+ };
+--- kernels.C.orig	Thu Jul 22 21:03:47 2004
++++ kernels.C	Thu Jul 22 21:03:59 2004
+@@ -316,7 +316,7 @@
+ 
+ ysKernelFactory::ysKernelFactory()
+ {
+-  _kernel_list = new (ysKernel*)[20];
++  _kernel_list = new ysKernel* [20];
+   _count = 0;
+   _kernel_list[_count++] = new BoxKernel;
+   _kernel_list[_count++] = new LinearKernel;
+--- scaler-matto.C.orig	Thu Jul 22 21:02:35 2004
++++ scaler-matto.C	Thu Jul 22 21:03:40 2004
+@@ -334,7 +334,7 @@
+   DBG("setup kernel cache\n");
+   DBG("  scale %f  p0 %f\n", scale, p0);
+ 
+-  KS = new (mattoScaler::kernelSet)[Dsize];
++  KS = new mattoScaler::kernelSet [Dsize];
+   minspot = Smax + 1;
+   maxspot = Smin - 1;
+ 
+@@ -348,7 +348,7 @@
+ 
+     int spot0 = (int)floor(Pq) - supp;
+     int spot1 = (int)floor(Pq) + supp + 1;
+-    KS[q].K = new (int)[spot1 - spot0 + 1];
++    KS[q].K = new int [spot1 - spot0 + 1];
+     KS[q].offset = 0;
+     KS[q].width = 0;
+     int valsum = 0;
+@@ -477,7 +477,7 @@
+   } else {
+     TframeX = Dx;
+     TframeY = _Ymaxspot - _Yminspot + 1;
+-    tempo = new (int)[TframeX * TframeY];
++    tempo = new int [TframeX * TframeY];
+     scaling_function = &mattoScaler::scale_x_then_y;
+   }
+ 
+@@ -573,7 +573,7 @@
+   } else {
+     TframeY = Dy;
+     TframeX = _Xmaxspot - _Xminspot + 1;
+-    tempo = new (int)[TframeY * TframeX];
++    tempo = new int [TframeY * TframeX];
+     scaling_function = &mattoScaler::scale_y_then_x;
+   }
+ }
+--- ysScaling.C.orig	Thu Jul 22 21:04:17 2004
++++ ysScaling.C	Thu Jul 22 21:06:24 2004
+@@ -246,7 +246,7 @@
+     _scaler_count = 1;
+   else
+     _scaler_count = 3;
+-  _scalers = new (ysScaler *)[_scaler_count];
++  _scalers = new ysScaler *[_scaler_count];
+   for (int i = 0; i < _scaler_count; i++)
+     _scalers[i] = _factory->new_scaler();
+ 
+@@ -310,7 +310,7 @@
+     _scaler_count = 1;
+   else
+     _scaler_count = 5;
+-  _scalers = new (ysScaler *)[_scaler_count];
++  _scalers = new ysScaler *[_scaler_count];
+   for (int i = 0; i < _scaler_count; i++)
+     _scalers[i] = _factory->new_scaler();
+ 
+@@ -464,8 +464,8 @@
+   y4m_init_frame_info(&frameinfo);
+ 
+   for (int i = 0; i < 3; i++) {
+-    in_frame[i] = new (uint8_t)[source.stream().framedim(i).area()];
+-    out_frame[i] = new (uint8_t)[target.stream().framedim(i).area()];
++    in_frame[i] = new uint8_t[source.stream().framedim(i).area()];
++    out_frame[i] = new uint8_t[target.stream().framedim(i).area()];
+     if (_mono && (i != 0)) {
+       memset(out_frame[i], 128,
+ 	     target.stream().framedim(i).area());
+@@ -530,9 +530,9 @@
+ 
+   y4m_init_frame_info(&frameinfo);
+ 
+-  out_field_top[0] = new (uint8_t)[target.stream().fielddim(0).area()];
+-  out_field_top[1] = new (uint8_t)[target.stream().fielddim(1).area()];
+-  out_field_bottom[0] = new (uint8_t)[target.stream().fielddim(0).area()];
++  out_field_top[0] = new uint8_t[target.stream().fielddim(0).area()];
++  out_field_top[1] = new uint8_t[target.stream().fielddim(1).area()];
++  out_field_bottom[0] = new uint8_t[target.stream().fielddim(0).area()];
+   memset(out_field_top[0],
+ 	 target.bgcolor().Y, target.stream().fielddim(0).area());
+   memset(out_field_bottom[0],
+@@ -543,9 +543,9 @@
+     out_field_bottom[2] = out_field_top[1];
+     memset(out_field_top[1], 128, target.stream().fielddim(1).area());
+   } else {
+-    out_field_top[2] = new (uint8_t)[target.stream().fielddim(2).area()];
+-    out_field_bottom[1] = new (uint8_t)[target.stream().fielddim(1).area()];
+-    out_field_bottom[2] = new (uint8_t)[target.stream().fielddim(2).area()];
++    out_field_top[2] = new uint8_t[target.stream().fielddim(2).area()];
++    out_field_bottom[1] = new uint8_t[target.stream().fielddim(1).area()];
++    out_field_bottom[2] = new uint8_t[target.stream().fielddim(2).area()];
+     memset(out_field_top[1],
+            target.bgcolor().Cb, target.stream().fielddim(1).area());
+     memset(out_field_bottom[1],
+@@ -556,14 +556,14 @@
+            target.bgcolor().Cr, target.stream().fielddim(2).area());
+   }
+ 
+-  in_field_top = new (uint8_t *)[3];
+-  in_field_bottom = new (uint8_t *)[3];
+-  in_field_other = new (uint8_t *)[3];
++  in_field_top = new uint8_t *[3];
++  in_field_bottom = new uint8_t *[3];
++  in_field_other = new uint8_t *[3];
+ 
+   for (int i = 0; i < 3; i++) {
+-    in_field_top[i] = new (uint8_t)[source.stream().fielddim(i).area()];
+-    in_field_bottom[i] = new (uint8_t)[source.stream().fielddim(i).area()];
+-    in_field_other[i] = new (uint8_t)[source.stream().fielddim(i).area()];
++    in_field_top[i] = new uint8_t[source.stream().fielddim(i).area()];
++    in_field_bottom[i] = new uint8_t[source.stream().fielddim(i).area()];
++    in_field_other[i] = new uint8_t[source.stream().fielddim(i).area()];
+   }
+ 
+ 
+--- ysStreamInfo.H.orig	Thu Jul 22 21:01:43 2004
++++ ysStreamInfo.H	Thu Jul 22 21:02:25 2004
+@@ -86,7 +86,7 @@
+   /* basic methods */
+   int read_stream_header(int fdin);
+   int write_stream_header(int fdout);
+-  void log_info(enum log_level_t level, const char *prefix) const;
++  void log_info(const log_level_t level, const char *prefix) const;
+ 
+   /* derivative methods */
+   int parse_dimensions(const char *s);
+@@ -97,7 +97,7 @@
+ const char *ilace_to_string(int i);
+ 
+ 
+-inline void ysStreamInfo::log_info(enum log_level_t level,
++inline void ysStreamInfo::log_info(const log_level_t level,
+ 				   const char *prefix) const
+ {
+   y4m_log_stream_info(level, prefix, &_streaminfo);
--- y4mscaler-0.6.1.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list