Bug 232832 - Please fix lazy written PHP scripts in gettext-tools/tests/
Summary: Please fix lazy written PHP scripts in gettext-tools/tests/
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: gettext
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jens Petersen
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: FC7Target
TreeView+ depends on / blocked
 
Reported: 2007-03-18 15:08 UTC by Robert Scheck
Modified: 2007-11-30 22:11 UTC (History)
0 users

Fixed In Version: 0.16.1-8
Clone Of:
Environment:
Last Closed: 2007-05-25 22:37:55 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Robert Scheck 2007-03-18 15:08:06 UTC
Description of problem:
Please fix lazy written PHP scripts in gettext-tools/tests/. There *always* 
should be "<?php" used in favor over "<?". 

Version-Release number of selected component (if applicable):
gettext-0.16.1-7

How reproducible:
Possible problems are caused when "short_open_tag = Off" is set in /etc/php.ini

Actual results:
Lazy written PHP scripts in gettext-tools/tests/

Expected results:
Apply the following fixes or better. Hopefully I forgot no file to patch...

--- ./gettext-tools/tests/xgettext-php-1     2006-11-27 18:02:11.000000000 +0100
+++ ./gettext-tools/tests/xgettext-php-1.rsc 2007-03-18 16:03:40.000000000 +0100
@@ -7,7 +7,7 @@

 tmpfiles="$tmpfiles xg-ph-1.php"
 cat <<EOF > xg-ph-1.php
-<?
+<?php
 // This comment will not be extracted.
 echo _("help");
 //  TRANSLATORS: This is an extracted comment.
--- ./gettext-tools/tests/xgettext-php-2     2006-05-15 14:23:49.000000000 +0200
+++ ./gettext-tools/tests/xgettext-php-2.rsc 2007-03-18 16:03:52.000000000 +0100
@@ -7,7 +7,7 @@

 tmpfiles="$tmpfiles xg-ph-2.php"
 cat <<EOF > xg-ph-2.php
-<?
+<?php
 echo _("Egyptians");
 echo <<<EOTMARKER
 Ramses
--- ./gettext-tools/tests/lang-php      2006-11-27 18:02:08.000000000 +0100
+++ ./gettext-tools/tests/lang-php.rsc  2007-03-18 16:04:42.000000000 +0100
@@ -9,7 +9,7 @@

 tmpfiles="$tmpfiles prog.php"
 cat <<\EOF > prog.php
-<?
+<?php
   setlocale (LC_ALL, "");
   textdomain ("prog");
   bindtextdomain ("prog", ".");
--- ./gettext-tools/tests/prog.php      2007-03-18 15:41:56.000000000 +0100
+++ ./gettext-tools/tests/prog.php.rsc  2007-03-18 16:04:53.000000000 +0100
@@ -1,4 +1,4 @@
-<?
+<?php
   setlocale (LC_ALL, "");
   textdomain ("prog");
   bindtextdomain ("prog", ".");

Comment 1 Jens Petersen 2007-03-19 03:09:37 UTC
Patch sent upstream to bug-gnu-utils.

Comment 2 Jens Petersen 2007-03-19 03:33:05 UTC
prog.php is a generated file I think.

Comment 3 Jens Petersen 2007-03-19 04:16:54 UTC
Thanks, patch added in package cvs.

Comment 4 Robert Scheck 2007-03-19 06:39:21 UTC
Thank you. Yeah, it's possible that I took a generated file, too. I did a make 
and after a make clean I worked out the replacements. But unfortunately I 
noticed the following error a few minutes ago when doing a local rebuild:

SKIP: lang-perl-2
2c2
< EUR remplace FF.
---
> EUR remplace FF.16
FAIL: lang-php

Any ideas?

Comment 5 Jens Petersen 2007-03-19 07:42:38 UTC
I just tried and it fails for me both with and without the patch.

Comment 6 Robert Scheck 2007-03-19 09:54:32 UTC
Yepp, patch doesn't change anything, but it fixes the lame upstream coding 
behaviour ;-)

Comment 7 Robert Scheck 2007-03-25 09:51:37 UTC
Oh, the Gentoo guys have the same problem: http://bugs.gentoo.org/
show_bug.cgi?id=159640

Comment 8 Jens Petersen 2007-03-26 00:50:25 UTC
BTW upstream only applied the patch to lang-php saying the other
test php code is not actually executed.

Comment 9 Robert Scheck 2007-04-29 09:44:45 UTC
Ping?

Comment 10 Jens Petersen 2007-04-30 08:16:17 UTC
Should be fixed in gettext-0.16.1-8.fc7.


Note You need to log in before you can comment on or make changes to this bug.