# duplicity - can't install latest version (10.2-RELEASE)



## royskatt (Aug 16, 2015)

Hello,

The current version in the ports tree contains a deprecated version of duplicity.
I want to install the newest version (https://code.launchpad.net/duplicity/0.7-series/0.7.04/+download/duplicity-0.7.04.tar.gz).

Unfortunately the installation returns the following error:

`python2.7 setup.py install`


```
/usr/local/lib/python2.7/site-packages/setuptools/dist.py:285: UserWarning: Normalizing '0.7.04' to '0.7.4'
  normalized_version,
running install
running build
running build_py
package init file 'testing/overrides/__init__.py' not found (or not a regular file)
running build_ext
building 'duplicity._librsync' extension
cc -fno-strict-aliasing -O2 -pipe -fstack-protector -fno-strict-aliasing -DNDEBUG -fPIC -I/usr/local/include/python2.7 -c duplicity/_librsyncmodule.c -o build/temp.freebsd-10.2-RELEASE-amd64-2.7/duplicity/_librsyncmodule.o
duplicity/_librsyncmodule.c:26:10: fatal error: 'librsync.h' file not found
#include <librsync.h>
         ^
1 error generated.
error: command 'cc' failed with exit status 1
```

net/librsync is installed:


```
pkg install librsync
Updating FreeBSD repository catalogue...
FreeBSD repository is up-to-date.
All repositories are up-to-date.
Checking integrity... done (0 conflicting)
The most recent version of packages are already installed
```

I couldn't Google a fix for that, maybe one of you would know?

Thanks in advance.


----------



## talsamon (Aug 16, 2015)

Changed files/patch-setup.py see attachment.

Change following lines in the Makefile to :

```
PORTVERSION=  0.7.04
MASTER_SITES=  http://launchpad.net/duplicity/0.7-series/${PORTVERSION}/+download/
PORTDOCS=  COPYING README README-REPO README-LOG
```
and run make makesum in the port

This works for me and I hope for you.


----------



## talsamon (Aug 16, 2015)

I make an update request PR 202361. (I find an open update-request from 2015-05-03 PR 199892 , it was to version 0.7.0.2).


----------



## xtaz (Aug 17, 2015)

Seeing this deprecated message concerned me too at first. But if you look at their website it shows that the latest stable version is still 0.6.26. It still calls 0.7.04 a stable development release. I would guess that is why the port maintainer has left it at this version.


----------



## talsamon (Aug 17, 2015)

Sorry, I only looked on launchpad, not directly on duplicity - my fault.  I correct the PR.


----------



## keithf4 (Aug 22, 2015)

Is there any solution in the mean time to getting the 0.7 series installed ourselves manually? I'm getting the same library error as the original poster.


----------



## talsamon (Aug 22, 2015)

As I described above, you had to change the Makefile and place the attached patch in the directory files of the port and run `make makesum` before you try to install.


----------



## keithf4 (Aug 22, 2015)

That's altering the ports package, right? What happens if I then run portsnap(8) to update my ports tree?
Never altered a port like this before, so just not sure of the consequences.

I'm also still curious why manually running the setup from original source code doesn't work.

EDIT: Actually, nevermind on the last question. I looked at the contents of patch-setup and saw you had to add the path to /usr/local/lib where net/librsync is located. Still curious on how to handle manually editing something in my ports tree tho.


----------



## talsamon (Aug 22, 2015)

portsnap(8) will work normal. You may reinstall the sysutils/duplicity port if the maintainer update the port.


----------



## keithf4 (Aug 24, 2015)

Looks like you had some weird copy-paste error this:


```
MASTER_SITES= http://launchpad.net/duplicity/0.7-serie-LOGs/${PORTVERSION}/+download/
```

should be this:


```
MASTER_SITES= http://launchpad.net/duplicity/0.7-series/${PORTVERSION}/+download/
```

Got the new version installed now, thanks!


----------



## talsamon (Aug 24, 2015)

> Looks like you had some weird copy-paste error this:



It is right, very sorry!

Something I wrote was not really exact:
If the maintainer update to this version, you have to make `rm -rf *` in the port and make after this the `portsnap` or only `portsnap extract sysutils/duplicity`. (It could not recognize cause it is the same PORTVERSION - only update normal if it is a "higher" version).


----------



## xtaz (Feb 8, 2016)

It looks like 0.7.06 is out now and it is marked as the stable version. So I'm disappointed that the port hasn't been officially upgraded yet. The patch above doesn't seem to apply cleanly to .06, only 3 out of the 5 applies. Doesn't look like your PR has got anywhere either.


----------



## talsamon (Feb 9, 2016)

Copy  from PR 199892 duplicity-0.7.0.5.patch in the port. Run `patch -p0 -i duplicity-0.7.0.5.patch`. Worked for me, I hope for you.


----------



## talsamon (Mar 5, 2016)

In the same PR a new patch is out for version 0.7.06 (not comitted yet - I have not tested it).
*Edit: *Is comitted, could be marked as solved.


----------

