From daec620c1a2e8f84a87761d9db891219bb27c6a8 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Wed, 24 Apr 2019 09:23:25 +0900 Subject: [PATCH] remove Makefile (#477) * remove Makefile * update configure.ac and configure to 2.3.4dev --- Makefile | 162 --------------------------------------------------- configure | 18 +++--- configure.ac | 2 +- 3 files changed, 10 insertions(+), 172 deletions(-) delete mode 100644 Makefile diff --git a/Makefile b/Makefile deleted file mode 100644 index 26cf602e..00000000 --- a/Makefile +++ /dev/null @@ -1,162 +0,0 @@ -DC ?= dmd -RELEASEVER = v2.3.3 -pkgconfig := $(shell if [ $(PKGCONFIG) ] && [ "$(PKGCONFIG)" != 0 ] ; then echo 1 ; else echo "" ; fi) -notifications := $(shell if [ $(NOTIFICATIONS) ] && [ "$(NOTIFICATIONS)" != 0 ] ; then echo 1 ; else echo "" ; fi) -completions := $(shell if [ $(COMPLETIONS) ] && [ "$(COMPLETIONS)" != 0 ] ; then echo 1 ; else echo "" ; fi) -gitversion := $(shell if [ -f .git/HEAD ] ; then echo 1 ; else echo "" ; fi) - -ifeq ($(pkgconfig),1) -LIBS = $(shell pkg-config --libs sqlite3 libcurl) -else -LIBS = -lcurl -lsqlite3 -endif -ifeq ($(notifications),1) -NOTIF_VERSIONS = -version=NoPragma -version=NoGdk -version=Notifications -ifeq ($(pkgconfig),1) -LIBS += $(shell pkg-config --libs libnotify) -else -LIBS += -lgmodule-2.0 -lglib-2.0 -lnotify -endif -endif -LIBS += -ldl - -# add the necessary prefix for the D compiler -LIBS := $(addprefix -L,$(LIBS)) - -# support ldc2 which needs -d prefix for version specification -ifeq ($(notdir $(DC)),ldc2) - NOTIF_VERSIONS := $(addprefix -d,$(NOTIF_VERSIONS)) -endif - -ifeq ($(DEBUG),1) -ifeq ($(notdir $(DC)),ldc2) -DFLAGS += -d-debug -gc -else -DFLAGS += -debug -gs -endif -endif - -# set up completion directories -ifeq ($(completions),1) -ifeq ($(pkgconfig),1) - BASHCOMPLETIONDIR ?= $(shell pkg-config --variable=completionsdir bash-completion) -else - BASHCOMPLETIONDIR ?= $(PREFIX)/share/bash-completion/completions -endif -ZSHCOMPLETIONDIR ?= /usr/local/share/zsh/site-functions -endif - -DFLAGS += -w -g -ofonedrive -O $(NOTIF_VERSIONS) $(LIBS) -J. - -PREFIX ?= /usr/local -DOCDIR ?= $(PREFIX)/share/doc/onedrive -MANDIR ?= $(PREFIX)/share/man/man1 -DOCFILES = README.md README.Office365.md config LICENSE CHANGELOG.md - -ifneq ("$(wildcard /etc/redhat-release)","") -RHEL = $(shell cat /etc/redhat-release | grep -E "(Red Hat Enterprise Linux Server|CentOS)" | wc -l) -RHEL_VERSION = $(shell rpm --eval "%{centos_ver}") -else -RHEL = 0 -RHEL_VERSION = 0 -endif - -SOURCES = \ - src/config.d \ - src/itemdb.d \ - src/log.d \ - src/main.d \ - src/monitor.d \ - src/onedrive.d \ - src/qxor.d \ - src/selective.d \ - src/sqlite.d \ - src/sync.d \ - src/upload.d \ - src/util.d \ - src/progress.d - -ifeq ($(notifications),1) -SOURCES += src/notifications/notify.d src/notifications/dnotify.d -endif - -all: onedrive onedrive.service onedrive.1 - -clean: - rm -f onedrive onedrive.o onedrive.service onedrive@.service onedrive.1 version - -onedrive: version $(SOURCES) - $(DC) $(DFLAGS) $(SOURCES) - -install.noservice: onedrive onedrive.1 - mkdir -p $(DESTDIR)/var/log/onedrive - chown root.users $(DESTDIR)/var/log/onedrive - chmod 0775 $(DESTDIR)/var/log/onedrive - install -D onedrive $(DESTDIR)$(PREFIX)/bin/onedrive - install -D onedrive.1 $(DESTDIR)$(MANDIR)/onedrive.1 - install -D -m 644 logrotate/onedrive.logrotate $(DESTDIR)/etc/logrotate.d/onedrive - -install: all install.noservice - for i in $(DOCFILES) ; do install -D -m 644 $$i $(DESTDIR)$(DOCDIR)/$$i ; done -ifeq ($(RHEL),1) -ifeq ($(RHEL_VERSION),6) - mkdir -p $(DESTDIR)/etc/init.d/ - chown root.root $(DESTDIR)/etc/init.d/ - install -D init.d/onedrive.init $(DESTDIR)/etc/init.d/onedrive - install -D init.d/onedrive_service.sh $(DESTDIR)$(PREFIX)/bin/onedrive_service.sh -else - mkdir -p $(DESTDIR)/usr/lib/systemd/system/ - chown root.root $(DESTDIR)/usr/lib/systemd/system/ - chmod 0755 $(DESTDIR)/usr/lib/systemd/system/ - install -D -m 644 *.service $(DESTDIR)/usr/lib/systemd/system/ -endif -else - mkdir -p $(DESTDIR)/usr/lib/systemd/user/ - chown root.root $(DESTDIR)/usr/lib/systemd/user/ - chmod 0755 $(DESTDIR)/usr/lib/systemd/user/ - install -D -m 644 onedrive.service $(DESTDIR)/usr/lib/systemd/user/ - mkdir -p $(DESTDIR)/usr/lib/systemd/system/ - chown root.root $(DESTDIR)/usr/lib/systemd/system/ - chmod 0755 $(DESTDIR)/usr/lib/systemd/system/ - install -D -m 644 onedrive@.service $(DESTDIR)/usr/lib/systemd/system/ - install -D -m 644 onedrive.service $(DESTDIR)/usr/lib/systemd/user/onedrive.service -endif -ifeq ($(completions),1) - install -D -m 644 completions/complete.zsh $(DESTDIR)$(ZSHCOMPLETIONDIR)/_onedrive - install -D -m 644 completions/complete.bash $(DESTDIR)$(BASHCOMPLETIONDIR)/onedrive -endif - -onedrive.service: - sed "s|@prefix@|$(PREFIX)|g" systemd.units/onedrive.service.in > onedrive.service - sed "s|@prefix@|$(PREFIX)|g" systemd.units/onedrive@.service.in > onedrive@.service - -onedrive.1: onedrive.1.in - sed "s|@DOCDIR@|$(DOCDIR)|g" onedrive.1.in > onedrive.1 - -uninstall: - rm -f $(DESTDIR)$(PREFIX)/bin/onedrive - rm -f $(DESTDIR)/etc/logrotate.d/onedrive -ifeq ($(RHEL),1) -ifeq ($(RHEL_VERSION),6) - rm -f $(DESTDIR)/etc/init.d/onedrive - rm -f $(DESTDIR)$(PREFIX)/bin/onedrive_service.sh -else - rm -f $(DESTDIR)/usr/lib/systemd/system/onedrive*.service -endif -else - rm -f $(DESTDIR)/usr/lib/systemd/user/onedrive.service - rm -f $(DESTDIR)/usr/lib/systemd/system/onedrive@.service -endif - for i in $(DOCFILES) ; do rm -f $(DESTDIR)$(DOCDIR)/$$i ; done - rm -f $(DESTDIR)$(MANDIR)/onedrive.1 -ifeq ($(completions),1) - rm -f $(DESTDIR)$(ZSHCOMPLETIONDIR)/_onedrive - rm -f $(DESTDIR)$(BASHCOMPLETIONDIR)/onedrive -endif - -version: -ifeq ($(gitversion),1) - echo $(shell git describe --tags) > version -else - echo $(RELEASEVER) > version -endif diff --git a/configure b/configure index 3c86d18e..12a0ad39 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for onedrive 2.3.2. +# Generated by GNU Autoconf 2.69 for onedrive 2.3.4dev. # # Report bugs to . # @@ -579,8 +579,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='onedrive' PACKAGE_TARNAME='onedrive' -PACKAGE_VERSION='2.3.2' -PACKAGE_STRING='onedrive 2.3.2' +PACKAGE_VERSION='2.3.4dev' +PACKAGE_STRING='onedrive 2.3.4dev' PACKAGE_BUGREPORT='https://github.com/abraunegg/onedrive' PACKAGE_URL='' @@ -1227,7 +1227,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures onedrive 2.3.2 to adapt to many kinds of systems. +\`configure' configures onedrive 2.3.4dev to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1289,7 +1289,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of onedrive 2.3.2:";; + short | recursive ) echo "Configuration of onedrive 2.3.4dev:";; esac cat <<\_ACEOF @@ -1398,7 +1398,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -onedrive configure 2.3.2 +onedrive configure 2.3.4dev generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -1415,7 +1415,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by onedrive $as_me 2.3.2, which was +It was created by onedrive $as_me 2.3.4dev, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -3033,7 +3033,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by onedrive $as_me 2.3.2, which was +This file was extended by onedrive $as_me 2.3.4dev, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -3086,7 +3086,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -onedrive config.status 2.3.2 +onedrive config.status 2.3.4dev configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff --git a/configure.ac b/configure.ac index cbc8b924..7f2cd38b 100644 --- a/configure.ac +++ b/configure.ac @@ -9,7 +9,7 @@ dnl - commit the changed files (configure.ac, configure) dnl - tag the release AC_PREREQ([2.69]) -AC_INIT([onedrive],[2.3.2], [https://github.com/abraunegg/onedrive], [onedrive]) +AC_INIT([onedrive],[2.3.4dev], [https://github.com/abraunegg/onedrive], [onedrive]) AC_CONFIG_SRCDIR([src/main.d])