Problem developing collection plan

I am having some problem developing a plan for a common collection.

I ran dh_make and also modified the documents. Nonetheless, when I most likely to construct the plan, I get the adhering to:

******@******-laptop:~/Documents/temp/jsoncpp/jsoncpp-0.5.0$ debuild
 dpkg-buildpackage -rfakeroot -D -us -uc
dpkg-buildpackage: set CFLAGS to default value: -g -O2
dpkg-buildpackage: set CPPFLAGS to default value: 
dpkg-buildpackage: set LDFLAGS to default value: -Wl,-Bsymbolic-functions
dpkg-buildpackage: set FFLAGS to default value: -g -O2
dpkg-buildpackage: set CXXFLAGS to default value: -g -O2
dpkg-buildpackage: source package jsoncpp
dpkg-buildpackage: source version 0.5.0-1
dpkg-buildpackage: source changed by ****** 
dpkg-buildpackage: host architecture amd64
 fakeroot debian/rules clean
dh  clean
 dpkg-source -b jsoncpp-0.5.0
dpkg-source: info: using source format `1.0'
dpkg-source: info: building jsoncpp using existing jsoncpp_0.5.0.orig.tar.gz
dpkg-source: info: building jsoncpp in jsoncpp_0.5.0-1.diff.gz
dpkg-source: info: building jsoncpp in jsoncpp_0.5.0-1.dsc
 debian/rules build
dh  build
make[1]: Entering directory `/home/******/Documents/temp/jsoncpp/jsoncpp-0.5.0'
test -d obj || mkdir obj
g++ -I ./include -c -o obj/json_reader.o src/lib_json/json_reader.cpp
g++ -I ./include -c -o obj/json_writer.o src/lib_json/json_writer.cpp
g++ -I ./include -c -o obj/json_value.o src/lib_json/json_value.cpp
ar -r libjsoncpp.a obj/json_reader.o obj/json_writer.o obj/json_value.o
ar: creating libjsoncpp.a
make[1]: Leaving directory `/home/******/Documents/temp/jsoncpp/jsoncpp-0.5.0'
 fakeroot debian/rules binary
dh  binary
make[1]: Entering directory `/home/******/Documents/temp/jsoncpp/jsoncpp-0.5.0'
sudo cp -r include/json --target-directory=/usr/include
ERROR: object '' from LD_PRELOAD cannot be preloaded: ignored.
cp libjsoncpp.a /usr/lib/libjsoncpp.a
cp: cannot create regular file `/usr/lib/libjsoncpp.a': Permission denied
make[1]: *** [install] Error 1
make[1]: Leaving directory `/home/******/Documents/temp/jsoncpp/jsoncpp-0.5.0'
dh_auto_install: make -j1 install DESTDIR=/home/******/Documents/temp/jsoncpp/jsoncpp-0.5.0/debian/tmp returned exit code 2
make: *** [binary] Error 29
dpkg-buildpackage: error: fakeroot debian/rules binary gave error exit status 2
debuild: fatal error at line 1340:
dpkg-buildpackage -rfakeroot -D -us -uc failed

The trouble appears to be below:

MISTAKE: object 'libfakeroot-sysv. so' from LD_PRELOAD can not be preloaded: overlooked.
cp libjsoncpp.a/ usr/lib/libjsoncpp. a
cp: can not create normal documents '/ usr/lib/libjsoncpp. a': Permission refuted

... yet I have not the faintest suggestion what the trouble is.

The makefile is here if required.

2019-05-07 01:00:09
Source Share
Answers: 2

As you figured the troubles exists below :

cp libjsoncpp.a /usr/lib/libjsoncpp.a

You are calling debbuild as regular customer, that has no civil liberties to contact that directory site. If you attempt sudo debbuild it need to function.

2019-05-08 22:11:30

The Makefile you are making use of is not valuing the DESTDIR variable - plans need to never ever install straight right into/ usr at construct time, yet rather placed files right into a short-lived tree. You've stated that you included the Makefile on your own - the common instance is that you would certainly require to make it make use of the DESTDIR variable as a prefix for all install courses. Having actually considered the plan construct guidelines, the plan makes use of scons as a construct system, which is a substitute of types for make. dh_make more than likely does not have a layout for constructing plans with this, so you need to seek plans that do utilize it for structure, such as yafray, and also consider their debian/rules

As plan builds are never ever done as origin, it is far better to have this mistake revealed & dealt with as opposed to having a plan overwrite vital files as the plan is being improved an innocent programmer's system.

2019-05-08 22:04:19