From: Marius Storm-Olsen Date: Mon, 18 Jul 2011 12:08:12 +0000 (-0500) Subject: Close filehandle when done X-Git-Tag: qt-v5.0.0-alpha1~3934 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=210211b7793bef626c085a354aa72ab6a397087b;p=profile%2Fivi%2Fqtbase.git Close filehandle when done Also add a fixme, since the version headers are currently being created in the source directory. Change-Id: If6e9eeba854a1f35561b69518eb8739dc28a58be Reviewed-on: http://codereview.qt.nokia.com/1763 Reviewed-by: Qt Sanity Bot Reviewed-by: Joerg Bornemann --- diff --git a/bin/syncqt b/bin/syncqt index 776ee9c..afa3238 100755 --- a/bin/syncqt +++ b/bin/syncqt @@ -870,6 +870,7 @@ foreach my $lib (@modules_to_sync) { my $modulepri = $modulepris{$lib}; if (-e $modulepri) { my $modulepriname = basename($modulepri); + # FIXME: this creates a file in the source location for shadow-builds my $moduleversionheader = "$modules{$lib}/" . lc($lib) . "version.h"; my $modulehexstring = sprintf("0x%02X%02X%02X", int($module_major_version), int($module_minor_version), int($module_patch_version)); open MODULE_VERSION_HEADER_FILE, ">$moduleversionheader"; @@ -882,6 +883,8 @@ foreach my $lib (@modules_to_sync) { print MODULE_VERSION_HEADER_FILE "#define " .uc($lib) . "_VERSION $modulehexstring\n", ; print MODULE_VERSION_HEADER_FILE "\n"; print MODULE_VERSION_HEADER_FILE "#endif // QT_". uc($lib) . "_VERSION_H\n"; + close MODULE_VERSION_HEADER_FILE; + print "$moduleversionheader created for $lib\n" if(!$quiet); } elsif ($modulepri) { print "WARNING: Module $lib\'s pri file '$modulepri' not found.\nSkipped creating module version header for $lib.\n"; }