Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Makefile for the latest version of twitCurl #8

Closed
GoogleCodeExporter opened this issue Mar 14, 2015 · 3 comments
Closed

Makefile for the latest version of twitCurl #8

GoogleCodeExporter opened this issue Mar 14, 2015 · 3 comments

Comments

@GoogleCodeExporter
Copy link

No Makefile exists for the latest version of twitCurl.  I would like to use 
twitCurl on linux with OAuth support, but there is no Makefile available.


Original issue reported on code.google.com by Felix.Na...@gmail.com on 29 Oct 2010 at 4:52

@GoogleCodeExporter
Copy link
Author

Hi,

Yes, no Makefile for the new lib yet!! I have to polish my rusty makefile 
writing skills ;) Will upload soon. If anybody has already written, please feel 
free to post it here. 

Original comment by swatkat....@gmail.com on 6 Nov 2010 at 3:02

@GoogleCodeExporter
Copy link
Author

Here's the version that I got to work.  Note, I had to download a new version 
of libcurl since I couldn't compile it with the old version on my system so I 
added a CURL_LIB that would not be needed by people with the latest version of 
libcurl.  By no means is this a production version of the Makefile.  A lot of 
cleanup is needed, and if I have chance to get around to it, I'll update it and 
clean it up.

# Hey Emacs, this is a -*- makefile -*-
# The twitcurl library.. a Makefile for OpenWRT
# Makefile-fu by John Boiles
# 28 September 2009

LIBNAME = twitcurl
SRC = $(LIBNAME).cpp \
    HMAC_SHA1.cpp \
    SHA1.cpp \
    base64.cpp \
    oauthlib.cpp \
    urlencode.cpp
STAGING_DIR = 
INCLUDE_DIR = $(STAGING_DIR)/usr/include
CURL_INCLUDE = /home/qa5535/libcurl/usr/local/include
LIBRARY_DIR = $(STAGING_DIR)/usr/lib
CURL_LIB = /home/qa5535/libcurl/usr/local/lib
LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib
CC = g++
REMOVE = rm -f
COPY = cp
REMOTEIP = 192.168.1.30

# Compiler flag to set the C Standard level.
# c89   - "ANSI" C
# gnu89 - c89 plus GCC extensions
# c99   - ISO C99 standard (not yet fully implemented)
# gnu99 - c99 plus GCC extensions
# CSTANDARD = -std=gnu99

# Place -D or -U options here
CDEFS =

# Place -I options here
CINCS = 

CFLAGS =$(CDEFS) $(CINCS) $(CSTANDARD)

all: target

target: $(SRC) $(LIBNAME).h
    $(CC) -Wall -fPIC -c -I$(CURL_INCLUDE) -I$(INCLUDE_DIR) $(SRC)
    $(CC) -shared -Wl,-soname,lib$(LIBNAME).so.1 $(LDFLAGS) -L$(CURL_LIB) -L$(LIBRARY_DIR) -lcurl -o lib$(LIBNAME).so.1.0 *.o

#clean project.
clean:
    $(REMOVE) $(LIBNAME)*.so.1.0
    $(REMOVE) $(LIBNAME).o
    $(REMOVE) $(LIBRARY_DIR)/lib$(LIBNAME).so*
# Install library to local openwrt library directory
install: all
    $(COPY) lib$(LIBNAME).so.1.0 $(LIBRARY_DIR)
    $(COPY) $(LIBNAME).h $(INCLUDE_DIR)/
    ln -sf $(LIBRARY_DIR)/lib$(LIBNAME).so.1.0 $(LIBRARY_DIR)/lib$(LIBNAME).so
    ln -sf $(LIBRARY_DIR)/lib$(LIBNAME).so.1.0 $(LIBRARY_DIR)/lib$(LIBNAME).so.1

Original comment by Felix.Na...@gmail.com on 8 Nov 2010 at 3:48

@GoogleCodeExporter
Copy link
Author

Thanks. Linux branch svn/branches/libtwitcurl has been updated with new code 
and makefile.

Original comment by swatkat....@gmail.com on 6 Mar 2011 at 3:58

  • Changed state: Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant