Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] update on a file in tslib not reflected after doing "Make"
@ 2009-12-15  7:30 Stanley
  2009-12-15  8:18 ` Peter Korsgaard
  2009-12-15  8:27 ` Thomas Petazzoni
  0 siblings, 2 replies; 8+ messages in thread
From: Stanley @ 2009-12-15  7:30 UTC (permalink / raw)
  To: buildroot

Hi all,

I am new to embedded world and this is the first time using buildroot.
I am currently trying to solve a problem in one of the files (input-raw.c)
on tslib. However after modify/patch the file, I do a "make" in main
buildroot directory. However the changes did not reflected (tested by adding
a few texts in already existing printf statement).

eg:

input-raw.c
-------------
original file
fprint(stderr,"Unknown event type %d\n",......);

modified file
fprintf(stderr,"test\n,"Unknown event type %d\n",......);

ts_calibrate.c
---------------
original file
printf("xres = %d, yres = %d\n", xres, yres);

modified file
printf("test\nxres = %d, yres = %d\n", xres, yres);


I am using at91rm9200dk board by the way.

Here is what I did.

1) delete "tslib" folder from "build_arm" folder.
2) delete "ts" folder and "libts.la", "libts.so", "libts-0.0.so.0" and
"libts-0.0.so.0.1.1" files from "build_arm/staging_dir/usr/lib" folder. I
think this is all the lib files for tslib
3) delete "ts_calibrate", "ts_print_raw", "ts_print", "ts_test",
"ts_harvest" files from "build_arm/staging_dir/usr/lib/bin" folder. these
are the test problem.
4) do a "make" in main buildroot directory.
5) break the "make" process halfway (after extracting and patching of the
input-raw.c file before running autoconf) and modify/patch the
file(s)(modify ts_calibrate for checking) and do a "make" to resume the
process.
6) download the kernel image and rootfs into the arm9 board and run the
tslib test. (ts_calibrate). Result = printf of the original file shown in
the examples above.

For step 5, I have to break halfway because the patch I added cannot be done
before buildroot tslib patch as it will cause a patch fail for buildroot
tslib patch. I have no idea what problem is buildroot tslib patch solve but
it is did not solve the problem I encounter.

Note: Here is how I do a patch before buildroot. 1) patch file, 2) zip whole
folder, 3) copy to dl folder, 4) delete relevant files and folder, 5) do a
make. I can't do it for tslib as buildroot tslib patch will fail with the
patch I am applying.

Anyone knows how to resolve this problem?

thanks

Regards,
Stanley
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20091215/94e1189e/attachment-0001.htm>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] update on a file in tslib not reflected after doing "Make"
  2009-12-15  7:30 [Buildroot] update on a file in tslib not reflected after doing "Make" Stanley
@ 2009-12-15  8:18 ` Peter Korsgaard
  2009-12-15  8:27 ` Thomas Petazzoni
  1 sibling, 0 replies; 8+ messages in thread
From: Peter Korsgaard @ 2009-12-15  8:18 UTC (permalink / raw)
  To: buildroot

>>>>> "Stanley" == Stanley  <eva2002@gmail.com> writes:

 Stanley> Hi all,

 Stanley> I am new to embedded world and this is the first time using
 Stanley> buildroot.  I am currently trying to solve a problem in one of
 Stanley> the files (input-raw.c) on tslib. However after modify/patch
 Stanley> the file, I do a "make" in main buildroot directory. However
 Stanley> the changes did not reflected (tested by adding a few texts in
 Stanley> already existing printf statement).

 Stanley> Here is what I did.

 Stanley> 1) delete "tslib" folder from "build_arm" folder.

If you have a build_arm folder, then you are not using the latest
release. Any reason why you are not using 2009.11?

So if I get you right, you want to add a custom patch to tslib? You can
either just place it in package/tslib together with the other patches
(make sure you name it tslib-1.0-<something>.patch), or for a quick test
just build tslib without changing anything, and then afterwards go to
output/build/tslib-1.0, change what you need to change and then remove
the stamp file (.stamp_built).

Once that is done you can just rerun make from the toplevel buildroot
dir and tslib should get rebuilt/reinstalled.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] update on a file in tslib not reflected after doing "Make"
  2009-12-15  7:30 [Buildroot] update on a file in tslib not reflected after doing "Make" Stanley
  2009-12-15  8:18 ` Peter Korsgaard
@ 2009-12-15  8:27 ` Thomas Petazzoni
  2009-12-16  4:30   ` Stanley
  1 sibling, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2009-12-15  8:27 UTC (permalink / raw)
  To: buildroot

Le Tue, 15 Dec 2009 15:30:06 +0800,
Stanley <eva2002@gmail.com> a ?crit :

> Anyone knows how to resolve this problem?

Let Buildroot does its compilation process to the end.

Then, make your modifications to build_arm/tslib-x.x/. Then, remove
the build_arm/tslib-x.x/.stamp_build file.

Re-run make.

This topic is covered in Buildroot documentation, see
docs/buildroot.html.

Cheers,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] update on a file in tslib not reflected after doing "Make"
  2009-12-15  8:27 ` Thomas Petazzoni
@ 2009-12-16  4:30   ` Stanley
  2009-12-16 20:35     ` Peter Korsgaard
  0 siblings, 1 reply; 8+ messages in thread
From: Stanley @ 2009-12-16  4:30 UTC (permalink / raw)
  To: buildroot

I tried your method and also tried creating some patches for editing the
test file. However in both cases, the changes still did not reflect.

However i did see that it got rebuilt after deleting .stamp_built file. What
I can try out now?
thanks

On Tue, Dec 15, 2009 at 4:27 PM, Thomas Petazzoni <
thomas.petazzoni@free-electrons.com> wrote:

> Le Tue, 15 Dec 2009 15:30:06 +0800,
> Stanley <eva2002@gmail.com> a ?crit :
>
> > Anyone knows how to resolve this problem?
>
> Let Buildroot does its compilation process to the end.
>
> Then, make your modifications to build_arm/tslib-x.x/. Then, remove
> the build_arm/tslib-x.x/.stamp_build file.
>
> Re-run make.
>
> This topic is covered in Buildroot documentation, see
> docs/buildroot.html.
>
> Cheers,
>
> Thomas
> --
> Thomas Petazzoni, Free Electrons
> Kernel, drivers and embedded Linux development,
> consulting, training and support.
> http://free-electrons.com
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20091216/b176f42a/attachment.htm>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] update on a file in tslib not reflected after doing "Make"
  2009-12-16  4:30   ` Stanley
@ 2009-12-16 20:35     ` Peter Korsgaard
  2009-12-17  7:35       ` Thomas Petazzoni
  0 siblings, 1 reply; 8+ messages in thread
From: Peter Korsgaard @ 2009-12-16 20:35 UTC (permalink / raw)
  To: buildroot

>>>>> "Stanley" == Stanley  <eva2002@gmail.com> writes:

 Stanley> I tried your method and also tried creating some patches for
 Stanley> editing the test file. However in both cases, the changes
 Stanley> still did not reflect.

 Stanley> However i did see that it got rebuilt after deleting
 Stanley> .stamp_built file. What I can try out now?  thanks

If you are putting new .patch files under package/tslib then you need to
rerun the patch step. The easiest way of doing this is simply to delete
the build dir (rm -rf output/build/tslib*)

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] update on a file in tslib not reflected after doing "Make"
  2009-12-16 20:35     ` Peter Korsgaard
@ 2009-12-17  7:35       ` Thomas Petazzoni
  2009-12-17 10:45         ` Stanley
  2009-12-21  4:39         ` Stanley
  0 siblings, 2 replies; 8+ messages in thread
From: Thomas Petazzoni @ 2009-12-17  7:35 UTC (permalink / raw)
  To: buildroot

Le Wed, 16 Dec 2009 21:35:16 +0100,
Peter Korsgaard <jacmet@uclibc.org> a ?crit :

> If you are putting new .patch files under package/tslib then you need
> to rerun the patch step. The easiest way of doing this is simply to
> delete the build dir (rm -rf output/build/tslib*)

Yeah, basically:

 *) If you hack directly into output/build/tslib*, then you must remove
    the .stamp_built stamp file and run make again. This will restart
    the compile process at the build step of tslib (but will *not*
    reconfigure tslib, so if you made any modifications at the
    configure level, it won't work)

 *) If you add new patches to package/tslib/, then as Peter said, the
    easiest way is to rm -rf output/build/tslib.

Cheers,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] update on a file in tslib not reflected after doing "Make"
  2009-12-17  7:35       ` Thomas Petazzoni
@ 2009-12-17 10:45         ` Stanley
  2009-12-21  4:39         ` Stanley
  1 sibling, 0 replies; 8+ messages in thread
From: Stanley @ 2009-12-17 10:45 UTC (permalink / raw)
  To: buildroot

Thanks for the reply.

In fact I did try both step ***separately*.

1) mod directly and remove.stamp_built file
2) create patches and rm the tslib folder and all related files (lib
file/folder, bin file) in the staging_dir.

however in both cases, the changes did not get reflected. I tried by greping
the mod statement.

eg. printf("xres = %d, yres = %d\n",...); << original
printf("test\n\n\n\n\nxres = %d, test yres = %d\n",...); << mod

then enter cmd: grep -r "test" <bin file> --> return nothing
enter cmd: grep -r "xres" <bin file> --> return 'xres = %d, yres = %d' only

Cheers,
Stanley

On Thu, Dec 17, 2009 at 3:35 PM, Thomas Petazzoni <
thomas.petazzoni@free-electrons.com> wrote:

> Le Wed, 16 Dec 2009 21:35:16 +0100,
> Peter Korsgaard <jacmet@uclibc.org> a ?crit :
>
> > If you are putting new .patch files under package/tslib then you need
> > to rerun the patch step. The easiest way of doing this is simply to
> > delete the build dir (rm -rf output/build/tslib*)
>
> Yeah, basically:
>
>  *) If you hack directly into output/build/tslib*, then you must remove
>    the .stamp_built stamp file and run make again. This will restart
>    the compile process at the build step of tslib (but will *not*
>    reconfigure tslib, so if you made any modifications at the
>    configure level, it won't work)
>
>  *) If you add new patches to package/tslib/, then as Peter said, the
>    easiest way is to rm -rf output/build/tslib.
>
> Cheers,
>
> Thomas
> --
> Thomas Petazzoni, Free Electrons
> Kernel, drivers and embedded Linux development,
> consulting, training and support.
> http://free-electrons.com
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20091217/d7304cc1/attachment.htm>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] update on a file in tslib not reflected after doing "Make"
  2009-12-17  7:35       ` Thomas Petazzoni
  2009-12-17 10:45         ` Stanley
@ 2009-12-21  4:39         ` Stanley
  1 sibling, 0 replies; 8+ messages in thread
From: Stanley @ 2009-12-21  4:39 UTC (permalink / raw)
  To: buildroot

Hi all,

I know what is my problem already and manage to resolve it. It is because
the changes is not updated into the target folder ie the lib files is update
in the output/build folder but not copied into the project folder (not
installed). I think its partly because I am using fakeroot option.

anyway, I just do the steps mentioned and delete the installed_file in
/project/<project_name>/autotools-stamps/

Thanks for your help

Regards,
Stanley

On Thu, Dec 17, 2009 at 3:35 PM, Thomas Petazzoni <
thomas.petazzoni@free-electrons.com> wrote:

> Le Wed, 16 Dec 2009 21:35:16 +0100,
> Peter Korsgaard <jacmet@uclibc.org> a ?crit :
>
> > If you are putting new .patch files under package/tslib then you need
> > to rerun the patch step. The easiest way of doing this is simply to
> > delete the build dir (rm -rf output/build/tslib*)
>
> Yeah, basically:
>
>  *) If you hack directly into output/build/tslib*, then you must remove
>    the .stamp_built stamp file and run make again. This will restart
>    the compile process at the build step of tslib (but will *not*
>    reconfigure tslib, so if you made any modifications at the
>    configure level, it won't work)
>
>  *) If you add new patches to package/tslib/, then as Peter said, the
>    easiest way is to rm -rf output/build/tslib.
>
> Cheers,
>
> Thomas
> --
> Thomas Petazzoni, Free Electrons
> Kernel, drivers and embedded Linux development,
> consulting, training and support.
> http://free-electrons.com
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20091221/86982212/attachment.htm>

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2009-12-21  4:39 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-15  7:30 [Buildroot] update on a file in tslib not reflected after doing "Make" Stanley
2009-12-15  8:18 ` Peter Korsgaard
2009-12-15  8:27 ` Thomas Petazzoni
2009-12-16  4:30   ` Stanley
2009-12-16 20:35     ` Peter Korsgaard
2009-12-17  7:35       ` Thomas Petazzoni
2009-12-17 10:45         ` Stanley
2009-12-21  4:39         ` Stanley

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox