help-gnu-radius
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-gnu-radius] Spec for RPM


From: Dmitriy Gnidchenko
Subject: [Help-gnu-radius] Spec for RPM
Date: Sun, 22 Dec 2002 18:25:30 +0300 (MSK)

Hi Radius!!!

I was try to make Spec file to build RPM for my System.
But with original distribution this is no possible
Because on most Linux (Redhat based system) only simple user
should make RPM package

And when i install all nessesery files in temp dir i have some
trouble

I install with options

make install DESTDIR="${RPM_BUILD_ROOT}"
where ${RPM_BUILD_ROOT} = ../homedir/tmp/gnu-radius-buildroot/

Installation broken on copy raddb dir to buildroot dir
reasen in Makefile.am and Makefile.in

--{CUT}--
install-data-local:
        @if [ ! -d $(raddbdir) ]; then \
                ${INSTALL} -d $(raddbdir); \
        fi
        @for dir in $(raddb_subdirs); do \
        if [ ! -d $(raddbdir)/$$dir ]; then \
        ${INSTALL} -d $(raddbdir)/$$dir; \
..
---{CUT}---
Whith option only $(raddbdir) i can't copy to dir which i want to
install for build package

should be $(DESTDIR)$(raddbdir)

This is Patche which correct this problem

--RADIUS.patch----

--- raddb/Makefile.in   2002-12-22 06:01:26 +0300
+++ raddb/Makefile.in   2002-12-22 06:02:19 +0300
@@ -267,25 +267,25 @@


 install-data-local:
-       @if [ ! -d $(raddbdir) ]; then \
-               ${INSTALL} -d $(raddbdir); \
+       @if [ ! -d $(DESTDIR)$(raddbdir) ]; then \
+               ${INSTALL} -d $(DESTDIR)$(raddbdir); \
        fi
        @for dir in $(raddb_subdirs); do \
-               if [ ! -d $(raddbdir)/$$dir ]; then \
-                       ${INSTALL} -d $(raddbdir)/$$dir; \
+               if [ ! -d $(DESTDIR)$(raddbdir)/$$dir ]; then \
+                       ${INSTALL} -d $(DESTDIR)$(raddbdir)/$$dir; \
                fi; \
        done
-       @if [ -r $(raddbdir)/users ]; then \
+       @if [ -r $(DESTDIR)$(raddbdir)/users ]; then \
                echo 
'================================================================='; \
-               echo "Warning: The configuration directory $(raddbdir) already 
exists"; \
+               echo "Warning: The configuration directory 
$(DESTDIR)$(raddbdir) already exists"; \
                echo "Make sure your dictionary is up to date!"; \
                echo 
'================================================================='; \
        else \
                for file in $(raddb_files_644); do \
-                       ${INSTALL} -m 644 $(top_srcdir)/raddb/$$file 
$(raddbdir)/$$file; \
+                       ${INSTALL} -m 644 $(top_srcdir)/raddb/$$file 
$(DESTDIR)$(raddbdir)/$$file; \
                done; \
                for file in $(raddb_files_600); do \
-                       ${INSTALL} -m 600 $(top_srcdir)/raddb/$$file 
$(raddbdir)/$$file; \
+                       ${INSTALL} -m 600 $(top_srcdir)/raddb/$$file 
$(DESTDIR)$(raddbdir)/$$file; \
                done; \
        fi

--- raddb/Makefile.am   2002-12-22 06:01:16 +0300
+++ raddb/Makefile.am   2002-12-22 06:01:54 +0300
@@ -51,25 +51,25 @@
 EXTRA_DIST=$(raddb_files)

 install-data-local:
-       @if [ ! -d $(raddbdir) ]; then \
-               ${INSTALL} -d $(raddbdir); \
+       @if [ ! -d $(DESTDIR)$(raddbdir) ]; then \
+               ${INSTALL} -d $(DESTDIR)$(raddbdir); \
        fi
        @for dir in $(raddb_subdirs); do \
-               if [ ! -d $(raddbdir)/$$dir ]; then \
-                       ${INSTALL} -d $(raddbdir)/$$dir; \
+               if [ ! -d $(DESTDIR)$(raddbdir)/$$dir ]; then \
+                       ${INSTALL} -d $(DESTDIR)$(raddbdir)/$$dir; \
                fi; \
        done
-       @if [ -r $(raddbdir)/users ]; then \
+       @if [ -r $(DESTDIR)$(raddbdir)/users ]; then \
                echo 
'================================================================='; \
-               echo "Warning: The configuration directory $(raddbdir) already 
exists"; \
+               echo "Warning: The configuration directory 
$(DESTDIR)$(raddbdir) already exists"; \
                echo "Make sure your dictionary is up to date!"; \
                echo 
'================================================================='; \
        else \
                for file in $(raddb_files_644); do \
-                       ${INSTALL} -m 644 $(top_srcdir)/raddb/$$file 
$(raddbdir)/$$file; \
+                       ${INSTALL} -m 644 $(top_srcdir)/raddb/$$file 
$(DESTDIR)$(raddbdir)/$$file; \
                done; \
                for file in $(raddb_files_600); do \
-                       ${INSTALL} -m 600 $(top_srcdir)/raddb/$$file 
$(raddbdir)/$$file; \
+                       ${INSTALL} -m 600 $(top_srcdir)/raddb/$$file 
$(DESTDIR)$(raddbdir)/$$file; \
                done; \
        fi
-----------------------------------------

May be possible to include this one ?



-- 

        Dmitriy  address@hidden

EX ISP DUX phone: +7(812)164-4877
           fax: +7(812)164-0827




reply via email to

[Prev in Thread] Current Thread [Next in Thread]