Skip to content

Commit

Permalink
Merge pull request #7 from eagletmt/linux
Browse files Browse the repository at this point in the history
Support D-Bus secret service via libsecret
  • Loading branch information
eagletmt committed Jun 8, 2016
2 parents d6d5d2b + 0d682b3 commit af16d2f
Show file tree
Hide file tree
Showing 6 changed files with 659 additions and 469 deletions.
22 changes: 17 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,14 +1,26 @@
CFLAGS += -Wall -Wextra -ansi -pedantic -std=c99 -mmacosx-version-min=10.7
LIBS = -ledit -ltermcap -framework Security -framework CoreFoundation
UNAME = $(shell uname)
CFLAGS += -Wall -Wextra -ansi -pedantic -std=c99
ifeq ($(UNAME), Darwin)
CFLAGS += -mmacosx-version-min=10.7
LIBS = -ledit -ltermcap -framework Security -framework CoreFoundation
OBJS = envchain.o envchain_osx.o
else
CFLAGS += `pkg-config --cflags libsecret-1`
LIBS = -lreadline `pkg-config --libs libsecret-1`
OBJS = envchain.o envchain_linux.o
endif

DESTDIR ?= /usr

all: envchain
envchain: envchain.c
$(CC) $(CFLAGS) $(LIBS) envchain.c -o envchain
envchain: $(OBJS)
$(CC) $(LDCFLAGS) $(LIBS) -o envchain $(OBJS)

%.o: %.c envchain.h
$(CC) -c $(CFLAGS) $(CPPFLAGS) -o $@ $<

clean:
rm -f envchain
rm -f envchain $(OBJS)

install: all
install -d $(DESTDIR)/./bin
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# envchain - set environment variables with OS X keychain
# envchain - set environment variables with OS X keychain or D-Bus secret service

## What?

Expand Down
Loading

0 comments on commit af16d2f

Please sign in to comment.