Re: win32 compilation of make 4.0 source code
On Mon, Jan 27, 2014 at 11:05 PM, Mark Brown mkbrown_...@hotmail.com wrote: From: Paul Smith Sent: Monday, January 27, 2014 8:57 PM ... ifneq ($(filter else-if,$(.FEATURES)),else-if) $(error Version $(MAKE_VERSION) does not support else-if) endif Are you saying that this statement can be placed outside of a make target recipe command sequence, and would be executed before the target recipe command sequence ? The answer to your question can be found in the GNU make info pages. Or, you could just TRY IT AND GET THE ANSWER INSTANTLY. This is what the new make 4.0 manual says about -trace capability: = ‘--trace’ Show tracing information for make execution. Prints the entire recipe to be executed, even for recipes that are normally silent (due to .SILENT or ‘@’). Also prints the makefile name and line number where the recipe was defined, and information on why the target is being rebuilt. = Again, this is a re-paste of the desired output, which again you deleted in your reply: == $(CC) -c $(CFLAGS) $ -o $@ Make_filename Makefile_Line_Num auto_var_eval auto_var_eval /adir/bdir/cdir/Makefile554.mk 1177 make_debug.c make_debug.o === In GNU make 4.0 the --trace option was introduced. From the NEWS file: * New command line option: --trace enables tracing of targets. When enabled ... Does this trace capability display the full evaluated automatic variables ? Why not include a sample paste of its output. You've been unwilling to given any specific examples of your problems, makefile snippets, or output, and yet you question when other don't provide them? Since you obviously don't have the current version of make installed, why would anyone bother? Philip Guenther Your role is maintenance of the make project. It is not your role to solve other people's engineering problems. When a bug or omission is presented to you, you have at least 3 appropriate response options: 1) we do not think that is an issue that needs to be solved by make, 2) that issue needs to be solved in make, and it is, but in a different way from what may be apparent from the documentation or intuitive, Read the following link URL, chapter, section etc. 3) we do think that issue should solved by make, but it has yet to be implemented. ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make
Re: win32 compilation of make 4.0 source code
First, let me request that you include the question posed to you, in your Reply responses in this email sequence. 1) I think my question was explicit. A method for an existing Makefile to test for .FEATURES capabilities when it is downloaded to a random linux or Windows make environment and existed. The Makefile itself when e.g make target is selected, should be able to precede execution of any target with a check of .FEATURES to verify the make environment into which it is downloaded. Give an example of .FEATURES display/echo in an existing Makefile., both v 3.80 and 4.00 . 2) Also, please answer the other question posed: --- I also want to know if there is a debug mode within make in which the Makefile filename and Line Number (some Makefiles are huge and distributed over several subordinate Makefiles) is matched to each automatic variable evaluation within a Target evaluation. --- If either of these make capabilities are not possible currently, then that is a case for implementation in Make version 4.1 . -Original Message- From: Paul Smith Sent: Monday, January 27, 2014 9:35 AM To: Mark Brown Cc: bug-make@gnu.org Subject: Re: win32 compilation of make 4.0 source code On Sun, 2014-01-26 at 16:22 -0800, Mark Brown wrote: That example method is a device to perform this .FEATURES test without inserting it into an existing Makefile. The syntax errors I was seeing were occurring when attempting to insert this test into an existing Makefile, full of Targets and command sequences. Well, since you've provided no details about exactly what you tried and what errors you received, or even details about exactly what you're trying to do, there's not much else we can say. You said echo the data, and I showed an example of echoing the data. If that's not what you want, you need to give more information. ==re-pasted text of the question posed= That example method is a device to perform this .FEATURES test without inserting it into an existing Makefile. The syntax errors I was seeing were occurring when attempting to insert this test into an existing Makefile, full of Targets and command sequences. If this feature is used it would be at the top of an existing Makefile, before any targets are evaluated. I also want to know if there is a debug mode within make in which the Makefile filename and Line Number (some Makefiles are huge and distributed over several subordinate Makefiles) is matched to each automatic variable evaluation within a Target evaluation. = ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make
Re: win32 compilation of make 4.0 source code
-Original Message- From: Philip Guenther Sent: Monday, January 27, 2014 1:34 PM To: Mark Brown Cc: Paul Smith ; bug-make Subject: Re: win32 compilation of make 4.0 source code (Dang it: gmail treats control-enter as send...) [Gmail is overrated. When I saw I could not free create folders and move messages between them, I bailed on Gmail.] On Mon, Jan 27, 2014 at 1:12 PM, Philip Guenther guent...@gmail.com wrote: On Mon, Jan 27, 2014 at 9:59 AM, Mark Brown mkbrown_...@hotmail.com wrote: First, let me request that you include the question posed to you, in your Reply responses in this email sequence. How about you stop top-posting and instead reply inline? Ok. 1) I think my question was explicit. A method for an existing Makefile to test for .FEATURES capabilities when it is downloaded to a random linux or Windows make environment and existed. sigh That wasn't the question you originally asked. To quote your original query about .FEATURES: As a separate related issue, I was try to echo the .FEATURES information, since one of the its it claims to display mentions its Else If capabilities. However, every time I tried to echo the data I received a syntax error. What would be an example of a Makefile contents which would display the .FEATURES information ? Makefile contents is operative here. The example that Paul gave answers that original question: all: echo ${.FEATURES} So now you have a new question The Makefile itself when e.g make target is selected, should be able to precede execution of any target with a check of .FEATURES to verify the make environment into which it is downloaded. Give an example of .FEATURES display/echo in an existing Makefile., both v 3.80 and 4.00 . This is where Paul question of what did you already try? comes in. Rather than give you a fish, it would be better to teach you how to fish; seeing what you tried would let us correct whatever misunderstanding caused the syntax errors you got. Or you could search the archives for examples, if you really don't want to understand. I tried -d (which equates to turning on all debug flags) and did not find the trace of a source file or the corresponding output file which I could see being generated when I deleted the output file each time. The particular build I performed generated a 3.2 GBytes file which had to be split into 5 portions to search each one. 2) Also, please answer the other question posed: Hmm, how much are you paying for these answers? Oh right, nothing... I am presenting features that are needed in the Make project for general usage. --- I also want to know if there is a debug mode within make in which the Makefile filename and Line Number (some Makefiles are huge and distributed over several subordinate Makefiles) is matched to each automatic variable evaluation within a Target evaluation. --- Since you don't say what debug output you've already looked at, I'll just suggest two possibilities 1) make -pq and examine the dumped output, which gives file and line number for all commands 2) check out the remake project. http://bashdb.sourceforge.net/remake/ Make documentation indicates that -d would include -p and -q . However, the specific information I am looking for should be readily available. i.e. make -h should highlight the flag which delivers the result I have described. $(CC) -c $(CFLAGS) $ -o $@ Make_filename Makefile_Line_Num auto_var_eval auto_var_eval /adir/bdir/cdir/Makefile554.mk1177 make_debug.c make_debug.o ... ... The current directory would be implied by the Makefile full pathname. If either of these make capabilities are not possible currently, then that is a case for implementation in Make version 4.1 . You didn't describe the problem that you're trying to solve; how do you know that data would solve it? Why *only* automatic variables? If there are several levels of variable expansion involved, what should the output look like? Philip Guenther Whenever I use Make on an existing big project, the information about where a particular source file is compiled is the main thing I want to know. Usually, this affects how additional files could be added to the executable or library related to a particular file. As mentioned, I searched the whole -d output and did not see particular .c sources, for which the .o or .so I knew were being generated by operation of make. Automatic variable resolution has an eventual end and I am sure the make parser is aware when there are no more variable fields within a token string, . At that point, especially for automatic variables like ‘$@’ and ‘$’ , the evaluated result should be displayed along with the full pathname of the current Makefile
Re: win32 compilation of make 4.0 source code
-Original Message- From: Philip Guenther Sent: Monday, January 27, 2014 1:34 PM To: Mark Brown Cc: Paul Smith ; bug-make Subject: Re: win32 compilation of make 4.0 source code (Dang it: gmail treats control-enter as send...) [Gmail is overrated. When I saw I could not free create folders and move messages between them, I bailed on Gmail.] On Mon, Jan 27, 2014 at 1:12 PM, Philip Guenther guent...@gmail.com wrote: On Mon, Jan 27, 2014 at 9:59 AM, Mark Brown mkbrown_...@hotmail.com wrote: First, let me request that you include the question posed to you, in your Reply responses in this email sequence. How about you stop top-posting and instead reply inline? Ok. 1) I think my question was explicit. A method for an existing Makefile to test for .FEATURES capabilities when it is downloaded to a random linux or Windows make environment and existed. sigh That wasn't the question you originally asked. To quote your original query about .FEATURES: As a separate related issue, I was try to echo the .FEATURES information, since one of the its it claims to display mentions its Else If capabilities. However, every time I tried to echo the data I received a syntax error. What would be an example of a Makefile contents which would display the .FEATURES information ? Makefile contents is operative here. The example that Paul gave answers that original question: all: echo ${.FEATURES} Looks like you are saying here that such a test to inhibit all operations by this Makefile would have to be implemented on a Target by Target basis. Sometimes there are scores of Targets in a Makefile or distributed Makefile, within each of which this test would have to be performed. So now you have a new question The Makefile itself when e.g make target is selected, should be able to precede execution of any target with a check of .FEATURES to verify the make environment into which it is downloaded. Give an example of .FEATURES display/echo in an existing Makefile., both v 3.80 and 4.00 . This is where Paul question of what did you already try? comes in. Rather than give you a fish, it would be better to teach you how to fish; seeing what you tried would let us correct whatever misunderstanding caused the syntax errors you got. Or you could search the archives for examples, if you really don't want to understand. I tried -d (which equates to turning on all debug flags) and did not find the trace of a source file or the corresponding output file which I could see being generated when I deleted the output file each time. The particular build I performed generated a 3.2 GBytes file which had to be split into 5 portions to search each one. 2) Also, please answer the other question posed: Hmm, how much are you paying for these answers? Oh right, nothing... I am presenting features that are needed in the Make project for general usage. --- I also want to know if there is a debug mode within make in which the Makefile filename and Line Number (some Makefiles are huge and distributed over several subordinate Makefiles) is matched to each automatic variable evaluation within a Target evaluation. --- Since you don't say what debug output you've already looked at, I'll just suggest two possibilities 1) make -pq and examine the dumped output, which gives file and line number for all commands 2) check out the remake project. http://bashdb.sourceforge.net/remake/ Make documentation indicates that -d would include -p and -q . However, the specific information I am looking for should be readily available. i.e. make -h should highlight the flag which delivers the result I have described. $(CC) -c $(CFLAGS) $ -o $@ Make_filename Makefile_Line_Num auto_var_eval auto_var_eval /adir/bdir/cdir/Makefile554.mk1177 make_debug.c make_debug.o ... ... The current directory would be implied by the Makefile full pathname. If either of these make capabilities are not possible currently, then that is a case for implementation in Make version 4.1 . You didn't describe the problem that you're trying to solve; how do you know that data would solve it? Why *only* automatic variables? If there are several levels of variable expansion involved, what should the output look like? Philip Guenther Whenever I use Make on an existing big project, the information about where a particular source file is compiled is the main thing I want to know. Usually, this affects how additional files could be added to the executable or library related to a particular file. As mentioned, I searched the whole -d output and did not see particular .c sources, for which the .o or .so I knew were being generated by operation of make. Automatic variable resolution has an eventual end
Re: win32 compilation of make 4.0 source code
That example method is a device to perform this .FEATURES test without inserting it into an existing Makefile. The syntax errors I was seeing were occurring when attempting to insert this test into an existing Makefile, full of Targets and command sequences. If this feature is used it would be at the top of an existing Makefile, before any targets are evaluated. I also want to know if there is a debug mode within make in which the Makefile filename and Line Number (some Makefiles are huge and distributed over several subordinate Makefiles) is matched to each automatic variable evaluation within a Target evaluation. -Original Message- From: Paul Smith Sent: Friday, January 24, 2014 11:28 AM To: Mark Brown Cc: Eli Zaretskii ; Pavel Fedin ; bug-make@gnu.org Subject: Re: win32 compilation of make 4.0 source code On Fri, 2014-01-24 at 11:03 -0800, Mark Brown wrote: I had a make.exe 3.80 and it had problems with else ifeq constructs, so that forced me to seek a more recent version for win32. Yes that version didn't support it. You can look at the latest NEWS file for info on what appeared when: http://git.savannah.gnu.org/cgit/make.git/tree/NEWS As a separate related issue, I was try to echo the .FEATURES information, since one of the its it claims to display mentions its Else If capabilities. However, every time I tried to echo the data I received a syntax error. What would be an example of a Makefile contents which would display the .FEATURES information ? There are a number of ways. Here's one that works with newer versions of GNU make (this is POSIX shell syntax): echo 'all: ; @echo FEATURES is $(.FEATURES)' | make -f- ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make
Re: win32 compilation of make 4.0 source code
I think the intent was to use MingW32 tools in the Windows win32 environment. I had a make.exe 3.80 and it had problems with else ifeq constructs, so that forced me to seek a more recent version for win32. As a separate related issue, I was try to echo the .FEATURES information, since one of the its it claims to display mentions its Else If capabilities. However, every time I tried to echo the data I received a syntax error. What would be an example of a Makefile contents which would display the .FEATURES information ? -Original Message- From: Eli Zaretskii Sent: Tuesday, January 14, 2014 8:04 AM To: Pavel Fedin Cc: mkbrown_...@hotmail.com ; bug-make@gnu.org Subject: Re: RE: win32 compilation of make 4.0 source code From: Pavel Fedin p.fe...@samsung.com Date: Tue, 14 Jan 2014 11:53:15 +0400 Cc: bug-make@gnu.org Obviously, you are trying to execute Makefile written for UNIX systems, are you ? This makefile relies on UNIX shell commands like uname, pwd, basename, etc. Right ? In order to run this Makefile, you need Cygwin or MinGW32 environment. Well, there are native Windows ports of these commands as well (e.g., on the GnuWin32 site). But I'm not sure whether Mark wants to run native or Cygwin tools. Actually, if Mark wants to run Cygwin tools, I'd suggest to install the Cygwin build of Make, it will have less issues with Cygwin programs than the native build of Make. ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make
win32 compilation of make 4.0 source code
I was able to compile the make 4.0 source code downloaded from the gnu make site using Visual C++ 2005 under Windows 7 64 (generated 0 errors, 259 warnings) but executing the resulting make command file from the Windows 7 DOS Command Prompt yields a series of warnings/errors: == process_begin: CreateProcess(NULL, uname, ...) failed. make: process_begin: CreateProcess(NULL, uname -a, ...) failed. make: process_begin: CreateProcess(NULL, cygpath C:\zzz_13.12.1_general\tools, ...) failed. make: process_begin: CreateProcess(NULL, pwd, ...) failed. == Is the resulting file supposed to executed under Cygwin ? Aeneas ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make
win32 compilation of make 4.0 source code
I was able to compile the make 4.0 source code downloaded from the gnu make site using Visual C++ 2005 under Windows 7 64 (generated 0 errors, 259 warnings) but executing the resulting make command file from the Windows 7 DOS Command Prompt yields a series of warnings/errors: == process_begin: CreateProcess(NULL, uname, ...) failed. make: process_begin: CreateProcess(NULL, uname -a, ...) failed. make: process_begin: CreateProcess(NULL, cygpath C:\zzz_13.12.1_general\tools, ...) failed. make: process_begin: CreateProcess(NULL, pwd, ...) failed. = Is the resulting file supposed to executed under Cygwin ? Aeneas ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make
Re: win32 compilation of make 4.0 source code
As mentioned I used Visual C++ 2005, loading the project file and building it: make_msvc_net2003.vcproj . This results in a make_msvc.net2003.exe of length 892 KB being created in the debug directory. If this is not the intended compilation method, do give step by step method to compile the project under Windows 7 64 , using Visual C++ 2005 . -Original Message- From: Paul Smith Sent: Monday, January 13, 2014 9:44 AM To: Eli Zaretskii Cc: bug-make@gnu.org Subject: Re: win32 compilation of make 4.0 source code On Mon, 2014-01-13 at 19:37 +0200, Eli Zaretskii wrote: On Windows, GNU make can be compiled in a quite a number of different ways. It would be helpful if you gave us an idea of which method you used. He said that: he used Microsoft Visual C++ version 2005. But I meant, how? Through the Visual Studio project files? Or via the build_w32.bat script? Maybe that doesn't matter; I'm definitely no expert on this :-). ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make
Re: win32 compilation of make 4.0 source code
I showed some of the output when this new windows/dos make is run from the command prompt, in the original message. Why not just post a step by step description of how to compile make in Windows 7 64, post some output of its operation, and clear everything up ? Also, can you describe what the series of failed process_begin's indicates ? Are they emanating from inside the make code or from executables invoked by make ? === process_begin: CreateProcess(NULL, uname, ...) failed. make: process_begin: CreateProcess(NULL, uname -a, ...) failed. make: process_begin: CreateProcess(NULL, cygpath C:\zzz_13.12.1_gener make: process_begin: CreateProcess(NULL, pwd, ...) failed. make: process_begin: CreateProcess(NULL, basename , ...) failed. make: process_begin: CreateProcess(NULL, pwd, ...) failed. make: process_begin: CreateProcess(NULL, basename , ...) failed. make: '.' is not recognized as an internal or external command, operable program or batch file. ... = -Original Message- From: Eli Zaretskii Sent: Monday, January 13, 2014 8:51 PM To: Mark Brown Cc: psm...@gnu.org ; bug-make@gnu.org Subject: Re: Re: win32 compilation of make 4.0 source code From: Mark Brown mkbrown_...@hotmail.com Cc: bug-make@gnu.org Date: Mon, 13 Jan 2014 14:06:16 -0800 As mentioned I used Visual C++ 2005, loading the project file and building it: make_msvc_net2003.vcproj . This results in a make_msvc.net2003.exe of length 892 KB being created in the debug directory. Does this binary work if you invoke it from the cmd.exe prompt? But please make sure your Makefile invokes programs that are on Path, and try to avoid invoking Cygwin programs as much as possible. Also, I would suggest to remove Cygwin's sh.exe from Path, as Make on Windows always prefers to use a Unix shell if available. If Make doesn't work even under these circumstances, then something is broken. Otherwise, you could be experiencing some incompatibility between Cygwin and native Windows programs. ___ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make