WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: On a roll now!  (Read 4347 times)

Offline coreplayer2

  • Hero Member
  • *****
  • Posts: 3020
On a roll now!
« on: June 27, 2011, 01:23:06 PM »
Now that many of my system issues have been resolved I've been making extensions left and right, thanks guys :)

like a wireless extension (with latest usb adapter driver) so can connect at every boot without issue, libdvdcss so can now watch dvd's  YAY  am almost ready to make an extension of all backed up settings.

The wiki is great for those who know how already, some examples of each of how to apply each process would really help, like
Am curious how to apply these flags?  at the terminal with compiletc loaded perhaps?

export CFLAGS="-march=i486 -mtune=i686 -Os -pipe"
export CXXFLAGS="-march=i486 -mtune=i686 -Os -pipe"
export LDFLAGS="-Wl,-O1"


And why "touch" exactly?  what is it's purpose?    is it a time stamp utility?


I can't help but wonder why the process is left for users to complete the process,  A utility to automate the entire process surely would make the OS more appealing to the masses.    Open the app, point to the downloaded tar file and lastly a on click install install,   right?   does it really need to be more complex  than this?








« Last Edit: June 27, 2011, 01:30:45 PM by coreplayer2 »

Offline hiro

  • Hero Member
  • *****
  • Posts: 1229
Re: On a roll now!
« Reply #1 on: June 27, 2011, 01:49:04 PM »
Huh, are you trying to compile something there?

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11705
Re: On a roll now!
« Reply #2 on: June 27, 2011, 01:59:06 PM »
Hi coreplayer2

The command   touch filename   will update the time stamp of the file   filename.
If the file   filename   does not exist, it will create an empty file called   filename.

Offline coreplayer2

  • Hero Member
  • *****
  • Posts: 3020
Re: On a roll now!
« Reply #3 on: June 27, 2011, 03:17:38 PM »
Hi coreplayer2

The command   touch filename   will update the time stamp of the file   filename.
If the file   filename   does not exist, it will create an empty file called   filename.


cool, so the reason for updating the time stamp is ?  possibly to ensure this file is used over an older file? ie one which is included in an extension over one present prior to extension loading??

Offline maro

  • Hero Member
  • *****
  • Posts: 1228
Re: On a roll now!
« Reply #4 on: June 27, 2011, 08:28:28 PM »
The touch /tmp/mark needs to be seen in conjunction with the find /usr/local -newer /tmp/mark -not -type d command (for the "When DESTDIR Fails" case).

For those cases the installation attempt via make DESTDIR=/tmp/package install does not result in an installation in '/tmp/package'. The idea is that even though the "final" installation is to '/usr/local' (due to ./configure --prefix=/usr/local) a "mock" installtion into DESTDIR (e.g. '/tmp/package') is attempted. If that works (i.e. no files are written to ''/usr/local' but rather to '/tmp/package/usr/local') one can easily use '/tmp/package' as the root of the squashFS.

In case DESTDIR has been "ignored" the timestamped file allows 'find' to figure out which files have been written to '/usr/local'. This file list is then used via two 'tar' executions to copy all those files to '/tmp/pkg' and this then becomes the root of the squashFS.

So creating a timestamped file immediately prior to the installation attempt should limit said file list to only those files that were part of the installation process.
« Last Edit: June 27, 2011, 08:31:43 PM by maro »

Offline coreplayer2

  • Hero Member
  • *****
  • Posts: 3020
Re: On a roll now!
« Reply #5 on: June 28, 2011, 12:11:56 AM »
I was wondering how you tar up the files associated with the recent compilation.  thanks  great description..
 :)
« Last Edit: June 28, 2011, 12:20:36 AM by coreplayer2 »

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: On a roll now!
« Reply #6 on: June 28, 2011, 01:51:43 AM »
So creating a timestamped file immediately prior to the installation attempt should limit said file list to only those files that were part of the installation process.

In most cases. However installer may copy some data, configuration or other files with original date which is not found by this method.
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline maro

  • Hero Member
  • *****
  • Posts: 1228
Re: On a roll now!
« Reply #7 on: June 28, 2011, 02:44:50 AM »
In most cases. However installer may copy some data, configuration or other files with original date which is not found by this method.
Very true, in which case one could try a "brute force" approach along the lines of
    find / -xdev | sort > ~/before
    sudo make install
    find / -xdev | sort > ~/after
    diff -U 0 ~/before ~/after
plus some appropriate post-processing of the 'diff' result to get to the list of added entries accross the whole file system (minus '/proc'  and '/sys' which the '-xdev' option helps to suppress).

Offline coreplayer2

  • Hero Member
  • *****
  • Posts: 3020
Re: On a roll now!
« Reply #8 on: June 28, 2011, 12:04:08 PM »
A quick question, while this seems obvious, what is the difference between "make" and "make install" ?

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: On a roll now!
« Reply #9 on: June 28, 2011, 12:43:02 PM »
You have to read the makefile to see what each target does.

man make

Offline maro

  • Hero Member
  • *****
  • Posts: 1228
Re: On a roll now!
« Reply #10 on: June 28, 2011, 06:19:04 PM »
A quick question, while this seems obvious, what is the difference between "make" and "make install" ?
I also strongly believe that reading relevant man-pages is an excercise anyone asking questions should have done prior to posting. This case might be a bit different, as I could not find 'man.1' (i.e. provides.sh man.1 && cat info.lst only delivers false positives).

So I went over to my usual first stop for online man-pages (i.e. this page), pretending that I don't know the answer. But this one is a bit too terse to help answer the original question. So I take the clue and head over to the GNU make manual. But a 800k+ document might be a bit intimidating initially. Nevertheless as a consequence of skimming over it I'd consider sections 1 (Overview) and 2 (Introduction) probably worth reading for a start. Another source of information might be the relevant Wikipedia page.

If after some reading the question is still open one could always come back here (or contact me by PM).

Offline coreplayer2

  • Hero Member
  • *****
  • Posts: 3020
Re: On a roll now!
« Reply #11 on: June 28, 2011, 09:11:13 PM »
yes I read the die.net explanation thanks, I also find it a great resource.   I was asking here directly because usually when you ask folks with experience using the specific program in question, one will often get more meaningful  explanations which no book or manual will ever be capable of explaining.

:)