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

Update Makefile #417

Merged
merged 1 commit into from
Mar 19, 2019
Merged

Update Makefile #417

merged 1 commit into from
Mar 19, 2019

Conversation

abraunegg
Copy link
Owner

  • Update makefile so if using 'release' archive to build, the 'version' file is created with the correct version string as .git/HEAD & index is not available.

* Update makefile so if using 'release' archive to build, the 'version' file is created with the correct version string as .git/HEAD & index is not available.
@abraunegg
Copy link
Owner Author

without patch:

(dmd-2.083.0)[alex@centos7full onedrive-2.2.6]$ make clean; make;
rm -f onedrive onedrive.o onedrive.service onedrive@.service onedrive.1
make: *** No rule to make target `.git/HEAD', needed by `version'.  Stop.
(dmd-2.083.0)[alex@centos7full onedrive-2.2.6]$ 

with patch:

(dmd-2.083.0)[alex@centos7full onedrive-2.2.6]$ make clean; make;
rm -f onedrive onedrive.o onedrive.service onedrive@.service onedrive.1
echo v2.2.6 > version
dmd -w -g -ofonedrive -O  -L-lcurl -L-lsqlite3 -L-ldl -J. 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
sed "s|@PREFIX@|/usr/local|g" systemd.units/onedrive.service.in > onedrive.service
sed "s|@PREFIX@|/usr/local|g" systemd.units/onedrive@.service.in > onedrive@.service
sed "s|@DOCDIR@|/usr/local/share/doc/onedrive|g" onedrive.1.in > onedrive.1

Also tested against a git repository to ensure that is non-breaking:

(dmd-2.083.0)[alex@centos7full onedrive]$ ./onedrive --version
onedrive v2.2.6-4-g99c0267
(dmd-2.083.0)[alex@centos7full onedrive]$ rm version 
(dmd-2.083.0)[alex@centos7full onedrive]$ make clean; make;   
rm -f onedrive onedrive.o onedrive.service onedrive@.service onedrive.1
echo v2.2.6-4-g99c0267 > version
dmd -w -g -ofonedrive -O  -L-lcurl -L-lsqlite3 -L-ldl -J. 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
sed "s|@PREFIX@|/usr/local|g" systemd.units/onedrive.service.in > onedrive.service
sed "s|@PREFIX@|/usr/local|g" systemd.units/onedrive@.service.in > onedrive@.service
sed "s|@DOCDIR@|/usr/local/share/doc/onedrive|g" onedrive.1.in > onedrive.1
(dmd-2.083.0)[alex@centos7full onedrive]$ ./onedrive --version
onedrive v2.2.6-4-g99c0267
(dmd-2.083.0)[alex@centos7full onedrive]$ 

@abraunegg abraunegg merged commit 58c2805 into master Mar 19, 2019
@abraunegg abraunegg deleted the Issue-#416 branch March 19, 2019 02:14
@lock
Copy link

lock bot commented Apr 18, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Apr 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants