Bug 1197070 - mapserver: FTBFS with SWIG 3.0.5
Summary: mapserver: FTBFS with SWIG 3.0.5
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: mapserver
Version: 21
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Pavel Lisý
QA Contact: Fedora Extras Quality Assurance
URL: https://koji.fedoraproject.org/koji/t...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-02-27 13:00 UTC by Jitka Plesnikova
Modified: 2015-12-02 17:33 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2015-12-02 09:31:53 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Fix coment and %pythoncode blocks for SWIG 3.0.5 (2.26 KB, patch)
2015-02-27 13:00 UTC, Jitka Plesnikova
no flags Details | Diff

Description Jitka Plesnikova 2015-02-27 13:00:10 UTC
Created attachment 996016 [details]
Fix coment and %pythoncode blocks for SWIG 3.0.5

The build failed with following error:

javamodule.i:4: Error: Unknown SWIG preprocessor directive: Uncomment (if this is a block of target language code, delimit it with %{ and %})
javamodule.i:5: Error: Unknown SWIG preprocessor directive: with (if this is a block of target language code, delimit it with %{ and %})
Makefile:60: recipe for target 'javamapscript_wrap.c' failed

The comments in the files starts with #, but such comments are not allowed  outside of %pythoncode/%perlcode block. Otherwise, these comments are handled by preprocessor as a macro.

The issue was previously ignored, but now it is reported as error.

SWIG allows C++-style comments. So, to fix the issue,  the lines which start with # but which aren't preprocessor statements should be changed. 

The issue is cause due to changes in SWIG 3.0.3.
I created patch and it fixed the build issue for me in F21.
Fedora 21 and higher are affected.


Additional info:
The %pythoncode blocks are also updated in the patch to prevent other issue.

From SWIG documentation 
http://www.swig.org/Doc3.0/SWIGDocumentation.html#Python_nn42

When using %pythoncode and %pythonbegin you generally want to make sure that the block is delimited by %{ and %}. If you delimit it with { and } then any lines with a leading # will be handled by SWIG as preprocessor directives, when you probably meant them as Python comments. Prior to SWIG 3.0.3, invalid preprocessor directives were silently ignored, so generally using the wrong delimiters resulted in such comments not appearing in the generated output (though a comment starting with a valid preprocessor directive could cause problems, for example: # error handling). SWIG 3.0.3 and later report an error for invalid preprocessor directives, so you may have to update existing interface files to delimit blocks of Python code correctly.

Comment 1 Fedora Update System 2015-03-19 15:02:18 UTC
mapserver-6.2.2-3.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/mapserver-6.2.2-3.fc21

Comment 2 Fedora Update System 2015-03-21 05:02:20 UTC
Package mapserver-6.2.2-3.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing mapserver-6.2.2-3.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2015-4341/mapserver-6.2.2-3.fc21
then log in and leave karma (feedback).

Comment 3 Fedora End Of Life 2015-11-04 16:03:20 UTC
This message is a reminder that Fedora 21 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 21. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '21'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 21 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 4 Fedora End Of Life 2015-12-02 09:31:57 UTC
Fedora 21 changed to end-of-life (EOL) status on 2015-12-01. Fedora 21 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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