logo

overlay

My (experimental) gentoo overlay

inspircd-2.0.27-fix-path-builds.patch (9655B)


      1 diff --git a/docs/conf/inspircd.conf.example b/docs/conf/inspircd.conf.example
      2 index d54cdc916..ee21be7f3 100644
      3 --- a/docs/conf/inspircd.conf.example
      4 +++ b/docs/conf/inspircd.conf.example
      5 @@ -425,11 +425,11 @@
      6  
      7  # This file has all the information about oper classes, types and o:lines.
      8  # You *MUST* edit it.
      9 -<include file="conf/examples/opers.conf.example">
     10 +<include file="/etc/inspircd/opers.conf.example">
     11  
     12  # This file has all the information about server links and ulined servers.
     13  # You *MUST* edit it if you intend to link servers.
     14 -<include file="conf/examples/links.conf.example">
     15 +<include file="/etc/inspircd/links.conf.example">
     16  
     17  #-#-#-#-#-#-#-#-#-#-  MISCELLANEOUS CONFIGURATION  -#-#-#-#-#-#-#-#-#-#
     18  #                                                                     #
     19 @@ -439,7 +439,8 @@
     20  #   motd - displayed on connect and when a user executes /MOTD
     21  #   rules - displayed when the user executes /RULES
     22  # Modules can also define their own files
     23 -<files motd="conf/examples/motd.txt.example" rules="conf/examples/rules.txt.example">
     24 +<files motd="/etc/inspircd/motd.txt.example"
     25 +       rules="/etc/inspircd/rules.txt.example">
     26  
     27  # Example of an executable file include. Note this will be read on rehash,
     28  # not when the command is run.
     29 @@ -485,7 +486,7 @@
     30  # the default of 'inspircd.pid' is used.                              #
     31  #                                                                     #
     32  
     33 -#<pid file="/path/to/inspircd.pid">
     34 +<pid file="/var/run/inspircd/inspircd.pid">
     35  
     36  #-#-#-#-#-#-#-#-#-#-#-#-#- BANLIST LIMITS #-#-#-#-#-#-#-#-#-#-#-#-#-#-#
     37  #                                                                     #
     38 @@ -994,7 +995,7 @@
     39  # provide almost all the features of InspIRCd. :)                     #
     40  #                                                                     #
     41  # The default does nothing -- we include it for simplicity for you.   #
     42 -<include file="conf/examples/modules.conf.example">
     43 +<include file="/etc/inspircd/modules.conf.example">
     44  
     45  # Here are some pre-built modules.conf files that closely match the
     46  # default configurations of some popular IRCd's. You still may want to
     47 @@ -1006,10 +1007,10 @@
     48  # recommended that you make your own modules file based on modules.conf.example.
     49  
     50  # Settings similar to UnrealIRCd defaults.
     51 -#<include file="conf/examples/modules/unrealircd.conf.example">
     52 +#<include file="/etc/inspircd/modules/unrealircd.conf.example">
     53  
     54  # Settings similar to Charybdis IRCd defaults.
     55 -#<include file="conf/examples/modules/charybdis.conf.example">
     56 +#<include file="/etc/inspircd/modules/charybdis.conf.example">
     57  
     58  
     59  #########################################################################
     60 diff --git a/docs/conf/modules.conf.example b/docs/conf/modules.conf.example
     61 index c3f074b94..4b0a584bb 100644
     62 --- a/docs/conf/modules.conf.example
     63 +++ b/docs/conf/modules.conf.example
     64 @@ -315,7 +315,7 @@
     65  # specify some censor tags. See also:                                 #
     66  # https://wiki.inspircd.org/Modules/2.0/censor                        #
     67  #
     68 -#<include file="conf/examples/censor.conf.example">
     69 +#<include file="/etc/inspircd/censor.conf.example">
     70  
     71  #-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#
     72  # CGI:IRC module: Adds support for automatic host changing in CGI:IRC
     73 @@ -790,7 +790,7 @@
     74  # specify below the path to the filter.conf file, or define some      #
     75  # <filter> tags.                                                      #
     76  #                                                                     #
     77 -#<include file="conf/examples/filter.conf.example">
     78 +#<include file="/etc/inspircd/filter.conf.example">
     79  
     80  #-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#
     81  # Gecos ban: Implements extended ban 'r', which stops anyone matching
     82 @@ -849,7 +849,7 @@
     83  #                                                                     #
     84  # If you specify to use the m_helpop.so module, then specify below    #
     85  # the path to the helpop.conf file.                                   #
     86 -#<include file="conf/examples/helpop-full.conf.example">
     87 +#<include file="/etc/inspircd/helpop-full.conf.example">
     88  
     89  #-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#
     90  # Hide chans module: Allows users to hide their channels list from non-
     91 @@ -1304,7 +1304,7 @@
     92  #                 Read the comment above <connect:allowmotdcolors> in #
     93  #                 inspircd.conf.example for details.                  #
     94  #                                                                     #
     95 -#<opermotd file="conf/examples/opermotd.txt.example" onoper="yes" processcolors="false">
     96 +#<opermotd file="/etc/inspircd/opermotd.txt.example" onoper="yes" processcolors="false">
     97  
     98  #-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#
     99  # Override module: Adds support for oper override.
    100 diff --git a/make/template/main.mk b/make/template/main.mk
    101 index 23daa7efc..386e0138a 100644
    102 --- a/make/template/main.mk
    103 +++ b/make/template/main.mk
    104 @@ -34,7 +34,7 @@ CC = @CC@
    105  SYSTEM = @SYSTEM@
    106  BUILDPATH = @BUILD_DIR@
    107  SOCKETENGINE = @SOCKETENGINE@
    108 -CXXFLAGS = -pipe -fPIC -DPIC
    109 +MYCXXFLAGS = -pipe -fPIC -DPIC
    110  LDLIBS = -pthread -lstdc++
    111  LDFLAGS = 
    112  CORELDFLAGS = -rdynamic -L. $(LDFLAGS)
    113 @@ -52,9 +52,9 @@ INSTMODE_BIN = 0755
    114  INSTMODE_LIB = 0644
    115  
    116  @IFEQ $(CC) icpc
    117 -  CXXFLAGS += -Wshadow
    118 +  MYCXXFLAGS += -Wshadow
    119  @ELSE
    120 -  CXXFLAGS += -pedantic -Woverloaded-virtual -Wshadow -Wformat=2 -Wmissing-format-attribute -Wall
    121 +  MYCXXFLAGS += -pedantic -Woverloaded-virtual -Wshadow -Wformat=2 -Wmissing-format-attribute -Wall
    122  @ENDIF
    123  
    124  
    125 @@ -76,46 +76,46 @@ INSTMODE_LIB = 0644
    126  	INSTALL = ginstall
    127  @ENDIF
    128  @IFEQ $(SYSTEM) darwin
    129 -  CXXFLAGS += -DDARWIN -frtti
    130 +  MYCXXFLAGS += -DDARWIN -frtti
    131    LDLIBS += -ldl
    132    CORELDFLAGS = -dynamic -bind_at_load -L. $(LDFLAGS)
    133    PICLDFLAGS = -fPIC -shared -twolevel_namespace -undefined dynamic_lookup $(LDFLAGS)
    134  @ENDIF
    135  @IFEQ $(SYSTEM) interix
    136 -  CXXFLAGS += -D_ALL_SOURCE -I/usr/local/include
    137 +  MYCXXFLAGS += -D_ALL_SOURCE -I/usr/local/include
    138  @ENDIF
    139  
    140 -@IFNDEF D
    141 -  D=0
    142 +@IFNDEF DEBUGLEVEL
    143 +  DEBUGLEVEL=0
    144  @ENDIF
    145  
    146  GCC6=@GCC6@
    147  @IFEQ $(GCC6) true
    148 -  CXXFLAGS += -fno-delete-null-pointer-checks
    149 +  MYCXXFLAGS += -fno-delete-null-pointer-checks
    150  @ENDIF
    151  
    152  DBGOK=0
    153 -@IFEQ $(D) 0
    154 -  CXXFLAGS += -O2
    155 +@IFEQ $(DEBUGLEVEL) 0
    156 +  MYCXXFLAGS += -O2
    157  @IFEQ $(CC) g++
    158 -    CXXFLAGS += -g1
    159 +    MYCXXFLAGS += -g1
    160  @ENDIF
    161    HEADER = std-header
    162    DBGOK=1
    163  @ENDIF
    164 -@IFEQ $(D) 1
    165 -  CXXFLAGS += -O0 -g3 -Werror
    166 +@IFEQ $(DEBUGLEVEL) 1
    167 +  MYCXXFLAGS += -O0 -g3 -Werror
    168    HEADER = debug-header
    169    DBGOK=1
    170  @ENDIF
    171 -@IFEQ $(D) 2
    172 -  CXXFLAGS += -O2 -g3
    173 +@IFEQ $(DEBUGLEVEL) 2
    174 +  MYCXXFLAGS += -O2 -g3
    175    HEADER = debug-header
    176    DBGOK=1
    177  @ENDIF
    178  FOOTER = finishmessage
    179  
    180 -CXXFLAGS += -Iinclude
    181 +MYCXXFLAGS += -Iinclude
    182  
    183  @GNU_ONLY MAKEFLAGS += --no-print-directory
    184  
    185 @@ -135,10 +135,11 @@ CXXFLAGS += -Iinclude
    186  @ENDIF
    187  
    188  @IFDEF PURE_STATIC
    189 -  CXXFLAGS += -DPURE_STATIC
    190 +  MYCXXFLAGS += -DPURE_STATIC
    191  @ENDIF
    192  
    193 -@DO_EXPORT RUNCC RUNLD CXXFLAGS LDLIBS PICLDFLAGS VERBOSE SOCKETENGINE CORELDFLAGS
    194 +MYCXXFLAGS += $(CXXFLAGS)
    195 +@DO_EXPORT RUNCC RUNLD MYCXXFLAGS LDLIBS PICLDFLAGS VERBOSE SOCKETENGINE CORELDFLAGS
    196  @DO_EXPORT SOURCEPATH BUILDPATH PURE_STATIC SPLIT_CC
    197  
    198  # Default target
    199 @@ -151,10 +152,10 @@ TARGET = all
    200      @GNU_ONLY TARGET = modules/$(M:.so=).so
    201  @ENDIF
    202  
    203 -@IFDEF T
    204 +@IFDEF TGT
    205      HEADER =
    206      FOOTER = target
    207 -    TARGET = $(T)
    208 +    TARGET = $(TGT)
    209  @ENDIF
    210  
    211  @IFEQ $(DBGOK) 0
    212 @@ -229,8 +230,8 @@ install: target
    213  	@-$(INSTALL) -d -o $(INSTUID) -m $(INSTMODE_DIR) $(DATPATH)
    214  	@-$(INSTALL) -d -o $(INSTUID) -m $(INSTMODE_DIR) $(LOGPATH)
    215  	@-$(INSTALL) -d -m $(INSTMODE_DIR) $(BINPATH)
    216 -	@-$(INSTALL) -d -m $(INSTMODE_DIR) $(CONPATH)/examples/aliases
    217 -	@-$(INSTALL) -d -m $(INSTMODE_DIR) $(CONPATH)/examples/modules
    218 +	@-$(INSTALL) -d -m $(INSTMODE_DIR) $(CONPATH)/aliases
    219 +	@-$(INSTALL) -d -m $(INSTMODE_DIR) $(CONPATH)/modules
    220  	@-$(INSTALL) -d -m $(INSTMODE_DIR) $(MODPATH)
    221  	[ "$(BUILDPATH)/bin/" -ef $(BINPATH) ] || $(INSTALL) -m $(INSTMODE_BIN) "$(BUILDPATH)/bin/inspircd" $(BINPATH)
    222  @IFNDEF PURE_STATIC
    223 @@ -238,9 +239,9 @@ install: target
    224  @ENDIF
    225  	-$(INSTALL) -m $(INSTMODE_BIN) @STARTSCRIPT@ $(BASE) 2>/dev/null
    226  	-$(INSTALL) -m $(INSTMODE_LIB) tools/gdbargs $(BASE)/.gdbargs 2>/dev/null
    227 -	-$(INSTALL) -m $(INSTMODE_LIB) docs/conf/*.example $(CONPATH)/examples
    228 -	-$(INSTALL) -m $(INSTMODE_LIB) docs/conf/aliases/*.example $(CONPATH)/examples/aliases
    229 -	-$(INSTALL) -m $(INSTMODE_LIB) docs/conf/modules/*.example $(CONPATH)/examples/modules
    230 +	-$(INSTALL) -m $(INSTMODE_LIB) docs/conf/*.example $(CONPATH)
    231 +	-$(INSTALL) -m $(INSTMODE_LIB) docs/conf/aliases/*.example $(CONPATH)/aliases
    232 +	-$(INSTALL) -m $(INSTMODE_LIB) docs/conf/modules/*.example $(CONPATH)/modules
    233  	@echo ""
    234  	@echo "*************************************"
    235  	@echo "*        INSTALL COMPLETE!          *"
    236 @@ -253,7 +254,7 @@ install: target
    237  	@echo '  Data:' $(DATPATH)
    238  	@echo 'To start the ircd, run:' $(BASE)/inspircd start
    239  	@echo 'Remember to create your config file:' $(CONPATH)/inspircd.conf
    240 -	@echo 'Examples are available at:' $(CONPATH)/examples/
    241 +	@echo 'Examples are available at:' $(CONPATH)
    242  
    243  @GNU_ONLY RCS_FILES = $(wildcard .git/index src/version.sh)
    244  @BSD_ONLY RCS_FILES = src/version.sh
    245 diff --git a/make/unit-cc.pl b/make/unit-cc.pl
    246 index a494fb74b..2a570ec91 100755
    247 --- a/make/unit-cc.pl
    248 +++ b/make/unit-cc.pl
    249 @@ -113,7 +113,7 @@ sub do_compile {
    250  	my $libs = '';
    251  	my $binary = $ENV{RUNCC};
    252  	if ($do_compile) {
    253 -		$flags = $ENV{CXXFLAGS};
    254 +		$flags = $ENV{MYCXXFLAGS};
    255  		$flags =~ s/ -pedantic// if nopedantic($file);
    256  		$flags .= ' ' . getcompilerflags($file);
    257