[PATCH] bugfix for compile minilib of libdvdnav
Hello, There's a little bug in libdvdnav/Makefile prevent from compiling minilib, here's fix: Index: libdvdnav/Makefile =================================================================== --- libdvdnav/Makefile (revision 955) +++ libdvdnav/Makefile (working copy) @@ -21,7 +21,7 @@ CFLAGS += -DDVDNAV_COMPILE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE CFLAGS += -DHAVE_CONFIG_H -DHAVE_DLFCN_H -ifeq ($(DVDREAD),internal) +ifeq ($(DVDREAD),"internal") L=libdvdnav VPATH+= $(SRC_PATH_BARE)/src/dvdread HEADERS += src/dvdread/dvd_reader.h \ -- Ulion
Ulion wrote:
Hello,
There's a little bug in libdvdnav/Makefile prevent from compiling minilib, here's fix:
Index: libdvdnav/Makefile =================================================================== --- libdvdnav/Makefile (revision 955) +++ libdvdnav/Makefile (working copy) @@ -21,7 +21,7 @@ CFLAGS += -DDVDNAV_COMPILE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE CFLAGS += -DHAVE_CONFIG_H -DHAVE_DLFCN_H
-ifeq ($(DVDREAD),internal) +ifeq ($(DVDREAD),"internal") L=libdvdnav VPATH+= $(SRC_PATH_BARE)/src/dvdread HEADERS += src/dvdread/dvd_reader.h \
ok to commit (if someone is online)
Hello, I also encounter a problem with the '-e' option of echo when generate dvdnav-config file, '-e' was printed into the targetfile also. I'm under ubuntu 7.04 on a PowerPC 64 just installed. Test echo command result just ok but when call it in the Makefile, it seems already has a '-e' hiddenly, maybe there's some alias somewhere. To fix it, I use a absolate path to call echo: Index: libdvdnav/Makefile =================================================================== --- libdvdnav/Makefile (revision 955) +++ libdvdnav/Makefile (working copy) @@ -127,11 +127,11 @@ rm -rf config.mak dvdnav-config: $(.OBJDIR) - echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config - echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config + /bin/echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config cat $(SRC_PATH_BARE)/misc/dvdnav-config2.sh >> $(.OBJDIR)/dvdnav-config chmod 0755 $(SRC_PATH_BARE)/$(.OBJDIR)/dvdnav-config -- Ulion
Ulion wrote:
Hello,
I also encounter a problem with the '-e' option of echo when generate dvdnav-config file, '-e' was printed into the targetfile also. I'm under ubuntu 7.04 on a PowerPC 64 just installed. Test echo command result just ok but when call it in the Makefile, it seems already has a '-e' hiddenly, maybe there's some alias somewhere. To fix it, I use a absolate path to call echo:
Index: libdvdnav/Makefile =================================================================== --- libdvdnav/Makefile (revision 955) +++ libdvdnav/Makefile (working copy) @@ -127,11 +127,11 @@ rm -rf config.mak
dvdnav-config: $(.OBJDIR) - echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config - echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config + /bin/echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config cat $(SRC_PATH_BARE)/misc/dvdnav-config2.sh >> $(.OBJDIR)/dvdnav-config chmod 0755 $(SRC_PATH_BARE)/$(.OBJDIR)/dvdnav-config
something is broken in your setup. I can't commit such workarounds
2007/9/19, Nico Sabbi <nicola_sabbi@fastwebnet.it>:
Ulion wrote:
Hello,
I also encounter a problem with the '-e' option of echo when generate dvdnav-config file, '-e' was printed into the targetfile also. I'm under ubuntu 7.04 on a PowerPC 64 just installed. Test echo command result just ok but when call it in the Makefile, it seems already has a '-e' hiddenly, maybe there's some alias somewhere. To fix it, I use a absolate path to call echo:
Index: libdvdnav/Makefile =================================================================== --- libdvdnav/Makefile (revision 955) +++ libdvdnav/Makefile (working copy) @@ -127,11 +127,11 @@ rm -rf config.mak
dvdnav-config: $(.OBJDIR) - echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config - echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config + /bin/echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config cat $(SRC_PATH_BARE)/misc/dvdnav-config2.sh >> $(.OBJDIR)/dvdnav-config chmod 0755 $(SRC_PATH_BARE)/$(.OBJDIR)/dvdnav-config
something is broken in your setup. I can't commit such workarounds
I understand. use '/bin/echo' may break on other platform, so just post here to let peoples known how to fix it if they encounter the same problem. -- Ulion
2007/9/19, Ulion <ulion2002@gmail.com>:
2007/9/19, Nico Sabbi <nicola_sabbi@fastwebnet.it>:
Ulion wrote:
Hello,
I also encounter a problem with the '-e' option of echo when generate dvdnav-config file, '-e' was printed into the targetfile also. I'm under ubuntu 7.04 on a PowerPC 64 just installed. Test echo command result just ok but when call it in the Makefile, it seems already has a '-e' hiddenly, maybe there's some alias somewhere. To fix it, I use a absolate path to call echo:
Index: libdvdnav/Makefile =================================================================== --- libdvdnav/Makefile (revision 955) +++ libdvdnav/Makefile (working copy) @@ -127,11 +127,11 @@ rm -rf config.mak
dvdnav-config: $(.OBJDIR) - echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config - echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config - echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e '#!/bin/sh\n\nprefix='$(PREFIX)'\n' > $(.OBJDIR)/dvdnav-config + /bin/echo -e 'version='$(SHLIB_VERSION)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdread='$(DVDREAD)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'dvdreaddir='$(DVDREAD_DIR)'\n' >> $(.OBJDIR)/dvdnav-config + /bin/echo -e 'threadlib='$(THREADLIB)'\n\n' >> $(.OBJDIR)/dvdnav-config cat $(SRC_PATH_BARE)/misc/dvdnav-config2.sh >> $(.OBJDIR)/dvdnav-config chmod 0755 $(SRC_PATH_BARE)/$(.OBJDIR)/dvdnav-config
something is broken in your setup. I can't commit such workarounds
I understand. use '/bin/echo' may break on other platform, so just post here to let peoples known how to fix it if they encounter the same problem.
After check other Makefiles, I found they all use '@echo' instead of 'echo -e', I tested with it and works just like '/bin/echo -e', maybe '@echo' is the correct way to use. So I think this patch will be worth to commit. I made this patch under libdvdnav directory, so need apply it under same directory. -- Ulion
Il Saturday 24 November 2007 02:03:03 Ulion ha scritto:
After check other Makefiles, I found they all use '@echo' instead of 'echo -e', I tested with it and works just like '/bin/echo -e', maybe '@echo' is the correct way to use. So I think this patch will be worth to commit. I made this patch under libdvdnav directory, so need apply it under same directory.
[nico@xp ~]$ @echo hello bash: @echo: command not found
2007/11/24, Nico Sabbi <nicola_sabbi@fastwebnet.it>:
Il Saturday 24 November 2007 02:03:03 Ulion ha scritto:
After check other Makefiles, I found they all use '@echo' instead of 'echo -e', I tested with it and works just like '/bin/echo -e', maybe '@echo' is the correct way to use. So I think this patch will be worth to commit. I made this patch under libdvdnav directory, so need apply it under same directory.
[nico@xp ~]$ @echo hello bash: @echo: command not found
It's not a shell command, I think it's a command identified by 'make', why not try it, I just have no time to find the man page for Makefile -- Ulion
On Saturday, 24 November 2007 at 15:13, Ulion wrote:
2007/11/24, Nico Sabbi <nicola_sabbi@fastwebnet.it>:
Il Saturday 24 November 2007 02:03:03 Ulion ha scritto:
After check other Makefiles, I found they all use '@echo' instead of 'echo -e', I tested with it and works just like '/bin/echo -e', maybe '@echo' is the correct way to use. So I think this patch will be worth to commit. I made this patch under libdvdnav directory, so need apply it under same directory.
[nico@xp ~]$ @echo hello bash: @echo: command not found
It's not a shell command, I think it's a command identified by 'make', why not try it, I just have no time to find the man page for Makefile
@ in front of a command in a Makefile simply prevents make from displaying the command itself, i.e. rule: echo blah will result in echo blah blah while rule: @echo blah will result in blah Regards, R. -- Fedora contributor http://fedoraproject.org/wiki/DominikMierzejewski Livna contributor http://rpm.livna.org MPlayer developer http://mplayerhq.hu "Faith manages." -- Delenn to Lennier in Babylon 5:"Confessions and Lamentations"
2007/11/24, Ulion <ulion2002@gmail.com>:
2007/11/24, Nico Sabbi <nicola_sabbi@fastwebnet.it>:
Il Saturday 24 November 2007 02:03:03 Ulion ha scritto:
After check other Makefiles, I found they all use '@echo' instead of 'echo -e', I tested with it and works just like '/bin/echo -e', maybe '@echo' is the correct way to use. So I think this patch will be worth to commit. I made this patch under libdvdnav directory, so need apply it under same directory.
[nico@xp ~]$ @echo hello bash: @echo: command not found
It's not a shell command, I think it's a command identified by 'make', why not try it, I just have no time to find the man page for Makefile
Found little document, it didn't mention whether it accept \n, but on my os x, it did, and work around the wrong dvdnav-config file bug. If this also works on linux, I think it did support \n, just undocumented. http://www.gnu.org/software/make/manual/html_node/Echoing.html -- Ulion
Il Saturday 24 November 2007 15:32:00 Ulion ha scritto:
Found little document, it didn't mention whether it accept \n, but on my os x, it did, and work around the wrong dvdnav-config file bug. If this also works on linux, I think it did support \n, just undocumented.
http://www.gnu.org/software/make/manual/html_node/Echoing.html
[nico@xp libdvdnav]$ head -8 obj/dvdnav-config #!/bin/sh\n\nprefix=/usr/local\n libdir=/usr/local/lib\n version=4.1.1\n dvdread=internal\n dvdreaddir=src/dvdread/\n threadlib=-lpthread\n\n dvdreadlib="-ldvdread" dvdreadmsg="[--minilibs]"
2007/11/25, Nico Sabbi <nicola_sabbi@fastwebnet.it>:
Il Saturday 24 November 2007 15:32:00 Ulion ha scritto:
Found little document, it didn't mention whether it accept \n, but on my os x, it did, and work around the wrong dvdnav-config file bug. If this also works on linux, I think it did support \n, just undocumented.
http://www.gnu.org/software/make/manual/html_node/Echoing.html
[nico@xp libdvdnav]$ head -8 obj/dvdnav-config #!/bin/sh\n\nprefix=/usr/local\n libdir=/usr/local/lib\n version=4.1.1\n dvdread=internal\n dvdreaddir=src/dvdread/\n threadlib=-lpthread\n\n dvdreadlib="-ldvdread" dvdreadmsg="[--minilibs]"
Sorry for this result. But since the original Makefile broken on mac osx build either 10.4 or 10.5 machine build env, so I still want to fix this problem, by remove all '\n's and add @prefix to echo, here's patch for it under libdvdnav dir. Do you agree with this? -- Ulion
Il Sunday 25 November 2007 02:47:53 Ulion ha scritto:
Sorry for this result. But since the original Makefile broken on mac osx build either 10.4 or 10.5 machine build env, so I still want to fix this problem, by remove all '\n's and add @prefix to echo, here's patch for it under libdvdnav dir. Do you agree with this?
applied, thanks
Nico Sabbi wrote:
Ulion wrote:
Hello,
There's a little bug in libdvdnav/Makefile prevent from compiling minilib, here's fix:
Index: libdvdnav/Makefile =================================================================== --- libdvdnav/Makefile (revision 955) +++ libdvdnav/Makefile (working copy) @@ -21,7 +21,7 @@ CFLAGS += -DDVDNAV_COMPILE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE CFLAGS += -DHAVE_CONFIG_H -DHAVE_DLFCN_H
-ifeq ($(DVDREAD),internal) +ifeq ($(DVDREAD),"internal") L=libdvdnav VPATH+= $(SRC_PATH_BARE)/src/dvdread HEADERS += src/dvdread/dvd_reader.h \
ok to commit (if someone is online)
I verified that in ffmpeg's and mplayer's Makefiles there's no such requirement: all iferq statements are without quotations. Can you post the output of the broken make and the details of your build tools?
participants (4)
-
Dominik 'Rathann' Mierzejewski -
Nico Sabbi -
Nico Sabbi -
Ulion