aMule Forum

English => Compilation problems => Topic started by: michelinok on May 18, 2011, 10:23:42 AM

Title: Stupid problem while updating svn...
Post by: michelinok on May 18, 2011, 10:23:42 AM
Hi there!
I've a very very trivial problem cross compiling amule...
This is what i've done the first time (i know...i'm quite stupid tell all the steps,maybe there's someting wrong...)

1) Installed ubuntu, full updates...
2) installed my cross compiler with all the tools needed (arm9)
3) downloaded in a folder (let's call it "amulenew") all the libraries and amule via svn
4) cross compiled the libraries (everythings ok!)
5) set the variables, ./autogen.sh inside amule's folder
6) ./configure with the required variables
7) make && make install
8) copied the executables to my embedded board

everything is ok at this moment...

but if i update amule's svn i get no errors, but the executables are not valid anymore.. (exceptions and/or invalid executable,blablablabla)

This is what i do when i want to update to the latest svn

1) Go inside amule's folder
2) svn up
3) make clean
4) set variables
5) ./configure blablablablabla
6) make && make install

at this point i get non working executable anymore.

Any idea on what it's wrong?

Today i've done a new installation of ubuntu repeating the steps, and i get working executable, but i'm 101% sure that when i'll "svn up" i'll get non working executables (this has happened 4 times in the last month,each time i've to reinstall everything from scratch!).

I'm going mad...  ??? :-\ >:(
Title: Re: Stupid problem while updating svn...
Post by: btkaos on May 18, 2011, 11:31:27 AM
Weird. What are the output of svn st after and before?
Title: Re: Stupid problem while updating svn...
Post by: michelinok on May 18, 2011, 11:52:35 AM
Weird. What are the output of svn st after and before?


I'm at work now,anyway what you mean with "svn st" ? and with "after and before"? I usually perform only "svn up".
"svn up" update correctly to the latest version (as i can see on googlecode).
Title: Re: Stupid problem while updating svn...
Post by: Stu Redman on May 19, 2011, 08:50:07 PM
Maybe the make clean is somehow botched for your cross platform?
Try the following:
- make dirs amule/source and amule/build
- check out a fresh woring copy to source
- run autogen.sh in source
- cd to build
- run ../source/configure from there
- build there

Next time svn up source, rm -r build and repeat.
I always build like that - I hate it when I have the binaries lying around among my sources.

Title: Re: Stupid problem while updating svn...
Post by: Kry on May 20, 2011, 05:46:42 AM
Set variables before make clean?
Title: Re: Stupid problem while updating svn...
Post by: michelinok on May 20, 2011, 08:03:16 AM
yesterday i've reinstalled ubuntu and recompiled everything...it's working now...
I'll wait next svn to try your suggestions.
Meanwhile i'll do a "clonezilla" of my installation  ;D
Title: Re: Stupid problem while updating svn...
Post by: michelinok on May 20, 2011, 09:02:26 AM
while waiting for the next svn up, what happen if i'll perform these steps when the next svn will come up?:

svn up
set variables
make && make install

i mean...what happen if i don't ./configure?
Title: Re: Stupid problem while updating svn...
Post by: Stu Redman on May 20, 2011, 08:33:54 PM
i mean...what happen if i don't ./configure?
Good chance it will work just fine. Guess what the devs are doing usually.  :)
You need to run autogen.sh and configure only if
- something in your environment has changed (different compiler, different libs or so)
- aMule's build configuration has changed (one of the makefile.am or configure scripts changed)

We just suggest to do full builds because it's the easiest way to make sure everything is fine.
Rule of thumb: if only .cpp .h .po has changed a simple make will do the trick.
Title: Re: Stupid problem while updating svn...
Post by: michelinok on May 23, 2011, 12:03:36 PM
These are the steps I do for each new svn, in the svn directory:

Code: [Select]
[ -f Makefile ] && make distclean   #Cleans old build if any, including configuration

# Ensures current source tree is aligned to svn server.
# 'svn up' is not enough because it doesn't touch any local modification to the source tree.
svn revert --recursive . 
svn up

./autogen.sh
./configure <bla...>
make clean # Yes, make clean, here!
make


This worked perfectly, but how i can i be 100% sure that the new version is compiled against the older one?  (ok,excluding the svn version reported by amuled and amulecmd...)?
Title: Re: Stupid problem while updating svn...
Post by: michelinok on May 23, 2011, 04:35:54 PM
I don't get you, please could you explain the concern?

...nevermind...stupid question...(i meant that i didn't understand how can i be 100% that the new generated files are the new one and not older ones...)  :P