Projects
home:mollekopf:branches:Kolab:Winterfell
guam-selfcontained
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 15
View file
guam.spec
Changed
@@ -152,6 +152,7 @@ # Copy over the release directory as well cp -av _build/default/rel/%{name}/releases/ %{buildroot}%{_erllibdir}/%{realname}-%{version}/ +# More configuration %if 0%{?plesk} install -m 644 -p %{SOURCE100} %{buildroot}%{_sysconfdir}/guam/sys.config %endif
View file
debian.control
Changed
@@ -11,26 +11,13 @@ Package: guam Architecture: any Section: mail -Depends: ${misc:Depends}, ${dist:GuamDepends} +Depends: erlang-base, + erlang-base-hipe, + erlang-asn1, + erlang-goldrush, + erlang-inets, + erlang-lager, + erlang-public-key Description: Smart Reverse IMAP Proxy Guam is a smart, unjustly outcast Reverse IMAP Proxy that lives at the perimeter of your IMAP environment. - -Package: guam-libs -Architecture: any -Section: mail -Depends: ${misc:Depends}, ${dist:GuamLibDepends} -Conflicts: guam-bundled-libs -Description: Dependency meta-package for Guam - This package pulls in all the library dependencies required to run Guam. - Debian backports users who have a backported Erlang version may need to install - guam-bundled-libs instead. - -Package: guam-bundled-libs -Architecture: any -Section: mail -Depends: ${misc:Depends}, ${dist:GuamBundleDepends} -Conflicts: guam-libs -Description: Bundled runtime environment for Guam - This is a support package for Debian backports users who have a backported - Erlang version. All others should preferably use guam-libs.
View file
debian.rules
Changed
@@ -3,7 +3,7 @@ include /usr/share/dpkg/pkg-info.mk DESTDIR = $(CURDIR)/debian/guam -LIBDIR = $(CURDIR)/debian/guam-libs +LIBDIR = $(CURDIR)/debian/guam-libs BUNDLEDIR = $(CURDIR)/debian/guam-bundled-libs # The versions of all dependencies are hardcoded by relx (which honestly sucks). @@ -18,22 +18,22 @@ # # For maintainers, the bottom line is this: please revision-bump this package # every time one of its dependencies gets version-bumped. -currver = $(shell dpkg-query -f '$${Version}' -W $(1) | sed 's/+-.*$$//') -nextver = $(shell echo $(call currver,$(1)) | perl -pe 's/((\d+\.)*)(\d+)$$/$$1.($$3+1)/e') -pinvermin = $(1) (>= $(call currver,$(1))) -pinvermax = $(1) (<< $(call nextver,$(1))) -pinver = $(call pinvermin,$(1)), $(call pinvermax,$(1)) -pinvererlmin = $(1) (>= $(call currver,erlang)) -pinvererlmax = $(1) (<< $(call nextver,erlang)) +# currver = $(shell dpkg-query -f '$${Version}' -W $(1) | sed 's/+-.*$$//') +# nextver = $(shell echo $(call currver,$(1)) | perl -pe 's/((\d+\.)*)(\d+)$$/$$1.($$3+1)/e') +# pinvermin = $(1) (>= $(call currver,$(1))) +# pinvermax = $(1) (<< $(call nextver,$(1))) +# pinver = $(call pinvermin,$(1)), $(call pinvermax,$(1)) +# pinvererlmin = $(1) (>= $(call currver,erlang)) +# pinvererlmax = $(1) (<< $(call nextver,erlang)) # We ship these packages ourselves, so they don't need bundling -KOLAB_PROVIDED_DEPS := $(call pinver,erlang-eimap), $(call pinver,erlang-lager-syslog) -EIMAP_DIR := eimap-$(call currver,erlang-eimap) -LAGER_SYSLOG_DIR := lager_syslog-$(call currver,erlang-lager-syslog) +# KOLAB_PROVIDED_DEPS := $(call pinver,erlang-eimap), $(call pinver,erlang-lager-syslog) +# EIMAP_DIR := eimap-$(call currver,erlang-eimap) +# LAGER_SYSLOG_DIR := lager_syslog-$(call currver,erlang-lager-syslog) -SUBSTVARS += -Vdist:GuamDepends="guam-libs (= $(DEB_VERSION)) | guam-bundled-libs (= $(DEB_VERSION))" -SUBSTVARS += -Vdist:GuamLibDepends="$(call pinvererlmin,erlang-base) | $(call pinvererlmin,erlang-base-hipe), $(call pinvererlmax,erlang-base) | $(call pinvererlmax,erlang-base-hipe), $(KOLAB_PROVIDED_DEPS), $(call pinver,erlang-asn1), $(call pinver,erlang-goldrush), $(call pinver,erlang-inets), $(call pinver,erlang-lager), $(call pinver,erlang-public-key)" -SUBSTVARS += -Vdist:GuamBundleDepends="$(KOLAB_PROVIDED_DEPS)" +# SUBSTVARS += -Vdist:GuamDepends="guam-libs (= $(DEB_VERSION)) | guam-bundled-libs (= $(DEB_VERSION))" +# SUBSTVARS += -Vdist:GuamLibDepends="$(call pinvererlmin,erlang-base) | $(call pinvererlmin,erlang-base-hipe), $(call pinvererlmax,erlang-base) | $(call pinvererlmax,erlang-base-hipe), $(KOLAB_PROVIDED_DEPS), $(call pinver,erlang-asn1), $(call pinver,erlang-goldrush), $(call pinver,erlang-inets), $(call pinver,erlang-lager), $(call pinver,erlang-public-key)" +# SUBSTVARS += -Vdist:GuamBundleDepends="$(KOLAB_PROVIDED_DEPS)" %: dh $@ --with=systemd @@ -41,41 +41,42 @@ override_dh_auto_build: # sed -i -e 's/include_erts,\s*false/include_erts, true/' rebar.config export DEBUG=1 - # Only available since hex v0.9.0 - export HEX_OFFLINE=true - export REBAR_CACHE_DIR=cache/rebar3/ + export HEX_OFFLINE=true + export REBAR_CACHE_DIR="cache/rebar3/" - # Rebuild all beam files (The otp version from the tarball may not match) - rm -rf _build - ./rebar3 compile + # Rebuild all beam files (The otp version from the tarball may not match) + rm -rf _build + ./rebar3 compile - ./rebar3 release \ - --dev-mode false \ - --relname guam \ - --relvsn $(DEB_VERSION_UPSTREAM) \ - --verbose + ./rebar3 release \ + --dev-mode false \ + --relname guam \ + --relvsn $(DEB_VERSION_UPSTREAM) \ + --verbose override_dh_auto_clean: - ./rebar3 clean || : + #./rebar3 clean || : override_dh_auto_test: + export DEBUG=1 + export HEX_OFFLINE=true + export REBAR_CACHE_DIR="cache/rebar3/" ./rebar3 eunit -v || : + ./rebar3 ct -v || : override_dh_auto_install: - mkdir -p $(DESTDIR)/usr/sbin $(DESTDIR)/etc/guam \ - $(DESTDIR)/lib/systemd/system $(DESTDIR)/var/log/ \ + mkdir -p $(DESTDIR)/usr/sbin \ + $(DESTDIR)/etc/guam \ + $(DESTDIR)/lib/systemd/system \ + $(DESTDIR)/var/log/ \ $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ \ - $(DESTDIR)/usr/lib/erlang/bin $(DESTDIR)/var/log/guam + $(DESTDIR)/usr/lib/erlang/bin \ + $(DESTDIR)/var/log/guam chmod o= $(DESTDIR)/var/log/guam + # Service scripts install -p -m 644 contrib/guam.service \ - $(DESTDIR)/lib/systemd/system/guam.service - - cp -a _build/default/rel/guam/bin \ - $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ - - cp -a _build/default/rel/guam/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ebin \ - $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ + $(DESTDIR)/lib/systemd/system/guam.service rm _build/default/rel/guam/releases/$(DEB_VERSION_UPSTREAM)/sys.config rm _build/default/rel/guam/releases/$(DEB_VERSION_UPSTREAM)/vm.args @@ -83,6 +84,7 @@ cp -a _build/default/rel/guam/releases \ $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ + # Configuration if -f "/etc/plesk-release" ; then \ cp ../SOURCES/plesk.sys.config \ $(DESTDIR)/etc/guam/sys.config ; \ @@ -105,9 +107,25 @@ ln -s ../../../../../var/log/guam $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/log + cp -a _build/default/rel/guam/bin \ + $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ + + #cp -a _build/default/rel/guam/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ebin \ + # $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ + + + # Remove the sources + find _build/default/rel/guam/lib/ -type d -name "src" -exec rm -Rf {} + + + # Copy over all lib dirs + cp -av _build/default/rel/guam/lib/* $(DESTDIR)/usr/lib/erlang/lib/ + + # Copy over the release directory as well + cp -av _build/default/rel/guam/releases/ $(DESTDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ + echo '#!/bin/bash' > $(DESTDIR)/usr/sbin/guam echo 'exec /usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/bin/guam $$*' \ - >> $(DESTDIR)/usr/sbin/guam + >> $(DESTDIR)/usr/sbin/guam chmod +x $(DESTDIR)/usr/sbin/guam ln -s ../lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/bin/guam \ @@ -118,17 +136,18 @@ ln -s ../../lib $(LIBDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib # Bundled runtime system and libraries - mkdir -p $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM) - cp -a _build/default/rel/guam/erts-* \ - $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ - cp -a _build/default/rel/guam/lib \ - $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ - rm -r $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/kolab_guam-$(DEB_VERSION_UPSTREAM) - ln -s .. $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/kolab_guam-$(DEB_VERSION_UPSTREAM) - for dir in $(EIMAP_DIR) $(LAGER_SYSLOG_DIR); do \ - rm -r $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/$$dir; \ - ln -s ../../$$dir $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/$$dir; \ - done + # mkdir -p $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM) + # cp -a _build/default/rel/guam/erts-* \ + # $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ + # cp -a _build/default/rel/guam/lib \ + # $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/ + # rm -r $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/kolab_guam-$(DEB_VERSION_UPSTREAM) + # ln -s .. $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/kolab_guam-$(DEB_VERSION_UPSTREAM) + # for dir in $(EIMAP_DIR) $(LAGER_SYSLOG_DIR); do \ + # rm -r $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/$$dir; \ + # ln -s ../../$$dir $(BUNDLEDIR)/usr/lib/erlang/lib/kolab_guam-$(DEB_VERSION_UPSTREAM)/lib/$$dir; \ + # done override_dh_gencontrol: - dh_gencontrol -- $(SUBSTVARS) + #dh_gencontrol -- $(SUBSTVARS) + dh_gencontrol
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.