From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31782 invoked by alias); 2 Jun 2014 13:57:11 -0000 Mailing-List: contact cygwin-xfree-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-xfree-owner@cygwin.com Reply-To: cygwin-xfree@cygwin.com Mail-Followup-To: cygwin-xfree@cygwin.com Received: (qmail 31766 invoked by uid 89); 2 Jun 2014 13:57:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.3 required=5.0 tests=AWL,BAYES_20,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 X-HELO: smtpout20.bt.lon5.cpcloud.co.uk Received: from smtpout20.bt.lon5.cpcloud.co.uk (HELO smtpout20.bt.lon5.cpcloud.co.uk) (65.20.0.140) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 02 Jun 2014 13:57:09 +0000 X-CTCH-RefID: str=0001.0A090201.538C82B3.002F,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0 X-Junkmail-Premium-Raw: score=8/97,refid=2.7.2:2014.6.2.110619:17:8.510,ip=,rules=__MOZILLA_MSGID, __HAS_MSGID, __SANE_MSGID, __HAS_FROM, __HAS_REPLYTO, __USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION, __TO_MALFORMED_2, __TO_NO_NAME, __BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT, __SUBJ_ALPHA_END, __IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE, __SUBJ_ALPHA_NEGATE, SUPERLONG_LINE, __FORWARDED_MSG, BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1800_1899, __MIME_TEXT_ONLY, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS, BODY_SIZE_2000_LESS, REPLYTO_FROM_DIFF_ADDY, BODY_SIZE_7000_LESS, NO_URI_FOUND X-CTCH-Spam: Unknown Received: from [192.168.1.93] (86.179.19.48) by smtpout20.bt.lon5.cpcloud.co.uk (8.6.100.99.10223) (authenticated as jonturney@btinternet.com) id 538C47C400039A32; Mon, 2 Jun 2014 14:57:06 +0100 Message-ID: <538C82AF.9080702@dronecode.org.uk> Date: Mon, 02 Jun 2014 13:57:00 -0000 From: Jon TURNEY Reply-To: cygwin-xfree@cygwin.com User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 MIME-Version: 1.0 To: cygwin-xfree@cygwin.com CC: p.fedin@samsung.com Subject: Re: Automatic X server startup References: <000a01cf79aa$8d1c7f50$a7557df0$%fedin@samsung.com> <5384AD24.4080504@dronecode.org.uk> <004001cf7a74$5c6b3ac0$1541b040$%fedin@samsung.com> In-Reply-To: <004001cf7a74$5c6b3ac0$1541b040$%fedin@samsung.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2014-06/txt/msg00002.txt.bz2 On 28/05/2014 13:57, Pavel Fedin wrote: >> I believe this is arranged using launchd on OS X, which listens on the >> socket the X server will use, and starts the X server when something >> connects. >> >> Unfortunately, there is no similar system facility on Windows. > > But it should be possible to make xlib a little bit more smart, isn't it ? It could automatically run X server when a connection is attempted but refused. So we would achieve the same effect as on MacOS. > We could e. g. have some directory like /etc/X11/autostart, to be examined by xlib. If it detects that e. g. :0 screen is not accessible, it would attempt to look up 0.xlaunch file there and run "xlaunch -run /etc/X11/autostart/0.xlaunch" command. > What do you think ? I could implement this idea if you have no time to work on that, i believe it should be very easy. Patches are always welcome, so please feel free to work on this if you like. I have my doubts that that it's straightforward to add this in libX11 in a way that is generally useful (for e.g.: there would be a race condition if two processes both try to start the server at the same time, there's much room for confusion about how to specify the X server options to be used, if it could be started explicitly for the start menu, or implicitly by libX11,...) >> You can achieve a somewhat similar effect by copying the X server >> shortcut to the startup group to start it automatically at login, at >> the cost of slowing down system startup somewhat. > > Heh, it's already slow because of antivirus and other corporate stuff (i cannot disable it). Running on demand would be better. You might consider looking at starting it from launchd or perhaps xinitd if possible, and then just that can be started by the X server shortcut, or at startup. -- Jon TURNEY Volunteer Cygwin/X X Server maintainer -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/