Bug #45515 MySQL Workbench Source RPM not rebuildable
Submitted: 16 Jun 2009 7:38 Modified: 5 Aug 2009 16:42
Reporter: Lenz Grimmer Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.1.13 OS:Linux (openSUSE 11.0)
Assigned to: Alfredo Kojima CPU Architecture:Any
Tags: building, CHECKED, compiling, rpm

[16 Jun 2009 7:38] Lenz Grimmer
Description:
I downloaded the Source RPM mysql-workbench-oss-5.1.13-1fc10.src.rpm and tried to rebuild it. However, it seems like the SRPM includes the unmodified template "mysql-workbench.spec.in" instead of the spec file that includes the replaced variables. Trying to compile using this spec file fails:

lenz@thebe:/usr/src/packages> rpmbuild -ba --clean SPECS/mysql-workbench.spec.in
error: File /usr/src/packages/SOURCES/mysql-workbench-oss-@VERSION@.tar.gz: No such file or directory

This is because @VERSION@ should have been replaced with the appropriate version string before the packaging process. In addition to that, the spec file suffix should be ".spec", not ".spec.in".

How to repeat:
Download the Source RPM and try to rebuild it. Observe that the file name suffix is wrong and that it contains unprocessed placeholders.

Suggested fix:
Fix the build process to generate a proper RPM specfile
[20 Jun 2009 8:52] Valeriy Kravchuk
Thank you for the problem report. Please, try to repeat with a newer version, 5.1.14, and inform about the results.
[29 Jun 2009 20:56] Lenz Grimmer
This is still the case for version 5.1.15. Interestingly, the RPM rebuilds when using "rpmbuild --rebuild mysql-workbench-oss-5.1.15-1fc10.src.rpm".

However, the spec file included should not end on ".in" and the version number placeholder @VERSION@ in the specfile should be replaced with the proper version string...
[30 Jun 2009 9:36] Susanne Ebrecht
Lenz,

I agree with you that this should work on Suse as well. But please consider, at the moment Suse is not an officially supported platform.

At the moment supported linux platforms are only Fedora and Ubuntu

Anyway, I will set this as bug and not as feature request.
[30 Jun 2009 10:56] Lenz Grimmer
This isn't actually specific to SUSE Linux. It will show up on any RPM-based Linux distribution.
[4 Aug 2009 19:17] Alfredo Kojima
Problem has been fixed for the next release of WB 5.1 and 5.2
Thanks for the heads up.
[5 Aug 2009 16:42] Tony Bedford
An entry was added to the 5.1.17 and 5.2.3 changelogs:

Attempts to rebuild the MySQL Workbench source RPM failed. The RPM appeared to contain an unmodified template mysql-workbench.spec.in instead of the correct spec file with variable placeholders replaced by actual values.

When using the following command to rebuild the RPM:

shell> rpmbuild -ba --clean SPECS/mysql-workbench.spec.in

The following error was generated:

error: File /usr/src/packages/SOURCES/mysql-workbench-oss-@VERSION@.tar.gz: 
No such file or directory

Further, the spec file in the package had the incorrect suffix “.spec.in” instead of “.spec”.