IRC log of #maemo for Wednesday, 2018-01-24

*** luke-jr has quit IRC00:00
*** luke-jr has joined #maemo00:04
*** luke-jr has joined #maemo00:05
*** luke-jr has quit IRC00:06
*** heroux has quit IRC00:07
*** luke-jr has joined #maemo00:08
*** luke-jr has quit IRC00:11
*** luke-jr has joined #maemo00:11
*** Kabouik_ has joined #maemo00:14
*** Kabouik has quit IRC00:17
*** Alexxxlrus has quit IRC00:27
*** xorly has joined #maemo00:29
*** Birchy has joined #maemo00:32
DocScrutinizer05Vajb: in xterm or ssh try "set"00:43
DocScrutinizer05or maybe better "set|less"00:43
DocScrutinizer05also try    man bash|less -j9 +"/A variable may be assigned to"00:47
DocScrutinizer05there yiou got a few screenfull of stuff to read about env vars00:47
DocScrutinizer05unlike windows, in unix a var has a scope only of the current process (shell) and all child spawned by that process. So a usual way to define env vars is to place them into an init script. A child can NOT change values of variables in sibling or parent processes (unlike windows where all vars are system global)00:51
DocScrutinizer05extually you even might need to "export MyVar" to make it available to child processes00:53
DocScrutinizer05actually*00:53
DocScrutinizer05an easy to memorize metaphor is: unix hands down info written into the family Bible and its copies from parent to children. The parents never get to know what the children write (or delete or change) in the Bible. On and on from generation to generation. In contrast to that windows has the env vars written to the chalk board in the classroom and every pupil and the teacher can see what every other person writes, changes or deletes there00:57
DocScrutinizer05HTH00:58
DocScrutinizer05less ~/.profile ~/.bashrc01:02
*** xes has quit IRC01:04
DocScrutinizer05also see /etc/init.d/* - PID1 (the very first process and thus parent of all) runs init scripts to start other processes like X11, so an env var defined in that e.g. X11 initscript will be available and visible to X11 process and all its children01:07
*** xes has joined #maemo01:10
*** xorly has quit IRC01:17
*** Pali has quit IRC01:32
MaxdamantusSo unix is like a religion and Windows is like modern science.01:33
*** dafox has joined #maemo01:35
*** xes has quit IRC01:57
*** xes has joined #maemo02:09
*** florian has quit IRC02:11
*** cyteen has quit IRC02:12
*** cyteen has joined #maemo02:16
*** xes_ has joined #maemo02:23
*** xes has quit IRC02:23
*** xes_ is now known as xes02:27
*** DocScrutinizer05 has quit IRC02:35
*** DocScrutinizer05 has joined #maemo02:35
valeriusDocScrutinizer05 I think that you're not right regarding windows. Windows is a system that inherits DOS. Since DOS, it's possible to add env. variables with "set" commands. So, these variables are set in the current shell, and get inherited by child processes. Also, the "root" environment variables can be set in autoexec.bat. This is a gobal env. variables for a "root" shell. DOS had child processes to, and they inherit the environment of the parent02:36
valerius. The same is in windows. Parent cannot get its child's environment. But what windows adds is a possibility to redefine a "root" environment (in settings of "My computer" icon). So that, the global environment change takes effect in all process hierarchy, immediately, i.e, without a reboot. So, the intent is to do that without a reboot. Otherwise, it is done the same way as in UNIX. The only difference is the absence of "export" command, but that's02:36
valerius because of a different shell.02:36
DocScrutinizer05valerius: you might be right, i'm no windows expert02:37
valeriusautoexec.bat can be thought of as "init scripts" in DOS02:38
*** dafox has quit IRC02:38
valeriusDocScrutinizer05 me too :)02:38
DocScrutinizer05I'm just pretty sure windows allows global changing of env vars and I know the better half od details how unix works02:38
DocScrutinizer05I never meant to claim parent could get childs env, what I meant was child can't change parent's env02:41
DocScrutinizer05in unix, and it can in windows02:41
*** eMHa has quit IRC02:43
DocScrutinizer05I mean I seem to recall in windos you can start an editor of sorts (-> it's a child) to edit global env vars (so owned by (grand)parent)02:43
valeriusI doubt that. You can only change the root environment with "My Computer" icon. Simple windows processes can't do that. I'm not sure, of course, if a windows program can call an API changing the "root" environment. Maybe, it could, but I cannot tell for sure02:43
valeriusI'm not a windows expert too :)02:44
DocScrutinizer05well, HOW do you change that? you need a process for doing that and that process is... a child of the process defining the vars, no?02:44
DocScrutinizer05or maybe not even that02:45
valeriushm, not sure. Maybe that requires special privileges, and only "explorer" could do that02:46
DocScrutinizer05that's irrelevant for the general architecture02:46
* valerius needs to ask about that on #reactos ;)02:46
DocScrutinizer05meh, anyway I'm really not the one to disczuss windows idiosyncrasies with02:47
valerius:)02:47
DocScrutinizer05I just tried to give some reference where unix might surprise users that are familiar with the way windows works, the topic was unix env vars though02:48
DocScrutinizer05and you define unix env vars in parent and children inherit a copy basically02:48
DocScrutinizer05children never gave write access to parrent address space02:49
DocScrutinizer05have* - for (env) vars02:49
valeriusYes, the question was about the UNIX environment, I agree. But DOS and DOS-based OS'es took this idea from UNIX, so they work the same02:50
DocScrutinizer05parent and child can share a memory segment, env vars are not in such shared segment though02:50
valeriusyes, that's logical02:51
DocScrutinizer05i think "man fork" and/or "man execve" might have details how parent copies env vars into child's address space02:52
DocScrutinizer05and for a windows user it might be puzzling to not find a whatchacalledit... "root environment with "My Computer" icon" to change env vars02:54
DocScrutinizer05in unix02:55
valeriusyes, agree02:59
DocScrutinizer05>>The fork() function shall create a new process. The new process (child process) shall be an exact copy of the calling process (parent process) except as detailed below: ... [no env vars mentioned in there, so they are a copy] ...<<03:04
DocScrutinizer05from  man 3p fork03:04
DocScrutinizer05well, that's also a pathetic rationale by me, env vars could get stored in any memory range that's world r/w and processes copy pointers to that memory (which is prolly what windows does)03:08
DocScrutinizer05anyway in unix they are not stored in such public place03:08
*** HRH_H_Crab has quit IRC03:14
valeriusHm, env vars are intended to be copied from parent environment to the child's one. I doubt that they are stored in a public place. I did not thoght it might be too bad in windows. I only thought that the "explorer" process only changes the environment of the whole win32 subsytem, and the changes are then propagated along the process hierarchy (i.e, it's copied down the hierarchy, but not that each process accesses some globally accessible area. That03:16
valerius would be too bad even for M$ :))03:16
*** infobot has quit IRC03:17
*** infobot has joined #maemo03:19
DocScrutinizer05how are arbitrary processes downstream the explorer hierarchy (read: children of explorer)?03:19
DocScrutinizer05but honestly, this is sort of OT for maemo03:20
MaxdamantusPresumably when getting explorer to start a new program, the new process will have a copy of explorers environment, with changes specified by configuration like global variables and variables set in the shortcut, if relevant.03:25
valeriusDocScrutinizer05 The global environment is somewhere in a "win32" subsystem. Explorer is just a windows task that could configure the whole subsystem settings, including the environment. Maybe, it's changing only its own environment, and that's sufficient, because it starts all other user processes. So, it can be thought as a login shell. So, it could change it's own environment. I'm not sure, how it's gets propagated to all children.03:25
Maxdamantusexplorer's*03:25
valeriusMaxdamantus Yes, maybe env changes are propagated only to newly-stared processes, but not the old ones03:26
*** yosafbridge has quit IRC03:27
valerius*started03:29
*** heroux has joined #maemo03:29
MaxdamantusI think the general expectation would be that most programs are started through explorer anyway.03:29
*** DocScrutinizer05 has quit IRC03:30
Maxdamantusunix-like systems don't really have that expectation; if someone starts a program from bash, bash directly forks/execs that program.03:30
Maxdamantusinstead of sending some message to the init system to start it.03:30
*** HRH_H_Crab has joined #maemo03:31
*** DocScrutinizer05 has joined #maemo03:31
Maxdamantusand if you start it from a file manager, the file manager probably forks/execs .. if you start it from some menubar program, that probably forks/execs, etc03:32
Maxdamantus(not that I use file managers or menubars, so might be mistaken as to how they're likely to work)03:32
*** pkill9 has quit IRC03:33
*** yosafbridge has joined #maemo03:37
valeriusMaxdamantus hm, I tried to start Far manager in windows, then change the global environment, and then run a compiler from inside Far. It seems, the environment change took an effect in Far's children too, though they are not started directly by explorer. But I'm not sure.03:37
valeriusYes, we have gone into offtopic, I agree ;)03:37
MaxdamantusYeah, so I'm wondering if such programs will communicate with explorer to get it to start the program instead of directly calling `SpawnProcess` itself.03:38
MaxdamantusActually, that's probably not right.03:44
valeriusAnyway, new programs are started by the win32 sybsystem by parent's request. So, explorer could ask the subsystem to change its global environment, so that all programs started get new environment changes from the central place. No matter, which process starts a child. It still needs to call an API from the win32 subsys. So, the sybsys copies env. variables from the parent's environment to child's one, and adds some new global vars from the global03:44
valerius environment. So, it just concats the changed global env to theparent's one. Then no env inheritance violation at all03:44
MaxdamantusSince I vaguely remember being able to do things like start explorer from the task manager.03:44
valeriusthey are communicating, but not with explorer. They communicate with win32 subsystem, I think03:44
valeriusyes, task manager can restart explorer -- it seems to be higher in the process hierarchy03:45
*** tm has quit IRC04:57
*** tm has joined #maemo05:01
*** Kabouik_ has quit IRC05:19
*** Kilroo has quit IRC06:09
*** FalconSpy has quit IRC06:24
*** FalconSpy has joined #maemo06:26
*** povbot has joined #maemo06:34
*** oniongarlic has quit IRC07:12
*** DocScrutinizer05 has quit IRC07:13
*** DocScrutinizer05 has joined #maemo07:13
*** vahe has joined #maemo07:41
*** vahe has left #maemo07:42
*** DarioAlejandro has quit IRC08:15
*** cyteen has quit IRC08:31
*** ceene has quit IRC08:40
*** ceene has joined #maemo08:41
*** __LauRoman has quit IRC08:49
*** eMHa has joined #maemo08:59
*** spiiroin has quit IRC09:01
*** cyteen has joined #maemo09:05
*** vahe has joined #maemo09:18
*** vahe has left #maemo09:18
*** jskarvad has joined #maemo09:26
*** jskarvad has quit IRC09:26
*** jskarvad has joined #maemo09:26
*** vahe1 has joined #maemo09:30
*** vahe1 has quit IRC09:32
*** vahe has joined #maemo09:33
*** vahe has left #maemo09:36
*** oniongarlic has joined #maemo09:37
*** vahe has joined #maemo09:43
*** vahe has quit IRC09:47
*** ecc3g has quit IRC10:21
*** ecc3g has joined #maemo10:23
*** geaaru has joined #maemo10:25
*** vahe has joined #maemo10:30
*** vahe has left #maemo10:30
*** Milhouse has quit IRC10:44
*** ceene has quit IRC11:05
*** ceene has joined #maemo11:05
*** TheKit has joined #maemo11:20
*** NotKit has quit IRC11:23
*** freemangordon_ has joined #maemo11:24
*** cyteen has quit IRC11:27
*** cyteen has joined #maemo11:30
*** florian has joined #maemo11:38
*** eMHa has quit IRC11:42
*** spiiroin has joined #maemo11:46
*** xorly has joined #maemo11:49
*** eMHa has joined #maemo12:16
*** eMHa has quit IRC12:38
*** eMHa has joined #maemo12:38
*** xes_ has joined #maemo12:39
*** xes has quit IRC12:41
*** xes_ is now known as xes12:47
*** freemangordon_ has quit IRC12:53
*** pkill9 has joined #maemo13:07
*** SmilyOrg has joined #maemo13:09
*** Smily has quit IRC13:09
*** aloril has quit IRC13:28
*** aloril has joined #maemo13:31
*** dafox has joined #maemo13:39
*** qwazix has quit IRC14:15
*** qwazix has joined #maemo14:19
*** cyteen has quit IRC14:22
*** cyteen has joined #maemo14:23
*** aloril has quit IRC14:24
*** xorly has quit IRC14:30
*** aloril has joined #maemo14:37
*** jskarvad has quit IRC14:37
*** Smily has joined #maemo14:54
*** SmilyOrg has quit IRC14:54
*** jskarvad has joined #maemo15:20
*** jskarvad has quit IRC15:20
*** jskarvad has joined #maemo15:20
*** aloril has quit IRC15:36
*** ceene has quit IRC15:39
*** aloril has joined #maemo15:43
*** zGrr has joined #maemo15:48
*** pkill9 has quit IRC15:52
*** xorly has joined #maemo16:06
*** varu- has joined #maemo16:16
*** varu has quit IRC16:17
*** spiiroin has quit IRC16:20
*** vakko has joined #maemo16:33
*** spiiroin has joined #maemo17:17
*** jskarvad has quit IRC17:31
*** jskarvad has joined #maemo17:43
*** jskarvad has quit IRC17:43
*** jskarvad has joined #maemo17:43
*** CatButts has joined #maemo18:00
CatButtsbutts18:00
* enyc blinks18:05
* bencoh mreows18:11
*** Kabouik_ has joined #maemo18:26
*** LauRoman has joined #maemo19:02
*** Hurrian_ has quit IRC19:06
*** jskarvad has quit IRC19:12
*** Pali has joined #maemo19:15
*** florian has quit IRC19:17
*** Pali has quit IRC19:27
*** Pali has joined #maemo19:27
*** zGrr has quit IRC19:28
*** Pali has quit IRC19:33
*** Pali has joined #maemo19:34
*** geaaru has quit IRC19:34
*** Pali has quit IRC19:35
*** Pali has joined #maemo19:35
*** xorly has quit IRC19:36
*** Pali has quit IRC19:37
*** Pali has joined #maemo19:37
*** Pali has quit IRC19:41
*** Pali has joined #maemo19:42
*** Pali has quit IRC19:45
*** Juesto has joined #maemo19:45
*** Pali has joined #maemo19:46
*** Pali has quit IRC19:51
*** Pali has joined #maemo19:51
*** Pali has quit IRC20:14
*** Pali has joined #maemo20:15
*** pkill9 has joined #maemo20:27
*** LauRoman has quit IRC20:46
*** LauRoman has joined #maemo20:54
*** Pali has quit IRC21:10
*** Pali has joined #maemo21:12
*** xorly has joined #maemo21:33
*** Pali has quit IRC21:42
*** Pali has joined #maemo21:42
*** florian has joined #maemo22:06
*** NotKit has joined #maemo22:20
*** TheKit has quit IRC22:23
*** eMHa has quit IRC22:42
*** eMHa has joined #maemo23:08

Generated by irclog2html.py 2.15.1 by Marius Gedminas - find it at mg.pov.lt!