Previous Thread
Next Thread
Print Thread
#108634 - 01/26/17 02:37 PM Should I "make clean"?  
Joined: Nov 2016
Posts: 9
dingodan Offline
Member
dingodan  Offline
Member

Joined: Nov 2016
Posts: 9
I'm a bit new to compiling stuff in general, and can't tell from the docs if "make clean" is needed. I've scheduled a monthly bash script to build the latest version of mame for me from a cloned, updated copy of the git repo.

Is this step needed/recommended?

Code:
latesttag=$(git describe --tags)
echo checking out ${latesttag} > make_log
git fetch >> make_log
git checkout ${latesttag} >> make_log
make clean >> make_log
make -j3 >> make_log

#108635 - 01/26/17 02:59 PM Re: Should I "make clean"? [Re: dingodan]  
Joined: Feb 2004
Posts: 1,747
Vas Crabb Offline
Very Senior Member
Vas Crabb  Offline
Very Senior Member

Joined: Feb 2004
Posts: 1,747
Sydney, Australia
If you're doing a full build once a month, you're better off just deleting the entire build folder before running the build to ensure you have a completely clean state. Also, I'm not quite sure what the good of doing a describe before the fetch is. You'd be better off doing something like:
Code:
rm -r build > make_log 2>&1
git fetch >> make_log 2>&1
latesttag=$(git tag | tail -1)
echo "checking out ${latesttag}" >> make_log
git checkout ${latesttag} >> make_log 2>&1
make -j3 >> make_log 2>&1

#108638 - 01/26/17 03:44 PM Re: Should I "make clean"? [Re: dingodan]  
Joined: Nov 2016
Posts: 9
dingodan Offline
Member
dingodan  Offline
Member

Joined: Nov 2016
Posts: 9
Done. Thank you Vas, and happy australia day! smile


Moderated by  R. Belmont 

Who's Online Now
4 registered members (Llaffer, B2K24, Olivier Galibert, Augusto), 25 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Shout Box
Forum Statistics
Forums9
Topics8,318
Posts107,539
Members4,734
Most Online225
May 26th, 2014
Powered by UBB.threads™ PHP Forum Software 7.6.0
Page Time: 0.274s Queries: 14 (0.257s) Memory: 4.9382 MB (Peak: 5.1075 MB) Zlib enabled. Server Time: 2017-04-27 03:09:24 UTC