After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 768616 - gstreamer-1.0.mk: Replacement fails
gstreamer-1.0.mk: Replacement fails
Status: RESOLVED DUPLICATE of bug 768326
Product: GStreamer
Classification: Platform
Component: common
1.9.1
Other Windows
: Normal blocker
: 1.8.3
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-07-09 21:43 UTC by Andy Devar
Modified: 2016-07-25 07:13 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch for gstreamer-1.0.mk in gstreamer-1.0-android-armv7-1.9.1 (973 bytes, patch)
2016-07-16 12:10 UTC, Andy Devar
none Details | Review

Description Andy Devar 2016-07-09 21:43:43 UTC
gstreamer.mk tries to do the following replacements:

ifeq ($(GSTREAMER_INCLUDE_FONTS),yes)
GSTREAMER_INCLUDE_FONTS_SUBST=""
else
GSTREAMER_INCLUDE_FONTS_SUBST="//"
endif

ifeq ($(GSTREAMER_INCLUDE_CA_CERTIFICATES),yes)
GSTREAMER_INCLUDE_CA_CERTIFICATES_SUBST=""
else
GSTREAMER_INCLUDE_CA_CERTIFICATES_SUBST="//"
endif

ifneq (,$(findstring yes,$(GSTREAMER_INCLUDE_FONTS)$(GSTREAMER_INCLUDE_CA_CERTIFICATES)))
GSTREAMER_COPY_FILE_SUBST=""
else
GSTREAMER_COPY_FILE_SUBST="//"
endif

[...]

	@"$(SED)" "s;@INCLUDE_FONTS@;$(GSTREAMER_INCLUDE_FONTS_SUBST);g" $(GSTREAMER_NDK_BUILD_PATH)/GStreamer.java | \
		"$(SED)" "s;@INCLUDE_CA_CERTIFICATES@;$(GSTREAMER_INCLUDE_CA_CERTIFICATES_SUBST);g" | \
		"$(SED)" "s;@INCLUDE_COPY_FILE@;$(GSTREAMER_COPY_FILE_SUBST);g" \
		> $(GSTREAMER_JAVA_SRC_DIR)/org/freedesktop/gstreamer/GStreamer.java

This fails because the replacement is set to one double quote character, and the double quote character ends the replacement statement prematurely.

This seems to work after modifying the statements which set the replacement values:


ifeq ($(GSTREAMER_INCLUDE_FONTS),yes)
GSTREAMER_INCLUDE_FONTS_SUBST :=
else
GSTREAMER_INCLUDE_FONTS_SUBST := //
endif

ifeq ($(GSTREAMER_INCLUDE_CA_CERTIFICATES),yes)
GSTREAMER_INCLUDE_CA_CERTIFICATES_SUBST :=
else
GSTREAMER_INCLUDE_CA_CERTIFICATES_SUBST := //
endif

ifneq (,$(findstring yes,$(GSTREAMER_INCLUDE_FONTS)$(GSTREAMER_INCLUDE_CA_CERTIFICATES)))
GSTREAMER_COPY_FILE_SUBST :=
else
GSTREAMER_COPY_FILE_SUBST := //
endif


gstreamer.mk is called by Android.mk which is part of gstreamer android tutorial-5.
To build, I call ndk-build.cmd, which is part of Android NDK.  

I downloaded gstreamer from here:
https://gstreamer.freedesktop.org/data/pkg/android/1.9.1/gstreamer-1.0-android-armv7-1.9.1.tar.bz2
Comment 1 Sebastian Dröge (slomo) 2016-07-10 18:36:02 UTC
Can you provide a patch/diff of your changes? I understand you correctly that your change is to remove the " " around the values in the assignment of those variables?
Comment 2 Andy Devar 2016-07-16 12:10:59 UTC
Created attachment 331625 [details] [review]
Patch for gstreamer-1.0.mk in gstreamer-1.0-android-armv7-1.9.1

>
> I understand you correctly that your change is to remove the " " around the values in the assignment of those variables?
>

That's correct. Otherwise, the quotes become part of the variables' value.


I've attached a patch file.
Comment 3 Sebastian Dröge (slomo) 2016-07-25 07:13:59 UTC
Let's handle that in the original bug then, you attached a patch with both changes there anyway :)

*** This bug has been marked as a duplicate of bug 768326 ***