summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2014-07-08man: fix typo in kmscon.1HEADmasterDavid Herrmann1-1/+1
Fix ecah -> each typo. Reported-by: Steven Honeyman Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2014-05-25Partly revert "shl: handle pathconf() errors"David Herrmann2-3/+9
This partly reverts commit 41e76d11dff6dd9bc08bf829751f9634f32cdd38. I removed the "superfluous" errno-handling, which in fact is needed. Turns out pathconf() might leave errno unchanged. Reported-by: Lubomir Rintel <lkundrak@v3.sk> Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2014-05-25shl: handle pathconf() errorsLubomir Rintel2-3/+7
It can return -1 (feature not supported, denied by a security module, etc.), resulting in wrong allocation later on. Signed-off-by: Lubomir Rintel <lkundrak@v3.sk> (remove superfluous errno-checks) Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2014-05-16build: add libtsm to bbulk and gltexXiong Zhang1-1/+8
text_bbulk.c and text_gltex.c contain text.h which depend on libtsm. Without adding tsm flags to compile option, bbulk and gltex can't be compiled. Signed-off-by: Xiong Zhang <panda0626@gmail.com> Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2014-04-22build: don't build shl_gl if GLES is disabledDavid Herrmann1-4/+2
We required GL headers for shl_gl.h. Even though the linker strips all the GL dependencies if it's disabled during compilation, we still require it as build-time dependency. Avoid that by not including shl_gl in any non-GL builds. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-04uterm: drm: activate context before swappingDavid Herrmann1-0/+1
Lets be safe here and activate the context before performing the buffer-swap. Drivers might be inconsistent and require this in case the background process changed the DRM state. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-04uterm: drm: force immediate modeset during wakeupDavid Herrmann2-10/+19
We need to call drmModeSetCrtc during wakeup to prepare for page-flips. An immediate modeset is needed, otherwise we cannot be sure the FB/Crtc configuration is still the same. Force an immediate DRM modeset on wakeup to reset the screen. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-04uterm: drm: set VIDEO_HOTPLUG on wakeupDavid Herrmann1-1/+3
Be more verbose during wake-up and set VIDEO_HOTPLUG so we force the hotplug-check. I don't know why it worked until now, but we definitely need to force it as we have no idea what display-status changed. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03uterm: input: forward xkbcommon log messagesDavid Herrmann1-1/+44
Instead of letting xkbcommon write to stderr, we now forward these messages via the llog handler. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03shl: log: check for trailing newlinesDavid Herrmann1-10/+13
If the format string contains a trailing newline, we now skip writing our own. We also skip the fn+file information as it would be written on the next line. Trailing newlines occur only when forwarding messages from other libraries. In this case we don't need the fn+file information, anyway. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03shl: log: don't use strerror()David Herrmann1-2/+2
strerror() is not re-entrant safe so we should use %m instead. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03uterm: input: use shl_llog instead of shl_logDavid Herrmann7-47/+78
We should use library-logging in uterm to avoid cluttering stderr for applications. Hence, use llog instead of log directly. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03build: strip \r from shadersDavid Herrmann1-2/+2
\r is rarely used and probably always escaped in strings so we can safely erase it together with \n to reduce its size. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03uterm: input: add built-in keymap fallbackDavid Herrmann4-7/+683
This adds a small US-keymap to the uterm library which is loaded if we cannot find a suitable system default keymap. This allows using the keymap if no XKB keymaps are installed. Thanks to Ran Benita for the minimal US keymap. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03genunifont: remove useless status messageDavid Herrmann1-1/+0
No reason to clutter build output with this debug message. Drop it. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03build: mark binary data as read-only with objcopyDavid Herrmann2-0/+9
Check for objcopy in configure.ac and then mark binary data as read-only by renaming .data to .rodata and setting the correct flags. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03build: mark XSLTPROC with AC_ARG_VARDavid Herrmann1-0/+1
This allows changing the path to XSLTPROC via the command-line option if it cannot be found by autoconf. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03build: replace genshader by binary linkerDavid Herrmann13-233/+89
Instead of generating C source files, we now use our binary-linker make target which can link in any arbitrary binary file. This way, we can delete genshader and instead link the files directly. This speeds up compilation and makes the code more consistent. We also strip the shaders from useless comments and whitespaces to reduce memory consumption. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03shl: shader: add "len" parameter to shader sourcesDavid Herrmann4-15/+22
Shader sources may not be 0 terminated if we mmap() them. Hence, we need to pass the length to the shader compiler. As glShaderSource() allows this <0 as zero-terminated strings, we can simply add a parameter for the shader length. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-11-03shl: move static_gl_* to shl_gl_*David Herrmann8-25/+27
No need to keep these static helpers outside of SHL. Instead, include them in SHL to avoid any external linking. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29Bump kmscon version to 8kmscon-8David Herrmann1-1/+1
We're ready for a new bugfix release. Bump version to 8. No libraries are installed, anymore, so no need to bump library versions. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29docs: adjust NEWS file for kmscon-8David Herrmann1-0/+30
Mostly build-tool changes and code removal. Everything else bug fixes, fixes, fixes, ... Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29docs: update README linksDavid Herrmann1-0/+3
Update links to dependencies in the README file. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29build: enable kmscon unconditionallyDavid Herrmann3-158/+24
We removed all additional libraries/applications so we can now always enable building kmscon. This also means we can remove a bunch of old now unused options and flags. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29build: link eloop staticallyDavid Herrmann8-614/+4
We don't want to export libeloop so link it statically. Avoid installing into into the system. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29build: link libuterm staticallyDavid Herrmann4-198/+4
We shouldn't export libraries which we don't really allow linkink externally. Link libuterm statically and avoid installing it into /lib. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29build: remove default /usr prefixDavid Herrmann1-1/+0
We should never install anything into /usr by default. Remove that. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29Remove cairo text-rendererDavid Herrmann6-593/+1
The cairo text-renderer is _way_ too slow. There's no reason to keep it around, anymore. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29Remove libuvtDavid Herrmann12-2452/+0
uvt is not used inside of kmscon. Moved into a separate library if some-one is interested. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-29Remove freetype2 font backendDavid Herrmann7-825/+2
The freetype2 font backend lacks support for proper combining marks and I do not intend to ever implement that. Use pango! If you don't want heavy dependencies, you can use the unifont or 8x16 backends. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-23tsm: remove and depend on libtsmDavid Herrmann20-6529/+32
TSM was extracted from kmscon sources so it can more easily be used by other emulators. It is available at: http://cgit.freedesktop.org/~dvdhrm/libtsm Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-23kmscon: remove cdev sessionsDavid Herrmann9-1600/+3
cdev sessions are outdated. Use libuvt instead. Remove all references to cdev-sessions and clean up the build chain. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-23uvtd: removeDavid Herrmann10-2075/+0
Remove uvtd. The idea is outdated and not really needed. With recent systemd-logind changes, all we need is a shim between legacy-programs (like XServer) and logind. We can easily do that via libuvt without requiring a huge daemon like uvtd. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-23wlterm: removeDavid Herrmann12-4355/+0
Remove all wlterm sources. I never intended to maintain it longer than any major terminal-emulator needs to get ported over to wayland. Hence, remove it. It was buggy, anyway. If anyone is interested, a GTK+ based wlterm is available on: http://cgit.freedesktop.org/~dvdhrm/wlterm Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-23dummy: redraw on display-refreshDavid Herrmann1-0/+11
If we get a display-refresh event, redraw the screen. Otherwise, we might stay blank during VT switches if we get a delayed set-master. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-23terminal: redraw on display-refreshDavid Herrmann1-0/+3
If we get a display-refresh event from the session layer, we must redraw the screen to avoid staying blank. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-18seat: forward UTERM_REFRESH events to sessionsDavid Herrmann3-0/+49
On UTERM_REFRESH events we now forward the event to all sessions on the bound seat. Sessions can then react to it and repaint the screen. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-18uterm: drm: retry DRM wakeup after short timeoutDavid Herrmann5-2/+49
If drm-wakeup fails, we now retry after 20ms continously to gain DRM-Master again. If we succeed we send UTERM_REFRESH events for all available displays so existing code can pick it up. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-18genunifont: fix MAX_DATA_SIZE to be in 8bit rangeDavid Herrmann1-1/+1
We only use uint8_t as length-counter so MAX_DATA_SIZE must be <256 to make our length-checks work. This fixes a bug where we read invalid data if someone uses modified genunifont data files. As this just produces garbled glyphs if garbled data is given, this is actually not critical at all. Reported-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-18genunifont: fix ftell() error checkingDavid Herrmann1-1/+1
We need to use signed types to actually see errors from ftell(). Fix it by using "long" for status bits now. Reported-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-10-18uterm: drm: move display_ops into vdrm objectDavid Herrmann4-23/+22
Instead of passing display-ops to every helper store it in vdrm-objects. During vdrm-setup we set the pointer and reuse it in all helpers. This simplifies the function headers and allows calling them from helper-callbacks without requiring a pointer from the respective user. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-09-12build: allow kmscon to be cross-compiledThierry Reding3-5/+142
The genshader and genunifont utilities are run during the build process to generate source files. In order for that to work when cross-compiling the files need to be built using the native compiler instead of the cross-compiler. Add the AX_PROG_CC_FOR_BUILD m4 macro which defines various *_FOR_BUILD variables that are the native equivalents of CC, CFLAGS, LDFLAGS, etc. Override CC, CFLAGS and LDFLAGS for genshader and genunifont and their object files so that they will be built natively and can be executed during the build. Signed-off-by: Thierry Reding <treding@nvidia.com> (added TODO marker) Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-09-12wlt: toolkit: flush display after wl_display_dispatch_pending()Ran Benita1-2/+5
wlterm doesn't work with current Wayland/Weston; the events are never sent and the window doesn't come up. We need to flush the display, as per wl_display_dispatch_pending(3): To proper integrate the wayland display fd into a main loop, the client should always call wl_display_dispatch_pending() and then wl_display_flush() prior to going back to sleep. Signed-off-by: Ran Benita <ran234@gmail.com> Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-09-04kmscon: set default precision for fragment shadersDavid Herrmann4-0/+8
With mesa-9.2 fragment shaders are required to define default precisions as defined in the standard. We didn't do this.. whoops. Add the mediump declarations and everything should be working again. fixes fdo bug: #68934 Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-08-19gltex: fix GL_UNPACK_ROW_LENGTH(_EXT) updateDavid Herrmann1-0/+5
Khronos updated their GLES2 headers and broke backwards compatibility, hurray. Fix it for real now. Reported-by: Yichao Yu <yyc1992@gmail.com> Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-08-19uterm: drm3d: fix GL_UNPACK_ROW_LENGTH(_EXT) macroDavid Herrmann1-0/+5
Khronos "fixed" their new OpenGLES2 headers and added a bunch of _EXT suffixes. Now we need to test for both, the old and new macros, yay! Thanks to Yichao Yu for spotting that. Reported-by: Yichao Yu <yyc1992@gmail.com> Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-07-15docs: use WantedBy in kmsconvt@.serviceDavid Herrmann1-1/+1
We currently use the old systemd syntax that was copied from getty@.service. It doesn't allow enabling specific TTYs, though. So use the new WantedBy syntax instead. Thanks to "trusktr" for investigating and reporting upstream to systemd developers. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-06-12kmscon: pass vtnr to pty so XDG_VTNR is setDavid Herrmann3-5/+15
We need to correctly set the VTNR for each new pty, otherwise the pty cannot set the XDG_VTNR correctly. Note that we do this only for real VTs, that is, vtnr > 0. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-06-12pty: set XDG_VTNR if requested by callerDavid Herrmann2-2/+24
A caller can now pass a VT-num to the PTY which will get set as XDG_VTNR in the environment of new childs. This can be used to tell systemd-logind to associate the session with the correct VT. But note that this still cannot overwrite VT-associations if the pty is created from within an existing session. Reported-by: Thomas Hebb Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-06-12uterm: vt: add uterm_vt_get_num() helperDavid Herrmann3-0/+14
This helper returns the VT-number for the given VT if, and only if, it is a real VT. In all other cases 0 is returned. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>