Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Rockbox Ports are now being developed for various digital audio players!

+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Starting Development and Compiling
| | |-+  Trouble with compiling some patches and adding new plugins
« previous next »
  • Print
Pages: [1]

Author Topic: Trouble with compiling some patches and adding new plugins  (Read 3180 times)

Offline joetermini

  • Member
  • *
  • Posts: 13
Trouble with compiling some patches and adding new plugins
« on: October 15, 2006, 03:23:16 PM »
Hey, I have been using Rockbox for a while on my 5G iPod, and have a pretty good understanding of how it works. I am running a custom build, Senab's Experimental.
I tried creating my own custom build, and I have a few questions about applying patches

When installing many of the patches which I know work, I get a bunch of messages such as "HUNK #1 Failed at 53". After one or two lines like this, the rest are successful. Is there anything I need to do to get these patches working?

Second Question: I have a few patches for new plugins, such as one called pegbox. Sometimes I get a .patch file, and sometimes it’s accompanied by a .c file. I know that .c is a plugin, but what do I do with it. And what do I do if I only get the .c file?

Final question: With some patches, I am given a number of separate patches. None of them work. (As in at the end of the text I get after entering the command, it says "File to Patch:" What do I do with this?
Logged

Offline saratoga

  • Developer
  • Member
  • *
  • Posts: 9231
Re: Trouble with compiling some patches and adding new plugins
« Reply #1 on: October 15, 2006, 04:17:48 PM »
If the c file contains the entire plugin, you probably just need to add it to the plugins directory and edit the SOURCES (IIRC this is what its called) file to list your plugin.c so that when you ./configure it adds that plugin to the make file.
Logged

Offline joetermini

  • Member
  • *
  • Posts: 13
Re: Trouble with compiling some patches and adding new plugins
« Reply #2 on: October 15, 2006, 10:08:42 PM »
Thanks man, but what about the failed hunks and the multiple patches?
Logged

Offline Kratos

  • Member
  • *
  • Posts: 16
Re: Trouble with compiling some patches and adding new plugins
« Reply #3 on: October 15, 2006, 10:34:00 PM »
The HUNK errors mean that the patches dont work with the more recent builds of rockbox.

so you either have to apply the changes to the firmware manually, or change the patches to match the firmware changes
Logged
You should (never) pay attention to words in parenthesis.

Offline joetermini

  • Member
  • *
  • Posts: 13
Re: Trouble with compiling some patches and adding new plugins
« Reply #4 on: October 16, 2006, 01:06:24 PM »
That sounds a little difficult. What would I be changing?
Logged

Offline Rincewind

  • Member
  • *
  • Posts: 266
Re: Trouble with compiling some patches and adding new plugins
« Reply #5 on: October 16, 2006, 03:48:56 PM »
Quote from: joetermini on October 16, 2006, 01:06:24 PM
That sounds a little difficult. What would I be changing?

That really depends.
I suggest you open both the patch file and the source file where the hunk failed in an editor. Then in the source file you go to the line-number of the failed hunk. You view both files side by side and try to understand what the hunk does and why it failed. Then you manually do what the patch utility would do with the hunk (removing lines with - , adding lines with + and changing lines with !).
If the result doesn't look like C-Code anymore, then you either have done something wrong or the patch is badly out if date. An editor with syntax coloring can help you spotting bad mistakes.

I don't know if the patch tool stops after a failed hunk, if it does you have to apply the hunks after the failed one, too. I use use a different tool to patch, so I can't help you with commandline switches that might help you here.

If you have multiple patches you apply them one after the other, in the same order the author of the patch suggests.

If you get a .c file, the author should mention somewhere where to put this file (a good guess is /apps if it is a patch to rockbox or /apps/plugins if it is a plugin)
Logged
Iriver H120, Sansa e280

Offline joetermini

  • Member
  • *
  • Posts: 13
Re: Trouble with compiling some patches and adding new plugins
« Reply #6 on: October 16, 2006, 08:21:20 PM »
thanks a ton man
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Starting Development and Compiling
| | |-+  Trouble with compiling some patches and adding new plugins
 

  • SMF 2.0.19 | SMF © 2021, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.03 seconds with 17 queries.