Opened 15 years ago

Closed 15 years ago

Last modified 6 years ago

#9072 closed patch

Quiet make process

Reported by: salty-horse Owned by: sev-
Priority: normal Component: --Other--
Version: Keywords:
Cc: Game:

Description

This patch makes the make output more pleasant to look at, and causes warnings to be more visible:

Example with fake warning:

CC common/zlib.o common/zlib.cpp: In function ‘bool Common::uncompress(byte*, long unsigned int*, const byte*, long unsigned int)’: common/zlib.cpp:47: warning: unused variable ‘a’ AR common/libcommon.a RANLIB common/libcommon.a CC base/version.o AR base/libbase.a RANLIB base/libbase.a LINK scummvm

mkdir, rm, echo and cat commands are silenced. The "clean" targets still shows the original output (rm's with lots of files)

The quieting can be disabled by defining the VERBOSE environment variable.

I based the patch on the build process of Git.

Ticket imported from: #2840212. Ticket imported from: patches/1177.

Attachments (2)

quiet-make.patch (5.1 KB ) - added by salty-horse 15 years ago.
quiet-make-2.patch (6.7 KB ) - added by salty-horse 15 years ago.
Updated patch with configure changes

Download all attachments as: .zip

Change History (11)

by salty-horse, 15 years ago

Attachment: quiet-make.patch added

comment:1 by SF/knakos, 15 years ago

I have not tested this. Aside the geekiness of such a thing, I find it useful since warnings can be spotted more easily this way (as opposed to scanning the Matrix when compiling). Some alignment would be nice, also dumping the CFLAGS, CXXFLAGS, engine-selection at the beginning/end of a quiet build (if that's not already done).

comment:2 by salty-horse, 15 years ago

There already is alignment of the CC/RANLIB and the text after them. It was probably removed when I pasted.

Nothing extra is being output, but that's a good idea.

comment:3 by lordhoto, 15 years ago

I also like this one. The idea to show CXXFLAGS (and maybe CFLAGS) etc at the beginning is imho in principle nice too, but I don't know if that's an information one needs to have on every make run though.

One thing I would like to have is some other string than "SO" for plugin linking though, maybe "PLUGIN" would be nicer.

comment:4 by sev-, 15 years ago

Really good stuff in fact.

After short discussion on IRC here are the notes: - add configure option something like --verbose-make - environment variable will override this setting - by default verbose output is off (easy to flip, though)

by salty-horse, 15 years ago

Attachment: quiet-make-2.patch added

Updated patch with configure changes

comment:5 by salty-horse, 15 years ago

The new patch changes CC to C++, SO to PLUGIN and adds a --enable-verbose-build to ./configure.

The quiet build is enabled by default so there's no need for --disable-verbose-build

It is also possible to enable the build at any time, regardless of the configure option, using "make VERBOSE_BUILD=1" or "make VERBOSE_BUILD=yes", or disable it using any other value.

This means that "make VERBOSE_BUILD=true" will actually be a quiet build. How many of variants of "yes" should be supported? :)

comment:6 by salty-horse, 15 years ago

I forgot to mention that none of the ports' Makefiles have been modified.

Also, some of the tools use non-standard Makefiles, such as tools/create_lure and tools/create_kyradat The output there has some errors (C++ printed instead of LINK): C++ tools/create_lure/create_lure_dat.o C++ tools/create_lure/process_actions.o C++ tools/create_lure/create_lure

comment:7 by sev-, 15 years ago

Owner: set to sev-
Status: newclosed

comment:8 by sev-, 15 years ago

Thanks, committed as is.

As of the tools Makefiles, we perhaps could make them uniform, but that should be done with separate patch

comment:9 by digitall, 6 years ago

Component: --Other--
Note: See TracTickets for help on using tickets.