Two new functions to retrieve the current major number and dynamically
allocate minor numbers.
This can be used by clients that allocate more than one CDEV for VTs to
dynamically retrieve a new minor number.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
We need to export the symbols to make use of them. This exports all useful
ctx+cdev functions for outside use. The other subsystems still need to get
reviewed before we export them.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
We used an incorrectly formatted arguments as we mixed up two local
variables. Use the correct DEVNAME format now.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
These numbers are pretty useful during debugging so print them before
attempting to create the cdev devices.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
A flagset is a dynamic array where each bit of the array can be
independently set/reset. It can be used for minor/major allocations or
for other dynamically growing bitsets.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
We now have official upload space on freedesktop.org. No need to link to
my personal upload space, anymore.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
kmscon is now hosted on freedesktop.org. Please don't use the github
links, anymore. I will push to github for some more weeks, but I recommend
to everyone to use my freedesktop.org repository as primary upstream link.
There were many reasons why github.com wasn't sufficient, anymore. But the
main reason is that they no longer provide upload space for release
tarballs. Hence, lets ditch github and move to freedesktop.org which
kindly provides everything we need plus a really nice mailing-list.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
xz is way better than bz2 with same/better decompression times.
Compression will take longer, but that's totally ok.
All new tarballs will be provided as xz only. Please adjust your
build-scripts to stop using bz2.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
This flag enables all other options that extend the build. It is used for
debugging only and should never be used by distributions to control what
is built. Hence, we don't document it and never advertise it.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
This introduces uvtd which replaces kmscon sessions as an external helper
program. It's still a dummy program but it will get extended soon. After
that, kmscon sessions will get removed and limited to a single seat. This
will simplify kmscon itself heavily and move rarely used features out of
kmscon into helpers.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
This moves githead.h to shl_githead.c so we can skip recompilations on
GIT-HEAD changes. We only need to relink now (which we cannot skip).
This speeds up build-processes considerably on slower machines.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
We want to avoid any static files that are shared between multiple
programs but are not part of SHL. These make the build-process just more
complex.
Move log.[ch] to SHL so we have a known context.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
There is no reason to include headers in the main body of the source code.
Move it to the top so it's more readable.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
ld automatically assumes that any binary input file requires an executable
stack. There's no way to tell it that it doesn't so we simply mark all
inputs as noexecstack.
Reported-by: Etam
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
This is kmscon-7. See ./NEWS for a list of new features.
Unfortunately, github disabled the "Downloads" section so there is no way
to upload new pre-generated tarballs. I have a pending application to move
kmscon to freedesktop.org, but it didn't get processed in time for this
release. Therefore, you need to build the GNU-autotools files yourself.
That is, before calling ./configure you need to call:
NOCONFIGURE=1 ./autogen.sh
You can extend your build-scripts with:
test -f ./configure || NOCONFIGURE=1 ./autogen.sh
Which will call ./autogen.sh if needed. Everything else can be left
unchanged.
I will not upload the tarballs at another location. Feel free to do that
yourself, but I personally think this will introduce more confusion than
help. I hope the freedesktop.org move will be soon approved. This will
also provide a mailing-list where I can properly announce new releases.
Raw tarballs will be available as (without pre-generated autotools):
https://github.com/dvdhrm/kmscon/archive/kmscon-7.tar.gzhttps://github.com/dvdhrm/kmscon/archive/kmscon-7.zip
The git-tag is: kmscon-7
You can use my public GPG key to verify the tarballs.
As usual, please report bugs to: https://github.com/dvdhrm/kmscon
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
It currently isn't possible to pass empty lists to these arguments as it
will then be interpreted as default. Fix this by using "default" if it is
empty.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
No reason to disable static libraries. Remove the LT_INIT parameter so we
can provide statically linked libraries.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
UVT is based heavily on the old cdev-sessions. It uses CUSE/FUSE to
implement virtual terminals in user-space.
This move into a library allows to use it in other projects, too. There is
no reason to limit it to kmscon sessions. In fact, we will remove the
cdev-sessions, soon and make kmscon a stand-alone terminal emulator
without any session capability.
Instead, the uvtd program will provide the VT emulation.
This library is not finished, nor ready for use. However, feel free to
contribute patches so we can eventually release a stable API.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
We changed a whole bunch of stuff since kmscon-6 but most of it still
isn't finished (mainly the modularization). However, we definitly need a
bugfix-release.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Unifont is a very nice font-backend that now has sane compilation times
(by using ld directly). It's recommended over 8x16 as it has proper
internationalization support.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
We now provide an experimental pixman backend. It still suffers from the
same problems but that cannot be fixed easily. Check it out if you want
it. Disabled by default, though.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
If we allow users to specify log functions, we should also allow them to
pass a context. This isn't used internally, but may be needed by external
users so provide it.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Instead of using the blown up UTERM_FORMAT_GREY binary data, we now use an
A1 1bit alpha channel and extract the data during runtime. This guarantees
that only used characters will be extracted into the full alpha channel.
We should add support for A1 formats in uterm to avoid this problem
entirely.
We also now link the binary file directly into the module via ld. This
avoids the long compile times for the huge C-array that we previously
generated. As a side effect, you no longer run out of memory linking this
file on small machines.
With this change we could even start making unifont a default font-backend
as it now works pretty well.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Major overhaul of the build system. This introduces symbol-versioning for
all exported libraries. Please note that none of these libraries is
stable, yet!
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Afterchecks should be always performed when reading data into a config
context. So perform them after copy operations, too.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
We need the font layer to build wlterm. However, the font layer depends on
kmscon internal module handling so we cannot do this. To avoid this, we
simply provide dummy handlers for the kmscon_module_* layer and link it
anyway. This is kind of ugly but works, yey!
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This renames the video-drm backend to drm3d (which was already used
internally). This is a pure rename, the code-logic stays the same.
This also puts the drm3d backend into a module so we can more easily
load it during runtime.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This moves all the drm-dumb code into a new module that is now called
drm2d (which was already used internally before).
No conceptual changes, just renames and moves.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
pixman expects stride values to be a multiple of 4. However, the glyphs we
get may be of a different stride so copy it if it is.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
The "true ||" case made pixman always use shadow buffers. Remove this
debug statement so it works as expected.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
We can preallocate a white solid-fill image so we don't have to do that
for each round where we blend white glyphs.
Also, if the background is black, we can omit the pixman_fill() operation
and use the direct composite with SRC operations.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This was recommended by Soren Sandmann on the pixman ML. We can optimize a
real t /= 255 with:
t += 0x80
t = (t + (t >> 8)) >> 8;
Instead of using a single fake (t >> 8) shift as we used to.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>