Here's how you can add lane dividers to roads on your map. There are two things to do: first, you need attributes in the road data stating how many lanes there are, and second, you need to use that information in your style sheet to draw narrow lines on the roads.

Add lane information to the map

You should add an attribute called _lanes to the data. The attribute name starts with an underscore to prevent it being part of the full-text index. For OpenStreetMap data you could create a custom import script (a .makemap file) with this line added to the highway section (shown in context):

<group test='highway'>
        <set_level value='layer'/>
        <if test='@way'>
                <set name='_lanes' value='lanes'/>


Remember, you can create custom import scripts by exporting the script using makemap -writerules >myfile.makemap, then editing the file that was written.

Add the new .makemap file to your makemap command line, before any files it should affect. Example:

makemap lanes.makemap cambridge.osm /project=osgb /urbanareas=yes /extent=0.05,52.16,0.2,52.24

Tell the style sheet to draw the lane dividers

Now add a macro to draw line dividers to your style sheet. Here's an example which handles 2, 3 and 4 lanes:

<macro id='lanes'>
    <condition exp='_lanes==2'>
        <highlight distance='0' fill='~color~' width='0.5m'/>
    <condition exp='_lanes==3'>
        <highlight distance='-16.66%' fill='~color~' width='0.5m'/>
        <highlight distance='16.66%' fill='~color~' width='0.5m'/>
    <condition exp='_lanes==4'>
        <highlight distance='-25%' fill='~color~' width='0.5m'/>
        <highlight distance='0' fill='~color~' width='0.5m'/>
        <highlight distance='25%' fill='~color~' width='0.5m'/>

Use the macro where suitable. For example, you could use it in your motorway style like this:

<condition exp='RoadType == "motorway"'>
    <line border='dimgrey' borderWidth='8%,0.35pt,1pt' fill='orange+0.03black+0.2white' width='12m@6000_100m@75000,0.75pt'/>
    <scale max='75000'>
        <label case='upper' color='dimgrey' duplicate='1000m,256pt' font-size='75%,5pt,18pt' glow='white' glowWidth='7%,0.5pt' labelFormat=';'/>
    <scale max='6000000'>
        <label baseline='central-caps' color='dimgrey+0.25white' condense='no' duplicate='1000m,256pt' font-size='90%,5pt,18pt'
            font-weight='bold' labelFormat='{[padding:20%,0.6pt;background-color:orange+0.5white;border-color:dimgrey+0.25white;border-width:12%,0.7;border-radius:50%,1.2pt}ref{]}'
            wrapLines='0' wrapWidth='30em'/>

    <macro ref='standard-bridge'/>
    <macro ref='standard-tunnel'/>
    <macro ref='lanes' color='darkgrey'/>

Here are some lane dividers drawn using this style.