summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTiago Vignatti <tiago.vignatti@intel.com>2012-02-13 18:19:24 +0200
committerTiago Vignatti <tiago.vignatti@intel.com>2012-02-14 16:49:38 +0200
commit6c02975a650883250ce505f310685f74f7d4ccd6 (patch)
tree86957bc2710066f33902a262f205e7b5adbc6446
parent52558a8618564ecc5c461dea0246b87b802d063a (diff)
Use new directory structure for the project
at the moment test/ is stub basically. Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
-rw-r--r--Makefile.am22
-rw-r--r--configure.ac11
-rw-r--r--include/Makefile.am1
-rw-r--r--include/libbacklight.h (renamed from libbacklight.h)0
-rw-r--r--src/Makefile.am6
-rw-r--r--src/libbacklight.c (renamed from libbacklight.c)0
-rw-r--r--test/Makefile.am29
-rw-r--r--test/setbacklight.c9
8 files changed, 65 insertions, 13 deletions
diff --git a/Makefile.am b/Makefile.am
index c44151a..7390993 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,12 +1,16 @@
-dist_doc_DATA = README COPYING
-
-include_HEADERS = libbacklight.h
-lib_LTLIBRARIES = libbacklight.la
-libbacklight_la_SOURCES = libbacklight.c libbacklight.h
-libbacklight_la_LDFLAGS = -version-number 0:0:1
-libatasmart_la_CFLAGS = $(PCIACCESS_CFLAGS)
-
-ACLOCAL_AMFLAGS = -I m4
+SUBDIRS = include src test
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libbacklight.pc
+
+MAINTAINERCLEANFILES = ChangeLog INSTALL
+
+.PHONY: ChangeLog INSTALL
+
+INSTALL:
+ $(INSTALL_CMD)
+
+ChangeLog:
+ $(CHANGELOG_CMD)
+
+dist-hook: ChangeLog INSTALL
diff --git a/configure.ac b/configure.ac
index 104ade2..a137bfd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,8 +1,7 @@
AC_PREREQ(2.63)
AC_INIT([libbacklight], 0.01, [mjg@redhat.com])
-AC_CONFIG_SRCDIR([libbacklight.c])
-AC_CONFIG_MACRO_DIR(m4)
+AC_CONFIG_SRCDIR([Makefile.am])
AM_INIT_AUTOMAKE([foreign 1.11 -Wall])
@@ -12,5 +11,9 @@ AM_SILENT_RULES([yes])
AC_PROG_CC
AC_PROG_LIBTOOL
PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.10.0])
-AC_CONFIG_FILES([Makefile libbacklight.pc])
-AC_OUTPUT \ No newline at end of file
+AC_CONFIG_FILES([Makefile
+ include/Makefile
+ src/Makefile
+ test/Makefile
+ libbacklight.pc])
+AC_OUTPUT
diff --git a/include/Makefile.am b/include/Makefile.am
new file mode 100644
index 0000000..1f9e1f7
--- /dev/null
+++ b/include/Makefile.am
@@ -0,0 +1 @@
+include_HEADERS = libbacklight.h
diff --git a/libbacklight.h b/include/libbacklight.h
index ff0e842..ff0e842 100644
--- a/libbacklight.h
+++ b/include/libbacklight.h
diff --git a/src/Makefile.am b/src/Makefile.am
new file mode 100644
index 0000000..bebc103
--- /dev/null
+++ b/src/Makefile.am
@@ -0,0 +1,6 @@
+AM_CPPFLAGS = -I$(top_srcdir)/include
+
+lib_LTLIBRARIES = libbacklight.la
+libbacklight_la_SOURCES = libbacklight.c libbacklight.h
+libbacklight_la_LDFLAGS = -version-number 0:0:1
+libatasmart_la_CFLAGS = $(PCIACCESS_CFLAGS)
diff --git a/libbacklight.c b/src/libbacklight.c
index fa78be2..fa78be2 100644
--- a/libbacklight.c
+++ b/src/libbacklight.c
diff --git a/test/Makefile.am b/test/Makefile.am
new file mode 100644
index 0000000..200aec6
--- /dev/null
+++ b/test/Makefile.am
@@ -0,0 +1,29 @@
+#
+# (C) Copyright Intel 2012
+# All Rights Reserved.
+#
+# Permission is hereby granted, free of charge, to any person obtaining a
+# copy of this software and associated documentation files (the "Software"),
+# to deal in the Software without restriction, including without limitation
+# on the rights to use, copy, modify, merge, publish, distribute, sub
+# license, and/or sell copies of the Software, and to permit persons to whom
+# the Software is furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice (including the next
+# paragraph) shall be included in all copies or substantial portions of the
+# Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
+# IBM AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+# DEALINGS IN THE SOFTWARE.
+
+noinst_PROGRAMS = setbacklight
+
+AM_CPPFLAGS = -I$(top_srcdir)/include
+LDADD = $(top_builddir)/src/libbacklight.la
+
+setbacklight_SOURCES = setbacklight.c
diff --git a/test/setbacklight.c b/test/setbacklight.c
new file mode 100644
index 0000000..021d7bf
--- /dev/null
+++ b/test/setbacklight.c
@@ -0,0 +1,9 @@
+#include <stdio.h>
+
+#include "libbacklight.h"
+
+int
+main(int argc, char **argv)
+{
+ return 0;
+}