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

readme script for Debian build has an error #19

Open
mohierf opened this issue Dec 19, 2016 · 1 comment
Open

readme script for Debian build has an error #19

mohierf opened this issue Dec 19, 2016 · 1 comment

Comments

@mohierf
Copy link
Contributor

mohierf commented Dec 19, 2016

This is the script:

apt-get install debhelper git-buildpackage python-pbr quilt
git clone https://github.com/Alignak-monitoring/alignak.git ~/alignak
git clone https://github.com/Alignak-monitoring/alignak-packaging.git ~/alignak-packaging
cp -r ~/alignak-packaging/debian ~/alignak-packaging/manpages ~/alignak
cd ~/alignak
# You will package current develop here, if you need master or specific checkout what you need
# You could just use `git-buildpackage -us -uc -tc -b` here but you have to add and commit the new file added
# This commit can't be pushed upstream of course

RELEASE=$(git log -1  --format=%ct.%h)
cd ../
VERSION=$(awk -F'\(?\-?' '/alignak/ {print $2}' alignak/debian/changelog)
sed -i "s/-\([0-9]\+\))/-\1.$RELEASE)/g" alignak/debian/changelog
tar -czf alignak_$VERSION.orig.tar.gz alignak
cd alignak
dpkg-buildpackage
lintian ../alignak*.deb

What seems broken to me:

  1. When awking the changelog file, the VERSION variable will contain 0.2 0.1 and it will raise an error in the tar command ... it seems that the awk get all the versions existing in the file :/

  2. the sed command is modifying all the version entries in the changelog file whereas only the most recent one should be modified ?

  3. When executing the dpkg_buildpackage some errors are raised:

running install_egg_info
Copying alignak.egg-info to /root/alignak/debian/alignak-all/usr/lib/python2.7/dist-packages/alignak-0.2.egg-info
running install_scripts
Installing alignak-broker script to /root/alignak/debian/alignak-all/usr/bin
Installing alignak-scheduler script to /root/alignak/debian/alignak-all/usr/bin
Installing alignak-receiver script to /root/alignak/debian/alignak-all/usr/bin
Installing alignak-poller script to /root/alignak/debian/alignak-all/usr/bin
Installing alignak-reactionner script to /root/alignak/debian/alignak-all/usr/bin
Installing alignak-arbiter script to /root/alignak/debian/alignak-all/usr/bin
   debian/rules override_dh_install
make[1]: Entering directory '/root/alignak'
dh_install
dh_install: alignak-all missing files (systemd/*), aborting
debian/rules:12: recipe for target 'override_dh_install' failed
make[1]: *** [override_dh_install] Error 2
make[1]: Leaving directory '/root/alignak'
debian/rules:4: recipe for target 'binary' failed
make: *** [binary] Error 2
dpkg-buildpackage: error: debian/rules binary gave error exit status 2
@mohierf
Copy link
Contributor Author

mohierf commented Dec 20, 2016

Ok. Got it ... this script is not to be used because @Seb-Solon you build with the alignak-docker repo ... I will update the script to make it correct anyway 😉 This will avoid some others to lose time as I did...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant