summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2010-02-14 13:22:16 (GMT)
committer Thomas Petazzoni <thomas.petazzoni@free-electrons.com>2010-02-18 23:35:24 (GMT)
commit161afc186256b05b2b1af0b3cfa909e104529ed6 (patch)
treeac3a5d54a1e04eedb751f1ec9450f660ca755fba
parent3df93063da925eb9787be0a98ce88d079173f762 (diff)
downloadbuildroot-161afc186256b05b2b1af0b3cfa909e104529ed6.tar.gz
buildroot-161afc186256b05b2b1af0b3cfa909e104529ed6.tar.bz2
Fix build failure of rubix
Add a patch to use strstr() instead of index(). Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-rw-r--r--package/games/rubix/rubix-1.0.5-dont-use-legacy-functions.patch18
1 files changed, 18 insertions, 0 deletions
diff --git a/package/games/rubix/rubix-1.0.5-dont-use-legacy-functions.patch b/package/games/rubix/rubix-1.0.5-dont-use-legacy-functions.patch
new file mode 100644
index 0000000..9c34aee
--- /dev/null
+++ b/package/games/rubix/rubix-1.0.5-dont-use-legacy-functions.patch
@@ -0,0 +1,18 @@
+Use strstr() instead of index(), since index() is a legacy function
+and it may not be available in uClibc, depending on the configuration.
+
+Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+
+Index: rubix-1.0.5/cube.c
+===================================================================
+--- rubix-1.0.5.orig/cube.c 2010-02-14 14:19:05.000000000 +0100
++++ rubix-1.0.5/cube.c 2010-02-14 14:19:14.000000000 +0100
+@@ -257,7 +257,7 @@
+ if (i==-1) goto finish;
+ if (buffer[0]=='%') goto new_section;
+ buffer[0]=toupper(buffer[0]);
+- ptr = index(buffer, '=');
++ ptr = strstr(buffer, '=');
+ if (ptr) {
+ ++ptr;
+ while (isspace(*ptr)) ++ptr;