patchmldonkey, a multi-networks file-sharing client - Patches: patch #8123, configure: Fix GD version check...

 
 

You are not allowed to post comments on this tracker with your current authentification level.

patch #8123: configure: Fix GD version check for GD 2.1.x

Submitted by:  Ryan Schmidt <ryandesign>
Submitted on:  Sat 13 Jul 2013 02:47:16 PM UTC  
 
Category: Bug fixesPriority: 7 - High
Status: DoneAssigned to: spiralvoice <spiralvoice>
Open/Closed: Closed

(Jump to the original submission Jump to the original submission)

Sat 20 Jul 2013 10:15:08 AM UTC, comment #12:

committed 2013/07/20

spiralvoice <spiralvoice>
Project AdministratorIn charge of this item.
Sat 20 Jul 2013 10:13:44 AM UTC, comment #11:

patch updated

(file #28623)

spiralvoice <spiralvoice>
Project AdministratorIn charge of this item.
Fri 19 Jul 2013 06:28:41 AM UTC, comment #10:

And I think there's no point checking that $GDMINORVERSION -eq 0 at that point since we already know it is, having handled $GDMINORVERSION -ge 1 right before it.

Ryan Schmidt <ryandesign>
Fri 19 Jul 2013 06:15:18 AM UTC, comment #9:

Looks good except in the else section it should be

Ryan Schmidt <ryandesign>
Mon 15 Jul 2013 05:05:47 PM UTC, comment #8:

Assuming that all GD versions > 2.0.14 will work with MLDonkey I am proposing the attached patch, tested with

checking for libgd > 2.0.14... 2.0.33
checking for libgd > 2.0.14... 2.1.1-dev

(file #28588)

spiralvoice <spiralvoice>
Project AdministratorIn charge of this item.
Mon 15 Jul 2013 02:11:11 PM UTC, comment #7:

It doesn't look like gdlib-config in gd 2.1.0 uses pkg-config; it's a standalone shell script. Using pkg-config directly when available would be great. Of course gd 2.0.x doesn't come with a pkg-config file.

Ryan Schmidt <ryandesign>
Mon 15 Jul 2013 08:44:07 AM UTC, comment #6:

Also note that since 2.1.0 gd (finally!) includes pkg-config support (actually gdlib-config calls pkg-config under the covers) and we should probably use it (pkg-config conveniently provides --atleast-version switch)

ygrek <ygrek>
Project Member
Mon 15 Jul 2013 04:51:29 AM UTC, comment #5:

Thanks. I don't think the problem you experienced was a result of any OS differences, but rather that I had installed gd "2.1.0" and you installed "2.1.1-dev". I had not realized that newer development versions of gd were already available; that development versions would have their own version numbers; or that those version numbers would not be completely numeric.

I believe your new code works fine for gd 2.1.x and earlier, however you'll have the same problem again if and when gd 2.2.0 or later are released. If I modify gdlib-config to claim to be 2.2.0, I get:

+verbose+
----- checking gd (optional)
checking for gdlib-config... gdlib-config
checking for libgd > 2.0.14... no (found 2.2.0)
configure: libgd not available
-verbose-

I think you'll want to fix this.

If I modify gdlib-config to claim to be 3.0.0, I get:

+verbose+
----- checking gd (optional)
checking for gdlib-config... gdlib-config
checking for libgd > 2.0.14... configure: libgd not available
-verbose-

In this code path, LIBGD isn't set at all, resulting in the first message being truncated and not printing the found gd version number and the second message appearing on the same line. This should be fixed by setting LIBGD to "no" in this code path.

That's assuming that you want to err on the side of caution and not claim support for a hypothetical future gd 3 at this time. That's probably reasonable; if gd changes enough to warrant a version number increase to 3, it's likely that some existing code won't work with it. However, the message printed should make it more clear (i.e. "checking for libgd > 2.0.14 < 3.0.0...").

Ryan Schmidt <ryandesign>
Sat 13 Jul 2013 03:05:46 PM UTC, comment #4:

The patch provided with file #28552 fails on Debian jessie/amd64

----- checking gd (optional)
checking for gdlib-config... gdlib-config
checking for libgd > 2.0.14... expr: non-integer argument
./configure: line 6822: test: -gt: unary operator expected
no (found 2.1.1-dev)
configure: libgd not available

The attached patch works for me on jessie and sarge, please test on OS X.

(file #28560)

spiralvoice <spiralvoice>
Project AdministratorIn charge of this item.
Sat 13 Jul 2013 02:47:16 PM UTC, comment #3:

This item has been reassigned from the project mldonkey, a multi-networks file-sharing client bugs tracker to your tracker.

The original report is still available at bugs #39436

Following are the information included in the original report:

[field #0] Item ID: 39436
[field #1] Group ID: 1409
[field #2] Open/Closed: Open
[field #3] Severity: 3 - Normal
[field #4] Privacy: Public
[field #8] : Unknown bugs Field Display Type
[field #9] Category: Core
[field #10] Submitted by: ryandesign
[field #11] Assigned to: None
[field #12] Submitted on: Mo 08 Jul 2013 08:21:57 CEST
[field #13] Summary: gd version check wrong
[field #14] Original Submission: On OS X 10.8.4, configuring mldonkey 3.1.3 with gd 2.1.0 installed produces this output:

And then it proceeds to build mldonkey without gd support.

Clearly this version check is wrong.
[field #16] Item Group: Compilation problem
[field #17] Status: None
[field #18] Component Version: None
[field #19] Operating System: None
[field #20] Reproducibility: None
[field #21] Size (loc): None
[field #22] Fixed Release: None
[field #23] Planned Release: None
[field #24] Effort: 0.00
[field #28] Priority: 5 - Normal
[field #31] Percent Complete: 0%
[field #33] Release: None
[field #34] Release: 3.1.3
[field #58] Binaries Origin: None
[field #59] CPU type: x86_64
[field #60] CPU: None
[field #61] Custom Select Box #4: None
[field #62] Custom Select Box #5: None
[field #63] Custom Select Box #6: None
[field #64] Custom Select Box #7: None
[field #65] Custom Select Box #8: None
[field #66] Custom Select Box #9: None
[field #67] Custom Select Box #10: None

spiralvoice <spiralvoice>
Project AdministratorIn charge of this item.
Fri 12 Jul 2013 08:18:56 AM UTC, comment #2:

Fixed the patch to check for gd > 2.0.14 (not gd >= 2.0.14 as before).

(file #28552)

Ryan Schmidt <ryandesign>
Fri 12 Jul 2013 08:08:07 AM UTC, comment #1:

I'm attaching a patch to fix this, based on the fix for the same problem in mapserver, from https://github.com/mapserver/mapserver/issues/4696

(file #28551)

Ryan Schmidt <ryandesign>
Sat 13 Jul 2013 02:47:16 PM UTC, original submission:

On OS X 10.8.4, configuring mldonkey 3.1.3 with gd 2.1.0 installed produces this output:

And then it proceeds to build mldonkey without gd support.

Clearly this version check is wrong.

Ryan Schmidt <ryandesign>

 

Attached Files
file #28623:  8123.patch added by spiralvoice (1kB - text/x-patch)
file #28552:  patch-config-configure.in.diff added by ryandesign (708B - application/octet-stream - corrected patch)
file #28551:  patch-config-configure.in.diff added by ryandesign (709B - application/octet-stream - proposed patch)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by ygrek (Posted a comment)
  • -unavailable- added by spiralvoice (Updated the item)
  • -unavailable- added by ryandesign (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 16 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 20 Jul 2013 10:15:08 AM UTCspiralvoiceStatusReady For Test=>Done
      Open/ClosedOpen=>Closed
    Sat 20 Jul 2013 10:13:44 AM UTCspiralvoiceAttached File-=>Added 8123.patch, #28623
    Sat 20 Jul 2013 10:13:29 AM UTCspiralvoiceAttached File#28588=>Removed
    Mon 15 Jul 2013 05:05:47 PM UTCspiralvoiceAttached File-=>Added 8123.patch, #28588
    Mon 15 Jul 2013 05:02:13 PM UTCspiralvoiceAttached File#28587=>Removed
    Mon 15 Jul 2013 04:24:08 PM UTCspiralvoiceAttached File-=>Added 8123.patch, #28587
    Mon 15 Jul 2013 04:24:01 PM UTCspiralvoiceAttached File#28560=>Removed
    Sat 13 Jul 2013 03:05:46 PM UTCspiralvoiceAttached File-=>Added 8123.patch, #28560
      Priority5 - Normal=>7 - High
      StatusWorks For Me=>Ready For Test
      Assigned toNone=>spiralvoice
    Sat 13 Jul 2013 02:48:03 PM UTCspiralvoiceCategoryNone=>Bug fixes
      StatusNone=>Works For Me
      Summarygd version check wrong=>configure: Fix GD version check for GD 2.1.x
    Sat 13 Jul 2013 02:47:16 PM UTCspiralvoiceReassign itemmldonkey, a multi-networks file-sharing client, bug #39436=>mldonkey, a multi-networks file-sharing client, patch #8123

    Back to the top


    Powered by Savane 3.1-cleanup