On 4/19/23 12:55, Stuart Henderson wrote:
On 2023/04/19 11:31, Renaud Allard wrote:

Here's a different approach to allowing it to find the files, which
gets rid of most of the patches to default.xml and use the relative
paths. What do you think?

If you tested it and everything works as expected, it looks indeed much cleaner.


Index: Makefile
===================================================================
RCS file: /cvs/ports/geo/traccar/Makefile,v
retrieving revision 1.30
diff -u -p -r1.30 Makefile
--- Makefile    19 Apr 2023 09:46:00 -0000      1.30
+++ Makefile    19 Apr 2023 10:53:44 -0000
@@ -1,5 +1,6 @@
  COMMENT =     modern GPS tracking platform
  V =           5.7
+REVISION =     0
  PKGNAME =     traccar-${V}
  DISTNAME =    traccar-other-${V}
  EXTRACT_SUFX =        .zip
Index: pkg/traccar.rc
===================================================================
RCS file: /cvs/ports/geo/traccar/pkg/traccar.rc,v
retrieving revision 1.4
diff -u -p -r1.4 traccar.rc
--- pkg/traccar.rc      24 May 2022 18:51:25 -0000      1.4
+++ pkg/traccar.rc      19 Apr 2023 10:53:44 -0000
@@ -2,6 +2,7 @@

  daemon="${TRUEPREFIX}/share/traccar/tracker-server.jar"
  daemon_user="_traccar"
+daemon_execdir="${TRUEPREFIX}/share/traccar"

  . /etc/rc.d/rc.subr

Index: patches/patch-conf_default_xml
===================================================================
RCS file: /cvs/ports/geo/traccar/patches/patch-conf_default_xml,v
retrieving revision 1.12
diff -u -p -r1.12 patch-conf_default_xml
--- patches/patch-conf_default_xml      19 Apr 2023 09:46:00 -0000      1.12
+++ patches/patch-conf_default_xml      19 Apr 2023 10:53:44 -0000
@@ -1,15 +1,11 @@
-seems that database.changelog requires a relative path
-
  Index: conf/default.xml
  --- conf/default.xml.orig
  +++ conf/default.xml
-@@ -11,7 +11,8 @@
-     -->
+@@ -12,6 +12,7 @@

       <entry key='web.port'>8082</entry>
--    <entry key='web.path'>./modern</entry>
+     <entry key='web.path'>./modern</entry>
  +    <entry key='web.address'>127.0.0.1</entry>
-+    <entry key='web.path'>${LOCALBASE}/share/traccar/modern</entry>
       <entry key='web.sanitize'>false</entry>
       <entry key='web.persistSession'>false</entry>

@@ -22,22 +18,12 @@ Index: conf/default.xml
       <entry key='logger.rotate'>true</entry>

       <entry key='filter.enable'>true</entry>
-@@ -30,16 +31,14 @@
-
-     <entry key='event.ignoreDuplicateAlerts'>true</entry>
-
--    <entry key='media.path'>./media</entry>
-+    <entry key='media.path'>${LOCALBASE}/share/traccar/media</entry>
+@@ -33,8 +34,6 @@
+     <entry key='media.path'>./media</entry>

       <entry key='notificator.types'>web,mail,command</entry>
-
--    <entry key='server.statistics'>https://www.traccar.org/analytics/</entry>
  -
-     <entry key='commands.queueing'>true</entry>
+-    <entry key='server.statistics'>https://www.traccar.org/analytics/</entry>

-     <entry key='database.ignoreUnknown'>true</entry>
--    <entry key='database.changelog'>./schema/changelog-master.xml</entry>
-+    <entry 
key='database.changelog'>../../..${LOCALBASE}/share/traccar/schema/changelog-master.xml</entry>
+     <entry key='commands.queueing'>true</entry>

-     <entry key='gps103.port'>5001</entry>
-     <entry key='tk103.port'>5002</entry>

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to