Bug 74570 - Custom makefiles project doesn't support "GNUmakefile" file name
Summary: Custom makefiles project doesn't support "GNUmakefile" file name
Status: RESOLVED FIXED
Alias: None
Product: kdevelop
Classification: Applications
Component: general (show other bugs)
Version: 3.0.0
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: KDevelop Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-02-08 14:43 UTC by Lukasz Wojtylak
Modified: 2004-03-29 20:20 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Enables "GNUmakefile" file name in custom makefiles project (686 bytes, patch)
2004-02-08 14:46 UTC, Lukasz Wojtylak
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lukasz Wojtylak 2004-02-08 14:43:30 UTC
Version:           3.0.0 (using KDE KDE 3.2.0)
Installed from:    Compiled From Sources
Compiler:          gcc-3.3.1 
OS:          Linux

Custom makefiles project should allow also "GNUmakefile" as the make file name. Here's a simple patch to the file buildtools/custommakefiles/customprojectpart.cpp:

--- customprojectpart.cpp.orig	2004-01-17 13:57:20.000000000 +0100
+++ customprojectpart.cpp	2004-02-08 14:23:01.000000000 +0100
@@ -503,9 +503,9 @@
     bool ant = DomUtil::readEntry(dom, "/kdevcustomproject/build/buildtool") == "ant";
 
     if (!ant) {
-        QFileInfo fi(dir + "/Makefile");
-	QFileInfo fi2(dir + "/makefile");
-        if (!fi.exists() && !fi2.exists()) {
+        if (!QFile::exists(dir + "/Makefile") && !QFile::exists(dir + "/makefile") &&
+	      !QFile::exists(dir + "/GNUmakefile"))
+	{
             KMessageBox::information(mainWindow()->main(),
                                      i18n("There is no Makefile in this directory."));
             return;
Comment 1 Lukasz Wojtylak 2004-02-08 14:46:57 UTC
Created attachment 4574 [details]
Enables "GNUmakefile" file name in custom makefiles project

Sorry for posting the patch twice (in the bug report and in this attachment);
it is my first KDE bug reported.
Comment 2 John Firebaugh 2004-03-14 19:30:39 UTC
CVS commit by firebaugh: 

Don't try to outguess make, it will produce a fine error message if no makefile is found.

CCMAIL: 74570-done@bugs.kde.org


  M +0 -10     customprojectpart.cpp   1.71


--- kdevelop/buildtools/custommakefiles/customprojectpart.cpp  #1.70:1.71
@@ -503,14 +503,4 @@ void CustomProjectPart::startMakeCommand
     bool ant = DomUtil::readEntry(dom, "/kdevcustomproject/build/buildtool") == "ant";
 
-    if (!ant) {
-        QFileInfo fi(dir + "/Makefile");
-        QFileInfo fi2(dir + "/makefile");
-        if (!fi.exists() && !fi2.exists()) {
-            KMessageBox::information(mainWindow()->main(),
-                                     i18n("There is no Makefile in this directory."));
-            return;
-        }
-    }
-
     QString cmdline;
     if (ant) {


Comment 3 Jens Dagerbo 2004-03-29 20:20:08 UTC
CVS commit by dagerbo: 

Don't try to outguess make, it will produce a fine error message if no makefile is found.

CCMAIL: 74570@bugs.kde.org


  M +0 -10     customprojectpart.cpp   1.68.2.2


--- kdevelop/buildtools/custommakefiles/customprojectpart.cpp  #1.68.2.1:1.68.2.2
@@ -503,14 +503,4 @@ void CustomProjectPart::startMakeCommand
     bool ant = DomUtil::readEntry(dom, "/kdevcustomproject/build/buildtool") == "ant";
 
-    if (!ant) {
-        QFileInfo fi(dir + "/Makefile");
-        QFileInfo fi2(dir + "/makefile");
-        if (!fi.exists() && !fi2.exists()) {
-            KMessageBox::information(mainWindow()->main(),
-                                     i18n("There is no Makefile in this directory."));
-            return;
-        }
-    }
-
     QString cmdline;
     if (ant) {