Commit Graph

3 Commits

Author SHA1 Message Date
Christophe Fergeau
bc5326b1ce Unify header guards
This changes the header guards in all .h files to follow this format:

/*
 * Licensing block
 */

/* ... */

Acked-by: Jonathon Jongsma <jjongsma@redhat.com>
2017-03-30 18:17:20 +01:00
Frediano Ziglio
f36c3887ba Make sure all headers are independent
Make sure is possible to include any headers alone.

I used this script to check independence (run under server directory):
----
#!/bin/bash

set -e

# check not already modified
if grep -q libheaders.la Makefile.am; then
    echo "Header library already prepared" >&2
    exit 1
fi

add_lib() {
    local hdr="$1"

    hdr=${hdr%.h}
    c="mao_${hdr}.c"
    echo "#include \"${hdr}.h\"" > $c
    echo -e "\t$c \\" >&3
}

# add library to compile all headers alones
exec 3>> Makefile.am
echo "
noinst_LTLIBRARIES += libheaders.la
libheaders_la_SOURCES =				\\" >&3
for hdr in *.h; do
    case $hdr in
    spice-bitmap-utils.h)
        add_lib $hdr
        ;;
    spice*.h)
        ;;
    *)
        add_lib $hdr
        ;;
    esac
done
echo -e "\t\$(NULL)" >&3
exec 3>&-
----

Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Acked-by: Jonathon Jongsma <jjongsma@redhat.com>
2016-05-18 00:24:37 +01:00
Frediano Ziglio
525cd67be7 server: rename files
Signed-off-by: Marc-André Lureau <marcandre.lureau@gmail.com>
Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Acked-by: Jonathon Jongsma <jjongsma@redhat.com>
2015-12-03 23:54:32 +00:00