Am 08.12.2016 um 20:44 schrieb Brian Willoughby:
On Dec 8, 2016, at 12:59 AM, Dave Yeo <dave.r....@gmail.com> wrote:
On 12/08/16 12:24 AM, Thomas Zander wrote:
On 7 December 2016 at 21:08, Erik de Castro Lopo <mle...@mega-nerd.com> wrote:
lvqcl.mail wrote:

"make -f Makefile.lite" also doesn't work out of box.
Didn't work for the 1.3.1 release either. Makes me wonder why we even
keep it around.
Because it works on many systems with only tiny tweaks (e.g. passing
an env var) without the mess that is GNU autotools.
I use it frequently and always thought of it of an fine asset to have
(which other projects lack).
Would be nice to keep it IMHO.
I agree. Here it would require a lot of tweaking but it is still a good 
beginning point for someone who needs a plain makefile.
Even if slightly broken, it should be kept as a template.
Dave
Maybe add a README.lite in that directory, or a section in an existing README, 
to explain the purpose of Makefile.lite and the fact that it may not work 
exactly as provided? I'm not building for any of the systems that would use it, 
so this is just my comment from the peanut gallery.

Brian Willoughby
Here is a patch for the Makefile.lite build system that should make it work again on most systems. Tested on Windows (MSYS) and Ubuntu 12.10. The main issues were inclusion of non-existing Makefile.deps, missing PACKAGE_VERSION define and wrong build order (i.e. trying to build flac before libFLAC and other dependencies).

----
Robert Kausch
robert.kau...@freac.org

diff -Naur flac-1.3.2pre1/Makefile.lite flac-1.3.2pre1+litefix/Makefile.lite
--- flac-1.3.2pre1/Makefile.lite	2016-12-06 09:05:46 +0000
+++ flac-1.3.2pre1+litefix/Makefile.lite	2016-12-10 16:21:24 +0000
@@ -74,4 +74,3 @@
 	-(cd test && $(MAKE) -f Makefile.lite clean)
 
 examples: libFLAC libFLAC++ share
-include $(topdir)/Makefile.deps
diff -Naur flac-1.3.2pre1/build/lib.mk flac-1.3.2pre1+litefix/build/lib.mk
--- flac-1.3.2pre1/build/lib.mk	2016-12-06 09:05:46 +0000
+++ flac-1.3.2pre1+litefix/build/lib.mk	2016-12-10 16:10:41 +0000
@@ -66,7 +66,7 @@
     LINKD       = $(CC) -shared
 endif
 
-BASE_CFLAGS = -Wall -Wextra $(CONFIG_CFLAGS) -DVERSION=$(VERSION) $(DEFINES) $(INCLUDES)
+BASE_CFLAGS = -Wall -Wextra $(CONFIG_CFLAGS) -DVERSION=$(VERSION) -DPACKAGE_VERSION=$(VERSION) $(DEFINES) $(INCLUDES)
 
 ifeq ($(DEFAULT_BUILD),debug)
 CFLAGS   := -g -O0 -DDEBUG $(CFLAGS) $(BASE_CFLAGS) -Wmissing-prototypes -Wstrict-prototypes
diff -Naur flac-1.3.2pre1/src/Makefile.lite flac-1.3.2pre1+litefix/src/Makefile.lite
--- flac-1.3.2pre1/src/Makefile.lite	2016-12-06 09:05:46 +0000
+++ flac-1.3.2pre1+litefix/src/Makefile.lite	2016-12-10 16:29:26 +0000
@@ -36,7 +36,7 @@
 endif
 
 .PHONY: all flac libFLAC libFLAC++ metaflac plugin_common plugin_xmms share/win_utf8_io share test_grabbag test_libs_common test_libFLAC test_libFLAC++ test_seeking test_streams flacdiff flactimer
-all: flac libFLAC libFLAC++ metaflac plugin_common $(EXTRA_TARGETS) share test_grabbag test_libs_common test_libFLAC test_libFLAC++ test_seeking test_streams
+all: libFLAC libFLAC++ share $(EXTRA_TARGETS) flac metaflac plugin_common test_grabbag test_libs_common test_libFLAC test_libFLAC++ test_seeking test_streams
 
 DEFAULT_CONFIG = release
 
@@ -72,5 +72,3 @@
 	-(cd test_streams ; $(MAKE) -f Makefile.lite clean)
 	-(cd utils/flacdiff ; $(MAKE) -f Makefile.lite clean)
 	-(cd utils/flactimer ; $(MAKE) -f Makefile.lite clean)
-
-include $(topdir)/Makefile.deps
diff -Naur flac-1.3.2pre1/src/share/win_utf8_io/Makefile.lite flac-1.3.2pre1+litefix/src/share/win_utf8_io/Makefile.lite
--- flac-1.3.2pre1/src/share/win_utf8_io/Makefile.lite	1970-01-01 00:00:00 +0000
+++ flac-1.3.2pre1+litefix/src/share/win_utf8_io/Makefile.lite	2016-12-10 16:16:18 +0000
@@ -0,0 +1,23 @@
+#
+# GNU makefile
+#
+
+topdir = ../../..
+libdir = $(topdir)/objs/$(BUILD)/lib
+
+LIB_NAME = libwin_utf8_io
+
+ifeq ($(OS),Darwin)
+    EXPLICIT_LIBS = $(libdir)/libFLAC.a
+else
+    LIBS = -lFLAC
+endif
+
+INCLUDES = -I$(topdir)/include
+
+SRCS_C = \
+	win_utf8_io.c
+
+include $(topdir)/build/lib.mk
+
+# DO NOT DELETE THIS LINE -- make depend depends on it.
diff -Naur flac-1.3.2pre1/src/test_streams/Makefile.lite flac-1.3.2pre1+litefix/src/test_streams/Makefile.lite
--- flac-1.3.2pre1/src/test_streams/Makefile.lite	2016-12-06 09:05:46 +0000
+++ flac-1.3.2pre1+litefix/src/test_streams/Makefile.lite	2016-12-10 17:15:41 +0000
@@ -30,9 +30,9 @@
 INCLUDES = -I./include -I$(topdir)/include
 
 ifeq ($(OS),Darwin)
-    EXPLICIT_LIBS = $(libdir)/libgrabbag.a -lm
+    EXPLICIT_LIBS = $(libdir)/libgrabbag.a $(libdir)/libreplaygain_analysis.a -lm
 else
-    LIBS = -lgrabbag -lm
+    LIBS = -lgrabbag -lreplaygain_analysis -lm
 endif
 
 SRCS_C = \
_______________________________________________
flac-dev mailing list
flac-dev@xiph.org
http://lists.xiph.org/mailman/listinfo/flac-dev

Reply via email to