sheepfs: add framework for http interface

Adding http.c in sheepfs dir as the framework and implement "address" file
to store http address.

Signed-off-by: Robin Dong <sanbai@taobao.com>
Signed-off-by: Liu Yuan <namei.unix@gmail.com>
sheepfs: implement the http interface of sheepfs by using libcurl

Use libcurl to call the interface of http for object-storage and implement
the read/write operation.

Signed-off-by: Robin Dong <sanbai@taobao.com>
[ replace sd_err by sheepfs_pr ]
Signed-off-by: Liu Yuan <namei.unix@gmail.com>
test: add test-case for http interface of sheepfs

Signed-off-by: Robin Dong <sanbai@taobao.com>
Signed-off-by: Liu Yuan <namei.unix@gmail.com>
sheepfs: add check for libcurl in configure.ac

Check header and library for libcurl in configure.ac

Signed-off-by: Robin Dong <sanbai@taobao.com>
Signed-off-by: Liu Yuan <namei.unix@gmail.com>
sheepfs: add support for "rmdir" and "unlink"

Add support for "rmdir" and "unlink" so users can remove all directories
of accounts/containers and files of objects after using it.
This "remove" operation only remove local entry in sheepfs, the objects
are still in remote object-service.

Signed-off-by: Robin Dong <sanbai@taobao.com>
Signed-off-by: Liu Yuan <namei.unix@gmail.com>
tests/084: add sheepfs http rm test

Signed-off-by: Robin Dong <sanbai@taobao.com>
Signed-off-by: Liu Yuan <namei.unix@gmail.com>
sheep/http: check http driver in http_init()

If users start sheep daemon like:

sheep -r host=127.0.0.1,port=8000 -c local

the sheep will startup normally, but when someone access
127.0.0.1:8000 by swift interface, it will get message of
"405 Method Not Allowed" without any explaination in sheep.log

So we use 'swift' as default http driver if users doesn't point out
in command line.

Signed-off-by: Robin Dong <sanbai@taobao.com>
Signed-off-by: Liu Yuan <namei.unix@gmail.com>
sheepfs: disable http interface if http is not enabled

Signed-off-by: Liu Yuan <namei.unix@gmail.com>
Signed-off-by: MORITA Kazutaka <morita.kazutaka@lab.ntt.co.jp>
sheepfs: fix complie error when http isn't enabled

Forgot to remove -lcurl in my last patch, remove it.

Signed-off-by: Liu Yuan <namei.unix@gmail.com>
Signed-off-by: MORITA Kazutaka <morita.kazutaka@lab.ntt.co.jp>